Skip to content

helpers

Functions:

poly3

poly3(x: float, c0: float, c1: float, c2: float, c3: float) -> float
Source code
14
15
def poly3(x: float, c0: float, c1: float, c2: float, c3: float) -> float:
    return c0 + x * (c1 + x * (c2 + x * c3))

sinc

sinc(x: float) -> float
Source code
10
11
def sinc(x: float) -> float:
    return 1.0 if x == 0.0 else sin(x * pi) / (x * pi)