Commit dc67afff authored by incardon's avatar incardon

Toward subset

parent bedb4e04
openfpm_numerics @ 8865e41b
Subproject commit 9c7fd13a7b6735c2384430bb96abb1596ec6b6ea
Subproject commit 8865e41b8572cf0a8385562947c1f630dfcfff7c
......@@ -568,6 +568,16 @@ public:
return g_m;
}
/*! \brief return the local size of the vector
*
* \return local size
*
*/
size_t size_local_orig() const
{
return g_m;
}
/*! \brief return the local size of the vector
*
* \return local size
......@@ -632,6 +642,40 @@ public:
return v_pos.template get<0>(vec_key);
}
/*! \brief Get the position of an element
*
* see the vector_dist iterator usage to get an element key
*
* \param vec_key element
*
* \return the position of the element in space
*
*/
inline auto getPosOrig(vect_dist_key_dx vec_key) const -> decltype(v_pos.template get<0>(vec_key.getKey()))
{
#ifdef SE_CLASS3
check_for_pos_nan_inf<prop::max_prop_real,prop::max_prop>(*this,vec_key.getKey());
#endif
return v_pos.template get<0>(vec_key.getKey());
}
/*! \brief Get the position of an element
*
* see the vector_dist iterator usage to get an element key
*
* \param vec_key element
*
* \return the position of the element in space
*
*/
inline auto getPosOrig(size_t vec_key) -> decltype(v_pos.template get<0>(vec_key))
{
#ifdef SE_CLASS3
check_for_pos_nan_inf<prop::max_prop_real,prop::max_prop>(*this,vec_key);
#endif
return v_pos.template get<0>(vec_key);
}
/*! \brief Get the position of an element
*
* see the vector_dist iterator usage to get an element key
......@@ -1031,6 +1075,11 @@ public:
////////////////////////////////////////////////////////////////
vect_dist_key_dx getOriginKey(vect_dist_key_dx vec_key)
{
return vec_key;
}
/*! \brief Construct a cell list symmetric based on a cut of radius
*
* \tparam CellL CellList type to construct
......
......@@ -82,6 +82,16 @@ public:
return g_m;
}
/*! \brief return the local size of the original vector
*
* \return local size
*
*/
size_t size_local_orig() const
{
return vd.size_local();
}
#ifndef ONLY_READWRITE_GETTER
/*! \brief Get the position of an element
......@@ -112,6 +122,34 @@ public:
return vd.getPos(vect_dist_key_dx(pid.template get<0>(vec_key.getKey())));
}
/*! \brief Get the position of an element
*
* see the vector_dist iterator usage to get an element key
*
* \param vec_key element
*
* \return the position of the element in space
*
*/
inline auto getPosOrig(vect_dist_key_dx vec_key) -> decltype(vd.getPos(vec_key))
{
return vd.getPos(vec_key.getKey());
}
/*! \brief Get the position of an element
*
* see the vector_dist iterator usage to get an element key
*
* \param vec_key element
*
* \return the position of the element in space
*
*/
inline auto getPosOrig(vect_dist_key_dx vec_key) const -> decltype(vd.getPos(vec_key))
{
return vd.getPos(vec_key.getKey());
}
/*! \brief Get the property of an element
*
* see the vector_dist iterator usage to get an element key
......@@ -143,6 +181,11 @@ public:
}
vect_dist_key_dx getOriginKey(vect_dist_key_dx vec_key)
{
return vect_dist_key_dx(pid.template get<0>(vec_key.getKey()));
}
#endif
/*! \brief Get an iterator that traverse the particles in the domain
......@@ -176,9 +219,6 @@ public:
if (no_se3 == false)
{se3.getNN();}
#endif
#ifdef SE_CLASS1
check_ghost_compatible_rcut(r_cut);
#endif
// Get ghost and anlarge by 1%
Ghost<dim,St> g = vd.getDecomposition().getGhost();
......@@ -236,7 +276,7 @@ public:
Point<dim,St> pos = getPos(key);
cell_list.add(pos, key.getKey());
cell_list.add(pos,pid.template get<0>(key.getKey()));
++it;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment