HyPar  1.0
Finite-Difference Hyperbolic-Parabolic PDE Solver on Cartesian Grids
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
libROM Examples

The following are some examples that use the reduced-order modeling capabilities implemented in the libROM library (https://www.librom.net/). To run them, HyPar needs to be compiled with libROM. Familiarity with using libROM and the mathematical concepts implemented in it is assumed.

Note:

  • In general, any other example or simulation can use the capabilities of libROM by providing the libROM-specific input file (librom.inp).
  • If HyPar is not compiled with libROM, these examples will run as a regular HyPar simulation.

These examples may come with a Python script to plot the solutions from the binary solution file. This script will need the environment variable HYPAR_DIR (/path/to/hypar) to be defined, so make sure this variable exists.

Dynamic Mode Decomposition

Training Examples

The following examples demonstrate training a DMDROMObject using the solutions from a PDE simulation. The same procedure (i.e. providing the libROM input file librom.inp with the appropriate inputs) can be used with any other simulation.

1D Linear Advection - Sine Wave
1D Linear Advection - Discontinuous Waves (Time Windowed DMD)
1D Euler Equations - Sod Shock Tube (Time Windowed DMD)
1D Euler Equations - Shu-Osher Problem (Time Windowed DMD)

2D Euler Equations - Isentropic Vortex Convection
2D Euler Equations - Riemann Problem Case 4 (Time Windowed DMD)
2D Euler Equations (with gravitational force) - Rising Thermal Bubble (Time-Windowed DMD)
2D Euler Equations (with gravitational force) - Inertia-Gravity Waves (Time-Windowed DMD) with PETSc IMEX time integration (Requires PETSc)
2D Navier-Stokes Equations - Lid-Driven Square Cavity (Time-Windowed DMD)
2D (1D-1V) Vlasov Equation - Two-Stream Instability (Time-Windowed DMD)

3D Navier-Stokes - Steady, incompressible, viscous flow around a cylinder (Time-Windowed DMD)
3D Navier-Stokes - Unsteady, incompressible, viscous flow around a cylinder with vortex shedding (Time-Windowed DMD)
3D Navier-Stokes - Inviscid Shock-Cylinder Interaction (Time-Windowed DMD)
3D Navier-Stokes Equations (with gravitational force) - Rising Thermal Bubble (Time-Windowed DMD) with PETSc IMEX time integration (Requires PETSc)

Prediction Examples

The following examples demonstrate using a trained DMDROMObject to compute the solution instead of the discretizing the PDE in space and time. The same steps (i.e. providing the libROM input file librom.inp and trained DMD objects consistent with the computational domain) can be used for any other simulation.

1D Linear Advection - Sine Wave
1D Linear Advection - Discontinuous Waves (Time Windowed DMD)
1D Euler Equations - Sod Shock Tube (Time Windowed DMD)

2D Euler Equations - Isentropic Vortex Convection
2D Navier-Stokes Equations - Lid-Driven Square Cavity (Time-Windowed DMD)
2D (1D-1V) Vlasov Equation - Two-Stream Instability (Time-Windowed DMD)

3D Navier-Stokes - Steady, incompressible, viscous flow around a cylinder (Time-Windowed DMD)
3D Navier-Stokes - Inviscid Shock-Cylinder Interaction (Time-Windowed DMD)