gridripper::math::InterpolationUtil Class Reference

Interpolation related utility methods. More...

#include <InterpolationUtil.h>

List of all members.

Static Public Member Functions

static void resizeLinear (const tvalarray< GReal_t > &xarr, const tvalarray< GReal_t > &data, tvalarray< GReal_t > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor, using linear interpolation.
static void resizeLinear (const tvalarray< int > &xarr, const tvalarray< GReal_t > &data, tvalarray< int > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor, using linear interpolation.
static void resizeCubic (const tvalarray< GReal_t > &xarr, const tvalarray< GReal_t > &data, tvalarray< GReal_t > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor.
static void resizeCubic (const tvalarray< int > &xarr, const tvalarray< GReal_t > &data, tvalarray< int > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor.
static void resizeQuintic (const tvalarray< GReal_t > &xarr, const tvalarray< GReal_t > &data, tvalarray< GReal_t > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor.
static void resizeQuintic (const tvalarray< int > &xarr, const tvalarray< GReal_t > &data, tvalarray< int > &oxarr, tvalarray< GReal_t > &odata) throw (IllegalArgumentException&)
 Resize a data array by an integer factor.
static void cubicCoeff12 (GReal_t x, GReal_t x0, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t *w)
 Calculation of cubic interpolation coefficients for the central interval.
static void quadraticCoeff01 (GReal_t x, GReal_t x0, GReal_t x1, GReal_t x2, GReal_t *w)
 Calculation of quadratic interpolation coefficients for the left interval.
static void quadraticCoeff23 (GReal_t x, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t *w)
 Calculation of quadratic interpolation coefficients for the right interval.
static void quinticCoeff23 (GReal_t x, GReal_t x0, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t x4, GReal_t x5, GReal_t *w)
 Calculation of quintic interpolation coefficients for the central interval.
static void quarticCoeff12 (GReal_t x, GReal_t x0, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t x4, GReal_t *w)
 Calculation of quartic interpolation coefficients for the [x1, x2] interval.
static void quarticCoeff01 (GReal_t x, GReal_t x0, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t x4, GReal_t *w)
 Calculation of quartic interpolation coefficients for the [x0, x1] interval.
static void quarticCoeff34 (GReal_t x, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t x4, GReal_t x5, GReal_t *w)
 Calculation of quartic interpolation coefficients for the [x3, x4] interval.
static void quarticCoeff45 (GReal_t x, GReal_t x1, GReal_t x2, GReal_t x3, GReal_t x4, GReal_t x5, GReal_t *w)
 Calculation of quartic interpolation coefficients for the [x4, x5] interval.


Detailed Description

Interpolation related utility methods.

Version:
0.5, 08/26/2007
Since:
0.5, 08/26/2007
Author:
Andras Laszlo

Member Function Documentation

static void gridripper::math::InterpolationUtil::resizeLinear ( const tvalarray< GReal_t > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< GReal_t > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor, using linear interpolation.

New x coordinates are multiplied by the integer factor.

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::resizeLinear ( const tvalarray< int > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< int > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor, using linear interpolation.

New x coordinates are multiplied by the integer factor (thus the `interpolated' coordinates are also integers).

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::resizeCubic ( const tvalarray< GReal_t > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< GReal_t > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor.

New data points are interpolated with cubic (quadratic near the edges) polynomials. New x coordinates are interpolated linearly and multiplied by the integer factor.

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::resizeCubic ( const tvalarray< int > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< int > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor.

New data points are interpolated with cubic (quadratic near the edges) polynomials. New x coordinates are interpolated linearly and multiplied by the integer factor (thus the resulting coordinates are also integers).

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::resizeQuintic ( const tvalarray< GReal_t > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< GReal_t > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor.

New data points are interpolated with quintic (quartic near the edges) polynomials. New x coordinates are interpolated linearly and multiplied by the integer factor.

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::resizeQuintic ( const tvalarray< int > &  xarr,
const tvalarray< GReal_t > &  data,
tvalarray< int > &  oxarr,
tvalarray< GReal_t > &  odata 
) throw (IllegalArgumentException&) [static]

Resize a data array by an integer factor.

New data points are interpolated with quintic (quartic near the edges) polynomials. New x coordinates are interpolated linearly and multiplied by the integer factor (thus the resulting coordinates are also integers).

Parameters:
xarr array of independent variable values
data array of dependent variable values
oxarr output array of independent variable values
odata output array of dependent variable values

static void gridripper::math::InterpolationUtil::cubicCoeff12 ( GReal_t  x,
GReal_t  x0,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t w 
) [static]

Calculation of cubic interpolation coefficients for the central interval.

The x1 and x2 points and the first derivatives are fixed here. The first derivates are calculated in second order, using the points (x0, x1, x2) and (x1, x2, x3), respectively.

Parameters:
x the x coordinate
x0 first point
x1 second point
x2 third point
x3 fourth point
w output array for the result, its size must be 4

static void gridripper::math::InterpolationUtil::quadraticCoeff01 ( GReal_t  x,
GReal_t  x0,
GReal_t  x1,
GReal_t  x2,
GReal_t w 
) [static]

Calculation of quadratic interpolation coefficients for the left interval.

The x0 and x1 points and the first derivatives are fixed here. The first derivates are calculated in second order.

Parameters:
x the x coordinate
x0 first point
x1 second point
x2 third point
w output array for the result, its size must be at least 3

static void gridripper::math::InterpolationUtil::quadraticCoeff23 ( GReal_t  x,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t w 
) [static]

Calculation of quadratic interpolation coefficients for the right interval.

The x1 and x2 points and the first derivatives are fixed here. The first derivates are calculated in second order.

Parameters:
x the x coordinate
x1 first point
x2 second point
x3 third point
w output array for the result, its size must be at least 3

static void gridripper::math::InterpolationUtil::quinticCoeff23 ( GReal_t  x,
GReal_t  x0,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t  x4,
GReal_t  x5,
GReal_t w 
) [static]

Calculation of quintic interpolation coefficients for the central interval.

The x2 and x3 points, the first and the second derivatives are fixed here. Derivates are calculated in fourth order, using the points (x0, x1, x2, x3, x4) and (x1, x2, x3, x4, x5), respectively.

Parameters:
x the x coordinate
x0 first point
x1 second point
x2 third point
x3 fourth point
x4 fifth point
x5 sixth point
w output array for the result, its size must be 6

static void gridripper::math::InterpolationUtil::quarticCoeff12 ( GReal_t  x,
GReal_t  x0,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t  x4,
GReal_t w 
) [static]

Calculation of quartic interpolation coefficients for the [x1, x2] interval.

The x1 and x2 points, the first and the second derivatives are fixed here. Derivates are calculated in fourth order.

Parameters:
x the x coordinate
x0 first point
x1 second point
x2 third point
x3 fourth point
x4 fifth point
w output array for the result, its size must be at least 5

static void gridripper::math::InterpolationUtil::quarticCoeff01 ( GReal_t  x,
GReal_t  x0,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t  x4,
GReal_t w 
) [static]

Calculation of quartic interpolation coefficients for the [x0, x1] interval.

The x0 and x1 points, the first and the second derivatives are fixed here. Derivates are calculated in fourth order.

Parameters:
x the x coordinate
x0 first point
x1 second point
x2 third point
x3 fourth point
x4 fifth point
w output array for the result, its size must be at least 5

static void gridripper::math::InterpolationUtil::quarticCoeff34 ( GReal_t  x,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t  x4,
GReal_t  x5,
GReal_t w 
) [static]

Calculation of quartic interpolation coefficients for the [x3, x4] interval.

The x3 and x4 points, the first and the second derivatives are fixed here. Derivates are calculated in fourth order.

Parameters:
x the x coordinate
x1 first point
x2 second point
x3 third point
x4 fourth point
x5 fifth point
w output array for the result, its size must be at least 5

static void gridripper::math::InterpolationUtil::quarticCoeff45 ( GReal_t  x,
GReal_t  x1,
GReal_t  x2,
GReal_t  x3,
GReal_t  x4,
GReal_t  x5,
GReal_t w 
) [static]

Calculation of quartic interpolation coefficients for the [x4, x5] interval.

The x4 and x5 points, the first and the second derivatives are fixed here. Derivates are calculated in fourth order.

Parameters:
x the x coordinate
x1 first point
x2 second point
x3 third point
x4 fourth point
x5 fifth point
w output array for the result, its size must be at least 5


The documentation for this class was generated from the following file:

Generated on Wed Jun 17 18:46:55 2009 for GridRipper by  doxygen 1.5.6