MOOSE Newsletter (February 2022)

Legacy Input Parameter Removal

As announced in November 2021, the legacy input parameter construction method (InputParameters validParams<T>()) is being removed on 1 March 2022 after two years of support. Any remaining templated methods will not compile after this date. For information on how to convert source code to the current input parameter construction method, directions can be found in the original deprecation announcement.

MOOSE Improvements

Thermal Hydraulics Module

The Thermal Hydraulics Module (THM), which serves as the foundation for applications such as RELAP-7 and Sockeye, is now open-source and available as the MOOSE Thermal Hydraulics module. Some key features of this module include:

  • The Components system, which provides a higher-level syntax for assembling simulations. Components create the lower-level MOOSE objects like the mesh, kernels, and boundary conditions. This is particularly well-suited to systems-level applications that primarily operate on 0-D and 1-D components that connect together.

  • The Control logic system provides a similar capability as MOOSE's Controls system but integrates with the Components system.

  • Components using 1D, single-phase flow using the Euler equations, discretized with the finite volume method with the HLLC Riemann solver. These components include flow channels, inlets/outlets, junctions, valves, heating terms, and turbo-machinery such as pumps, compressors, and turbines.

Lagrangian solid mechanics kernels

A new system of solid mechanics kernels are available in the tensor mechanics module. These kernels both duplicate the existing updated Lagrangian formulation used in the current kernels and also add a new option for a total Lagrangian formulation. The main goal of this project was to provide exact large deformation Jacobians without requiring the use of AD to increase the efficiency of running large, finite deformation simulations. The system documentation includes a detailed description of the mathematical theory underlying the kernels as well as information on the new features available along with the kernels themselves.

Some of these new features include:

  • Cartesian versions of a reformulated updated Lagrangian kernel and a new total Lagrangian kernel, both with exact large deformation Jacobians.

  • Stabilization for linear triangular and tetraheadral elements.

  • A new material system, which provides new options for implementing material models, including options for defining material models with alternative stress measures.

  • A new approach for applying an objective integration to constitutive models defined in terms of the small (engineering) stress and strain to "promote" the response of these models to provide a large deformation material response.

  • Partial compatibility with the current MOOSE materials system.

  • A new homogenization subsystem for applying cell-average stress or deformation constraints to periodic domains, useful for homogenizing the response of microstructural representative volume elements.

These changes, put together, should make it easier to run large deformation simulations, including simulations with very large rotations or stretches.

Figure 1: Large stretch and rotations simulation using the Lagrangian kernels.

The Lagrangian kernel system is included in the updated tensor mechanics action so users can switch between the current and Lagrangian kernels systems without significantly changing their input files.

Over time additional features will be added to the Lagrangian kernel system to eventually bring it up to full compatibility with the current kernels. Some features the Lagrangian system currently lacks are:

  • Axisymmetric and spherical coordinates.

  • Generalized plane strain and plane stress formulations.

Automatic differentiation support in MOOSE Functions

Dual number support has been added to the MOOSE Function system. Two overloads now exist for the value() member function.


Real value(Real, Point);
ADReal value(ADReal, ADPoint);

This enables evaluation of functions with dual numbers. As most legacy function do not implement an AD overload of the value() function, the Function base class automatically provides one that uses the non-AD value(), timeDerivative(), and gradient() member functions to construct an AD result. Check out PiecewiseBilinear.C to see how to update a function to support AD by using a templated valueInternal() function with virtual value() forwarders.

Check out BodyForce and CoupledValueFunctionMaterial for applications of this new AD capability.

Additionally the API for the value() and timeDerivative() members has been updated to permit the following usage:


auto r = func.value(t);
auto r = func.value(t, x);
auto r = func.value(t, x, y);
auto r = func.value(t, x, y, z);

This simplifies code that uses function evaluations with custom variables, such as in HeatConductionMaterial, where a function that only depends on temperature can be supplied. The variable temperature takes the place of the first argument (internally designated as "time").

Brayton cycle model demonstrated using the thermal hydraulics module

Examples demonstrating the startup and steady operation of a simple open-Brayton and closed-Brayton cycle were demonstrated using the thermal hydraulics module. This setup consists of 0-D compressor and turbine models, connected via a common shaft, as well as a motor and generator. The examples start from rest and have the motor apply torque in the beginning of the transient. Eventually the compressor and turbine are able to activate, and torque provided by the turbine provides the torque necessary to sustain the compressor without help from the motor, as well as provide excess torque to be applied to a generator for the production of electricity. For more information on these examples, see Brayton Cycle.

Finite volume Navier Stokes incompressible and weakly compressible implementation

The finite volume discretization of the Navier Stokes incompressible and weakly compressible equations was reworked to feature a INSFVRhieChowInterpolator, which handles face interpolations of velocity. The user object gathers all the contributions to the diagonal term in the momentum equation, allowing for performing Rhie Chow interpolation on the face with the maximum amount of information about the contributions of the kernels (diffusion, friction term, ...) to the momentum equations.

This allows other objects to query face-interpolated velocities, from the user object, facilitating future development of boundary conditions, postprocessors, auxiliary kernels and others.

The ReynoldsNumberFunctorAux auxliary kernels and RayleighNumber postprocessor were added to help modelers understand characteristics of the flow they are studying, guiding their physical analysis and helping with decisions about the numerical scheme.

Bug Fixes and Minor Enhancements

  • Additional documentation was released describing every kind of testers used by the MOOSE test suite

  • Missing documentation for the LibmeshPartitioner and for how to perform a field split using preconditioning, see the FSP, was added

  • Changes to MooseDocs parameter descriptions generated by !syntax parameters and other similar commands:

    • Removed empty "Options" fields, i.e., for parameter types that do not inherit from MooseEnumBase

    • Added a "Controllable" field indicating "Yes" if a parameter is controllable or "No" otherwise