Simulation – Nalu Top-level Interface

class Simulation

Realms

Realm is a Nalu abstraction of a set of equations that are solved on a computational domain, reresented by an Exodus-II mesh. A simulation can contain multiple Realms and that can interact via sierra::nalu::Transfer instance. InputOutputRealm is a special type of Realm that exists solely to provide data (input) or extract a subset of data from another Realm.

class Realm

Representation of a computational domain and physics equations solved on this domain.

Subclassed by sierra::nalu::InputOutputRealm

Public Functions

void check_job(bool get_node_count)

check job for fitting in memory

Public Members

stk::mesh::PartVector bcPartVec_

Vector holding side sets that have been registered with the boundary conditions in the input file.

The member is intended to for use in Realm::enforce_bc_on_exposed_faces to check for “exposed surfaces” that might have not been assigned BCs in the input file.

class InputOutputRealm : public sierra::nalu::Realm
class Realms

Time Integration

class TimeIntegrator

Linear Solver Interface

class LinearSystem

Subclassed by sierra::nalu::TpetraLinearSystem

Public Functions

virtual void buildDirichletNodeGraph(const stk::mesh::PartVector&)

Process nodes that belong to Dirichlet-type BC.

virtual void buildDirichletNodeGraph(const std::vector<stk::mesh::Entity>&)

Process nodes as belonging to a Dirichlet-type row.

See the documentation/implementation of sierra::nalu::FixPressureAtNodeAlgorithm for an example of this use case.

virtual void resetRows(std::vector<stk::mesh::Entity> nodeList, const unsigned beginPos, const unsigned endPos) = 0

Reset LHS and RHS for the given set of nodes to 0.

Parameters
  • nodeList: A list of STK node entities whose rows are zeroed out

  • beginPos: Starting index (usually 0)

  • endPos: Terminating index (1 for scalar quantities; nDim for vectors)

class LinearSolver

An abstract representation of a linear solver in Nalu.

Defines the basic API supported by the linear solvers for use within Nalu. See concrete implementations such as sierra::nalu::TpetraLinearSolver for more details.

Subclassed by sierra::nalu::TpetraLinearSolver

Public Functions

virtual PetraType getType() = 0

Type of solver instance as defined in sierra::nalu::PetraType.

virtual void destroyLinearSolver() = 0

Utility method to cleanup solvers during simulation.

bool &recomputePreconditioner()

Flag indicating whether the preconditioner is recomputed on each invocation.

bool &reusePreconditioner()

Flag indicating whether the preconditioner is reused on each invocation.

void zero_timer_precond()

Reset the preconditioner timer to 0.0 for future accumulation.

double get_timer_precond()

Get the preconditioner timer for the last invocation.

bool &activeMueLu()

Flag indicating whether the user has activated MueLU.

LinearSolverConfig *getConfig()

Get the solver configuration specified in the input file.

Public Members

std::string name_

User-friendly identifier for this particular solver instance.

class TpetraLinearSystem : public sierra::nalu::LinearSystem

Public Functions

virtual void resetRows(const std::vector<stk::mesh::Entity> nodeList, const unsigned beginPos, const unsigned endPos)

Reset LHS and RHS for the given set of nodes to 0.

Parameters
  • nodeList: A list of STK node entities whose rows are zeroed out

  • beginPos: Starting index (usually 0)

  • endPos: Terminating index (1 for scalar quantities; nDim for vectors)

Transfers

class Transfer
class Transfers