8 #ifndef OPENFPM_DATA_SRC_NN_CELLLIST_CELLLISTFAST_GEN_HPP_
9 #define OPENFPM_DATA_SRC_NN_CELLLIST_CELLLISTFAST_GEN_HPP_
13 #include "CellList.hpp"
14 #include "ProcKeys.hpp"
27 template<
unsigned int dim,
29 template <
unsigned int,
typename>
class Prock,
42 Prock<dim,CellList_gen<dim,T,Prock,Mem_type,transform,base>>
SFC;
57 for (
size_t i = 0; i < dim ; i++)
62 size_t a = gs_small.
size(0);
64 for (
size_t i = 1 ; i < dim ; i++)
66 if (a < gs_small.
size(i))
86 SFC.get_hkey(*
this,gk,m);
92 SFC.linearize_hkeys(*
this,m);
108 const Prock<dim,CellList_gen<dim,T,Prock,Mem_type,transform,base>> &
getCellSFC()
const
131 inline typename Prock<dim,CellList_gen<dim,T,Prock,Mem_type,transform,base>>::Pit
getIterator()
135 return typename Prock<dim,CellList_gen<dim,T,Prock,Mem_type,transform,base>>::Pit(*
this);
147 void Initialize(
const Box<dim,T> & box,
const size_t (&div)[dim],
const size_t pad = 1,
size_t slot=STARTING_NSLOT)
160 return SFC.getKeys();
size_t size() const
Return the size of the grid.
void Initialize(CellDecomposer_sm< dim, T, transform > &cd_sm, const Box< dim, T > &dom_box, const size_t pad=1, size_t slot=STARTING_NSLOT)
void init_SFC()
Initialize Space-filling-curve (SFC)
void Initialize(const Box< dim, T > &box, const size_t(&div)[dim], const size_t pad=1, size_t slot=STARTING_NSLOT)
size_t(& getPadding())[dim]
Return the number of padding cells of the Cell decomposer as an array.
void initialize_sfc(size_t pad)
Initialize the space-filling-curve.
Prock< dim, CellList_gen< dim, T, Prock, Mem_type, transform, base > > SFC
const grid_key_dx< dim > & get() const
Get the actual key.
const Prock< dim, CellList_gen< dim, T, Prock, Mem_type, transform, base > > & getCellSFC() const
Get the space filling curve object.
bool isNext()
Check if there is the next element.
This class represent an N-dimensional box.
const openfpm::vector< size_t > & getKeys()
Return cellkeys vector.
Prock< dim, CellList_gen< dim, T, Prock, Mem_type, transform, base > >::Pit getIterator()
return the celllist iterator (across cells)
const grid_sm< dim, void > & getGrid()
Return the underlying grid information of the cell list.
void set_gm(size_t g_m)
Set the ghost marker.
size_t get_gm()
return the ghost marker
Class for FAST cell list implementation.