IBSimu 1.0.4
Public Member Functions | Protected Member Functions | Protected Attributes
Interpolation2D Class Reference

Base class for 2d interpolation. More...

#include <interpolation.hpp>

Inheritance diagram for Interpolation2D:
BiCubicInterpolation2D BiLinearInterpolation2D ClosestInterpolation2D

List of all members.

Public Member Functions

virtual ~Interpolation2D ()
 Virtual destructor.
virtual double operator() (double x, double y) const =0
 Operator for getting interpolation at (x,y).

Protected Member Functions

 Interpolation2D (size_t n, size_t m, const std::vector< double > &f)
 Constructor.
const double & __f (int i, int j) const
double & __f (int i, int j)

Protected Attributes

size_t _n
 Size of first coordinate of mesh.
size_t _m
 Size of second coordinate of mesh.
std::vector< double > _f
 Function data mesh.

Detailed Description

Base class for 2d interpolation.

Provides an interpolation of a function defined at mesh points (x,y), where 0 <= (x,y) <= 1.


Constructor & Destructor Documentation

Interpolation2D::Interpolation2D ( size_t  n,
size_t  m,
const std::vector< double > &  f 
) [protected]

Constructor.

Makes an independent object for interpolation of data. An internal copy of f is created.

virtual Interpolation2D::~Interpolation2D ( ) [inline, virtual]

Virtual destructor.


Member Function Documentation

const double& Interpolation2D::__f ( int  i,
int  j 
) const [protected]
double& Interpolation2D::__f ( int  i,
int  j 
) [protected]
virtual double Interpolation2D::operator() ( double  x,
double  y 
) const [pure virtual]

Operator for getting interpolation at (x,y).

Returns an interpolated value of the function at (x,y), where 0 <= (x,y) <= 1. Returns NaN outside this area.

Implemented in ClosestInterpolation2D, BiLinearInterpolation2D, and BiCubicInterpolation2D.


Member Data Documentation

std::vector<double> Interpolation2D::_f [protected]

Function data mesh.

size_t Interpolation2D::_m [protected]

Size of second coordinate of mesh.

size_t Interpolation2D::_n [protected]

Size of first coordinate of mesh.


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