Interpolation.hpp File Reference

Interpolation between two GridVec s of (different) arbitrary size. More...

#include "MultiIndex.hpp"

Include dependency graph for Interpolation.hpp:

This graph shows which files directly or indirectly include this file:


Functions

template<typename T>
int CellToCoordinates (MultiIndex &cell, Array< int > &size, Array< int > &type, Array< T > &x)
 Calculates the coordinates of the "left lower" corner of a cell.
template<typename T>
int Interpolate (GridVec< T > &gridVec, Array< Array< int > > &types, Array< T > &coord, Array< T > &val)
 Interpolates the vector of grids gridVec at point coord and yields vector val.
template<typename T>
int Interpolate (GridVec< T > &gridVec, Array< int > &type, Array< T > &coord, T &val)
template<typename T>
int Interpolate (MultiVector< T > &grid, Array< int > &type, Array< T > &x, T &val)
 Interpolates the grid at a point coord and yields scalar val.
template<typename T>
int CoordinatesToCell (Array< T > &x, Array< int > &size, Array< int > &type, MultiIndex &cell)
 Finds the cell in which x lies.

Detailed Description

Interpolation between two GridVec s of (different) arbitrary size.

Note:
About the "type" of a grid -1... 2^(n+1)-1 points = 1, 3, 7, 15, 31,... 0... 2^n points = 1, 2, 4, 8, 16,... +1... 2^n+1 points = 2, 3, 5, 9, 17,...
Date:
created 26. 2. 2005

Function Documentation

template<typename T>
int CellToCoordinates ( MultiIndex cell,
Array< int > &  size,
Array< int > &  type,
Array< T > &  x 
) [inline]

Calculates the coordinates of the "left lower" corner of a cell.

template<typename T>
int CoordinatesToCell ( Array< T > &  x,
Array< int > &  size,
Array< int > &  type,
MultiIndex cell 
) [inline]

Finds the cell in which x lies.

template<typename T>
int Interpolate ( MultiVector< T > &  grid,
Array< int > &  type,
Array< T > &  x,
T &  val 
) [inline]

Interpolates the grid at a point coord and yields scalar val.

condition:
dimension of grid is equal to dimension of type and dimension of coord

template<typename T>
int Interpolate ( GridVec< T > &  gridVec,
Array< int > &  type,
Array< T > &  coord,
T &  val 
) [inline]

template<typename T>
int Interpolate ( GridVec< T > &  gridVec,
Array< Array< int > > &  types,
Array< T > &  coord,
Array< T > &  val 
) [inline]

Interpolates the vector of grids gridVec at point coord and yields vector val.

conditions:

  1. size of system is equal to size of types and size of val
  2. dimension of grids is equal to dimension of types and dimension of coord


Generated on Fri Sep 21 12:33:17 2007 for SG2 by  doxygen 1.5.2