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 | |
template<unsigned int prp_v, unsigned int prp_g> | |
void | p2m (vector &vd, grid &gd) |
Interpolate particles to mesh. | |
template<unsigned int prp_g, unsigned int prp_v> | |
void | m2p (grid &gd, vector &vd) |
Interpolate mesh to particle. | |
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. | |
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. | |
int | getSub (Point< vector::dims, typename vector::stype > &p) |
Return the sub-domain of the particles. | |
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. | |
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. | |
|
private |
Type of the calculations.
Definition at line 541 of file interpolation.hpp.
|
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 |
Return the sub-domain of the particles.
p | Point to check |
Definition at line 831 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 797 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.
|
private |
Simulation domain.
Definition at line 553 of file interpolation.hpp.
|
private |
grid spacing
Definition at line 550 of file interpolation.hpp.
|
private |
grid
Definition at line 538 of file interpolation.hpp.
|
private |
Cell list used to convert particles position to sub-domain.
Definition at line 506 of file interpolation.hpp.
|
private |
the offset for each sub-sub-domain
Definition at line 544 of file interpolation.hpp.
|
private |
kernel size
Definition at line 547 of file interpolation.hpp.
|
private |
particles
Definition at line 535 of file interpolation.hpp.