15 data[
X] = float(v[
X]);
16 data[
Y] = float(v[
Y]);
17 data[
Z] = float(v[
Z]);
43 for (
Size i = 0; i < r.
size(); ++i) {
46 radii[i] = float(r[i][
H]);
53 for (
Size i = 0; i < r.
size(); ++i) {
54 r[i] =
Vector(positions[i]);
60 for (
Size i = 0; i < v.size(); ++i) {
61 v[i] =
Vector(velocities[i]);
uint32_t Size
Integral type used to index arrays (by default).
double Float
Precision used withing the code. Use Float instead of float or double where precision is important.
#define NAMESPACE_SPH_END
@ POSITION
Positions (velocities, accelerations) of particles, always a vector quantity,.
Holder of quantity values and their temporal derivatives.
@ FIRST
Quantity with 1st derivative.
StaticArray< T0 &, sizeof...(TArgs)+1 > tie(T0 &t0, TArgs &... rest)
Creates a static array from a list of l-value references.
Container for storing particle quantities and materials.
BasicVector< Float > Vector
Object providing safe access to continuous memory of data.
INLINE TCounter size() const
void resize(const TCounter newSize)
Resizes the array to new size.
INLINE TCounter size() const noexcept
contains reduced information
CompressedStorage(const Storage &storage)
CompressedStorage()=default
CompressedVector(const Vector &v)
CompressedVector()=default
Container storing all quantities used within the simulations.
Quantity & insert(const QuantityId key, const OrderEnum order, const TValue &defaultValue)
Creates a quantity in the storage, given its key, value type and order.
StaticArray< Array< TValue > &, 3 > getAll(const QuantityId key)
Retrieves quantity buffers from the storage, given its key and value type.
Array< TValue > & getDt(const QuantityId key)
Retrieves a quantity derivative from the storage, given its key and value type.
Object with deleted copy constructor and copy operator.