OpenFPM  5.2.0
Project that contain the implementation of distributed structures
NNc_array< dim, size, thr > Class Template Reference

Public Member Functions

void set_size (const size_t(&sz)[dim])
 Set the size in each. More...
 
const long int & operator[] (size_t i) const
 return the element i More...
 
long int & operator[] (size_t i)
 return the element i More...
 
void init_full ()
 Initialize the NNc array with full neighborhood cells indexes.
 
void init_sym ()
 Initialize the NNc array with symmetric neighborhood cells indexes.
 
void init_sym_local ()
 Initialize the NNc array with symmetric local neighborhood cells indexes. More...
 
const long int * getPointer () const
 return the pointer to the array More...
 
NNc_array< dim, size, thr > & operator= (const NNc_array< dim, size, thr > &nnc)
 Copy the NNc_array. More...
 
void swap (NNc_array< dim, size, thr > &nnc)
 swap NNc_array More...
 

Private Attributes

long int NNc_arr [size]
 NNc_array.
 
grid_sm< dim, void > gs
 size of the cell array on each dimension
 

Detailed Description

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
class NNc_array< dim, size, thr >

Definition at line 32 of file NNc_array.hpp.

Member Function Documentation

◆ getPointer()

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
const long int* NNc_array< dim, size, thr >::getPointer ( ) const
inline

return the pointer to the array

Returns
the pointer

Definition at line 158 of file NNc_array.hpp.

◆ init_sym_local()

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
void NNc_array< dim, size, thr >::init_sym_local ( )
inline

Initialize the NNc array with symmetric local neighborhood cells indexes.

The neighborhood is the same as with the full iteration scheme to account for interactions with ghost particles in bottom left neighboring cells. In the symmetric case those are completely skipped

Definition at line 148 of file NNc_array.hpp.

◆ operator=()

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
NNc_array<dim,size,thr>& NNc_array< dim, size, thr >::operator= ( const NNc_array< dim, size, thr > &  nnc)
inline

Copy the NNc_array.

Parameters
nncNNc_array to copy

Definition at line 168 of file NNc_array.hpp.

◆ operator[]() [1/2]

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
long int& NNc_array< dim, size, thr >::operator[] ( size_t  i)
inline

return the element i

Returns
element i

Definition at line 67 of file NNc_array.hpp.

◆ operator[]() [2/2]

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
const long int& NNc_array< dim, size, thr >::operator[] ( size_t  i) const
inline

return the element i

Returns
element i

Definition at line 57 of file NNc_array.hpp.

◆ set_size()

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
void NNc_array< dim, size, thr >::set_size ( const size_t(&)  sz[dim])
inline

Set the size in each.

Parameters
szsize og the cell grid in each dimensions

Definition at line 47 of file NNc_array.hpp.

◆ swap()

template<unsigned int dim, unsigned int size, bool thr = as_array_nnc<dim>::type::value>
void NNc_array< dim, size, thr >::swap ( NNc_array< dim, size, thr > &  nnc)
inline

swap NNc_array

Parameters
nncNNc_array to copy

Definition at line 181 of file NNc_array.hpp.


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