class
#include <src/Inciter/NodeDiagnostics.hpp>
NodeDiagnostics NodeDiagnostics class used to compute diagnostics while integrating PDEs.
Public static functions
- static void registerReducers()
- Configure Charm++ custom reduction types initiated from this class.
Public functions
- auto rhocompute(Discretization& d, const tk::Fields& u, const tk::Fields& un, uint64_t diag_iter) const -> bool
- Compute diagnostics for density-based solvers.
-
auto precompute(Discretization& d,
const tk::Fields& u,
const tk::Fields& un,
const std::vector<tk::
real>& p, const std::vector<tk:: real>& dp, uint64_t diag_iter) const -> bool - Compute diagnostics for pressure-based solvers.
Charm++ pack/unpack serializer member functions
- void pup(PUP::er&)
- Pack/Unpack serialize member function.
- void operator|(PUP::er& p, NodeDiagnostics& d)
- Pack/Unpack serialize operator|.
Function documentation
static void inciter:: NodeDiagnostics:: registerReducers()
Configure Charm++ custom reduction types initiated from this class.
This routine is supposed to be called from a Charm++ initnode routine. Since the runtime system executes initnode routines exactly once on every logical node early on in the Charm++ init sequence, they must be static as they are called without an object. See also: Section "Initializations at Program Startup" at in the Charm++ manual http:/
bool inciter:: NodeDiagnostics:: rhocompute(Discretization& d,
const tk::Fields& u,
const tk::Fields& un,
uint64_t diag_iter) const
Compute diagnostics for density-based solvers.
Parameters | |
---|---|
d in | Discretization proxy to read from |
u in | Current solution vector |
un in | Previous solution vector |
diag_iter in | Diagnostics output frequency |
Returns | True if diagnostics have been computed |
Diagnostics are defined as some norm, e.g., L2 norm, of a quantity, computed in mesh nodes, A, as ||A||_2 = sqrt[ sum_i(A_i)^2 V_i ], where the sum is taken over all mesh nodes and V_i is the nodal volume. We send multiple sets of quantities to the host for aggregation across the whole mesh. The final aggregated solution will end up in Transporter::diagnostics(). Aggregation of the partially computed diagnostics is done via potentially different policies for each field.
bool inciter:: NodeDiagnostics:: precompute(Discretization& d,
const tk::Fields& u,
const tk::Fields& un,
const std::vector<tk:: real>& p,
const std::vector<tk:: real>& dp,
uint64_t diag_iter) const
Compute diagnostics for pressure-based solvers.
Parameters | |
---|---|
d in | Discretization proxy to read from |
u in | Current solution vector |
un in | Previous solution vector |
p in | Current pressure solution |
dp in | Recent pressure solution increment |
diag_iter in | Diagnostics output frequency |
Returns | True if diagnostics have been computed |
Diagnostics are defined as some norm, e.g., L2 norm, of a quantity, computed in mesh nodes, A, as ||A||_2 = sqrt[ sum_i(A_i)^2 V_i ], where the sum is taken over all mesh nodes and V_i is the nodal volume. We send multiple sets of quantities to the host for aggregation across the whole mesh. The final aggregated solution will end up in Transporter::diagnostics(). Aggregation of the partially computed diagnostics is done via potentially different policies for each field.
void inciter:: NodeDiagnostics:: operator|(PUP::er& p,
NodeDiagnostics& d)
Pack/Unpack serialize operator|.
Parameters | |
---|---|
p in/out | Charm++'s PUP::er serializer object reference |
d in/out | Diagnostics object reference |