MPI-parallel distributed array of per-cell Degrees-of-Freedom (conservative variable vectors).
More...
|
| void | setConstant (real R) |
| | Set all DOF entries to a uniform scalar value.
|
| |
| void | setConstant (const Eigen::Ref< const t_element_mat > &R) |
| | Set all DOF entries to copies of a given vector.
|
| |
| void | operator+= (const t_self &R) |
| | Element-wise addition: this[i] += R[i] for every cell.
|
| |
| void | operator-= (const t_self &R) |
| | Element-wise subtraction: this[i] -= R[i] for every cell.
|
| |
| void | operator*= (real R) |
| | Uniform scalar multiplication: this[i] *= R for every cell.
|
| |
| void | operator= (const t_self &R) |
| | Deep copy assignment from another ArrayDOFV.
|
| |
| void | addTo (const t_self &R, real r) |
| | Scaled addition: this[i] += r * R[i] for every cell (axpy-style).
|
| |
| void | operator*= (const std::vector< real > &R) |
| | Per-cell scalar multiplication from a vector of cell-wise weights.
|
| |
| template<int nVarsFixed_T = nVarsFixed> |
| std::enable_if_t<!(nVarsFixed_T==1)> | operator*= (const ArrayDOFV< 1 > &R) |
| | Component-wise multiplication by a scalar-per-cell ArrayDOFV<1>.
|
| |
| void | operator+= (const Eigen::Vector< real, nVarsFixed > &R) |
| | Add a constant vector to every cell: this[i] += R for all cells.
|
| |
| void | operator+= (real R) |
| | Add a scalar to every component of every cell.
|
| |
| void | operator*= (const Eigen::Vector< real, nVarsFixed > &R) |
| | Component-wise multiplication by a constant vector.
|
| |
| void | operator*= (const t_self &R) |
| | Element-wise (Hadamard) multiplication: this[i] = this[i] .* R[i].
|
| |
| void | operator/= (const t_self &R) |
| | Element-wise division: this[i] = this[i] ./ R[i].
|
| |
| real | norm2 () |
| | Compute the global L2 norm across all MPI ranks.
|
| |
| Eigen::Vector< real, nVarsFixed > | componentWiseNorm1 () |
| | Compute the per-component global L1 norm.
|
| |
| Eigen::Vector< real, nVarsFixed > | min () |
| | Compute the global component-wise minimum across all MPI ranks.
|
| |
| real | dot (const t_self &R) |
| | Compute the global dot product <this, R> with MPI reduction.
|
| |
| template<class TMultL , class TMultR > |
| real | dot (const t_self &R, TMultL &&mL, TMultR &&mR) |
| | Compute a weighted global dot product with per-component multipliers.
|
| |
| template<class TR > |
| void | setMaxWith (TR R) |
| | Clamp all components from below: this[i] = max(this[i], R).
|
| |
| template<DeviceBackend B> |
| t_deviceView< B > | deviceView () |
| | Build a mutable device view (wraps the base-class implementation).
|
| |
| template<DeviceBackend B> |
| t_deviceViewConst< B > | deviceView () const |
| | Build a const device view.
|
| |
| void | clone (const t_self &R) |
| | Deep copy from another ArrayDof. Delegates to the base-class clone.
|
| |
| void | setConstant (real R) |
| | Set every entry of every (father+son) row to the scalar R.
|
| |
| void | setConstant (const Eigen::Ref< const t_element_mat > &R) |
| | Set every row to the matrix R (must have shape n_m x n_n).
|
| |
| void | operator+= (const t_self &R) |
| | In-place element-wise add: this += R.
|
| |
| void | operator+= (real R) |
| | Add the scalar R to every entry.
|
| |
| void | operator+= (const Eigen::Ref< const t_element_mat > &R) |
| | Add a per-row matrix R (same to every row).
|
| |
| void | operator-= (const t_self &R) |
| | In-place element-wise subtract: this -= R.
|
| |
| void | operator*= (real R) |
| | Scalar multiply in place.
|
| |
| template<int n_m_T = n_m> |
| std::enable_if_t<!(n_m_T==1 &&n_n==1)> | operator*= (const ArrayDof< 1, 1 > &R) |
| | Scale each row by a corresponding scalar stored in R (a 1x1 ArrayDof).
|
| |
| void | operator*= (const Eigen::Ref< const t_element_mat > &R) |
| | In-place multiplication by a small fixed matrix (same applied to every row).
|
| |
| void | operator*= (const t_self &R) |
| | Element-wise multiply: this *= R (Hadamard).
|
| |
| void | operator/= (const t_self &R) |
| | Element-wise divide: this /= R.
|
| |
| void | operator= (const t_self &R) |
| | Value-copy assignment from another ArrayDof of identical layout.
|
| |
| void | addTo (const t_self &R, real r) |
| | AXPY: this += r * R. One of the hot-path solver primitives.
|
| |
| real | norm2 () |
| | Global L2 norm (MPI-collective). sqrt(sum_i sum_j x_ij^2).
|
| |
| real | norm2 (const t_self &R) |
| | Global L2 distance between this and R (collective).
|
| |
| real | min () |
| | Global minimum across all entries (collective).
|
| |
| real | max () |
| | Global maximum across all entries (collective).
|
| |
| real | sum () |
| | Global sum of all entries (collective).
|
| |
| t_element_mat | componentWiseNorm1 () |
| | Per-component global L1 norm, returned as an n_m x n_n matrix (collective).
|
| |
| t_element_mat | componentWiseNorm1 (const t_self &R) |
| | Per-component global L1 distance between this and R (collective).
|
| |
| real | dot (const t_self &R) |
| | Global inner product: sum_i sum_j x_ij * R_ij (collective).
|
| |
| void | to_device (DeviceBackend backend) |
| | Mirror both father and son to the given device backend.
|
| |
| void | to_host () |
| | Bring both father and son mirrors back to host memory.
|
| |
| void | clone (const t_self &R) |
| | Deep-copy: allocate new father / son and copy their data; rebind trans.
|
| |
| decltype(father->operator[](index(0))) | operator[] (index i) const |
| | Read-only row-pointer access in the combined address space.
|
| |
| decltype(father->operator[](index(0))) | operator[] (index i) |
| | Mutable row-pointer access in the combined address space.
|
| |
| template<class... TOthers> |
| decltype(auto) | operator() (index i, TOthers... aOthers) |
| | N-ary element access in the combined space (mutable). Arguments after the row index are forwarded to the underlying operator().
|
| |
| template<class... TOthers> |
| decltype(auto) | operator() (index i, TOthers... aOthers) const |
| | N-ary element access (const).
|
| |
| template<class TF > |
| auto | runFunctionAppendedIndex (index i, TF &&F) |
| | Invoke F(array, localIndex) on either father or son depending on which range i falls into.
|
| |
| auto | RowSize () const |
| | Uniform row width (delegates to father).
|
| |
| auto | RowSize (index i) const |
| | Per-row width in the combined address space.
|
| |
| void | ResizeRow (index i, rowsize rs) |
| | Resize a single row in the combined address space.
|
| |
| template<class... TOthers> |
| void | ResizeRow (index i, TOthers... aOthers) |
| | Variadic ResizeRow overload that forwards extra args.
|
| |
| index | Size () const |
| | Combined row count (father->Size() + son->Size()).
|
| |
| void | TransAttach () |
| | Bind the transformer to the current father / son pointers.
|
| |
| template<typename... Args> |
| void | InitPair (const std::string &name, Args &&...args) |
| | Allocate both father and son arrays, forwarding all args to TArray constructor.
|
| |
| template<class TPrimaryPair > |
| void | BorrowAndPull (TPrimaryPair &primary) |
| | Attach, borrow ghost indexing from a primary pair, create MPI types, and pull once.
|
| |
| template<class TPrimaryPair > |
| void | BorrowSetup (TPrimaryPair &primary) |
| | Attach, borrow ghost indexing from a primary pair, and create MPI types (no pull).
|
| |
| void | CompressBoth () |
| | Compress both father and son CSR arrays (no-op for non-CSR layouts).
|
| |
| void | CopyFather (t_self &R) |
| | Copy only the father's data from another pair (shallow).
|
| |
| void | SwapDataFatherSon (t_self &R) |
| | Swap both father and son data with another pair of the same type.
|
| |
| std::size_t | hash () |
| | Combined hash across ranks. Used for determinism / equality checks in tests.
|
| |
| void | WriteSerialize (Serializer::SerializerBaseSSP serializerP, const std::string &name, bool includePIG=true, bool includeSon=true) |
| | Writes the ArrayPair (father, optional son, optional ghost mapping).
|
| |
| void | WriteSerialize (Serializer::SerializerBaseSSP serializerP, const std::string &name, const std::vector< index > &origIndex, bool includePIG=true, bool includeSon=true) |
| | Writes the ArrayPair with an origIndex companion dataset for redistribution support.
|
| |
| void | ReadSerialize (Serializer::SerializerBaseSSP serializerP, const std::string &name, bool includePIG=true, bool includeSon=true) |
| | Reads an ArrayPair written by WriteSerialize (same partition count).
|
| |
| void | ReadSerializeRedistributed (Serializer::SerializerBaseSSP serializerP, const std::string &name, const std::vector< index > &newOrigIndex) |
| | Reads ArrayPair data from HDF5 with redistribution support.
|
| |
| template<DeviceBackend B> |
| auto | deviceView () |
| | Produce a mutable device view; both father and son must be allocated.
|
| |
| template<DeviceBackend B> |
| auto | deviceView () const |
| | Produce a const device view.
|
| |
| void | to_device (DeviceBackend backend) |
| | Mirror both father and son to the given device backend.
|
| |
| void | to_host () |
| | Bring both father and son mirrors back to host memory.
|
| |
template<
int nVarsFixed>
class DNDS::Euler::ArrayDOFV< nVarsFixed >
MPI-parallel distributed array of per-cell Degrees-of-Freedom (conservative variable vectors).
Wraps CFV::tUDof<nVarsFixed> (which is ArrayDof<nVarsFixed, 1>), adding element-wise arithmetic operators, norms, dot products, and MPI-collective reductions that operate across all ranks transparently.
Each cell stores a single column vector of nVarsFixed conservative variables (e.g. \([\rho,\; \rho u,\; \rho v,\; \rho w,\; E]\) for a 3D NS model). Instances of this class are used for the solution vector u, the solution increment uInc, the right-hand-side rhs, and other per-cell vector quantities throughout the EulerEvaluator.
The "father" sub-array holds locally-owned cells; the "son" sub-array holds ghost cells received from neighboring MPI ranks. Reduction operations (norm, dot, min) only iterate over father cells and then call MPI_Allreduce for global results.
- Template Parameters
-
| nVarsFixed | Compile-time number of conservative variables per cell, or Eigen::Dynamic for runtime-sized vectors. |
- See also
- ArrayRECV for reconstruction coefficient storage.
-
ArrayGRADV for gradient storage.
Definition at line 92 of file Euler.hpp.