Spline

Spline — Solve the tridiagonal equation.

Functions

PocPointArray * poc_spline_get_points ()
PocDoubleArray * poc_spline_get_vector ()

Includes

#include <poc.h>

Description

Interpolate a curve based on its control points using an algorithm that solves the tridiagonal equation based on Numerical Recipies 2nd Edition

Functions

poc_spline_get_points ()

PocPointArray *
poc_spline_get_points (PocPointArray *points,
                       gdouble min_x,
                       gdouble max_x,
                       guint veclen);

Compute a vector of veclen points spaced evenly between and including min_x and max_x .

Parameters

points

A PocPointArray of control points.

 

min_x

The lowest (leftmost) X coordinate value.

 

max_x

The highest (rightmost) X coordinate value.

 

veclen

The number or points to be calculated in the result vector.

 

Returns

A PocPointArray of (X,Y) coordinates.

[transfer full]


poc_spline_get_vector ()

PocDoubleArray *
poc_spline_get_vector (PocPointArray *points,
                       gdouble min_x,
                       gdouble max_x,
                       guint veclen);

Compute a vector of veclen Y coordinates spaced evenly between and including min_x and max_x .

Parameters

points

A PocPointArray of control points.

 

min_x

The lowest (leftmost) X coordinate value.

 

max_x

The highest (rightmost) X coordinate value.

 

veclen

The number or points to be calculated in the result vector.

 

Returns

A PocDoubleArray of Y coordinates.

[transfer full]

See Also

PocDatasetSpline