Main class for interpolation Particle to mest p2m and Mesh to particle m2p. More...
Main class for interpolation Particle to mest p2m and Mesh to particle m2p.
This function is the main class to interpolate from particle to mesh and mesh to particle
vector | type of vector for interpolation |
grid | type of grid for interpolation |
interpolation | kernel |
Definition at line 503 of file interpolation.hpp.
#include <interpolation.hpp>
Data Structures | |
struct | Box_vol |
Public Member Functions | |
interpolate (vector &vd, grid &gd) | |
construct an interpolation object between a grid and a vector More... | |
template<unsigned int prp_v, unsigned int prp_g> | |
void | p2m (vector &vd, grid &gd) |
Interpolate particles to mesh. More... | |
template<unsigned int prp_g, unsigned int prp_v> | |
void | m2p (grid &gd, vector &vd) |
Interpolate mesh to particle. More... | |
template<unsigned int prp_v, unsigned int prp_g> | |
void | p2m (vector &vd, grid &gd, const vect_dist_key_dx &p) |
Interpolate particles to mesh. More... | |
template<unsigned int prp_g, unsigned int prp_v> | |
void | m2p (grid &gd, vector &vd, const vect_dist_key_dx &p) |
Interpolate mesh to particle. More... | |
Private Types | |
typedef vector::stype | arr_type |
Type of the calculations. | |
Private Member Functions | |
void | calculate_the_offsets (openfpm::vector< agg_arr< openfpm::math::pow(kernel::np, vector::dims)>> &offsets, size_t(&sz)[vector::dims]) |
It calculate the interpolation stencil offsets. More... | |
Private Attributes | |
CellList< vector::dims, typename vector::stype, Mem_fast<>, shift < vector::dims, typename vector::stype > > | geo_cell |
Cell list used to convert particles position to sub-domain. | |
vector & | vd |
particles | |
grid & | gd |
grid | |
openfpm::vector< agg_arr < openfpm::math::pow(kernel::np, vector::dims)> > | offsets |
the offset for each sub-sub-domain | |
size_t | sz [vector::dims] |
kernel size | |
vector::stype | dx [vector::dims] |
grid spacing | |
Box< vector::dims, typename vector::stype > | domain |
Simulation domain. | |
|
inline |
construct an interpolation object between a grid and a vector
When possible and easy to do we suggest to retain the object
vd | interpolation vector |
gd | interpolation grid |
Definition at line 600 of file interpolation.hpp.
|
inlineprivate |
It calculate the interpolation stencil offsets.
offsets | array where to store the linearized offset of the kernel stencil for each local-grid (sub-domain) |
sz | kernel stencil points in each direction |
Definition at line 562 of file interpolation.hpp.
|
inline |
Interpolate mesh to particle.
Most of the time the particle set and the mesh are the same as the one used in the constructor. They also can be different as soon as they have the same decomposition
gd | grid or mesh |
vd | particle set |
Definition at line 708 of file interpolation.hpp.
|
inline |
Interpolate mesh to particle.
Most of the time the particle set and the mesh are the same as the one used in the constructor. They also can be different as soon as they have the same decomposition
gd | grid or mesh |
vd | particle set |
p | particle |
Definition at line 796 of file interpolation.hpp.
|
inline |
Interpolate particles to mesh.
Most of the time the particle set and the mesh are the same as the one used in the constructor. They also can be different as soon as they have the same decomposition
gd | grid or mesh |
vd | particle set |
Definition at line 662 of file interpolation.hpp.
|
inline |
Interpolate particles to mesh.
Most of the time the particle set and the mesh are the same as the one used in the constructor. They also can be different as soon as they have the same decomposition
gd | grid or mesh |
vd | particle set |
p | particle |
Definition at line 758 of file interpolation.hpp.