8#ifndef OPENFPM_NUMERICS_SRC_DRAW_POINTITERATORSKIN_HPP_
9#define OPENFPM_NUMERICS_SRC_DRAW_POINTITERATORSKIN_HPP_
11#include "Grid/Iterators/grid_dist_id_iterator_dec_skin.hpp"
53template<
unsigned int dim,
typename T,
typename Decomposition>
70 for (
size_t i = 0 ; i < dim ; i++)
75 for (
size_t i = 0 ; i < dim ; i++)
77 size_t Ast = std::ceil( (sub_domA.
getLow(i) - dom.
getLow(i)) /
sp[i] ) - 1;
78 size_t Asp = std::floor( (sub_domA.
getHigh(i) - dom.
getLow(i)) /
sp[i] ) + 1;
80 size_t Bst = std::ceil( (sub_domB.
getLow(i) - dom.
getLow(i)) /
sp[i] );
81 size_t Bsp = std::floor( (sub_domB.
getHigh(i) - dom.
getLow(i)) /
sp[i] );
84 Ast = (Ast < Bst)?Bst:Ast;
85 Asp = (Asp > Bsp)?Bsp:Asp;
109 for (
size_t i = 0 ; i < dim ; i++)
146 getAB(sz,
domain,sub_A,sub_B,
sp,RETURN_B), bc),
197 for (
size_t i = 0 ; i < dim; i++)
This class represent an N-dimensional box.
__device__ __host__ T getLow(int i) const
get the i-coordinate of the low bound interval of the box
__device__ __host__ T getHigh(int i) const
get the high interval of the box
__host__ __device__ bool isInside(const Point< dim, T > &p) const
Check if the point is inside the box.
__device__ __host__ void setHigh(int i, T val)
set the high interval of the box
__device__ __host__ void setLow(int i, T val)
set the low interval of the box
This class define the domain decomposition interface.
this class draw particles on subset of grid-like position
openfpm::vector< Box< dim, T > > sub_domainA
sub_domain (required to filter out points)
Box< dim, T > domain
domain
PointIteratorSkin & operator++()
Next point.
PointIteratorSkin(Decomposition &dec, size_t(&sz)[dim], const Box< dim, T > &domain, const Box< dim, T > &sub_A, const Box< dim, T > &sub_B, size_t(&bc)[dim])
Draw Particles.
Point< dim, T > ap
Actual point.
This class implement the point shape in an N-dimensional space.
Given the decomposition it create an iterator.
bool isNext()
Check if there is the next element.
grid_key_dx< Decomposition::dims > get()
Get the actual global key of the grid.
grid_dist_id_iterator_dec_skin< Decomposition > & operator=(const grid_dist_id_iterator_dec_skin< Decomposition > &tmp)
Copy operator=.
grid_dist_id_iterator_dec_skin< Decomposition > & operator++()
Get the next element.
grid_key_dx is the key to access any element in the grid
__device__ __host__ index_type get(index_type i) const
Get the i index.
Implementation of 1-D std::vector like structure.