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 11bc7bbd5dSLeila GhaffariBuild by using: 12ccaff030SJeremy L Thompson 13ccaff030SJeremy L Thompson`make` 14ccaff030SJeremy L Thompson 15bc7bbd5dSLeila Ghaffariand run with: 16ccaff030SJeremy L Thompson 17bc7bbd5dSLeila Ghaffari``` 18bc7bbd5dSLeila Ghaffari./navierstokes -ceed [ceed] -problem [problem type] -degree [degree] 19bc7bbd5dSLeila Ghaffari``` 20ccaff030SJeremy L Thompson 21bc7bbd5dSLeila Ghaffari## Runtime options 22ccaff030SJeremy L Thompson 23bc7bbd5dSLeila Ghaffari% inclusion-fluids-marker 24ccaff030SJeremy L Thompson 25bc7bbd5dSLeila GhaffariThe Navier-Stokes mini-app is controlled via command-line options. 26bc7bbd5dSLeila GhaffariThe following options are common among all problem types: 27ccaff030SJeremy L Thompson 28bc7bbd5dSLeila Ghaffari:::{list-table} Common Runtime Options 29bc7bbd5dSLeila Ghaffari:header-rows: 1 30ccaff030SJeremy L Thompson 31bc7bbd5dSLeila Ghaffari* - Option 32bc7bbd5dSLeila Ghaffari - Description 33bc7bbd5dSLeila Ghaffari - Default value 34ccaff030SJeremy L Thompson 35bc7bbd5dSLeila Ghaffari* - `-ceed` 36bc7bbd5dSLeila Ghaffari - CEED resource specifier 37bc7bbd5dSLeila Ghaffari - `/cpu/self/opt/blocked` 38ccaff030SJeremy L Thompson 393866774cSJames Wright* - `-test_type` 403866774cSJames Wright - Run in test mode and specify whether solution (`solver`) or turbulent statistics (`turb_spanstats`) output should be verified 413866774cSJames Wright - `none` 42ccaff030SJeremy L Thompson 43bc7bbd5dSLeila Ghaffari* - `-compare_final_state_atol` 44bc7bbd5dSLeila Ghaffari - Test absolute tolerance 45bc7bbd5dSLeila Ghaffari - `1E-11` 46ccaff030SJeremy L Thompson 47bc7bbd5dSLeila Ghaffari* - `-compare_final_state_filename` 48bc7bbd5dSLeila Ghaffari - Test filename 49bc7bbd5dSLeila Ghaffari - 50ccaff030SJeremy L Thompson 51bc7bbd5dSLeila Ghaffari* - `-problem` 52bc7bbd5dSLeila Ghaffari - Problem to solve (`advection`, `advection2d`, `density_current`, or `euler_vortex`) 53bc7bbd5dSLeila Ghaffari - `density_current` 54ccaff030SJeremy L Thompson 55bc7bbd5dSLeila Ghaffari* - `-implicit` 56bc7bbd5dSLeila Ghaffari - Use implicit time integartor formulation 57bc7bbd5dSLeila Ghaffari - 58ccaff030SJeremy L Thompson 59bc7bbd5dSLeila Ghaffari* - `-degree` 60bc7bbd5dSLeila Ghaffari - Polynomial degree of tensor product basis (must be >= 1) 61bc7bbd5dSLeila Ghaffari - `1` 62ccaff030SJeremy L Thompson 632288fb52SJeremy L Thompson* - `-q_extra` 64bc7bbd5dSLeila Ghaffari - Number of extra quadrature points 65fc14f3f6SLeila Ghaffari - `0` 66ccaff030SJeremy L Thompson 6737cbb16aSJed Brown* - `-ts_monitor_solution` 6837cbb16aSJed Brown - PETSc output format, such as `cgns:output-%d.cgns` (requires PETSc `--download-cgns`) 6937cbb16aSJed Brown - 70ccaff030SJeremy L Thompson 7137cbb16aSJed Brown* - `-ts_monitor_solution_interval` 7237cbb16aSJed Brown - Number of time steps between visualization output frames. 7337cbb16aSJed Brown - `1` 7437cbb16aSJed Brown 7537cbb16aSJed Brown* - `-viewer_cgns_batch_size` 7637cbb16aSJed Brown - Number of frames written per CGNS file if the CGNS file name includes a format specifier (`%d`). 7737cbb16aSJed Brown - `20` 7837cbb16aSJed Brown 7937cbb16aSJed Brown* - `-checkpoint_interval` 8037cbb16aSJed Brown - Number of steps between writing binary checkpoints. `0` has no output, `-1` outputs final state only 81bc7bbd5dSLeila Ghaffari - `10` 82ccaff030SJeremy L Thompson 8337cbb16aSJed Brown* - `-checkpoint_vtk` 8437cbb16aSJed Brown - Checkpoints include VTK (`*.vtu`) files for visualization. Consider `-ts_monitor_solution`instead. 8537cbb16aSJed Brown - `false` 8637cbb16aSJed Brown 8737cbb16aSJed Brown* - `-viz_refine` 8837cbb16aSJed Brown - Use regular refinement for VTK visualization 8937cbb16aSJed Brown - `0` 9037cbb16aSJed Brown 91bc7bbd5dSLeila Ghaffari* - `-output_dir` 9237cbb16aSJed Brown - Output directory for binary checkpoints and VTK files (if enabled). 93bc7bbd5dSLeila Ghaffari - `.` 94ccaff030SJeremy L Thompson 9569293791SJames Wright* - `-output_add_stepnum2bin` 9669293791SJames Wright - Whether to add step numbers to output binary files 9769293791SJames Wright - `false` 9869293791SJames Wright 9969293791SJames Wright* - `-continue` 10069293791SJames Wright - Continue from previous solution (input is step number of previous solution) 10169293791SJames Wright - `0` 10269293791SJames Wright 10369293791SJames Wright* - `-continue_filename` 10469293791SJames Wright - Path to solution binary file from which to continue from 10569293791SJames Wright - `[output_dir]/ns-solution.bin` 10669293791SJames Wright 10769293791SJames Wright* - `-continue_time_filename` 1084de8550aSJed Brown - Path to time stamp binary file (only for legacy checkpoints) 10969293791SJames Wright - `[output_dir]/ns-time.bin` 11069293791SJames Wright 1114534a52eSLeila Ghaffari* - `-bc_wall` 1124534a52eSLeila Ghaffari - Use wall boundary conditions on this list of faces 1134534a52eSLeila Ghaffari - 1144534a52eSLeila Ghaffari 1154534a52eSLeila Ghaffari* - `-wall_comps` 1164534a52eSLeila Ghaffari - An array of constrained component numbers for wall BCs 1174534a52eSLeila Ghaffari - 1184534a52eSLeila Ghaffari 1194534a52eSLeila Ghaffari* - `-bc_slip_x` 1204534a52eSLeila Ghaffari - Use slip boundary conditions, for the x component, on this list of faces 1214534a52eSLeila Ghaffari - 1224534a52eSLeila Ghaffari 1234534a52eSLeila Ghaffari* - `-bc_slip_y` 1244534a52eSLeila Ghaffari - Use slip boundary conditions, for the y component, on this list of faces 1254534a52eSLeila Ghaffari - 1264534a52eSLeila Ghaffari 1274534a52eSLeila Ghaffari* - `-bc_slip_z` 1284534a52eSLeila Ghaffari - Use slip boundary conditions, for the z component, on this list of faces 1294534a52eSLeila Ghaffari - 1304534a52eSLeila Ghaffari 1314534a52eSLeila Ghaffari* - `-bc_inflow` 1324534a52eSLeila Ghaffari - Use inflow boundary conditions on this list of faces 1334534a52eSLeila Ghaffari - 1344534a52eSLeila Ghaffari 1354534a52eSLeila Ghaffari* - `-bc_outflow` 1364534a52eSLeila Ghaffari - Use outflow boundary conditions on this list of faces 1374534a52eSLeila Ghaffari - 13889d0f5c0SLeila Ghaffari 1397ec884f8SJames Wright* - `-bc_freestream` 1407ec884f8SJames Wright - Use freestream boundary conditions on this list of faces 1417ec884f8SJames Wright - 1427ec884f8SJames Wright 143b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_collect_interval` 144ee3de563SJames Wright - Number of timesteps between statistics collection 145ee3de563SJames Wright - `1` 146ee3de563SJames Wright 147b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer` 148b7d66439SJames 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. 1498ed52730SJames Wright - 1508ed52730SJames Wright 151b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer_interval` 152ee3de563SJames Wright - Number of timesteps between statistics file writing (`-1` means only at end of run) 153ee3de563SJames Wright - `-1` 154ee3de563SJames Wright 155b7d66439SJames Wright* - `-ts_monitor_turbulence_spanstats_viewer_cgns_batch_size` 1568ed52730SJames Wright - Number of frames written per CGNS file if the CGNS file name includes a format specifier (`%d`). 1578ed52730SJames Wright - `20` 1588ed52730SJames Wright 159ca69d878SAdeleke O. Bankole* - `-ts_monitor_wall_force` 160ca69d878SAdeleke O. Bankole - Viewer for the force on each no-slip wall, e.g., `ascii:force.csv:ascii_csv` to write a CSV file. 161ca69d878SAdeleke O. Bankole - 162ca69d878SAdeleke O. Bankole 163bc7bbd5dSLeila Ghaffari* - `-snes_view` 164bc7bbd5dSLeila Ghaffari - View PETSc `SNES` nonlinear solver configuration 165bc7bbd5dSLeila Ghaffari - 16689d0f5c0SLeila Ghaffari 167bc7bbd5dSLeila Ghaffari* - `-log_view` 168bc7bbd5dSLeila Ghaffari - View PETSc performance log 169bc7bbd5dSLeila Ghaffari - 170ccaff030SJeremy L Thompson 171bc7bbd5dSLeila Ghaffari* - `-help` 172bc7bbd5dSLeila Ghaffari - View comprehensive information about run-time options 173bc7bbd5dSLeila Ghaffari - 174bc7bbd5dSLeila Ghaffari::: 175ccaff030SJeremy L Thompson 1767ec884f8SJames 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: 1774534a52eSLeila Ghaffari 17888626eedSJames Wright:::{list-table} 2D Face ID Labels 17988626eedSJames Wright:header-rows: 1 18088626eedSJames Wright* - PETSc Face Name 18188626eedSJames Wright - Cartesian direction 18288626eedSJames Wright - Face ID 18388626eedSJames Wright 18488626eedSJames Wright* - faceMarkerBottom 18588626eedSJames Wright - -z 18688626eedSJames Wright - 1 18788626eedSJames Wright 18888626eedSJames Wright* - faceMarkerRight 18988626eedSJames Wright - +x 19088626eedSJames Wright - 2 19188626eedSJames Wright 19288626eedSJames Wright* - faceMarkerTop 19388626eedSJames Wright - +z 19488626eedSJames Wright - 3 19588626eedSJames Wright 19688626eedSJames Wright* - faceMarkerLeft 19788626eedSJames Wright - -x 19888626eedSJames Wright - 4 19988626eedSJames Wright::: 20088626eedSJames Wright 201b5e826a6SLeila Ghaffari:::{list-table} 3D Face ID Labels 20288626eedSJames Wright:header-rows: 1 20388626eedSJames Wright* - PETSc Face Name 20488626eedSJames Wright - Cartesian direction 20588626eedSJames Wright - Face ID 20688626eedSJames Wright 20788626eedSJames Wright* - faceMarkerBottom 20888626eedSJames Wright - -z 20988626eedSJames Wright - 1 21088626eedSJames Wright 21188626eedSJames Wright* - faceMarkerTop 21288626eedSJames Wright - +z 21388626eedSJames Wright - 2 21488626eedSJames Wright 21588626eedSJames Wright* - faceMarkerFront 21688626eedSJames Wright - -y 21788626eedSJames Wright - 3 21888626eedSJames Wright 21988626eedSJames Wright* - faceMarkerBack 22088626eedSJames Wright - +y 22188626eedSJames Wright - 4 22288626eedSJames Wright 22388626eedSJames Wright* - faceMarkerRight 22488626eedSJames Wright - +x 22588626eedSJames Wright - 5 22688626eedSJames Wright 22788626eedSJames Wright* - faceMarkerLeft 22888626eedSJames Wright - -x 22988626eedSJames Wright - 6 23088626eedSJames Wright::: 2314534a52eSLeila Ghaffari 2328a94a473SJed Brown### Boundary conditions 2338a94a473SJed Brown 2348a94a473SJed BrownBoundary conditions for compressible viscous flows are notoriously tricky. Here we offer some recommendations 2358a94a473SJed Brown 2368a94a473SJed Brown#### Inflow 2378a94a473SJed Brown 2388a94a473SJed 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). 2398a94a473SJed BrownIt is stable and the least reflective boundary condition for acoustics. 2408a94a473SJed Brown 2418a94a473SJed BrownIf near a viscous wall, you may want a specified inflow profile. 2428a94a473SJed BrownUse `bc_inflow` and see {ref}`example-blasius` and discussion of synthetic turbulence generation for ways to analytically generate developed inflow profiles. 2438a94a473SJed 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. 2448a94a473SJed BrownThe strong approach gives sharper resolution of velocity structures. 2458a94a473SJed BrownWe have described the primitive variable formulation here; the conservative variants are similar, but not equivalent. 2468a94a473SJed Brown 247f3f66076SJames Wright#### Outflow 2488a94a473SJed Brown 2498a94a473SJed BrownIf you know the complete exterior state, `bc_freestream` is the least reflective boundary condition, but is disruptive to viscous flow structures. 2508a94a473SJed BrownIf thermal anomalies must exit the domain, the Riemann solver must resolve the contact wave to avoid reflections. 2518a94a473SJed 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. 2528a94a473SJed Brown 2538a94a473SJed 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. 2548a94a473SJed Brown 2558a94a473SJed 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). 2568a94a473SJed BrownIn our experience, `riemann` is slightly less reflective but produces similar flows in cases of strict outflow. 2578a94a473SJed BrownThe `pressure` variant is retained to facilitate comparison with other codes, such as PHASTA-C, but we recommend `riemann` for general use. 2588a94a473SJed Brown 259f3f66076SJames Wright#### Periodicity 2608a94a473SJed Brown 2618a94a473SJed BrownPETSc provides two ways to specify periodicity: 2628a94a473SJed Brown 2638a94a473SJed Brown1. Topological periodicity, in which the donor and receiver dofs are the same, obtained using: 2648a94a473SJed Brown 2658a94a473SJed Brown```yaml 2668a94a473SJed Browndm_plex: 2678a94a473SJed Brown shape: box 2688a94a473SJed Brown box_faces: 10,12,4 2698a94a473SJed Brown box_bd: none,none,periodic 2708a94a473SJed Brown``` 2718a94a473SJed Brown 272ca69d878SAdeleke O. BankoleThe coordinates for such cases are stored as a new field with special cell-based indexing to enable wrapping through the boundary. 273ca69d878SAdeleke 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. 274ca69d878SAdeleke O. Bankole 275ca69d878SAdeleke O. Bankole2. Isoperiodicity, in which the donor and receiver dofs are distinct in local vectors. This is obtained using `zbox`, as in: 276ca69d878SAdeleke O. Bankole 277ca69d878SAdeleke O. Bankole```yaml 278ca69d878SAdeleke O. Bankoledm_plex: 279ca69d878SAdeleke O. Bankole shape: zbox 280ca69d878SAdeleke O. Bankole box_faces: 10,12,4 281ca69d878SAdeleke O. Bankole box_bd: none,none,periodic 282ca69d878SAdeleke O. Bankole``` 283ca69d878SAdeleke O. Bankole 284ca69d878SAdeleke O. BankoleIsoperiodicity enables standard boundary integrals, and is recommended for general use. 285ca69d878SAdeleke O. BankoleAt the time of this writing, it only supports one direction of periodicity. 286ca69d878SAdeleke 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. 2878a94a473SJed Brown 288019b7682STimothy Aiken### Advection 289019b7682STimothy Aiken 29017be3a41SJeremy 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$. 29117be3a41SJeremy L ThompsonThese are available in 2D and 3D. 292019b7682STimothy Aiken 293019b7682STimothy Aiken#### 2D advection 294019b7682STimothy Aiken 295bc7bbd5dSLeila GhaffariFor the 2D advection problem, the following additional command-line options are available: 296ccaff030SJeremy L Thompson 297bc7bbd5dSLeila Ghaffari:::{list-table} Advection2D Runtime Options 298bc7bbd5dSLeila Ghaffari:header-rows: 1 29989d0f5c0SLeila Ghaffari 300bc7bbd5dSLeila Ghaffari* - Option 301bc7bbd5dSLeila Ghaffari - Description 302bc7bbd5dSLeila Ghaffari - Default value 303bc7bbd5dSLeila Ghaffari - Unit 30489d0f5c0SLeila Ghaffari 305bc7bbd5dSLeila Ghaffari* - `-rc` 306bc7bbd5dSLeila Ghaffari - Characteristic radius of thermal bubble 307bc7bbd5dSLeila Ghaffari - `1000` 308bc7bbd5dSLeila Ghaffari - `m` 30989d0f5c0SLeila Ghaffari 310bc7bbd5dSLeila Ghaffari* - `-units_meter` 311bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 312bc7bbd5dSLeila Ghaffari - `1E-2` 313bc7bbd5dSLeila Ghaffari - 31489d0f5c0SLeila Ghaffari 315bc7bbd5dSLeila Ghaffari* - `-units_second` 316bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 317bc7bbd5dSLeila Ghaffari - `1E-2` 318bc7bbd5dSLeila Ghaffari - 31989d0f5c0SLeila Ghaffari 320bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 321bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 322bc7bbd5dSLeila Ghaffari - `1E-6` 323bc7bbd5dSLeila Ghaffari - 32477841947SLeila Ghaffari 325bc7bbd5dSLeila Ghaffari* - `-strong_form` 326bc7bbd5dSLeila Ghaffari - Strong (1) or weak/integrated by parts (0) residual 327bc7bbd5dSLeila Ghaffari - `0` 328bc7bbd5dSLeila Ghaffari - 32977841947SLeila Ghaffari 330bc7bbd5dSLeila Ghaffari* - `-stab` 331bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 332bc7bbd5dSLeila Ghaffari - `none` 333bc7bbd5dSLeila Ghaffari - 33477841947SLeila Ghaffari 335bc7bbd5dSLeila Ghaffari* - `-CtauS` 336bc7bbd5dSLeila Ghaffari - Scale coefficient for stabilization tau (nondimensional) 337bc7bbd5dSLeila Ghaffari - `0` 338bc7bbd5dSLeila Ghaffari - 33977841947SLeila Ghaffari 340bc7bbd5dSLeila Ghaffari* - `-wind_type` 341bc7bbd5dSLeila Ghaffari - Wind type in Advection (`rotation` or `translation`) 342bc7bbd5dSLeila Ghaffari - `rotation` 343bc7bbd5dSLeila Ghaffari - 34477841947SLeila Ghaffari 345bc7bbd5dSLeila Ghaffari* - `-wind_translation` 346bc7bbd5dSLeila Ghaffari - Constant wind vector when `-wind_type translation` 347bc7bbd5dSLeila Ghaffari - `1,0,0` 348bc7bbd5dSLeila Ghaffari - 34989d0f5c0SLeila Ghaffari 350bc7bbd5dSLeila Ghaffari* - `-E_wind` 351bc7bbd5dSLeila Ghaffari - Total energy of inflow wind when `-wind_type translation` 352bc7bbd5dSLeila Ghaffari - `1E6` 353bc7bbd5dSLeila Ghaffari - `J` 354bc7bbd5dSLeila Ghaffari::: 355e43605a5SLeila Ghaffari 356bc7bbd5dSLeila GhaffariAn example of the `rotation` mode can be run with: 357e43605a5SLeila Ghaffari 358bc7bbd5dSLeila Ghaffari``` 3594534a52eSLeila 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 360bc7bbd5dSLeila Ghaffari``` 361e43605a5SLeila Ghaffari 362bc7bbd5dSLeila Ghaffariand the `translation` mode with: 363e43605a5SLeila Ghaffari 364bc7bbd5dSLeila Ghaffari``` 3654534a52eSLeila 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 366bc7bbd5dSLeila Ghaffari``` 3674534a52eSLeila GhaffariNote the lengths in `-dm_plex_box_upper` are given in meters, and will be nondimensionalized according to `-units_meter`. 368e43605a5SLeila Ghaffari 369019b7682STimothy Aiken#### 3D advection 370019b7682STimothy Aiken 371bc7bbd5dSLeila GhaffariFor the 3D advection problem, the following additional command-line options are available: 372e43605a5SLeila Ghaffari 373bc7bbd5dSLeila Ghaffari:::{list-table} Advection3D Runtime Options 374bc7bbd5dSLeila Ghaffari:header-rows: 1 375e43605a5SLeila Ghaffari 376bc7bbd5dSLeila Ghaffari* - Option 377bc7bbd5dSLeila Ghaffari - Description 378bc7bbd5dSLeila Ghaffari - Default value 379bc7bbd5dSLeila Ghaffari - Unit 380e43605a5SLeila Ghaffari 381bc7bbd5dSLeila Ghaffari* - `-rc` 382bc7bbd5dSLeila Ghaffari - Characteristic radius of thermal bubble 383bc7bbd5dSLeila Ghaffari - `1000` 384bc7bbd5dSLeila Ghaffari - `m` 385e43605a5SLeila Ghaffari 386bc7bbd5dSLeila Ghaffari* - `-units_meter` 387bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 388bc7bbd5dSLeila Ghaffari - `1E-2` 389bc7bbd5dSLeila Ghaffari - 390e43605a5SLeila Ghaffari 391bc7bbd5dSLeila Ghaffari* - `-units_second` 392bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 393bc7bbd5dSLeila Ghaffari - `1E-2` 394bc7bbd5dSLeila Ghaffari - 395e43605a5SLeila Ghaffari 396bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 397bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 398bc7bbd5dSLeila Ghaffari - `1E-6` 399bc7bbd5dSLeila Ghaffari - 400e43605a5SLeila Ghaffari 401bc7bbd5dSLeila Ghaffari* - `-strong_form` 402bc7bbd5dSLeila Ghaffari - Strong (1) or weak/integrated by parts (0) residual 403bc7bbd5dSLeila Ghaffari - `0` 404bc7bbd5dSLeila Ghaffari - 405e43605a5SLeila Ghaffari 406bc7bbd5dSLeila Ghaffari* - `-stab` 407bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 408bc7bbd5dSLeila Ghaffari - `none` 409bc7bbd5dSLeila Ghaffari - 410e43605a5SLeila Ghaffari 411bc7bbd5dSLeila Ghaffari* - `-CtauS` 412bc7bbd5dSLeila Ghaffari - Scale coefficient for stabilization tau (nondimensional) 413bc7bbd5dSLeila Ghaffari - `0` 414bc7bbd5dSLeila Ghaffari - 415e43605a5SLeila Ghaffari 416bc7bbd5dSLeila Ghaffari* - `-wind_type` 417bc7bbd5dSLeila Ghaffari - Wind type in Advection (`rotation` or `translation`) 418bc7bbd5dSLeila Ghaffari - `rotation` 419bc7bbd5dSLeila Ghaffari - 420e43605a5SLeila Ghaffari 421bc7bbd5dSLeila Ghaffari* - `-wind_translation` 422bc7bbd5dSLeila Ghaffari - Constant wind vector when `-wind_type translation` 423bc7bbd5dSLeila Ghaffari - `1,0,0` 424bc7bbd5dSLeila Ghaffari - 425e43605a5SLeila Ghaffari 426bc7bbd5dSLeila Ghaffari* - `-E_wind` 427bc7bbd5dSLeila Ghaffari - Total energy of inflow wind when `-wind_type translation` 428bc7bbd5dSLeila Ghaffari - `1E6` 429bc7bbd5dSLeila Ghaffari - `J` 430e43605a5SLeila Ghaffari 431bc7bbd5dSLeila Ghaffari* - `-bubble_type` 432bc7bbd5dSLeila Ghaffari - `sphere` (3D) or `cylinder` (2D) 433f3f66076SJames Wright - `sphere` 434bc7bbd5dSLeila Ghaffari - 435e43605a5SLeila Ghaffari 436bc7bbd5dSLeila Ghaffari* - `-bubble_continuity` 437bc7bbd5dSLeila Ghaffari - `smooth`, `back_sharp`, or `thick` 438bc7bbd5dSLeila Ghaffari - `smooth` 439bc7bbd5dSLeila Ghaffari - 440bc7bbd5dSLeila Ghaffari::: 441ccaff030SJeremy L Thompson 442bc7bbd5dSLeila GhaffariAn example of the `rotation` mode can be run with: 443ccaff030SJeremy L Thompson 444bc7bbd5dSLeila Ghaffari``` 4454534a52eSLeila 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 446bc7bbd5dSLeila Ghaffari``` 447ccaff030SJeremy L Thompson 448bc7bbd5dSLeila Ghaffariand the `translation` mode with: 449ccaff030SJeremy L Thompson 450bc7bbd5dSLeila Ghaffari``` 4514534a52eSLeila 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 452bc7bbd5dSLeila Ghaffari``` 453ccaff030SJeremy L Thompson 454019b7682STimothy Aiken### Inviscid Ideal Gas 455019b7682STimothy Aiken 456019b7682STimothy Aiken#### Isentropic Euler vortex 457019b7682STimothy Aiken 458bc7bbd5dSLeila GhaffariFor the Isentropic Vortex problem, the following additional command-line options are available: 459ccaff030SJeremy L Thompson 460bc7bbd5dSLeila Ghaffari:::{list-table} Isentropic Vortex Runtime Options 461bc7bbd5dSLeila Ghaffari:header-rows: 1 462ccaff030SJeremy L Thompson 463bc7bbd5dSLeila Ghaffari* - Option 464bc7bbd5dSLeila Ghaffari - Description 465bc7bbd5dSLeila Ghaffari - Default value 466bc7bbd5dSLeila Ghaffari - Unit 467ccaff030SJeremy L Thompson 468bc7bbd5dSLeila Ghaffari* - `-center` 469bc7bbd5dSLeila Ghaffari - Location of vortex center 470bc7bbd5dSLeila Ghaffari - `(lx,ly,lz)/2` 471bc7bbd5dSLeila Ghaffari - `(m,m,m)` 472ccaff030SJeremy L Thompson 473bc7bbd5dSLeila Ghaffari* - `-units_meter` 474bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 475bc7bbd5dSLeila Ghaffari - `1E-2` 476bc7bbd5dSLeila Ghaffari - 477ccaff030SJeremy L Thompson 478bc7bbd5dSLeila Ghaffari* - `-units_second` 479bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 480bc7bbd5dSLeila Ghaffari - `1E-2` 481bc7bbd5dSLeila Ghaffari - 482ccaff030SJeremy L Thompson 483bc7bbd5dSLeila Ghaffari* - `-mean_velocity` 484bc7bbd5dSLeila Ghaffari - Background velocity vector 485bc7bbd5dSLeila Ghaffari - `(1,1,0)` 486bc7bbd5dSLeila Ghaffari - 487ccaff030SJeremy L Thompson 488bc7bbd5dSLeila Ghaffari* - `-vortex_strength` 489bc7bbd5dSLeila Ghaffari - Strength of vortex < 10 490bc7bbd5dSLeila Ghaffari - `5` 491bc7bbd5dSLeila Ghaffari - 492932417b3SJed Brown 493932417b3SJed Brown* - `-c_tau` 494932417b3SJed Brown - Stabilization constant 495504dc8e0SLeila Ghaffari - `0.5` 496932417b3SJed Brown - 497bc7bbd5dSLeila Ghaffari::: 498ccaff030SJeremy L Thompson 499bc7bbd5dSLeila GhaffariThis problem can be run with: 500ccaff030SJeremy L Thompson 501bc7bbd5dSLeila Ghaffari``` 5024534a52eSLeila 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. 503bc7bbd5dSLeila Ghaffari``` 504ccaff030SJeremy L Thompson 505019b7682STimothy Aiken#### Sod shock tube 506019b7682STimothy Aiken 507019b7682STimothy AikenFor the Shock Tube problem, the following additional command-line options are available: 508019b7682STimothy Aiken 509019b7682STimothy Aiken:::{list-table} Shock Tube Runtime Options 510019b7682STimothy Aiken:header-rows: 1 511019b7682STimothy Aiken 512019b7682STimothy Aiken* - Option 513019b7682STimothy Aiken - Description 514019b7682STimothy Aiken - Default value 515019b7682STimothy Aiken - Unit 516019b7682STimothy Aiken 517019b7682STimothy Aiken* - `-units_meter` 518019b7682STimothy Aiken - 1 meter in scaled length units 519019b7682STimothy Aiken - `1E-2` 520019b7682STimothy Aiken - 521019b7682STimothy Aiken 522019b7682STimothy Aiken* - `-units_second` 523019b7682STimothy Aiken - 1 second in scaled time units 524019b7682STimothy Aiken - `1E-2` 525019b7682STimothy Aiken - 526019b7682STimothy Aiken 527019b7682STimothy Aiken* - `-yzb` 528019b7682STimothy Aiken - Use YZB discontinuity capturing 529019b7682STimothy Aiken - `none` 530019b7682STimothy Aiken - 531019b7682STimothy Aiken 532019b7682STimothy Aiken* - `-stab` 533019b7682STimothy Aiken - Stabilization method (`none`, `su`, or `supg`) 534019b7682STimothy Aiken - `none` 535019b7682STimothy Aiken - 536019b7682STimothy Aiken::: 537019b7682STimothy Aiken 538019b7682STimothy AikenThis problem can be run with: 539019b7682STimothy Aiken 540019b7682STimothy Aiken``` 541019b7682STimothy 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 542019b7682STimothy Aiken``` 543019b7682STimothy Aiken 544019b7682STimothy Aiken### Newtonian viscosity, Ideal Gas 545019b7682STimothy Aiken 54688626eedSJames WrightFor the Density Current, Channel, and Blasius problems, the following common command-line options are available: 547ccaff030SJeremy L Thompson 54888626eedSJames Wright:::{list-table} Newtonian Ideal Gas problems Runtime Options 549bc7bbd5dSLeila Ghaffari:header-rows: 1 550ccaff030SJeremy L Thompson 551bc7bbd5dSLeila Ghaffari* - Option 552bc7bbd5dSLeila Ghaffari - Description 553bc7bbd5dSLeila Ghaffari - Default value 554bc7bbd5dSLeila Ghaffari - Unit 555ccaff030SJeremy L Thompson 556bc7bbd5dSLeila Ghaffari* - `-units_meter` 557bc7bbd5dSLeila Ghaffari - 1 meter in scaled length units 55888626eedSJames Wright - `1` 559bc7bbd5dSLeila Ghaffari - 560ccaff030SJeremy L Thompson 561bc7bbd5dSLeila Ghaffari* - `-units_second` 562bc7bbd5dSLeila Ghaffari - 1 second in scaled time units 56388626eedSJames Wright - `1` 564bc7bbd5dSLeila Ghaffari - 565ccaff030SJeremy L Thompson 566bc7bbd5dSLeila Ghaffari* - `-units_kilogram` 567bc7bbd5dSLeila Ghaffari - 1 kilogram in scaled mass units 56888626eedSJames Wright - `1` 569bc7bbd5dSLeila Ghaffari - 570ccaff030SJeremy L Thompson 571bc7bbd5dSLeila Ghaffari* - `-units_Kelvin` 572bc7bbd5dSLeila Ghaffari - 1 Kelvin in scaled temperature units 573bc7bbd5dSLeila Ghaffari - `1` 574bc7bbd5dSLeila Ghaffari - 575ccaff030SJeremy L Thompson 576bc7bbd5dSLeila Ghaffari* - `-stab` 577bc7bbd5dSLeila Ghaffari - Stabilization method (`none`, `su`, or `supg`) 578bc7bbd5dSLeila Ghaffari - `none` 579bc7bbd5dSLeila Ghaffari - 580ccaff030SJeremy L Thompson 581932417b3SJed Brown* - `-c_tau` 58288626eedSJames Wright - Stabilization constant, $c_\tau$ 583504dc8e0SLeila Ghaffari - `0.5` 584932417b3SJed Brown - 585932417b3SJed Brown 58688626eedSJames Wright* - `-Ctau_t` 58788626eedSJames Wright - Stabilization time constant, $C_t$ 58888626eedSJames Wright - `1.0` 58988626eedSJames Wright - 590ccaff030SJeremy L Thompson 59188626eedSJames Wright* - `-Ctau_v` 59288626eedSJames Wright - Stabilization viscous constant, $C_v$ 59394c01735SLeila Ghaffari - `36, 60, 128 for degree = 1, 2, 3` 59488626eedSJames Wright - 595ccaff030SJeremy L Thompson 59688626eedSJames Wright* - `-Ctau_C` 59788626eedSJames Wright - Stabilization continuity constant, $C_c$ 59888626eedSJames Wright - `1.0` 59988626eedSJames Wright - 600ccaff030SJeremy L Thompson 60188626eedSJames Wright* - `-Ctau_M` 60288626eedSJames Wright - Stabilization momentum constant, $C_m$ 60388626eedSJames Wright - `1.0` 60488626eedSJames Wright - 60588626eedSJames Wright 60688626eedSJames Wright* - `-Ctau_E` 60788626eedSJames Wright - Stabilization energy constant, $C_E$ 60888626eedSJames Wright - `1.0` 60988626eedSJames Wright - 610ccaff030SJeremy L Thompson 611bc7bbd5dSLeila Ghaffari* - `-cv` 612bc7bbd5dSLeila Ghaffari - Heat capacity at constant volume 613bc7bbd5dSLeila Ghaffari - `717` 614bc7bbd5dSLeila Ghaffari - `J/(kg K)` 615ccaff030SJeremy L Thompson 616bc7bbd5dSLeila Ghaffari* - `-cp` 617bc7bbd5dSLeila Ghaffari - Heat capacity at constant pressure 618bc7bbd5dSLeila Ghaffari - `1004` 619bc7bbd5dSLeila Ghaffari - `J/(kg K)` 620ccaff030SJeremy L Thompson 621bc7bbd5dSLeila Ghaffari* - `-g` 622bc7bbd5dSLeila Ghaffari - Gravitational acceleration 623bc7bbd5dSLeila Ghaffari - `9.81` 624bc7bbd5dSLeila Ghaffari - `m/s^2` 625ccaff030SJeremy L Thompson 626bc7bbd5dSLeila Ghaffari* - `-lambda` 627bc7bbd5dSLeila Ghaffari - Stokes hypothesis second viscosity coefficient 628bc7bbd5dSLeila Ghaffari - `-2/3` 629bc7bbd5dSLeila Ghaffari - 630ccaff030SJeremy L Thompson 631bc7bbd5dSLeila Ghaffari* - `-mu` 632bc7bbd5dSLeila Ghaffari - Shear dynamic viscosity coefficient 633bc7bbd5dSLeila Ghaffari - `75` 634bc7bbd5dSLeila Ghaffari - `Pa s` 63577841947SLeila Ghaffari 636bc7bbd5dSLeila Ghaffari* - `-k` 637bc7bbd5dSLeila Ghaffari - Thermal conductivity 638bc7bbd5dSLeila Ghaffari - `0.02638` 639bc7bbd5dSLeila Ghaffari - `W/(m K)` 640a1df05f8SJed Brown 641a1df05f8SJed Brown* - `-newtonian_unit_tests` 642a1df05f8SJed Brown - Developer option to test properties 643a1df05f8SJed Brown - `false` 644a1df05f8SJed Brown - boolean 645de2fdd78SJames Wright 6465c0afad3SJames Wright* - `-state_var` 6475c0afad3SJames Wright - State variables to solve solution with. `conservative` ($\rho, \rho \bm{u}, \rho e$) or `primitive` ($P, \bm{u}, T$) 6485c0afad3SJames Wright - `conservative` 6495c0afad3SJames Wright - string 650530ad8c4SKenneth E. Jansen 651530ad8c4SKenneth E. Jansen* - `-idl_decay_time` 652530ad8c4SKenneth E. Jansen - Characteristic timescale of the pressure deviance decay. The timestep is good starting point 653530ad8c4SKenneth E. Jansen - `-1` (disabled) 654530ad8c4SKenneth E. Jansen - `s` 655530ad8c4SKenneth E. Jansen 656530ad8c4SKenneth E. Jansen* - `-idl_start` 657530ad8c4SKenneth E. Jansen - Start of IDL in the x direction 658530ad8c4SKenneth E. Jansen - `0` 659530ad8c4SKenneth E. Jansen - `m` 660530ad8c4SKenneth E. Jansen 661530ad8c4SKenneth E. Jansen* - `-idl_length` 662530ad8c4SKenneth E. Jansen - Length of IDL in the positive x direction 663530ad8c4SKenneth E. Jansen - `0` 664530ad8c4SKenneth E. Jansen - `m` 665530ad8c4SKenneth E. Jansen 666c79d6dc9SJames Wright* - `-sgs_model_type` 667c79d6dc9SJames Wright - Type of subgrid stress model to use. Currently only `data_driven` is available 668c79d6dc9SJames Wright - `none` 669c79d6dc9SJames Wright - string 670c79d6dc9SJames Wright 671c79d6dc9SJames Wright* - `-sgs_model_dd_leakyrelu_alpha` 672c79d6dc9SJames Wright - Slope parameter for Leaky ReLU activation function. `0` corresponds to normal ReLU 673c79d6dc9SJames Wright - 0 674c79d6dc9SJames Wright - 675c79d6dc9SJames Wright 676c79d6dc9SJames Wright* - `-sgs_model_dd_parameter_dir` 677c79d6dc9SJames Wright - Path to directory with data-driven model parameters (weights, biases, etc.) 678c79d6dc9SJames Wright - `./dd_sgs_parameters` 679c79d6dc9SJames Wright - string 680c79d6dc9SJames Wright 681*3f89fbfdSJames Wright* - `-diff_filter_monitor` 682*3f89fbfdSJames Wright - Enable differential filter TSMonitor 683*3f89fbfdSJames Wright - `false` 684*3f89fbfdSJames Wright - boolean 685*3f89fbfdSJames Wright 686*3f89fbfdSJames Wright* - `-diff_filter_grid_based_width` 687*3f89fbfdSJames Wright - Use filter width based on the grid size 688*3f89fbfdSJames Wright - `false` 689*3f89fbfdSJames Wright - boolean 690*3f89fbfdSJames Wright 691*3f89fbfdSJames Wright* - `-diff_filter_width_scaling` 692*3f89fbfdSJames Wright - Anisotropic scaling for filter width in wall-aligned coordinates (snz) 693*3f89fbfdSJames Wright - `1,1,1` 694*3f89fbfdSJames Wright - `m` 695*3f89fbfdSJames Wright 696*3f89fbfdSJames Wright* - `-diff_filter_kernel_scaling` 697*3f89fbfdSJames Wright - Scaling to make differential kernel size equivalent to other filter kernels 698*3f89fbfdSJames Wright - `0.1` 699*3f89fbfdSJames Wright - `m^2` 700*3f89fbfdSJames Wright 701*3f89fbfdSJames Wright* - `-diff_filter_wall_damping_function` 702*3f89fbfdSJames Wright - Damping function to use at the wall for anisotropic filtering (`none`, `van_driest`) 703*3f89fbfdSJames Wright - `none` 704*3f89fbfdSJames Wright - string 705*3f89fbfdSJames Wright 706*3f89fbfdSJames Wright* - `-diff_filter_wall_damping_constant` 707*3f89fbfdSJames Wright - Constant for the wall-damping function. $\A^+$ for `van_driest` damping function. 708*3f89fbfdSJames Wright - 25 709*3f89fbfdSJames Wright - 710*3f89fbfdSJames Wright 711*3f89fbfdSJames Wright* - `-diff_filter_friction_length` 712*3f89fbfdSJames Wright - Friction length associated with the flow, $\delta_\nu$. Used in wall-damping functions 713*3f89fbfdSJames Wright - 0 714*3f89fbfdSJames Wright - `m` 715*3f89fbfdSJames Wright 716bc7bbd5dSLeila Ghaffari::: 71777841947SLeila Ghaffari 718530ad8c4SKenneth E. Jansen#### Gaussian Wave 7197ec884f8SJames Wright 720530ad8c4SKenneth E. JansenThe Gaussian wave problem has the following command-line options in addition to the Newtonian Ideal Gas options: 7217ec884f8SJames Wright 722530ad8c4SKenneth E. Jansen:::{list-table} Gaussian Wave Runtime Options 7237ec884f8SJames Wright:header-rows: 1 7247ec884f8SJames Wright 7257ec884f8SJames Wright* - Option 7267ec884f8SJames Wright - Description 7277ec884f8SJames Wright - Default value 7287ec884f8SJames Wright - Unit 7297ec884f8SJames Wright 730f1e435c9SJed Brown* - `-freestream_riemann` 731f1e435c9SJed Brown - Riemann solver for boundaries (HLL or HLLC) 732f1e435c9SJed Brown - `hllc` 733f1e435c9SJed Brown - 734f1e435c9SJed Brown 735f1e435c9SJed Brown* - `-freestream_velocity` 7367ec884f8SJames Wright - Freestream velocity vector 7377ec884f8SJames Wright - `0,0,0` 7387ec884f8SJames Wright - `m/s` 7397ec884f8SJames Wright 740f1e435c9SJed Brown* - `-freestream_temperature` 7417ec884f8SJames Wright - Freestream temperature 7427ec884f8SJames Wright - `288` 7437ec884f8SJames Wright - `K` 7447ec884f8SJames Wright 745f1e435c9SJed Brown* - `-freestream_pressure` 74689e3cb53SJames Wright - Freestream pressure 7477ec884f8SJames Wright - `1.01e5` 7487ec884f8SJames Wright - `Pa` 7497ec884f8SJames Wright 7507ec884f8SJames Wright* - `-epicenter` 7517ec884f8SJames Wright - Coordinates of center of perturbation 7527ec884f8SJames Wright - `0,0,0` 7537ec884f8SJames Wright - `m` 7547ec884f8SJames Wright 7557ec884f8SJames Wright* - `-amplitude` 7567ec884f8SJames Wright - Amplitude of the perturbation 7577ec884f8SJames Wright - `0.1` 7587ec884f8SJames Wright - 7597ec884f8SJames Wright 7607ec884f8SJames Wright* - `-width` 7617ec884f8SJames Wright - Width parameter of the perturbation 7627ec884f8SJames Wright - `0.002` 7637ec884f8SJames Wright - `m` 7647ec884f8SJames Wright 7657ec884f8SJames Wright::: 7667ec884f8SJames Wright 767530ad8c4SKenneth E. JansenThis problem can be run with the `gaussianwave.yaml` file via: 7687ec884f8SJames Wright 7697ec884f8SJames Wright``` 770530ad8c4SKenneth E. Jansen./navierstokes -options_file gaussianwave.yaml 7717ec884f8SJames Wright``` 7727ec884f8SJames Wright 773530ad8c4SKenneth E. Jansen```{literalinclude} ../../../../../examples/fluids/gaussianwave.yaml 7747ec884f8SJames Wright:language: yaml 7757ec884f8SJames Wright``` 776a1df05f8SJed Brown 777d310b3d3SAdeleke O. Bankole#### Vortex Shedding - Flow past Cylinder 778d310b3d3SAdeleke O. Bankole 779d310b3d3SAdeleke O. BankoleThe vortex shedding, flow past cylinder problem has the following command-line options in addition to the Newtonian Ideal Gas options: 780d310b3d3SAdeleke O. Bankole 781d310b3d3SAdeleke O. Bankole:::{list-table} Vortex Shedding Runtime Options 782d310b3d3SAdeleke O. Bankole:header-rows: 1 783d310b3d3SAdeleke O. Bankole 784d310b3d3SAdeleke O. Bankole* - Option 785d310b3d3SAdeleke O. Bankole - Description 786d310b3d3SAdeleke O. Bankole - Default value 787d310b3d3SAdeleke O. Bankole - Unit 788d310b3d3SAdeleke O. Bankole 789d310b3d3SAdeleke O. Bankole* - `-freestream_velocity` 790d310b3d3SAdeleke O. Bankole - Freestream velocity vector 791d310b3d3SAdeleke O. Bankole - `0,0,0` 792d310b3d3SAdeleke O. Bankole - `m/s` 793d310b3d3SAdeleke O. Bankole 794d310b3d3SAdeleke O. Bankole* - `-freestream_temperature` 795d310b3d3SAdeleke O. Bankole - Freestream temperature 796d310b3d3SAdeleke O. Bankole - `288` 797d310b3d3SAdeleke O. Bankole - `K` 798d310b3d3SAdeleke O. Bankole 799d310b3d3SAdeleke O. Bankole* - `-freestream_pressure` 800d310b3d3SAdeleke O. Bankole - Freestream pressure 801d310b3d3SAdeleke O. Bankole - `1.01e5` 802d310b3d3SAdeleke O. Bankole - `Pa` 803d310b3d3SAdeleke O. Bankole 804d310b3d3SAdeleke O. Bankole::: 805d310b3d3SAdeleke O. Bankole 806d310b3d3SAdeleke O. BankoleThe initial condition is taken from `-reference_temperature` and `-reference_pressure`. 807d310b3d3SAdeleke O. BankoleTo run this problem, first generate a mesh: 808d310b3d3SAdeleke O. Bankole 809d310b3d3SAdeleke O. Bankole```console 810d310b3d3SAdeleke O. Bankole$ make -C examples/fluids/meshes 811d310b3d3SAdeleke O. Bankole``` 812d310b3d3SAdeleke O. Bankole 813d310b3d3SAdeleke O. BankoleThen run by building the executable and running: 814d310b3d3SAdeleke O. Bankole 815d310b3d3SAdeleke O. Bankole```console 816d310b3d3SAdeleke O. Bankole$ make build/fluids-navierstokes 817ca69d878SAdeleke O. Bankole$ mpiexec -n 6 build/fluids-navierstokes -options_file examples/fluids/vortexshedding.yaml -{ts,snes}_monitor_ 818d310b3d3SAdeleke O. Bankole``` 819d310b3d3SAdeleke O. Bankole 820ca69d878SAdeleke O. BankoleThe vortex shedding period is roughly 5.6 and this problem runs until time 100 (2000 time steps). 821ca69d878SAdeleke 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. 822ca69d878SAdeleke O. Bankole 823ca69d878SAdeleke O. Bankole```console 824d6734f85SAdeleke O. Bankole$ python examples/fluids/postprocess/vortexshedding.py 825ca69d878SAdeleke O. Bankole``` 826d310b3d3SAdeleke O. Bankole 827d310b3d3SAdeleke O. Bankole```{literalinclude} ../../../../../examples/fluids/vortexshedding.yaml 828d310b3d3SAdeleke O. Bankole:language: yaml 829d310b3d3SAdeleke O. Bankole``` 830d310b3d3SAdeleke O. Bankole 831019b7682STimothy Aiken#### Density current 832019b7682STimothy Aiken 833061ff11eSJames WrightThe Density Current problem has the following command-line options in addition to the Newtonian Ideal Gas options: 83488626eedSJames Wright 83588626eedSJames Wright:::{list-table} Density Current Runtime Options 83688626eedSJames Wright:header-rows: 1 83788626eedSJames Wright 83888626eedSJames Wright* - Option 83988626eedSJames Wright - Description 84088626eedSJames Wright - Default value 84188626eedSJames Wright - Unit 84288626eedSJames Wright 84388626eedSJames Wright* - `-center` 84488626eedSJames Wright - Location of bubble center 84588626eedSJames Wright - `(lx,ly,lz)/2` 84688626eedSJames Wright - `(m,m,m)` 84788626eedSJames Wright 84888626eedSJames Wright* - `-dc_axis` 84988626eedSJames Wright - Axis of density current cylindrical anomaly, or `(0,0,0)` for spherically symmetric 85088626eedSJames Wright - `(0,0,0)` 85188626eedSJames Wright - 85288626eedSJames Wright 85388626eedSJames Wright* - `-rc` 85488626eedSJames Wright - Characteristic radius of thermal bubble 85588626eedSJames Wright - `1000` 85688626eedSJames Wright - `m` 85788626eedSJames Wright 85888626eedSJames Wright* - `-theta0` 85988626eedSJames Wright - Reference potential temperature 86088626eedSJames Wright - `300` 86188626eedSJames Wright - `K` 86288626eedSJames Wright 86388626eedSJames Wright* - `-thetaC` 86488626eedSJames Wright - Perturbation of potential temperature 86588626eedSJames Wright - `-15` 86688626eedSJames Wright - `K` 86788626eedSJames Wright 86888626eedSJames Wright* - `-P0` 86988626eedSJames Wright - Atmospheric pressure 87088626eedSJames Wright - `1E5` 87188626eedSJames Wright - `Pa` 87288626eedSJames Wright 87388626eedSJames Wright* - `-N` 87488626eedSJames Wright - Brunt-Vaisala frequency 87588626eedSJames Wright - `0.01` 87688626eedSJames Wright - `1/s` 87788626eedSJames Wright::: 87888626eedSJames Wright 879bc7bbd5dSLeila GhaffariThis problem can be run with: 880ccaff030SJeremy L Thompson 881bc7bbd5dSLeila Ghaffari``` 88288626eedSJames 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 88388626eedSJames Wright``` 88488626eedSJames Wright 885019b7682STimothy Aiken#### Channel flow 886019b7682STimothy Aiken 887061ff11eSJames WrightThe Channel problem has the following command-line options in addition to the Newtonian Ideal Gas options: 88888626eedSJames Wright 88988626eedSJames Wright:::{list-table} Channel Runtime Options 89088626eedSJames Wright:header-rows: 1 89188626eedSJames Wright 89288626eedSJames Wright* - Option 89388626eedSJames Wright - Description 89488626eedSJames Wright - Default value 89588626eedSJames Wright - Unit 89688626eedSJames Wright 89788626eedSJames Wright* - `-umax` 89888626eedSJames Wright - Maximum/centerline velocity of the flow 89988626eedSJames Wright - `10` 90088626eedSJames Wright - `m/s` 90188626eedSJames Wright 90288626eedSJames Wright* - `-theta0` 90388626eedSJames Wright - Reference potential temperature 90488626eedSJames Wright - `300` 90588626eedSJames Wright - `K` 90688626eedSJames Wright 90788626eedSJames Wright* - `-P0` 90888626eedSJames Wright - Atmospheric pressure 90988626eedSJames Wright - `1E5` 91088626eedSJames Wright - `Pa` 911a1df05f8SJed Brown 912a1df05f8SJed Brown* - `-body_force_scale` 913a1df05f8SJed Brown - Multiplier for body force (`-1` for flow reversal) 914a1df05f8SJed Brown - 1 915a1df05f8SJed Brown - 91688626eedSJames Wright::: 91788626eedSJames Wright 91888626eedSJames WrightThis problem can be run with the `channel.yaml` file via: 91988626eedSJames Wright 92088626eedSJames Wright``` 92188626eedSJames Wright./navierstokes -options_file channel.yaml 92288626eedSJames Wright``` 92388626eedSJames Wright```{literalinclude} ../../../../../examples/fluids/channel.yaml 92488626eedSJames Wright:language: yaml 92588626eedSJames Wright``` 92688626eedSJames Wright 9278a94a473SJed Brown(example-blasius)= 9288a94a473SJed Brown 929019b7682STimothy Aiken#### Blasius boundary layer 930019b7682STimothy Aiken 931061ff11eSJames WrightThe Blasius problem has the following command-line options in addition to the Newtonian Ideal Gas options: 93288626eedSJames Wright 93388626eedSJames Wright:::{list-table} Blasius Runtime Options 93488626eedSJames Wright:header-rows: 1 93588626eedSJames Wright 93688626eedSJames Wright* - Option 93788626eedSJames Wright - Description 93888626eedSJames Wright - Default value 93988626eedSJames Wright - Unit 94088626eedSJames Wright 941fb455ff0SLeila Ghaffari* - `-velocity_infinity` 94288626eedSJames Wright - Freestream velocity 94388626eedSJames Wright - `40` 94488626eedSJames Wright - `m/s` 94588626eedSJames Wright 946fb455ff0SLeila Ghaffari* - `-temperature_infinity` 947fb455ff0SLeila Ghaffari - Freestream temperature 94888626eedSJames Wright - `288` 94988626eedSJames Wright - `K` 95088626eedSJames Wright 951fb455ff0SLeila Ghaffari* - `-temperature_wall` 952fb455ff0SLeila Ghaffari - Wall temperature 95307d14e58SLeila Ghaffari - `288` 954fb455ff0SLeila Ghaffari - `K` 955fb455ff0SLeila Ghaffari 956fb455ff0SLeila Ghaffari* - `-delta0` 957fb455ff0SLeila Ghaffari - Boundary layer height at the inflow 958fb455ff0SLeila Ghaffari - `4.2e-3` 959fb455ff0SLeila Ghaffari - `m` 960fb455ff0SLeila Ghaffari 96188626eedSJames Wright* - `-P0` 96288626eedSJames Wright - Atmospheric pressure 96388626eedSJames Wright - `1.01E5` 96488626eedSJames Wright - `Pa` 96588626eedSJames Wright 96691eaef80SJames Wright* - `-platemesh_refine_height` 96791eaef80SJames Wright - Height at which `-platemesh_Ndelta` number of elements should refined into 96888626eedSJames Wright - `5.9E-4` 96988626eedSJames Wright - `m` 97088626eedSJames Wright 97191eaef80SJames Wright* - `-platemesh_Ndelta` 97291eaef80SJames Wright - Number of elements to keep below `-platemesh_refine_height` 97388626eedSJames Wright - `45` 97488626eedSJames Wright - 97588626eedSJames Wright 97691eaef80SJames Wright* - `-platemesh_growth` 97788626eedSJames Wright - Growth rate of the elements in the refinement region 97888626eedSJames Wright - `1.08` 97988626eedSJames Wright - 98088626eedSJames Wright 98191eaef80SJames Wright* - `-platemesh_top_angle` 98288626eedSJames Wright - Downward angle of the top face of the domain. This face serves as an outlet. 98388626eedSJames Wright - `5` 98488626eedSJames Wright - `degrees` 985ba6664aeSJames Wright 986ba6664aeSJames Wright* - `-stg_use` 987ba6664aeSJames Wright - Whether to use stg for the inflow conditions 988ba6664aeSJames Wright - `false` 989ba6664aeSJames Wright - 99091eaef80SJames Wright 99191eaef80SJames Wright* - `-platemesh_y_node_locs_path` 99291eaef80SJames Wright - Path to file with y node locations. If empty, will use mesh warping instead. 99391eaef80SJames Wright - `""` 99491eaef80SJames Wright - 995fb455ff0SLeila Ghaffari 99607d14e58SLeila Ghaffari* - `-n_chebyshev` 997fb455ff0SLeila Ghaffari - Number of Chebyshev terms 998fb455ff0SLeila Ghaffari - `20` 999fb455ff0SLeila Ghaffari - 1000fb455ff0SLeila Ghaffari 100107d14e58SLeila Ghaffari* - `-chebyshev_` 100207d14e58SLeila Ghaffari - Prefix for Chebyshev snes solve 100307d14e58SLeila Ghaffari - 100407d14e58SLeila Ghaffari - 100507d14e58SLeila Ghaffari 100688626eedSJames Wright::: 100788626eedSJames Wright 100888626eedSJames WrightThis problem can be run with the `blasius.yaml` file via: 100988626eedSJames Wright 101088626eedSJames Wright``` 101188626eedSJames Wright./navierstokes -options_file blasius.yaml 101288626eedSJames Wright``` 101388626eedSJames Wright 101488626eedSJames Wright```{literalinclude} ../../../../../examples/fluids/blasius.yaml 101588626eedSJames Wright:language: yaml 1016bc7bbd5dSLeila Ghaffari``` 1017ba6664aeSJames Wright 1018ba6664aeSJames Wright#### STG Inflow for Flat Plate 1019ba6664aeSJames Wright 102017be3a41SJeremy L ThompsonUsing the STG Inflow for the blasius problem adds the following command-line options: 1021ba6664aeSJames Wright 1022ba6664aeSJames Wright:::{list-table} Blasius Runtime Options 1023ba6664aeSJames Wright:header-rows: 1 1024ba6664aeSJames Wright 1025ba6664aeSJames Wright* - Option 1026ba6664aeSJames Wright - Description 1027ba6664aeSJames Wright - Default value 1028ba6664aeSJames Wright - Unit 1029ba6664aeSJames Wright 1030ba6664aeSJames Wright* - `-stg_inflow_path` 1031ba6664aeSJames Wright - Path to the STGInflow file 1032ba6664aeSJames Wright - `./STGInflow.dat` 1033ba6664aeSJames Wright - 1034ba6664aeSJames Wright 1035ba6664aeSJames Wright* - `-stg_rand_path` 1036ba6664aeSJames Wright - Path to the STGRand file 1037ba6664aeSJames Wright - `./STGRand.dat` 1038ba6664aeSJames Wright - 1039ba6664aeSJames Wright 1040ba6664aeSJames Wright* - `-stg_alpha` 1041ba6664aeSJames Wright - Growth rate of the wavemodes 1042ba6664aeSJames Wright - `1.01` 1043ba6664aeSJames Wright - 1044ba6664aeSJames Wright 1045ba6664aeSJames Wright* - `-stg_u0` 1046ba6664aeSJames Wright - Convective velocity, $U_0$ 1047ba6664aeSJames Wright - `0.0` 1048ba6664aeSJames Wright - `m/s` 1049ba6664aeSJames Wright 1050ba6664aeSJames Wright* - `-stg_mean_only` 1051ba6664aeSJames Wright - Only impose the mean velocity (no fluctutations) 1052ba6664aeSJames Wright - `false` 1053ba6664aeSJames Wright - 1054ba6664aeSJames Wright 105530af3636SJames Wright* - `-stg_strong` 105630af3636SJames Wright - Strongly enforce the STG inflow boundary condition 105730af3636SJames Wright - `false` 105830af3636SJames Wright - 105930af3636SJames Wright 106089060322SJames Wright* - `-stg_fluctuating_IC` 106189060322SJames Wright - "Extrude" the fluctuations through the domain as an initial condition 106289060322SJames Wright - `false` 106389060322SJames Wright - 106489060322SJames Wright 1065ba6664aeSJames Wright::: 1066ba6664aeSJames Wright 1067ba6664aeSJames WrightThis problem can be run with the `blasius.yaml` file via: 1068ba6664aeSJames Wright 1069ba6664aeSJames Wright``` 1070ba6664aeSJames Wright./navierstokes -options_file blasius.yaml -stg_use true 1071ba6664aeSJames Wright``` 1072ba6664aeSJames Wright 107317be3a41SJeremy L ThompsonNote the added `-stg_use true` flag 107417be3a41SJeremy L ThompsonThis overrides the `stg: use: false` setting in the `blasius.yaml` file, enabling the use of the STG inflow. 1075