1ccaff030SJeremy L Thompson## libCEED: Navier-Stokes Example 2ccaff030SJeremy L Thompson 3ccaff030SJeremy L ThompsonThis page provides a description of the Navier-Stokes example for the libCEED library, based on PETSc. 4b8962995SJeremy L ThompsonPETSc v3.17 or a development version of PETSc at commit 0e95d842 or later is required. 5ccaff030SJeremy L Thompson 677841947SLeila GhaffariThe Navier-Stokes problem solves the compressible Navier-Stokes equations in three dimensions using an explicit time integration. 777841947SLeila GhaffariThe state variables are mass density, momentum density, and energy density. 8ccaff030SJeremy L Thompson 977841947SLeila GhaffariThe main Navier-Stokes solver for libCEED is defined in [`navierstokes.c`](navierstokes.c) with different problem definitions according to the application of interest. 10ccaff030SJeremy L Thompson 113b219b86SJames Wright## Build instructions 123b219b86SJames Wright 13bc7bbd5dSLeila GhaffariBuild by using: 14ccaff030SJeremy L Thompson 15ccaff030SJeremy L Thompson`make` 16ccaff030SJeremy L Thompson 17bc7bbd5dSLeila Ghaffariand run with: 18ccaff030SJeremy L Thompson 19bc7bbd5dSLeila Ghaffari``` 20bc7bbd5dSLeila Ghaffari./navierstokes -ceed [ceed] -problem [problem type] -degree [degree] 21bc7bbd5dSLeila Ghaffari``` 22ccaff030SJeremy L Thompson 233b219b86SJames WrightIf you want to do *in situ* machine-learning training, specify `SMARTREDIS_DIR` in the make command like: 243b219b86SJames Wright 253b219b86SJames Wright``` 263b219b86SJames Wrightmake SMARTREDIS_DIR=~/software/smartredis/install 273b219b86SJames Wright``` 283b219b86SJames Wright 29bc7bbd5dSLeila Ghaffari## Runtime options 30ccaff030SJeremy L Thompson 31bc7bbd5dSLeila Ghaffari% inclusion-fluids-marker 32ccaff030SJeremy L Thompson 33bc7bbd5dSLeila GhaffariThe Navier-Stokes mini-app is controlled via command-line options. 34bc7bbd5dSLeila GhaffariThe following options are common among all problem types: 35ccaff030SJeremy L Thompson 36bc7bbd5dSLeila Ghaffari:::{list-table} Common Runtime Options 37bc7bbd5dSLeila Ghaffari:header-rows: 1 38ccaff030SJeremy L Thompson 39bc7bbd5dSLeila Ghaffari* - Option 40bc7bbd5dSLeila Ghaffari - Description 41bc7bbd5dSLeila Ghaffari - Default value 42ccaff030SJeremy L Thompson 43bc7bbd5dSLeila Ghaffari* - `-ceed` 44bc7bbd5dSLeila Ghaffari - CEED resource specifier 45bc7bbd5dSLeila Ghaffari - `/cpu/self/opt/blocked` 46ccaff030SJeremy L Thompson 473866774cSJames Wright* - `-test_type` 483866774cSJames Wright - Run in test mode and specify whether solution (`solver`) or turbulent statistics (`turb_spanstats`) output should be verified 493866774cSJames Wright - `none` 50ccaff030SJeremy L Thompson 51bc7bbd5dSLeila Ghaffari* - `-compare_final_state_atol` 52bc7bbd5dSLeila Ghaffari - Test absolute tolerance 53bc7bbd5dSLeila Ghaffari - `1E-11` 54ccaff030SJeremy L Thompson 55bc7bbd5dSLeila Ghaffari* - `-compare_final_state_filename` 56bc7bbd5dSLeila Ghaffari - Test filename 57bc7bbd5dSLeila Ghaffari - 58ccaff030SJeremy L Thompson 59bc7bbd5dSLeila Ghaffari* - `-problem` 609e576805SJames Wright - Problem to solve (`advection`, `advection2d`, `density_current`, `euler_vortex`, `shocktube`, `blasius`, `channel`, `gaussian_wave`, and `taylor_green`) 61bc7bbd5dSLeila Ghaffari - `density_current` 62ccaff030SJeremy L Thompson 63bc7bbd5dSLeila Ghaffari* - `-implicit` 649e576805SJames Wright - Use implicit time integrator formulation 65bc7bbd5dSLeila Ghaffari - 66ccaff030SJeremy L Thompson 67bc7bbd5dSLeila Ghaffari* - `-degree` 68bc7bbd5dSLeila Ghaffari - Polynomial degree of tensor product basis (must be >= 1) 69bc7bbd5dSLeila Ghaffari - `1` 70ccaff030SJeremy L Thompson 712288fb52SJeremy L Thompson* - `-q_extra` 72bc7bbd5dSLeila Ghaffari - Number of extra quadrature points 73fc14f3f6SLeila Ghaffari - `0` 74ccaff030SJeremy L Thompson 7537cbb16aSJed Brown* - `-ts_monitor_solution` 7637cbb16aSJed Brown - PETSc output format, such as `cgns:output-%d.cgns` (requires PETSc `--download-cgns`) 7737cbb16aSJed Brown - 78ccaff030SJeremy L Thompson 7937cbb16aSJed Brown* - `-ts_monitor_solution_interval` 8037cbb16aSJed Brown - Number of time steps between visualization output frames. 8137cbb16aSJed Brown - `1` 8237cbb16aSJed Brown 8337cbb16aSJed Brown* - `-viewer_cgns_batch_size` 8437cbb16aSJed Brown - Number of frames written per CGNS file if the CGNS file name includes a format specifier (`%d`). 8537cbb16aSJed Brown - `20` 8637cbb16aSJed Brown 8737cbb16aSJed Brown* - `-checkpoint_interval` 8837cbb16aSJed Brown - Number of steps between writing binary checkpoints. `0` has no output, `-1` outputs final state only 89bc7bbd5dSLeila Ghaffari - `10` 90ccaff030SJeremy L Thompson 9137cbb16aSJed Brown* - `-checkpoint_vtk` 9237cbb16aSJed Brown - Checkpoints include VTK (`*.vtu`) files for visualization. Consider `-ts_monitor_solution`instead. 9337cbb16aSJed Brown - `false` 9437cbb16aSJed Brown 9537cbb16aSJed Brown* - `-viz_refine` 9637cbb16aSJed Brown - Use regular refinement for VTK visualization 9737cbb16aSJed Brown - `0` 9837cbb16aSJed Brown 99bc7bbd5dSLeila Ghaffari* - `-output_dir` 10037cbb16aSJed Brown - Output directory for binary checkpoints and VTK files (if enabled). 101bc7bbd5dSLeila Ghaffari - `.` 102ccaff030SJeremy L Thompson 10369293791SJames Wright* - `-output_add_stepnum2bin` 10469293791SJames Wright - Whether to add step numbers to output binary files 10569293791SJames Wright - `false` 10669293791SJames Wright 10769293791SJames Wright* - `-continue` 10869293791SJames Wright - Continue from previous solution (input is step number of previous solution) 10969293791SJames Wright - `0` 11069293791SJames Wright 11169293791SJames Wright* - `-continue_filename` 11269293791SJames Wright - Path to solution binary file from which to continue from 11369293791SJames Wright - `[output_dir]/ns-solution.bin` 11469293791SJames Wright 11569293791SJames Wright* - `-continue_time_filename` 1164de8550aSJed Brown - Path to time stamp binary file (only for legacy checkpoints) 11769293791SJames Wright - `[output_dir]/ns-time.bin` 11869293791SJames Wright 1194534a52eSLeila Ghaffari* - `-bc_wall` 1204534a52eSLeila Ghaffari - Use wall boundary conditions on this list of faces 1214534a52eSLeila Ghaffari - 1224534a52eSLeila Ghaffari 1234534a52eSLeila Ghaffari* - `-wall_comps` 1244534a52eSLeila Ghaffari - An array of constrained component numbers for wall BCs 1254534a52eSLeila Ghaffari - 1264534a52eSLeila Ghaffari 1274534a52eSLeila Ghaffari* - `-bc_slip_x` 1284534a52eSLeila Ghaffari - Use slip boundary conditions, for the x component, on this list of faces 1294534a52eSLeila Ghaffari - 1304534a52eSLeila Ghaffari 1314534a52eSLeila Ghaffari* - `-bc_slip_y` 1324534a52eSLeila Ghaffari - Use slip boundary conditions, for the y component, on this list of faces 1334534a52eSLeila Ghaffari - 1344534a52eSLeila Ghaffari 1354534a52eSLeila Ghaffari* - `-bc_slip_z` 1364534a52eSLeila Ghaffari - Use slip boundary conditions, for the z component, on this list of faces 1374534a52eSLeila Ghaffari - 1384534a52eSLeila Ghaffari 1394534a52eSLeila Ghaffari* - `-bc_inflow` 1404534a52eSLeila Ghaffari - Use inflow boundary conditions on this list of faces 1414534a52eSLeila Ghaffari - 1424534a52eSLeila Ghaffari 1434534a52eSLeila Ghaffari* - `-bc_outflow` 1444534a52eSLeila Ghaffari - Use outflow boundary conditions on this list of faces 1454534a52eSLeila Ghaffari - 14689d0f5c0SLeila Ghaffari 1477ec884f8SJames Wright* - `-bc_freestream` 1487ec884f8SJames Wright - Use freestream boundary conditions on this list of faces 1497ec884f8SJames Wright - 1507ec884f8SJames Wright 151b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_collect_interval` 152ee3de563SJames Wright - Number of timesteps between statistics collection 153ee3de563SJames Wright - `1` 154ee3de563SJames Wright 155b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer` 156b7d66439SJames Wright - Sets the PetscViewer for the statistics file writing, such as `cgns:output-%d.cgns` (requires PETSc `--download-cgns`). Also turns the statistics collection on. 1578ed52730SJames Wright - 1588ed52730SJames Wright 159b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer_interval` 160ee3de563SJames Wright - Number of timesteps between statistics file writing (`-1` means only at end of run) 161ee3de563SJames Wright - `-1` 162ee3de563SJames Wright 163b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer_cgns_batch_size` 1648ed52730SJames Wright - Number of frames written per CGNS file if the CGNS file name includes a format specifier (`%d`). 1658ed52730SJames Wright - `20` 1668ed52730SJames Wright 167ca69d878SAdeleke O. Bankole* - `-ts_monitor_wall_force` 168ca69d878SAdeleke O. Bankole - Viewer for the force on each no-slip wall, e.g., `ascii:force.csv:ascii_csv` to write a CSV file. 169ca69d878SAdeleke O. Bankole - 170ca69d878SAdeleke O. Bankole 1712526956eSJames Wright* - `-mesh_transform` 1722526956eSJames Wright - Transform the mesh, usually for an initial box mesh. 1732526956eSJames Wright - `none` 1742526956eSJames Wright 175bc7bbd5dSLeila Ghaffari* - `-snes_view` 176bc7bbd5dSLeila Ghaffari - View PETSc `SNES` nonlinear solver configuration 177bc7bbd5dSLeila Ghaffari - 17889d0f5c0SLeila Ghaffari 179bc7bbd5dSLeila Ghaffari* - `-log_view` 180bc7bbd5dSLeila Ghaffari - View PETSc performance log 181bc7bbd5dSLeila Ghaffari - 182ccaff030SJeremy L Thompson 183bc7bbd5dSLeila Ghaffari* - `-help` 184bc7bbd5dSLeila Ghaffari - View comprehensive information about run-time options 185bc7bbd5dSLeila Ghaffari - 186bc7bbd5dSLeila Ghaffari::: 187ccaff030SJeremy L Thompson 1887ec884f8SJames WrightFor the case of a square/cubic mesh, the list of face indices to be used with `-bc_wall`, `bc_inflow`, `bc_outflow`, `bc_freestream` and/or `-bc_slip_x`, `-bc_slip_y`, and `-bc_slip_z` are: 1894534a52eSLeila Ghaffari 19088626eedSJames Wright:::{list-table} 2D Face ID Labels 19188626eedSJames Wright:header-rows: 1 19288626eedSJames Wright* - PETSc Face Name 19388626eedSJames Wright - Cartesian direction 19488626eedSJames Wright - Face ID 19588626eedSJames Wright 19688626eedSJames Wright* - faceMarkerBottom 19788626eedSJames Wright - -z 19888626eedSJames Wright - 1 19988626eedSJames Wright 20088626eedSJames Wright* - faceMarkerRight 20188626eedSJames Wright - +x 20288626eedSJames Wright - 2 20388626eedSJames Wright 20488626eedSJames Wright* - faceMarkerTop 20588626eedSJames Wright - +z 20688626eedSJames Wright - 3 20788626eedSJames Wright 20888626eedSJames Wright* - faceMarkerLeft 20988626eedSJames Wright - -x 21088626eedSJames Wright - 4 21188626eedSJames Wright::: 21288626eedSJames Wright 213b5e826a6SLeila Ghaffari:::{list-table} 3D Face ID Labels 21488626eedSJames Wright:header-rows: 1 21588626eedSJames Wright* - PETSc Face Name 21688626eedSJames Wright - Cartesian direction 21788626eedSJames Wright - Face ID 21888626eedSJames Wright 21988626eedSJames Wright* - faceMarkerBottom 22088626eedSJames Wright - -z 22188626eedSJames Wright - 1 22288626eedSJames Wright 22388626eedSJames Wright* - faceMarkerTop 22488626eedSJames Wright - +z 22588626eedSJames Wright - 2 22688626eedSJames Wright 22788626eedSJames Wright* - faceMarkerFront 22888626eedSJames Wright - -y 22988626eedSJames Wright - 3 23088626eedSJames Wright 23188626eedSJames Wright* - faceMarkerBack 23288626eedSJames Wright - +y 23388626eedSJames Wright - 4 23488626eedSJames Wright 23588626eedSJames Wright* - faceMarkerRight 23688626eedSJames Wright - +x 23788626eedSJames Wright - 5 23888626eedSJames Wright 23988626eedSJames Wright* - faceMarkerLeft 24088626eedSJames Wright - -x 24188626eedSJames Wright - 6 24288626eedSJames Wright::: 2434534a52eSLeila Ghaffari 2448a94a473SJed Brown### Boundary conditions 2458a94a473SJed Brown 2463b219b86SJames WrightBoundary conditions for compressible viscous flows are notoriously tricky. 2473b219b86SJames WrightHere we offer some recommendations. 2488a94a473SJed Brown 2498a94a473SJed Brown#### Inflow 2508a94a473SJed Brown 2518a94a473SJed BrownIf in a region where the flow velocity is known (e.g., away from viscous walls), use `bc_freestream`, which solves a Riemann problem and can handle inflow and outflow (simultaneously and dynamically). 2528a94a473SJed BrownIt is stable and the least reflective boundary condition for acoustics. 2538a94a473SJed Brown 2548a94a473SJed BrownIf near a viscous wall, you may want a specified inflow profile. 2558a94a473SJed BrownUse `bc_inflow` and see {ref}`example-blasius` and discussion of synthetic turbulence generation for ways to analytically generate developed inflow profiles. 2568a94a473SJed BrownThese conditions may be either weak or strong, with the latter specifying velocity and temperature as essential boundary conditions and evaluating a boundary integral for the mass flux. 2578a94a473SJed BrownThe strong approach gives sharper resolution of velocity structures. 2588a94a473SJed BrownWe have described the primitive variable formulation here; the conservative variants are similar, but not equivalent. 2598a94a473SJed Brown 260f3f66076SJames Wright#### Outflow 2618a94a473SJed Brown 2628a94a473SJed BrownIf you know the complete exterior state, `bc_freestream` is the least reflective boundary condition, but is disruptive to viscous flow structures. 2638a94a473SJed BrownIf thermal anomalies must exit the domain, the Riemann solver must resolve the contact wave to avoid reflections. 2648a94a473SJed BrownThe default Riemann solver, HLLC, is sufficient in this regard while the simpler HLL converts thermal structures exiting the domain into grid-scale reflecting acoustics. 2658a94a473SJed Brown 2668a94a473SJed BrownIf acoustic reflections are not a concern and/or the flow is impacted by walls or interior structures that you wish to resolve to near the boundary, choose `bc_outflow`. This condition (with default `outflow_type: riemann`) is stable for both inflow and outflow, so can be used in areas that have recirculation and lateral boundaries in which the flow fluctuates. 2678a94a473SJed Brown 2688a94a473SJed BrownThe simpler `bc_outflow` variant, `outflow_type: pressure`, requires that the flow be a strict outflow (or the problem becomes ill-posed and the solver will diverge). 2698a94a473SJed BrownIn our experience, `riemann` is slightly less reflective but produces similar flows in cases of strict outflow. 2708a94a473SJed BrownThe `pressure` variant is retained to facilitate comparison with other codes, such as PHASTA-C, but we recommend `riemann` for general use. 2718a94a473SJed Brown 272f3f66076SJames Wright#### Periodicity 2738a94a473SJed Brown 2748a94a473SJed BrownPETSc provides two ways to specify periodicity: 2758a94a473SJed Brown 2768a94a473SJed Brown1. Topological periodicity, in which the donor and receiver dofs are the same, obtained using: 2778a94a473SJed Brown 2788a94a473SJed Brown```yaml 2798a94a473SJed Browndm_plex: 2808a94a473SJed Brown shape: box 2818a94a473SJed Brown box_faces: 10,12,4 2828a94a473SJed Brown box_bd: none,none,periodic 2838a94a473SJed Brown``` 2848a94a473SJed Brown 285ca69d878SAdeleke O. BankoleThe coordinates for such cases are stored as a new field with special cell-based indexing to enable wrapping through the boundary. 286ca69d878SAdeleke O. BankoleThis choice of coordinates prevents evaluating boundary integrals that cross the periodicity, such as for the outflow Riemann problem in the presence of spanwise periodicity. 287ca69d878SAdeleke O. Bankole 288ca69d878SAdeleke O. Bankole2. Isoperiodicity, in which the donor and receiver dofs are distinct in local vectors. This is obtained using `zbox`, as in: 289ca69d878SAdeleke O. Bankole 290ca69d878SAdeleke O. Bankole```yaml 291ca69d878SAdeleke O. Bankoledm_plex: 292ca69d878SAdeleke O. Bankole shape: zbox 293ca69d878SAdeleke O. Bankole box_faces: 10,12,4 294ca69d878SAdeleke O. Bankole box_bd: none,none,periodic 295ca69d878SAdeleke O. Bankole``` 296ca69d878SAdeleke O. Bankole 297ca69d878SAdeleke O. BankoleIsoperiodicity enables standard boundary integrals, and is recommended for general use. 298ca69d878SAdeleke O. BankoleAt the time of this writing, it only supports one direction of periodicity. 299ca69d878SAdeleke O. BankoleThe `zbox` method uses [Z-ordering](https://en.wikipedia.org/wiki/Z-order_curve) to construct the mesh in parallel and provide an adequate initial partition, which makes it higher performance and avoids needing a partitioning package. 3008a94a473SJed Brown 301019b7682STimothy Aiken### Advection 302019b7682STimothy Aiken 30317be3a41SJeremy L ThompsonFor testing purposes, there is a reduced mode for pure advection, which holds density $\rho$ and momentum density $\rho \bm u$ constant while advecting "total energy density" $E$. 30417be3a41SJeremy L ThompsonThese are available in 2D and 3D. 305019b7682STimothy Aiken 306019b7682STimothy Aiken#### 2D advection 307019b7682STimothy Aiken 308bc7bbd5dSLeila GhaffariFor the 2D advection problem, the following additional command-line options are available: 309ccaff030SJeremy L Thompson 310bc7bbd5dSLeila Ghaffari:::{list-table} Advection2D Runtime Options 311bc7bbd5dSLeila Ghaffari:header-rows: 1 31289d0f5c0SLeila Ghaffari 313bc7bbd5dSLeila Ghaffari* - Option 314bc7bbd5dSLeila Ghaffari - Description 315bc7bbd5dSLeila Ghaffari - Default value 316bc7bbd5dSLeila Ghaffari - Unit 31789d0f5c0SLeila Ghaffari 318bc7bbd5dSLeila Ghaffari* - `-rc` 319bc7bbd5dSLeila Ghaffari - Characteristic radius of thermal bubble 320bc7bbd5dSLeila Ghaffari - `1000` 321bc7bbd5dSLeila Ghaffari - `m` 32289d0f5c0SLeila Ghaffari 323bc7bbd5dSLeila Ghaffari* - `-units_meter` 324bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 325bc7bbd5dSLeila Ghaffari - `1E-2` 326bc7bbd5dSLeila Ghaffari - 32789d0f5c0SLeila Ghaffari 328bc7bbd5dSLeila Ghaffari* - `-units_second` 329bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 330bc7bbd5dSLeila Ghaffari - `1E-2` 331bc7bbd5dSLeila Ghaffari - 33289d0f5c0SLeila Ghaffari 333bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 334bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 335bc7bbd5dSLeila Ghaffari - `1E-6` 336bc7bbd5dSLeila Ghaffari - 33777841947SLeila Ghaffari 338bc7bbd5dSLeila Ghaffari* - `-strong_form` 339bc7bbd5dSLeila Ghaffari - Strong (1) or weak/integrated by parts (0) residual 340bc7bbd5dSLeila Ghaffari - `0` 341bc7bbd5dSLeila Ghaffari - 34277841947SLeila Ghaffari 343bc7bbd5dSLeila Ghaffari* - `-stab` 344bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 345bc7bbd5dSLeila Ghaffari - `none` 346bc7bbd5dSLeila Ghaffari - 34777841947SLeila Ghaffari 348bc7bbd5dSLeila Ghaffari* - `-CtauS` 349bc7bbd5dSLeila Ghaffari - Scale coefficient for stabilization tau (nondimensional) 350bc7bbd5dSLeila Ghaffari - `0` 351bc7bbd5dSLeila Ghaffari - 35277841947SLeila Ghaffari 353bc7bbd5dSLeila Ghaffari* - `-wind_type` 354bc7bbd5dSLeila Ghaffari - Wind type in Advection (`rotation` or `translation`) 355bc7bbd5dSLeila Ghaffari - `rotation` 356bc7bbd5dSLeila Ghaffari - 35777841947SLeila Ghaffari 358bc7bbd5dSLeila Ghaffari* - `-wind_translation` 359bc7bbd5dSLeila Ghaffari - Constant wind vector when `-wind_type translation` 360bc7bbd5dSLeila Ghaffari - `1,0,0` 361bc7bbd5dSLeila Ghaffari - 36289d0f5c0SLeila Ghaffari 363bc7bbd5dSLeila Ghaffari* - `-E_wind` 364bc7bbd5dSLeila Ghaffari - Total energy of inflow wind when `-wind_type translation` 365bc7bbd5dSLeila Ghaffari - `1E6` 366bc7bbd5dSLeila Ghaffari - `J` 367bc7bbd5dSLeila Ghaffari::: 368e43605a5SLeila Ghaffari 369bc7bbd5dSLeila GhaffariAn example of the `rotation` mode can be run with: 370e43605a5SLeila Ghaffari 371bc7bbd5dSLeila Ghaffari``` 3724534a52eSLeila Ghaffari./navierstokes -problem advection2d -dm_plex_box_faces 20,20 -dm_plex_box_lower 0,0 -dm_plex_box_upper 1000,1000 -bc_wall 1,2,3,4 -wall_comps 4 -wind_type rotation -implicit -stab supg 373bc7bbd5dSLeila Ghaffari``` 374e43605a5SLeila Ghaffari 375bc7bbd5dSLeila Ghaffariand the `translation` mode with: 376e43605a5SLeila Ghaffari 377bc7bbd5dSLeila Ghaffari``` 3784534a52eSLeila Ghaffari./navierstokes -problem advection2d -dm_plex_box_faces 20,20 -dm_plex_box_lower 0,0 -dm_plex_box_upper 1000,1000 -units_meter 1e-4 -wind_type translation -wind_translation 1,-.5 -bc_inflow 1,2,3,4 379bc7bbd5dSLeila Ghaffari``` 3804534a52eSLeila GhaffariNote the lengths in `-dm_plex_box_upper` are given in meters, and will be nondimensionalized according to `-units_meter`. 381e43605a5SLeila Ghaffari 382019b7682STimothy Aiken#### 3D advection 383019b7682STimothy Aiken 384bc7bbd5dSLeila GhaffariFor the 3D advection problem, the following additional command-line options are available: 385e43605a5SLeila Ghaffari 386bc7bbd5dSLeila Ghaffari:::{list-table} Advection3D Runtime Options 387bc7bbd5dSLeila Ghaffari:header-rows: 1 388e43605a5SLeila Ghaffari 389bc7bbd5dSLeila Ghaffari* - Option 390bc7bbd5dSLeila Ghaffari - Description 391bc7bbd5dSLeila Ghaffari - Default value 392bc7bbd5dSLeila Ghaffari - Unit 393e43605a5SLeila Ghaffari 394bc7bbd5dSLeila Ghaffari* - `-rc` 395bc7bbd5dSLeila Ghaffari - Characteristic radius of thermal bubble 396bc7bbd5dSLeila Ghaffari - `1000` 397bc7bbd5dSLeila Ghaffari - `m` 398e43605a5SLeila Ghaffari 399bc7bbd5dSLeila Ghaffari* - `-units_meter` 400bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 401bc7bbd5dSLeila Ghaffari - `1E-2` 402bc7bbd5dSLeila Ghaffari - 403e43605a5SLeila Ghaffari 404bc7bbd5dSLeila Ghaffari* - `-units_second` 405bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 406bc7bbd5dSLeila Ghaffari - `1E-2` 407bc7bbd5dSLeila Ghaffari - 408e43605a5SLeila Ghaffari 409bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 410bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 411bc7bbd5dSLeila Ghaffari - `1E-6` 412bc7bbd5dSLeila Ghaffari - 413e43605a5SLeila Ghaffari 414bc7bbd5dSLeila Ghaffari* - `-strong_form` 415bc7bbd5dSLeila Ghaffari - Strong (1) or weak/integrated by parts (0) residual 416bc7bbd5dSLeila Ghaffari - `0` 417bc7bbd5dSLeila Ghaffari - 418e43605a5SLeila Ghaffari 419bc7bbd5dSLeila Ghaffari* - `-stab` 420bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 421bc7bbd5dSLeila Ghaffari - `none` 422bc7bbd5dSLeila Ghaffari - 423e43605a5SLeila Ghaffari 424bc7bbd5dSLeila Ghaffari* - `-CtauS` 425bc7bbd5dSLeila Ghaffari - Scale coefficient for stabilization tau (nondimensional) 426bc7bbd5dSLeila Ghaffari - `0` 427bc7bbd5dSLeila Ghaffari - 428e43605a5SLeila Ghaffari 429bc7bbd5dSLeila Ghaffari* - `-wind_type` 430bc7bbd5dSLeila Ghaffari - Wind type in Advection (`rotation` or `translation`) 431bc7bbd5dSLeila Ghaffari - `rotation` 432bc7bbd5dSLeila Ghaffari - 433e43605a5SLeila Ghaffari 434bc7bbd5dSLeila Ghaffari* - `-wind_translation` 435bc7bbd5dSLeila Ghaffari - Constant wind vector when `-wind_type translation` 436bc7bbd5dSLeila Ghaffari - `1,0,0` 437bc7bbd5dSLeila Ghaffari - 438e43605a5SLeila Ghaffari 439bc7bbd5dSLeila Ghaffari* - `-E_wind` 440bc7bbd5dSLeila Ghaffari - Total energy of inflow wind when `-wind_type translation` 441bc7bbd5dSLeila Ghaffari - `1E6` 442bc7bbd5dSLeila Ghaffari - `J` 443e43605a5SLeila Ghaffari 444*7b77ddfdSJames Wright* - `-advection_ic_type` 445*7b77ddfdSJames Wright - Initial condition type, from `sphere`, `cylinder`, `cosine_hill`, and `skew` 446f3f66076SJames Wright - `sphere` 447bc7bbd5dSLeila Ghaffari - 448e43605a5SLeila Ghaffari 449bc7bbd5dSLeila Ghaffari* - `-bubble_continuity` 450bc7bbd5dSLeila Ghaffari - `smooth`, `back_sharp`, or `thick` 451bc7bbd5dSLeila Ghaffari - `smooth` 452bc7bbd5dSLeila Ghaffari - 453bc7bbd5dSLeila Ghaffari::: 454ccaff030SJeremy L Thompson 455bc7bbd5dSLeila GhaffariAn example of the `rotation` mode can be run with: 456ccaff030SJeremy L Thompson 457bc7bbd5dSLeila Ghaffari``` 4584534a52eSLeila Ghaffari./navierstokes -problem advection -dm_plex_box_faces 10,10,10 -dm_plex_dim 3 -dm_plex_box_lower 0,0,0 -dm_plex_box_upper 8000,8000,8000 -bc_wall 1,2,3,4,5,6 -wall_comps 4 -wind_type rotation -implicit -stab su 459bc7bbd5dSLeila Ghaffari``` 460ccaff030SJeremy L Thompson 461bc7bbd5dSLeila Ghaffariand the `translation` mode with: 462ccaff030SJeremy L Thompson 463bc7bbd5dSLeila Ghaffari``` 4644534a52eSLeila Ghaffari./navierstokes -problem advection -dm_plex_box_faces 10,10,10 -dm_plex_dim 3 -dm_plex_box_lower 0,0,0 -dm_plex_box_upper 8000,8000,8000 -wind_type translation -wind_translation .5,-1,0 -bc_inflow 1,2,3,4,5,6 465bc7bbd5dSLeila Ghaffari``` 466ccaff030SJeremy L Thompson 467019b7682STimothy Aiken### Inviscid Ideal Gas 468019b7682STimothy Aiken 469019b7682STimothy Aiken#### Isentropic Euler vortex 470019b7682STimothy Aiken 471bc7bbd5dSLeila GhaffariFor the Isentropic Vortex problem, the following additional command-line options are available: 472ccaff030SJeremy L Thompson 473bc7bbd5dSLeila Ghaffari:::{list-table} Isentropic Vortex Runtime Options 474bc7bbd5dSLeila Ghaffari:header-rows: 1 475ccaff030SJeremy L Thompson 476bc7bbd5dSLeila Ghaffari* - Option 477bc7bbd5dSLeila Ghaffari - Description 478bc7bbd5dSLeila Ghaffari - Default value 479bc7bbd5dSLeila Ghaffari - Unit 480ccaff030SJeremy L Thompson 481bc7bbd5dSLeila Ghaffari* - `-center` 482bc7bbd5dSLeila Ghaffari - Location of vortex center 483bc7bbd5dSLeila Ghaffari - `(lx,ly,lz)/2` 484bc7bbd5dSLeila Ghaffari - `(m,m,m)` 485ccaff030SJeremy L Thompson 486bc7bbd5dSLeila Ghaffari* - `-units_meter` 487bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 488bc7bbd5dSLeila Ghaffari - `1E-2` 489bc7bbd5dSLeila Ghaffari - 490ccaff030SJeremy L Thompson 491bc7bbd5dSLeila Ghaffari* - `-units_second` 492bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 493bc7bbd5dSLeila Ghaffari - `1E-2` 494bc7bbd5dSLeila Ghaffari - 495ccaff030SJeremy L Thompson 496bc7bbd5dSLeila Ghaffari* - `-mean_velocity` 497bc7bbd5dSLeila Ghaffari - Background velocity vector 498bc7bbd5dSLeila Ghaffari - `(1,1,0)` 499bc7bbd5dSLeila Ghaffari - 500ccaff030SJeremy L Thompson 501bc7bbd5dSLeila Ghaffari* - `-vortex_strength` 502bc7bbd5dSLeila Ghaffari - Strength of vortex < 10 503bc7bbd5dSLeila Ghaffari - `5` 504bc7bbd5dSLeila Ghaffari - 505932417b3SJed Brown 506932417b3SJed Brown* - `-c_tau` 507932417b3SJed Brown - Stabilization constant 508504dc8e0SLeila Ghaffari - `0.5` 509932417b3SJed Brown - 510bc7bbd5dSLeila Ghaffari::: 511ccaff030SJeremy L Thompson 512bc7bbd5dSLeila GhaffariThis problem can be run with: 513ccaff030SJeremy L Thompson 514bc7bbd5dSLeila Ghaffari``` 5154534a52eSLeila Ghaffari./navierstokes -problem euler_vortex -dm_plex_box_faces 20,20,1 -dm_plex_box_lower 0,0,0 -dm_plex_box_upper 1000,1000,50 -dm_plex_dim 3 -bc_inflow 4,6 -bc_outflow 3,5 -bc_slip_z 1,2 -mean_velocity .5,-.8,0. 516bc7bbd5dSLeila Ghaffari``` 517ccaff030SJeremy L Thompson 518019b7682STimothy Aiken#### Sod shock tube 519019b7682STimothy Aiken 520019b7682STimothy AikenFor the Shock Tube problem, the following additional command-line options are available: 521019b7682STimothy Aiken 522019b7682STimothy Aiken:::{list-table} Shock Tube Runtime Options 523019b7682STimothy Aiken:header-rows: 1 524019b7682STimothy Aiken 525019b7682STimothy Aiken* - Option 526019b7682STimothy Aiken - Description 527019b7682STimothy Aiken - Default value 528019b7682STimothy Aiken - Unit 529019b7682STimothy Aiken 530019b7682STimothy Aiken* - `-units_meter` 531019b7682STimothy Aiken - 1 meter in scaled length units 532019b7682STimothy Aiken - `1E-2` 533019b7682STimothy Aiken - 534019b7682STimothy Aiken 535019b7682STimothy Aiken* - `-units_second` 536019b7682STimothy Aiken - 1 second in scaled time units 537019b7682STimothy Aiken - `1E-2` 538019b7682STimothy Aiken - 539019b7682STimothy Aiken 540019b7682STimothy Aiken* - `-yzb` 541019b7682STimothy Aiken - Use YZB discontinuity capturing 542019b7682STimothy Aiken - `none` 543019b7682STimothy Aiken - 544019b7682STimothy Aiken 545019b7682STimothy Aiken* - `-stab` 546019b7682STimothy Aiken - Stabilization method (`none`, `su`, or `supg`) 547019b7682STimothy Aiken - `none` 548019b7682STimothy Aiken - 549019b7682STimothy Aiken::: 550019b7682STimothy Aiken 551019b7682STimothy AikenThis problem can be run with: 552019b7682STimothy Aiken 553019b7682STimothy Aiken``` 554019b7682STimothy Aiken./navierstokes -problem shocktube -yzb -stab su -bc_slip_z 3,4 -bc_slip_y 1,2 -bc_wall 5,6 -dm_plex_dim 3 -dm_plex_box_lower 0,0,0 -dm_plex_box_upper 1000,100,100 -dm_plex_box_faces 200,1,1 -units_second 0.1 555019b7682STimothy Aiken``` 556019b7682STimothy Aiken 557019b7682STimothy Aiken### Newtonian viscosity, Ideal Gas 558019b7682STimothy Aiken 55988626eedSJames WrightFor the Density Current, Channel, and Blasius problems, the following common command-line options are available: 560ccaff030SJeremy L Thompson 56188626eedSJames Wright:::{list-table} Newtonian Ideal Gas problems Runtime Options 562bc7bbd5dSLeila Ghaffari:header-rows: 1 563ccaff030SJeremy L Thompson 564bc7bbd5dSLeila Ghaffari* - Option 565bc7bbd5dSLeila Ghaffari - Description 566bc7bbd5dSLeila Ghaffari - Default value 567bc7bbd5dSLeila Ghaffari - Unit 568ccaff030SJeremy L Thompson 569bc7bbd5dSLeila Ghaffari* - `-units_meter` 570bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 57188626eedSJames Wright - `1` 572bc7bbd5dSLeila Ghaffari - 573ccaff030SJeremy L Thompson 574bc7bbd5dSLeila Ghaffari* - `-units_second` 575bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 57688626eedSJames Wright - `1` 577bc7bbd5dSLeila Ghaffari - 578ccaff030SJeremy L Thompson 579bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 580bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 58188626eedSJames Wright - `1` 582bc7bbd5dSLeila Ghaffari - 583ccaff030SJeremy L Thompson 584bc7bbd5dSLeila Ghaffari* - `-units_Kelvin` 585bc7bbd5dSLeila Ghaffari - 1 Kelvin in scaled temperature units 586bc7bbd5dSLeila Ghaffari - `1` 587bc7bbd5dSLeila Ghaffari - 588ccaff030SJeremy L Thompson 589bc7bbd5dSLeila Ghaffari* - `-stab` 590bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 591bc7bbd5dSLeila Ghaffari - `none` 592bc7bbd5dSLeila Ghaffari - 593ccaff030SJeremy L Thompson 594932417b3SJed Brown* - `-c_tau` 59588626eedSJames Wright - Stabilization constant, $c_\tau$ 596504dc8e0SLeila Ghaffari - `0.5` 597932417b3SJed Brown - 598932417b3SJed Brown 59988626eedSJames Wright* - `-Ctau_t` 60088626eedSJames Wright - Stabilization time constant, $C_t$ 60188626eedSJames Wright - `1.0` 60288626eedSJames Wright - 603ccaff030SJeremy L Thompson 60488626eedSJames Wright* - `-Ctau_v` 60588626eedSJames Wright - Stabilization viscous constant, $C_v$ 60694c01735SLeila Ghaffari - `36, 60, 128 for degree = 1, 2, 3` 60788626eedSJames Wright - 608ccaff030SJeremy L Thompson 60988626eedSJames Wright* - `-Ctau_C` 61088626eedSJames Wright - Stabilization continuity constant, $C_c$ 61188626eedSJames Wright - `1.0` 61288626eedSJames Wright - 613ccaff030SJeremy L Thompson 61488626eedSJames Wright* - `-Ctau_M` 61588626eedSJames Wright - Stabilization momentum constant, $C_m$ 61688626eedSJames Wright - `1.0` 61788626eedSJames Wright - 61888626eedSJames Wright 61988626eedSJames Wright* - `-Ctau_E` 62088626eedSJames Wright - Stabilization energy constant, $C_E$ 62188626eedSJames Wright - `1.0` 62288626eedSJames Wright - 623ccaff030SJeremy L Thompson 624bc7bbd5dSLeila Ghaffari* - `-cv` 625bc7bbd5dSLeila Ghaffari - Heat capacity at constant volume 626bc7bbd5dSLeila Ghaffari - `717` 627bc7bbd5dSLeila Ghaffari - `J/(kg K)` 628ccaff030SJeremy L Thompson 629bc7bbd5dSLeila Ghaffari* - `-cp` 630bc7bbd5dSLeila Ghaffari - Heat capacity at constant pressure 631bc7bbd5dSLeila Ghaffari - `1004` 632bc7bbd5dSLeila Ghaffari - `J/(kg K)` 633ccaff030SJeremy L Thompson 634a2726bdbSJames Wright* - `-gravity` 635a2726bdbSJames Wright - Gravitational acceleration vector 636a2726bdbSJames Wright - `0,0,0` 637bc7bbd5dSLeila Ghaffari - `m/s^2` 638ccaff030SJeremy L Thompson 639bc7bbd5dSLeila Ghaffari* - `-lambda` 640bc7bbd5dSLeila Ghaffari - Stokes hypothesis second viscosity coefficient 641bc7bbd5dSLeila Ghaffari - `-2/3` 642bc7bbd5dSLeila Ghaffari - 643ccaff030SJeremy L Thompson 644bc7bbd5dSLeila Ghaffari* - `-mu` 645bc7bbd5dSLeila Ghaffari - Shear dynamic viscosity coefficient 646a2726bdbSJames Wright - `1.8e-5` 647bc7bbd5dSLeila Ghaffari - `Pa s` 64877841947SLeila Ghaffari 649bc7bbd5dSLeila Ghaffari* - `-k` 650bc7bbd5dSLeila Ghaffari - Thermal conductivity 651bc7bbd5dSLeila Ghaffari - `0.02638` 652bc7bbd5dSLeila Ghaffari - `W/(m K)` 653a1df05f8SJed Brown 654a1df05f8SJed Brown* - `-newtonian_unit_tests` 655a1df05f8SJed Brown - Developer option to test properties 656a1df05f8SJed Brown - `false` 657a1df05f8SJed Brown - boolean 658de2fdd78SJames Wright 6595c0afad3SJames Wright* - `-state_var` 6605c0afad3SJames Wright - State variables to solve solution with. `conservative` ($\rho, \rho \bm{u}, \rho e$) or `primitive` ($P, \bm{u}, T$) 6615c0afad3SJames Wright - `conservative` 6625c0afad3SJames Wright - string 663530ad8c4SKenneth E. Jansen 664530ad8c4SKenneth E. Jansen* - `-idl_decay_time` 665530ad8c4SKenneth E. Jansen - Characteristic timescale of the pressure deviance decay. The timestep is good starting point 666530ad8c4SKenneth E. Jansen - `-1` (disabled) 667530ad8c4SKenneth E. Jansen - `s` 668530ad8c4SKenneth E. Jansen 669530ad8c4SKenneth E. Jansen* - `-idl_start` 670530ad8c4SKenneth E. Jansen - Start of IDL in the x direction 671530ad8c4SKenneth E. Jansen - `0` 672530ad8c4SKenneth E. Jansen - `m` 673530ad8c4SKenneth E. Jansen 674530ad8c4SKenneth E. Jansen* - `-idl_length` 675530ad8c4SKenneth E. Jansen - Length of IDL in the positive x direction 676530ad8c4SKenneth E. Jansen - `0` 677530ad8c4SKenneth E. Jansen - `m` 678530ad8c4SKenneth E. Jansen 679c79d6dc9SJames Wright* - `-sgs_model_type` 680c79d6dc9SJames Wright - Type of subgrid stress model to use. Currently only `data_driven` is available 681c79d6dc9SJames Wright - `none` 682c79d6dc9SJames Wright - string 683c79d6dc9SJames Wright 684c79d6dc9SJames Wright* - `-sgs_model_dd_leakyrelu_alpha` 685c79d6dc9SJames Wright - Slope parameter for Leaky ReLU activation function. `0` corresponds to normal ReLU 686c79d6dc9SJames Wright - 0 687c79d6dc9SJames Wright - 688c79d6dc9SJames Wright 689c79d6dc9SJames Wright* - `-sgs_model_dd_parameter_dir` 690c79d6dc9SJames Wright - Path to directory with data-driven model parameters (weights, biases, etc.) 691c79d6dc9SJames Wright - `./dd_sgs_parameters` 692c79d6dc9SJames Wright - string 693c79d6dc9SJames Wright 6943f89fbfdSJames Wright* - `-diff_filter_monitor` 6953f89fbfdSJames Wright - Enable differential filter TSMonitor 6963f89fbfdSJames Wright - `false` 6973f89fbfdSJames Wright - boolean 6983f89fbfdSJames Wright 6993f89fbfdSJames Wright* - `-diff_filter_grid_based_width` 7003f89fbfdSJames Wright - Use filter width based on the grid size 7013f89fbfdSJames Wright - `false` 7023f89fbfdSJames Wright - boolean 7033f89fbfdSJames Wright 7043f89fbfdSJames Wright* - `-diff_filter_width_scaling` 7053f89fbfdSJames Wright - Anisotropic scaling for filter width in wall-aligned coordinates (snz) 7063f89fbfdSJames Wright - `1,1,1` 7073f89fbfdSJames Wright - `m` 7083f89fbfdSJames Wright 7093f89fbfdSJames Wright* - `-diff_filter_kernel_scaling` 7103f89fbfdSJames Wright - Scaling to make differential kernel size equivalent to other filter kernels 7113f89fbfdSJames Wright - `0.1` 7123f89fbfdSJames Wright - `m^2` 7133f89fbfdSJames Wright 7143f89fbfdSJames Wright* - `-diff_filter_wall_damping_function` 7153f89fbfdSJames Wright - Damping function to use at the wall for anisotropic filtering (`none`, `van_driest`) 7163f89fbfdSJames Wright - `none` 7173f89fbfdSJames Wright - string 7183f89fbfdSJames Wright 7193f89fbfdSJames Wright* - `-diff_filter_wall_damping_constant` 7209d9c52bbSJed Brown - Constant for the wall-damping function. $A^+$ for `van_driest` damping function. 7213f89fbfdSJames Wright - 25 7223f89fbfdSJames Wright - 7233f89fbfdSJames Wright 7243f89fbfdSJames Wright* - `-diff_filter_friction_length` 7253f89fbfdSJames Wright - Friction length associated with the flow, $\delta_\nu$. Used in wall-damping functions 7263f89fbfdSJames Wright - 0 7273f89fbfdSJames Wright - `m` 7283f89fbfdSJames Wright 7293b219b86SJames Wright* - `-sgs_train_enable` 7303b219b86SJames Wright - Whether to enable *in situ* training of data-driven SGS model. Require building with SmartRedis. 7313b219b86SJames Wright - `false` 7323b219b86SJames Wright - boolean 7333b219b86SJames Wright 7343b219b86SJames Wright* - `-sgs_train_write_data_interval` 7353b219b86SJames Wright - Number of timesteps between writing training data into SmartRedis database 7363b219b86SJames Wright - `1` 7373b219b86SJames Wright - 7383b219b86SJames Wright 7393b219b86SJames Wright* - `-sgs_train_overwrite_data` 7403b219b86SJames Wright - Whether new training data should overwrite old data on database 7413b219b86SJames Wright - `true` 7423b219b86SJames Wright - boolean 7433b219b86SJames Wright 7443b219b86SJames Wright* - `-smartsim_collocated_num_ranks` 7453b219b86SJames Wright - Number of MPI ranks associated with each collocated database (i.e. ranks per node) 7463b219b86SJames Wright - `1` 7473b219b86SJames Wright - 748bc7bbd5dSLeila Ghaffari::: 74977841947SLeila Ghaffari 750530ad8c4SKenneth E. Jansen#### Gaussian Wave 7517ec884f8SJames Wright 752530ad8c4SKenneth E. JansenThe Gaussian wave problem has the following command-line options in addition to the Newtonian Ideal Gas options: 7537ec884f8SJames Wright 754530ad8c4SKenneth E. Jansen:::{list-table} Gaussian Wave Runtime Options 7557ec884f8SJames Wright:header-rows: 1 7567ec884f8SJames Wright 7577ec884f8SJames Wright* - Option 7587ec884f8SJames Wright - Description 7597ec884f8SJames Wright - Default value 7607ec884f8SJames Wright - Unit 7617ec884f8SJames Wright 762f1e435c9SJed Brown* - `-freestream_riemann` 763f1e435c9SJed Brown - Riemann solver for boundaries (HLL or HLLC) 764f1e435c9SJed Brown - `hllc` 765f1e435c9SJed Brown - 766f1e435c9SJed Brown 767f1e435c9SJed Brown* - `-freestream_velocity` 7687ec884f8SJames Wright - Freestream velocity vector 7697ec884f8SJames Wright - `0,0,0` 7707ec884f8SJames Wright - `m/s` 7717ec884f8SJames Wright 772f1e435c9SJed Brown* - `-freestream_temperature` 7737ec884f8SJames Wright - Freestream temperature 7747ec884f8SJames Wright - `288` 7757ec884f8SJames Wright - `K` 7767ec884f8SJames Wright 777f1e435c9SJed Brown* - `-freestream_pressure` 77889e3cb53SJames Wright - Freestream pressure 7797ec884f8SJames Wright - `1.01e5` 7807ec884f8SJames Wright - `Pa` 7817ec884f8SJames Wright 7827ec884f8SJames Wright* - `-epicenter` 7837ec884f8SJames Wright - Coordinates of center of perturbation 7847ec884f8SJames Wright - `0,0,0` 7857ec884f8SJames Wright - `m` 7867ec884f8SJames Wright 7877ec884f8SJames Wright* - `-amplitude` 7887ec884f8SJames Wright - Amplitude of the perturbation 7897ec884f8SJames Wright - `0.1` 7907ec884f8SJames Wright - 7917ec884f8SJames Wright 7927ec884f8SJames Wright* - `-width` 7937ec884f8SJames Wright - Width parameter of the perturbation 7947ec884f8SJames Wright - `0.002` 7957ec884f8SJames Wright - `m` 7967ec884f8SJames Wright 7977ec884f8SJames Wright::: 7987ec884f8SJames Wright 799530ad8c4SKenneth E. JansenThis problem can be run with the `gaussianwave.yaml` file via: 8007ec884f8SJames Wright 8017ec884f8SJames Wright``` 802530ad8c4SKenneth E. Jansen./navierstokes -options_file gaussianwave.yaml 8037ec884f8SJames Wright``` 8047ec884f8SJames Wright 805530ad8c4SKenneth E. Jansen```{literalinclude} ../../../../../examples/fluids/gaussianwave.yaml 8067ec884f8SJames Wright:language: yaml 8077ec884f8SJames Wright``` 808a1df05f8SJed Brown 809d310b3d3SAdeleke O. Bankole#### Vortex Shedding - Flow past Cylinder 810d310b3d3SAdeleke O. Bankole 811d310b3d3SAdeleke O. BankoleThe vortex shedding, flow past cylinder problem has the following command-line options in addition to the Newtonian Ideal Gas options: 812d310b3d3SAdeleke O. Bankole 813d310b3d3SAdeleke O. Bankole:::{list-table} Vortex Shedding Runtime Options 814d310b3d3SAdeleke O. Bankole:header-rows: 1 815d310b3d3SAdeleke O. Bankole 816d310b3d3SAdeleke O. Bankole* - Option 817d310b3d3SAdeleke O. Bankole - Description 818d310b3d3SAdeleke O. Bankole - Default value 819d310b3d3SAdeleke O. Bankole - Unit 820d310b3d3SAdeleke O. Bankole 821d310b3d3SAdeleke O. Bankole* - `-freestream_velocity` 822d310b3d3SAdeleke O. Bankole - Freestream velocity vector 823d310b3d3SAdeleke O. Bankole - `0,0,0` 824d310b3d3SAdeleke O. Bankole - `m/s` 825d310b3d3SAdeleke O. Bankole 826d310b3d3SAdeleke O. Bankole* - `-freestream_temperature` 827d310b3d3SAdeleke O. Bankole - Freestream temperature 828d310b3d3SAdeleke O. Bankole - `288` 829d310b3d3SAdeleke O. Bankole - `K` 830d310b3d3SAdeleke O. Bankole 831d310b3d3SAdeleke O. Bankole* - `-freestream_pressure` 832d310b3d3SAdeleke O. Bankole - Freestream pressure 833d310b3d3SAdeleke O. Bankole - `1.01e5` 834d310b3d3SAdeleke O. Bankole - `Pa` 835d310b3d3SAdeleke O. Bankole 836d310b3d3SAdeleke O. Bankole::: 837d310b3d3SAdeleke O. Bankole 838d310b3d3SAdeleke O. BankoleThe initial condition is taken from `-reference_temperature` and `-reference_pressure`. 839d310b3d3SAdeleke O. BankoleTo run this problem, first generate a mesh: 840d310b3d3SAdeleke O. Bankole 841d310b3d3SAdeleke O. Bankole```console 842d310b3d3SAdeleke O. Bankole$ make -C examples/fluids/meshes 843d310b3d3SAdeleke O. Bankole``` 844d310b3d3SAdeleke O. Bankole 845d310b3d3SAdeleke O. BankoleThen run by building the executable and running: 846d310b3d3SAdeleke O. Bankole 847d310b3d3SAdeleke O. Bankole```console 848d310b3d3SAdeleke O. Bankole$ make build/fluids-navierstokes 849ca69d878SAdeleke O. Bankole$ mpiexec -n 6 build/fluids-navierstokes -options_file examples/fluids/vortexshedding.yaml -{ts,snes}_monitor_ 850d310b3d3SAdeleke O. Bankole``` 851d310b3d3SAdeleke O. Bankole 852ca69d878SAdeleke O. BankoleThe vortex shedding period is roughly 5.6 and this problem runs until time 100 (2000 time steps). 853ca69d878SAdeleke O. BankoleThe above run writes a file named `force.csv` (see `ts_monitor_wall_force` in `vortexshedding.yaml`), which can be postprocessed by running to create a figure showing lift and drag coefficients over time. 854ca69d878SAdeleke O. Bankole 855ca69d878SAdeleke O. Bankole```console 856d6734f85SAdeleke O. Bankole$ python examples/fluids/postprocess/vortexshedding.py 857ca69d878SAdeleke O. Bankole``` 858d310b3d3SAdeleke O. Bankole 859d310b3d3SAdeleke O. Bankole```{literalinclude} ../../../../../examples/fluids/vortexshedding.yaml 860d310b3d3SAdeleke O. Bankole:language: yaml 861d310b3d3SAdeleke O. Bankole``` 862d310b3d3SAdeleke O. Bankole 863019b7682STimothy Aiken#### Density current 864019b7682STimothy Aiken 865061ff11eSJames WrightThe Density Current problem has the following command-line options in addition to the Newtonian Ideal Gas options: 86688626eedSJames Wright 86788626eedSJames Wright:::{list-table} Density Current Runtime Options 86888626eedSJames Wright:header-rows: 1 86988626eedSJames Wright 87088626eedSJames Wright* - Option 87188626eedSJames Wright - Description 87288626eedSJames Wright - Default value 87388626eedSJames Wright - Unit 87488626eedSJames Wright 87588626eedSJames Wright* - `-center` 87688626eedSJames Wright - Location of bubble center 87788626eedSJames Wright - `(lx,ly,lz)/2` 87888626eedSJames Wright - `(m,m,m)` 87988626eedSJames Wright 88088626eedSJames Wright* - `-dc_axis` 88188626eedSJames Wright - Axis of density current cylindrical anomaly, or `(0,0,0)` for spherically symmetric 88288626eedSJames Wright - `(0,0,0)` 88388626eedSJames Wright - 88488626eedSJames Wright 88588626eedSJames Wright* - `-rc` 88688626eedSJames Wright - Characteristic radius of thermal bubble 88788626eedSJames Wright - `1000` 88888626eedSJames Wright - `m` 88988626eedSJames Wright 89088626eedSJames Wright* - `-theta0` 89188626eedSJames Wright - Reference potential temperature 89288626eedSJames Wright - `300` 89388626eedSJames Wright - `K` 89488626eedSJames Wright 89588626eedSJames Wright* - `-thetaC` 89688626eedSJames Wright - Perturbation of potential temperature 89788626eedSJames Wright - `-15` 89888626eedSJames Wright - `K` 89988626eedSJames Wright 90088626eedSJames Wright* - `-P0` 90188626eedSJames Wright - Atmospheric pressure 90288626eedSJames Wright - `1E5` 90388626eedSJames Wright - `Pa` 90488626eedSJames Wright 90588626eedSJames Wright* - `-N` 90688626eedSJames Wright - Brunt-Vaisala frequency 90788626eedSJames Wright - `0.01` 90888626eedSJames Wright - `1/s` 90988626eedSJames Wright::: 91088626eedSJames Wright 911bc7bbd5dSLeila GhaffariThis problem can be run with: 912ccaff030SJeremy L Thompson 913bc7bbd5dSLeila Ghaffari``` 91488626eedSJames Wright./navierstokes -problem density_current -dm_plex_box_faces 16,1,8 -degree 1 -dm_plex_box_lower 0,0,0 -dm_plex_box_upper 2000,125,1000 -dm_plex_dim 3 -rc 400. -bc_wall 1,2,5,6 -wall_comps 1,2,3 -bc_slip_y 3,4 -mu 75 91588626eedSJames Wright``` 91688626eedSJames Wright 917019b7682STimothy Aiken#### Channel flow 918019b7682STimothy Aiken 919061ff11eSJames WrightThe Channel problem has the following command-line options in addition to the Newtonian Ideal Gas options: 92088626eedSJames Wright 92188626eedSJames Wright:::{list-table} Channel Runtime Options 92288626eedSJames Wright:header-rows: 1 92388626eedSJames Wright 92488626eedSJames Wright* - Option 92588626eedSJames Wright - Description 92688626eedSJames Wright - Default value 92788626eedSJames Wright - Unit 92888626eedSJames Wright 92988626eedSJames Wright* - `-umax` 93088626eedSJames Wright - Maximum/centerline velocity of the flow 93188626eedSJames Wright - `10` 93288626eedSJames Wright - `m/s` 93388626eedSJames Wright 93488626eedSJames Wright* - `-theta0` 93588626eedSJames Wright - Reference potential temperature 93688626eedSJames Wright - `300` 93788626eedSJames Wright - `K` 93888626eedSJames Wright 93988626eedSJames Wright* - `-P0` 94088626eedSJames Wright - Atmospheric pressure 94188626eedSJames Wright - `1E5` 94288626eedSJames Wright - `Pa` 943a1df05f8SJed Brown 944a1df05f8SJed Brown* - `-body_force_scale` 945a1df05f8SJed Brown - Multiplier for body force (`-1` for flow reversal) 946a1df05f8SJed Brown - 1 947a1df05f8SJed Brown - 94888626eedSJames Wright::: 94988626eedSJames Wright 95088626eedSJames WrightThis problem can be run with the `channel.yaml` file via: 95188626eedSJames Wright 95288626eedSJames Wright``` 95388626eedSJames Wright./navierstokes -options_file channel.yaml 95488626eedSJames Wright``` 95588626eedSJames Wright```{literalinclude} ../../../../../examples/fluids/channel.yaml 95688626eedSJames Wright:language: yaml 95788626eedSJames Wright``` 95888626eedSJames Wright 9598a94a473SJed Brown(example-blasius)= 9608a94a473SJed Brown 961019b7682STimothy Aiken#### Blasius boundary layer 962019b7682STimothy Aiken 963061ff11eSJames WrightThe Blasius problem has the following command-line options in addition to the Newtonian Ideal Gas options: 96488626eedSJames Wright 96588626eedSJames Wright:::{list-table} Blasius Runtime Options 96688626eedSJames Wright:header-rows: 1 96788626eedSJames Wright 96888626eedSJames Wright* - Option 96988626eedSJames Wright - Description 97088626eedSJames Wright - Default value 97188626eedSJames Wright - Unit 97288626eedSJames Wright 973fb455ff0SLeila Ghaffari* - `-velocity_infinity` 97488626eedSJames Wright - Freestream velocity 97588626eedSJames Wright - `40` 97688626eedSJames Wright - `m/s` 97788626eedSJames Wright 978fb455ff0SLeila Ghaffari* - `-temperature_infinity` 979fb455ff0SLeila Ghaffari - Freestream temperature 98088626eedSJames Wright - `288` 98188626eedSJames Wright - `K` 98288626eedSJames Wright 983fb455ff0SLeila Ghaffari* - `-temperature_wall` 984fb455ff0SLeila Ghaffari - Wall temperature 98507d14e58SLeila Ghaffari - `288` 986fb455ff0SLeila Ghaffari - `K` 987fb455ff0SLeila Ghaffari 988fb455ff0SLeila Ghaffari* - `-delta0` 989fb455ff0SLeila Ghaffari - Boundary layer height at the inflow 990fb455ff0SLeila Ghaffari - `4.2e-3` 991fb455ff0SLeila Ghaffari - `m` 992fb455ff0SLeila Ghaffari 99388626eedSJames Wright* - `-P0` 99488626eedSJames Wright - Atmospheric pressure 99588626eedSJames Wright - `1.01E5` 99688626eedSJames Wright - `Pa` 99788626eedSJames Wright 9989309e21cSJames Wright* - `-platemesh_modify_mesh` 9999309e21cSJames Wright - Whether to modify the mesh using the given options below. 10009309e21cSJames Wright - `false` 10019309e21cSJames Wright - 10029309e21cSJames Wright 100391eaef80SJames Wright* - `-platemesh_refine_height` 100491eaef80SJames Wright - Height at which `-platemesh_Ndelta` number of elements should refined into 100588626eedSJames Wright - `5.9E-4` 100688626eedSJames Wright - `m` 100788626eedSJames Wright 100891eaef80SJames Wright* - `-platemesh_Ndelta` 100991eaef80SJames Wright - Number of elements to keep below `-platemesh_refine_height` 101088626eedSJames Wright - `45` 101188626eedSJames Wright - 101288626eedSJames Wright 101391eaef80SJames Wright* - `-platemesh_growth` 101488626eedSJames Wright - Growth rate of the elements in the refinement region 101588626eedSJames Wright - `1.08` 101688626eedSJames Wright - 101788626eedSJames Wright 101891eaef80SJames Wright* - `-platemesh_top_angle` 101988626eedSJames Wright - Downward angle of the top face of the domain. This face serves as an outlet. 102088626eedSJames Wright - `5` 102188626eedSJames Wright - `degrees` 1022ba6664aeSJames Wright 102391eaef80SJames Wright* - `-platemesh_y_node_locs_path` 102491eaef80SJames Wright - Path to file with y node locations. If empty, will use mesh warping instead. 102591eaef80SJames Wright - `""` 102691eaef80SJames Wright - 1027fb455ff0SLeila Ghaffari 10289309e21cSJames Wright* - `-stg_use` 10299309e21cSJames Wright - Whether to use STG for the inflow conditions 10309309e21cSJames Wright - `false` 10319309e21cSJames Wright - 10329309e21cSJames Wright 103307d14e58SLeila Ghaffari* - `-n_chebyshev` 1034fb455ff0SLeila Ghaffari - Number of Chebyshev terms 1035fb455ff0SLeila Ghaffari - `20` 1036fb455ff0SLeila Ghaffari - 1037fb455ff0SLeila Ghaffari 103807d14e58SLeila Ghaffari* - `-chebyshev_` 103907d14e58SLeila Ghaffari - Prefix for Chebyshev snes solve 104007d14e58SLeila Ghaffari - 104107d14e58SLeila Ghaffari - 104207d14e58SLeila Ghaffari 104388626eedSJames Wright::: 104488626eedSJames Wright 104588626eedSJames WrightThis problem can be run with the `blasius.yaml` file via: 104688626eedSJames Wright 104788626eedSJames Wright``` 104888626eedSJames Wright./navierstokes -options_file blasius.yaml 104988626eedSJames Wright``` 105088626eedSJames Wright 105188626eedSJames Wright```{literalinclude} ../../../../../examples/fluids/blasius.yaml 105288626eedSJames Wright:language: yaml 1053bc7bbd5dSLeila Ghaffari``` 1054ba6664aeSJames Wright 1055ba6664aeSJames Wright#### STG Inflow for Flat Plate 1056ba6664aeSJames Wright 105717be3a41SJeremy L ThompsonUsing the STG Inflow for the blasius problem adds the following command-line options: 1058ba6664aeSJames Wright 1059ba6664aeSJames Wright:::{list-table} Blasius Runtime Options 1060ba6664aeSJames Wright:header-rows: 1 1061ba6664aeSJames Wright 1062ba6664aeSJames Wright* - Option 1063ba6664aeSJames Wright - Description 1064ba6664aeSJames Wright - Default value 1065ba6664aeSJames Wright - Unit 1066ba6664aeSJames Wright 1067ba6664aeSJames Wright* - `-stg_inflow_path` 1068ba6664aeSJames Wright - Path to the STGInflow file 1069ba6664aeSJames Wright - `./STGInflow.dat` 1070ba6664aeSJames Wright - 1071ba6664aeSJames Wright 1072ba6664aeSJames Wright* - `-stg_rand_path` 1073ba6664aeSJames Wright - Path to the STGRand file 1074ba6664aeSJames Wright - `./STGRand.dat` 1075ba6664aeSJames Wright - 1076ba6664aeSJames Wright 1077ba6664aeSJames Wright* - `-stg_alpha` 1078ba6664aeSJames Wright - Growth rate of the wavemodes 1079ba6664aeSJames Wright - `1.01` 1080ba6664aeSJames Wright - 1081ba6664aeSJames Wright 1082ba6664aeSJames Wright* - `-stg_u0` 1083ba6664aeSJames Wright - Convective velocity, $U_0$ 1084ba6664aeSJames Wright - `0.0` 1085ba6664aeSJames Wright - `m/s` 1086ba6664aeSJames Wright 1087ba6664aeSJames Wright* - `-stg_mean_only` 1088ba6664aeSJames Wright - Only impose the mean velocity (no fluctutations) 1089ba6664aeSJames Wright - `false` 1090ba6664aeSJames Wright - 1091ba6664aeSJames Wright 109230af3636SJames Wright* - `-stg_strong` 109330af3636SJames Wright - Strongly enforce the STG inflow boundary condition 109430af3636SJames Wright - `false` 109530af3636SJames Wright - 109630af3636SJames Wright 109789060322SJames Wright* - `-stg_fluctuating_IC` 109889060322SJames Wright - "Extrude" the fluctuations through the domain as an initial condition 109989060322SJames Wright - `false` 110089060322SJames Wright - 110189060322SJames Wright 1102ba6664aeSJames Wright::: 1103ba6664aeSJames Wright 1104ba6664aeSJames WrightThis problem can be run with the `blasius.yaml` file via: 1105ba6664aeSJames Wright 1106ba6664aeSJames Wright``` 1107ba6664aeSJames Wright./navierstokes -options_file blasius.yaml -stg_use true 1108ba6664aeSJames Wright``` 1109ba6664aeSJames Wright 111017be3a41SJeremy L ThompsonNote the added `-stg_use true` flag 111117be3a41SJeremy L ThompsonThis overrides the `stg: use: false` setting in the `blasius.yaml` file, enabling the use of the STG inflow. 1112