8 #ifndef SRC_GRID_ITERATORS_GRID_DIST_ID_ITERATOR_UTIL_HPP_
9 #define SRC_GRID_ITERATORS_GRID_DIST_ID_ITERATOR_UTIL_HPP_
27 for (
size_t i = 0 ; i < Decomposition::dims ; i++)
29 long int start_p = gdb_ext.get(g_c).Dbox.getP1().get(i) + gdb_ext.get(g_c).origin.get(i);
30 long int stop_p = gdb_ext.get(g_c).Dbox.getP2().get(i) + gdb_ext.get(g_c).origin.get(i);
31 if (start.
get(i) <= start_p)
32 start_c.
set_d(i,gdb_ext.get(g_c).Dbox.getP1().get(i));
33 else if (start.
get(i) <= stop_p)
34 start_c.
set_d(i,start.
get(i) - gdb_ext.get(g_c).origin.get(i));
38 if (stop.
get(i) >= stop_p)
39 stop_c.
set_d(i,gdb_ext.get(g_c).Dbox.getP2().get(i));
40 else if (stop.
get(i) >= start_p)
41 stop_c.
set_d(i,stop.
get(i) - gdb_ext.get(g_c).origin.get(i));
mem_id get(size_t i) const
Get the i index.
This structure store the Box that define the domain inside the Ghost + domain box.
void set_d(size_t i, mem_id id)
Set the i index.
Implementation of 1-D std::vector like structure.