Table of contents Index

class CubicSpline - General Cubic Spline class.

Declared in module PySplines.CubicSplines

Inheritance hierarchy:

PySplines.CubicSplines.CubicSpline
  bhoelHelper.CheckArgs.CheckArgs

Synopsis

class CubicSpline(CheckArgs):
    def __call__(self, *data, **kw)
    def __init__(self, *data, **kw)
    def _ret_b(self)
    def _ret_c(self)
    def _ret_d(self)
    def _ret_h(self)
    def evaluate(self, val)
    def intersect(self, norm, dist)

    # Inherited from bhoelHelper.CheckArgs.CheckArgs
    def __init__(self, data, kw)

tuple default = (('nodes', None), ('first', <PySplines.CubicSplines.NaturalA instance at 8165248>), ('second', None))
int minNodes = 2
None period = None

Description

General Cubic Spline class. Constructor takes a list of tabulated values and two boundary condition, one for either side of the defined range (Only one in case of periodic splines). The class instance has a __call__ method which take a single of an array of values and calculates the values of the interpolated function.

The interpolating spline in the n'th intervall is calculated by

y = a_n + b_n (x - x_n) + c_n (x - x_n)**2 + d_n (x - x_n)**3

intersect(self, norm, dist)

None

Retruns a list of intersections


Author: Berthold H\366llmann
Version: 1.7