xref: /honee/README.md (revision edd152dc729b650dbd7faeabfd488ced7046365d)
1ea10196cSJeremy L Thompson## libCEED: Navier-Stokes Example
2ea10196cSJeremy L Thompson
3ea10196cSJeremy L ThompsonThis page provides a description of the Navier-Stokes example for the libCEED library, based on PETSc.
4b9842f74SJeremy L ThompsonPETSc v3.17 or a development version of PETSc at commit 0e95d842 or later is required.
5ea10196cSJeremy L Thompson
6a515125bSLeila GhaffariThe Navier-Stokes problem solves the compressible Navier-Stokes equations in three dimensions using an explicit time integration.
7a515125bSLeila GhaffariThe state variables are mass density, momentum density, and energy density.
8ea10196cSJeremy L Thompson
9a515125bSLeila GhaffariThe main Navier-Stokes solver for libCEED is defined in [`navierstokes.c`](navierstokes.c) with different problem definitions according to the application of interest.
10ea10196cSJeremy L Thompson
11575f8106SLeila GhaffariBuild by using:
12ea10196cSJeremy L Thompson
13ea10196cSJeremy L Thompson`make`
14ea10196cSJeremy L Thompson
15575f8106SLeila Ghaffariand run with:
16ea10196cSJeremy L Thompson
17575f8106SLeila Ghaffari```
18575f8106SLeila Ghaffari./navierstokes -ceed [ceed] -problem [problem type] -degree [degree]
19575f8106SLeila Ghaffari```
20ea10196cSJeremy L Thompson
21575f8106SLeila Ghaffari## Runtime options
22ea10196cSJeremy L Thompson
23575f8106SLeila Ghaffari% inclusion-fluids-marker
24ea10196cSJeremy L Thompson
25575f8106SLeila GhaffariThe Navier-Stokes mini-app is controlled via command-line options.
26575f8106SLeila GhaffariThe following options are common among all problem types:
27ea10196cSJeremy L Thompson
28575f8106SLeila Ghaffari:::{list-table} Common Runtime Options
29575f8106SLeila Ghaffari:header-rows: 1
30ea10196cSJeremy L Thompson
31575f8106SLeila Ghaffari* - Option
32575f8106SLeila Ghaffari  - Description
33575f8106SLeila Ghaffari  - Default value
34ea10196cSJeremy L Thompson
35575f8106SLeila Ghaffari* - `-ceed`
36575f8106SLeila Ghaffari  - CEED resource specifier
37575f8106SLeila Ghaffari  - `/cpu/self/opt/blocked`
38ea10196cSJeremy L Thompson
39575f8106SLeila Ghaffari* - `-test`
40575f8106SLeila Ghaffari  - Run in test mode
41575f8106SLeila Ghaffari  - `false`
42ea10196cSJeremy L Thompson
43575f8106SLeila Ghaffari* - `-compare_final_state_atol`
44575f8106SLeila Ghaffari  - Test absolute tolerance
45575f8106SLeila Ghaffari  - `1E-11`
46ea10196cSJeremy L Thompson
47575f8106SLeila Ghaffari* - `-compare_final_state_filename`
48575f8106SLeila Ghaffari  - Test filename
49575f8106SLeila Ghaffari  -
50ea10196cSJeremy L Thompson
51575f8106SLeila Ghaffari* - `-problem`
52575f8106SLeila Ghaffari  - Problem to solve (`advection`, `advection2d`, `density_current`, or `euler_vortex`)
53575f8106SLeila Ghaffari  - `density_current`
54ea10196cSJeremy L Thompson
55575f8106SLeila Ghaffari* - `-implicit`
56575f8106SLeila Ghaffari  - Use implicit time integartor formulation
57575f8106SLeila Ghaffari  -
58ea10196cSJeremy L Thompson
59575f8106SLeila Ghaffari* - `-degree`
60575f8106SLeila Ghaffari  - Polynomial degree of tensor product basis (must be >= 1)
61575f8106SLeila Ghaffari  - `1`
62ea10196cSJeremy L Thompson
63c1680e98SJeremy L Thompson* - `-q_extra`
64575f8106SLeila Ghaffari  - Number of extra quadrature points
65575f8106SLeila Ghaffari  - `2`
66ea10196cSJeremy L Thompson
67575f8106SLeila Ghaffari* - `-viz_refine`
68575f8106SLeila Ghaffari  - Use regular refinement for visualization
69575f8106SLeila Ghaffari  - `0`
70ea10196cSJeremy L Thompson
71575f8106SLeila Ghaffari* - `-output_freq`
72575f8106SLeila Ghaffari  - Frequency of output, in number of steps
73575f8106SLeila Ghaffari  - `10`
74ea10196cSJeremy L Thompson
75575f8106SLeila Ghaffari* - `-continue`
76575f8106SLeila Ghaffari  - Continue from previous solution
77575f8106SLeila Ghaffari  - `0`
78ea10196cSJeremy L Thompson
79575f8106SLeila Ghaffari* - `-output_dir`
80575f8106SLeila Ghaffari  - Output directory
81575f8106SLeila Ghaffari  - `.`
82ea10196cSJeremy L Thompson
83f4277be3SLeila Ghaffari* - `-bc_wall`
84f4277be3SLeila Ghaffari  - Use wall boundary conditions on this list of faces
85f4277be3SLeila Ghaffari  -
86f4277be3SLeila Ghaffari
87f4277be3SLeila Ghaffari* - `-wall_comps`
88f4277be3SLeila Ghaffari  - An array of constrained component numbers for wall BCs
89f4277be3SLeila Ghaffari  -
90f4277be3SLeila Ghaffari
91f4277be3SLeila Ghaffari* - `-bc_slip_x`
92f4277be3SLeila Ghaffari  - Use slip boundary conditions, for the x component, on this list of faces
93f4277be3SLeila Ghaffari  -
94f4277be3SLeila Ghaffari
95f4277be3SLeila Ghaffari* - `-bc_slip_y`
96f4277be3SLeila Ghaffari  - Use slip boundary conditions, for the y component, on this list of faces
97f4277be3SLeila Ghaffari  -
98f4277be3SLeila Ghaffari
99f4277be3SLeila Ghaffari* - `-bc_slip_z`
100f4277be3SLeila Ghaffari  - Use slip boundary conditions, for the z component, on this list of faces
101f4277be3SLeila Ghaffari  -
102f4277be3SLeila Ghaffari
103f4277be3SLeila Ghaffari* - `-bc_inflow`
104f4277be3SLeila Ghaffari  - Use inflow boundary conditions on this list of faces
105f4277be3SLeila Ghaffari  -
106f4277be3SLeila Ghaffari
107f4277be3SLeila Ghaffari* - `-bc_outflow`
108f4277be3SLeila Ghaffari  - Use outflow boundary conditions on this list of faces
109f4277be3SLeila Ghaffari  -
1108ef11c93SLeila Ghaffari
111575f8106SLeila Ghaffari* - `-snes_view`
112575f8106SLeila Ghaffari  - View PETSc `SNES` nonlinear solver configuration
113575f8106SLeila Ghaffari  -
1148ef11c93SLeila Ghaffari
115575f8106SLeila Ghaffari* - `-log_view`
116575f8106SLeila Ghaffari  - View PETSc performance log
117575f8106SLeila Ghaffari  -
118ea10196cSJeremy L Thompson
119575f8106SLeila Ghaffari* - `-help`
120575f8106SLeila Ghaffari  - View comprehensive information about run-time options
121575f8106SLeila Ghaffari  -
122575f8106SLeila Ghaffari:::
123ea10196cSJeremy L Thompson
124f4277be3SLeila GhaffariFor the case of a square/cubic mesh, the list of face indices to be used with `-bc_wall`, `bc_inflow`, `bc_outflow` and/or `-bc_slip_x`, `-bc_slip_y`, and `-bc_slip_z` are:
125f4277be3SLeila Ghaffari
126bb8a0c61SJames Wright:::{list-table} 2D Face ID Labels
127bb8a0c61SJames Wright:header-rows: 1
128bb8a0c61SJames Wright* - PETSc Face Name
129bb8a0c61SJames Wright  - Cartesian direction
130bb8a0c61SJames Wright  - Face ID
131bb8a0c61SJames Wright
132bb8a0c61SJames Wright* - faceMarkerBottom
133bb8a0c61SJames Wright  - -z
134bb8a0c61SJames Wright  - 1
135bb8a0c61SJames Wright
136bb8a0c61SJames Wright* - faceMarkerRight
137bb8a0c61SJames Wright  - +x
138bb8a0c61SJames Wright  - 2
139bb8a0c61SJames Wright
140bb8a0c61SJames Wright* - faceMarkerTop
141bb8a0c61SJames Wright  - +z
142bb8a0c61SJames Wright  - 3
143bb8a0c61SJames Wright
144bb8a0c61SJames Wright* - faceMarkerLeft
145bb8a0c61SJames Wright  - -x
146bb8a0c61SJames Wright  - 4
147bb8a0c61SJames Wright:::
148bb8a0c61SJames Wright
149bb8a0c61SJames Wright:::{list-table} 2D Face ID Labels
150bb8a0c61SJames Wright:header-rows: 1
151bb8a0c61SJames Wright* - PETSc Face Name
152bb8a0c61SJames Wright  - Cartesian direction
153bb8a0c61SJames Wright  - Face ID
154bb8a0c61SJames Wright
155bb8a0c61SJames Wright* - faceMarkerBottom
156bb8a0c61SJames Wright  - -z
157bb8a0c61SJames Wright  - 1
158bb8a0c61SJames Wright
159bb8a0c61SJames Wright* - faceMarkerTop
160bb8a0c61SJames Wright  - +z
161bb8a0c61SJames Wright  - 2
162bb8a0c61SJames Wright
163bb8a0c61SJames Wright* - faceMarkerFront
164bb8a0c61SJames Wright  - -y
165bb8a0c61SJames Wright  - 3
166bb8a0c61SJames Wright
167bb8a0c61SJames Wright* - faceMarkerBack
168bb8a0c61SJames Wright  - +y
169bb8a0c61SJames Wright  - 4
170bb8a0c61SJames Wright
171bb8a0c61SJames Wright* - faceMarkerRight
172bb8a0c61SJames Wright  - +x
173bb8a0c61SJames Wright  - 5
174bb8a0c61SJames Wright
175bb8a0c61SJames Wright* - faceMarkerLeft
176bb8a0c61SJames Wright  - -x
177bb8a0c61SJames Wright  - 6
178bb8a0c61SJames Wright:::
179f4277be3SLeila Ghaffari
180af8870a9STimothy Aiken### Advection
181af8870a9STimothy Aiken
182af8870a9STimothy AikenFor 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$. These are available in 2D and 3D.
183af8870a9STimothy Aiken
184af8870a9STimothy Aiken#### 2D advection
185af8870a9STimothy Aiken
186575f8106SLeila GhaffariFor the 2D advection problem, the following additional command-line options are available:
187ea10196cSJeremy L Thompson
188575f8106SLeila Ghaffari:::{list-table} Advection2D Runtime Options
189575f8106SLeila Ghaffari:header-rows: 1
1908ef11c93SLeila Ghaffari
191575f8106SLeila Ghaffari* - Option
192575f8106SLeila Ghaffari  - Description
193575f8106SLeila Ghaffari  - Default value
194575f8106SLeila Ghaffari  - Unit
1958ef11c93SLeila Ghaffari
196575f8106SLeila Ghaffari* - `-rc`
197575f8106SLeila Ghaffari  - Characteristic radius of thermal bubble
198575f8106SLeila Ghaffari  - `1000`
199575f8106SLeila Ghaffari  - `m`
2008ef11c93SLeila Ghaffari
201575f8106SLeila Ghaffari* - `-units_meter`
202575f8106SLeila Ghaffari  - 1 meter in scaled length units
203575f8106SLeila Ghaffari  - `1E-2`
204575f8106SLeila Ghaffari  -
2058ef11c93SLeila Ghaffari
206575f8106SLeila Ghaffari* - `-units_second`
207575f8106SLeila Ghaffari  - 1 second in scaled time units
208575f8106SLeila Ghaffari  - `1E-2`
209575f8106SLeila Ghaffari  -
2108ef11c93SLeila Ghaffari
211575f8106SLeila Ghaffari* - `-units_kilogram`
212575f8106SLeila Ghaffari  - 1 kilogram in scaled mass units
213575f8106SLeila Ghaffari  - `1E-6`
214575f8106SLeila Ghaffari  -
215a515125bSLeila Ghaffari
216575f8106SLeila Ghaffari* - `-strong_form`
217575f8106SLeila Ghaffari  - Strong (1) or weak/integrated by parts (0) residual
218575f8106SLeila Ghaffari  - `0`
219575f8106SLeila Ghaffari  -
220a515125bSLeila Ghaffari
221575f8106SLeila Ghaffari* - `-stab`
222575f8106SLeila Ghaffari  - Stabilization method (`none`, `su`, or `supg`)
223575f8106SLeila Ghaffari  - `none`
224575f8106SLeila Ghaffari  -
225a515125bSLeila Ghaffari
226575f8106SLeila Ghaffari* - `-CtauS`
227575f8106SLeila Ghaffari  - Scale coefficient for stabilization tau (nondimensional)
228575f8106SLeila Ghaffari  - `0`
229575f8106SLeila Ghaffari  -
230a515125bSLeila Ghaffari
231575f8106SLeila Ghaffari* - `-wind_type`
232575f8106SLeila Ghaffari  - Wind type in Advection (`rotation` or `translation`)
233575f8106SLeila Ghaffari  - `rotation`
234575f8106SLeila Ghaffari  -
235a515125bSLeila Ghaffari
236575f8106SLeila Ghaffari* - `-wind_translation`
237575f8106SLeila Ghaffari  - Constant wind vector when `-wind_type translation`
238575f8106SLeila Ghaffari  - `1,0,0`
239575f8106SLeila Ghaffari  -
2408ef11c93SLeila Ghaffari
241575f8106SLeila Ghaffari* - `-E_wind`
242575f8106SLeila Ghaffari  - Total energy of inflow wind when `-wind_type translation`
243575f8106SLeila Ghaffari  - `1E6`
244575f8106SLeila Ghaffari  - `J`
245575f8106SLeila Ghaffari:::
246268c6924SLeila Ghaffari
247575f8106SLeila GhaffariAn example of the `rotation` mode can be run with:
248268c6924SLeila Ghaffari
249575f8106SLeila Ghaffari```
250f4277be3SLeila 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
251575f8106SLeila Ghaffari```
252268c6924SLeila Ghaffari
253575f8106SLeila Ghaffariand the `translation` mode with:
254268c6924SLeila Ghaffari
255575f8106SLeila Ghaffari```
256f4277be3SLeila 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
257575f8106SLeila Ghaffari```
258f4277be3SLeila GhaffariNote the lengths in `-dm_plex_box_upper` are given in meters, and will be nondimensionalized according to `-units_meter`.
259268c6924SLeila Ghaffari
260af8870a9STimothy Aiken#### 3D advection
261af8870a9STimothy Aiken
262575f8106SLeila GhaffariFor the 3D advection problem, the following additional command-line options are available:
263268c6924SLeila Ghaffari
264575f8106SLeila Ghaffari:::{list-table} Advection3D Runtime Options
265575f8106SLeila Ghaffari:header-rows: 1
266268c6924SLeila Ghaffari
267575f8106SLeila Ghaffari* - Option
268575f8106SLeila Ghaffari  - Description
269575f8106SLeila Ghaffari  - Default value
270575f8106SLeila Ghaffari  - Unit
271268c6924SLeila Ghaffari
272575f8106SLeila Ghaffari* - `-rc`
273575f8106SLeila Ghaffari  - Characteristic radius of thermal bubble
274575f8106SLeila Ghaffari  - `1000`
275575f8106SLeila Ghaffari  - `m`
276268c6924SLeila Ghaffari
277575f8106SLeila Ghaffari* - `-units_meter`
278575f8106SLeila Ghaffari  - 1 meter in scaled length units
279575f8106SLeila Ghaffari  - `1E-2`
280575f8106SLeila Ghaffari  -
281268c6924SLeila Ghaffari
282575f8106SLeila Ghaffari* - `-units_second`
283575f8106SLeila Ghaffari  - 1 second in scaled time units
284575f8106SLeila Ghaffari  - `1E-2`
285575f8106SLeila Ghaffari  -
286268c6924SLeila Ghaffari
287575f8106SLeila Ghaffari* - `-units_kilogram`
288575f8106SLeila Ghaffari  - 1 kilogram in scaled mass units
289575f8106SLeila Ghaffari  - `1E-6`
290575f8106SLeila Ghaffari  -
291268c6924SLeila Ghaffari
292575f8106SLeila Ghaffari* - `-strong_form`
293575f8106SLeila Ghaffari  - Strong (1) or weak/integrated by parts (0) residual
294575f8106SLeila Ghaffari  - `0`
295575f8106SLeila Ghaffari  -
296268c6924SLeila Ghaffari
297575f8106SLeila Ghaffari* - `-stab`
298575f8106SLeila Ghaffari  - Stabilization method (`none`, `su`, or `supg`)
299575f8106SLeila Ghaffari  - `none`
300575f8106SLeila Ghaffari  -
301268c6924SLeila Ghaffari
302575f8106SLeila Ghaffari* - `-CtauS`
303575f8106SLeila Ghaffari  - Scale coefficient for stabilization tau (nondimensional)
304575f8106SLeila Ghaffari  - `0`
305575f8106SLeila Ghaffari  -
306268c6924SLeila Ghaffari
307575f8106SLeila Ghaffari* - `-wind_type`
308575f8106SLeila Ghaffari  - Wind type in Advection (`rotation` or `translation`)
309575f8106SLeila Ghaffari  - `rotation`
310575f8106SLeila Ghaffari  -
311268c6924SLeila Ghaffari
312575f8106SLeila Ghaffari* - `-wind_translation`
313575f8106SLeila Ghaffari  - Constant wind vector when `-wind_type translation`
314575f8106SLeila Ghaffari  - `1,0,0`
315575f8106SLeila Ghaffari  -
316268c6924SLeila Ghaffari
317575f8106SLeila Ghaffari* - `-E_wind`
318575f8106SLeila Ghaffari  - Total energy of inflow wind when `-wind_type translation`
319575f8106SLeila Ghaffari  - `1E6`
320575f8106SLeila Ghaffari  - `J`
321268c6924SLeila Ghaffari
322575f8106SLeila Ghaffari* - `-bubble_type`
323575f8106SLeila Ghaffari  - `sphere` (3D) or `cylinder` (2D)
324575f8106SLeila Ghaffari  - `shpere`
325575f8106SLeila Ghaffari  -
326268c6924SLeila Ghaffari
327575f8106SLeila Ghaffari* - `-bubble_continuity`
328575f8106SLeila Ghaffari  - `smooth`, `back_sharp`, or `thick`
329575f8106SLeila Ghaffari  - `smooth`
330575f8106SLeila Ghaffari  -
331575f8106SLeila Ghaffari:::
332ea10196cSJeremy L Thompson
333575f8106SLeila GhaffariAn example of the `rotation` mode can be run with:
334ea10196cSJeremy L Thompson
335575f8106SLeila Ghaffari```
336f4277be3SLeila 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
337575f8106SLeila Ghaffari```
338ea10196cSJeremy L Thompson
339575f8106SLeila Ghaffariand the `translation` mode with:
340ea10196cSJeremy L Thompson
341575f8106SLeila Ghaffari```
342f4277be3SLeila 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
343575f8106SLeila Ghaffari```
344ea10196cSJeremy L Thompson
345af8870a9STimothy Aiken### Inviscid Ideal Gas
346af8870a9STimothy Aiken
347af8870a9STimothy Aiken#### Isentropic Euler vortex
348af8870a9STimothy Aiken
349575f8106SLeila GhaffariFor the Isentropic Vortex problem, the following additional command-line options are available:
350ea10196cSJeremy L Thompson
351575f8106SLeila Ghaffari:::{list-table} Isentropic Vortex Runtime Options
352575f8106SLeila Ghaffari:header-rows: 1
353ea10196cSJeremy L Thompson
354575f8106SLeila Ghaffari* - Option
355575f8106SLeila Ghaffari  - Description
356575f8106SLeila Ghaffari  - Default value
357575f8106SLeila Ghaffari  - Unit
358ea10196cSJeremy L Thompson
359575f8106SLeila Ghaffari* - `-center`
360575f8106SLeila Ghaffari  - Location of vortex center
361575f8106SLeila Ghaffari  - `(lx,ly,lz)/2`
362575f8106SLeila Ghaffari  - `(m,m,m)`
363ea10196cSJeremy L Thompson
364575f8106SLeila Ghaffari* - `-units_meter`
365575f8106SLeila Ghaffari  - 1 meter in scaled length units
366575f8106SLeila Ghaffari  - `1E-2`
367575f8106SLeila Ghaffari  -
368ea10196cSJeremy L Thompson
369575f8106SLeila Ghaffari* - `-units_second`
370575f8106SLeila Ghaffari  - 1 second in scaled time units
371575f8106SLeila Ghaffari  - `1E-2`
372575f8106SLeila Ghaffari  -
373ea10196cSJeremy L Thompson
374575f8106SLeila Ghaffari* - `-mean_velocity`
375575f8106SLeila Ghaffari  - Background velocity vector
376575f8106SLeila Ghaffari  - `(1,1,0)`
377575f8106SLeila Ghaffari  -
378ea10196cSJeremy L Thompson
379575f8106SLeila Ghaffari* - `-vortex_strength`
380575f8106SLeila Ghaffari  - Strength of vortex < 10
381575f8106SLeila Ghaffari  - `5`
382575f8106SLeila Ghaffari  -
383d8a22b9eSJed Brown
384d8a22b9eSJed Brown* - `-c_tau`
385d8a22b9eSJed Brown  - Stabilization constant
386f821ee77SLeila Ghaffari  - `0.5`
387d8a22b9eSJed Brown  -
388575f8106SLeila Ghaffari:::
389ea10196cSJeremy L Thompson
390575f8106SLeila GhaffariThis problem can be run with:
391ea10196cSJeremy L Thompson
392575f8106SLeila Ghaffari```
393f4277be3SLeila 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.
394575f8106SLeila Ghaffari```
395ea10196cSJeremy L Thompson
396af8870a9STimothy Aiken#### Sod shock tube
397af8870a9STimothy Aiken
398af8870a9STimothy AikenFor the Shock Tube problem, the following additional command-line options are available:
399af8870a9STimothy Aiken
400af8870a9STimothy Aiken:::{list-table} Shock Tube Runtime Options
401af8870a9STimothy Aiken:header-rows: 1
402af8870a9STimothy Aiken
403af8870a9STimothy Aiken* - Option
404af8870a9STimothy Aiken  - Description
405af8870a9STimothy Aiken  - Default value
406af8870a9STimothy Aiken  - Unit
407af8870a9STimothy Aiken
408af8870a9STimothy Aiken* - `-units_meter`
409af8870a9STimothy Aiken  - 1 meter in scaled length units
410af8870a9STimothy Aiken  - `1E-2`
411af8870a9STimothy Aiken  -
412af8870a9STimothy Aiken
413af8870a9STimothy Aiken* - `-units_second`
414af8870a9STimothy Aiken  - 1 second in scaled time units
415af8870a9STimothy Aiken  - `1E-2`
416af8870a9STimothy Aiken  -
417af8870a9STimothy Aiken
418af8870a9STimothy Aiken* - `-yzb`
419af8870a9STimothy Aiken  - Use YZB discontinuity capturing
420af8870a9STimothy Aiken  - `none`
421af8870a9STimothy Aiken  -
422af8870a9STimothy Aiken
423af8870a9STimothy Aiken* - `-stab`
424af8870a9STimothy Aiken  - Stabilization method (`none`, `su`, or `supg`)
425af8870a9STimothy Aiken  - `none`
426af8870a9STimothy Aiken  -
427af8870a9STimothy Aiken:::
428af8870a9STimothy Aiken
429af8870a9STimothy AikenThis problem can be run with:
430af8870a9STimothy Aiken
431af8870a9STimothy Aiken```
432af8870a9STimothy 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
433af8870a9STimothy Aiken```
434af8870a9STimothy Aiken
435af8870a9STimothy Aiken### Newtonian viscosity, Ideal Gas
436af8870a9STimothy Aiken
437bb8a0c61SJames WrightFor the Density Current, Channel, and Blasius problems, the following common command-line options are available:
438ea10196cSJeremy L Thompson
439bb8a0c61SJames Wright:::{list-table} Newtonian Ideal Gas problems Runtime Options
440575f8106SLeila Ghaffari:header-rows: 1
441ea10196cSJeremy L Thompson
442575f8106SLeila Ghaffari* - Option
443575f8106SLeila Ghaffari  - Description
444575f8106SLeila Ghaffari  - Default value
445575f8106SLeila Ghaffari  - Unit
446ea10196cSJeremy L Thompson
447575f8106SLeila Ghaffari* - `-units_meter`
448575f8106SLeila Ghaffari  - 1 meter in scaled length units
449bb8a0c61SJames Wright  - `1`
450575f8106SLeila Ghaffari  -
451ea10196cSJeremy L Thompson
452575f8106SLeila Ghaffari* - `-units_second`
453575f8106SLeila Ghaffari  - 1 second in scaled time units
454bb8a0c61SJames Wright  - `1`
455575f8106SLeila Ghaffari  -
456ea10196cSJeremy L Thompson
457575f8106SLeila Ghaffari* - `-units_kilogram`
458575f8106SLeila Ghaffari  - 1 kilogram in scaled mass units
459bb8a0c61SJames Wright  - `1`
460575f8106SLeila Ghaffari  -
461ea10196cSJeremy L Thompson
462575f8106SLeila Ghaffari* - `-units_Kelvin`
463575f8106SLeila Ghaffari  - 1 Kelvin in scaled temperature units
464575f8106SLeila Ghaffari  - `1`
465575f8106SLeila Ghaffari  -
466ea10196cSJeremy L Thompson
467575f8106SLeila Ghaffari* - `-stab`
468575f8106SLeila Ghaffari  - Stabilization method (`none`, `su`, or `supg`)
469575f8106SLeila Ghaffari  - `none`
470575f8106SLeila Ghaffari  -
471ea10196cSJeremy L Thompson
472d8a22b9eSJed Brown* - `-c_tau`
473bb8a0c61SJames Wright  - Stabilization constant, $c_\tau$
474f821ee77SLeila Ghaffari  - `0.5`
475d8a22b9eSJed Brown  -
476d8a22b9eSJed Brown
477bb8a0c61SJames Wright* - `-Ctau_t`
478bb8a0c61SJames Wright  - Stabilization time constant, $C_t$
479bb8a0c61SJames Wright  - `1.0`
480bb8a0c61SJames Wright  -
481ea10196cSJeremy L Thompson
482bb8a0c61SJames Wright* - `-Ctau_v`
483bb8a0c61SJames Wright  - Stabilization viscous constant, $C_v$
484bb8a0c61SJames Wright  - `36.0`
485bb8a0c61SJames Wright  -
486ea10196cSJeremy L Thompson
487bb8a0c61SJames Wright* - `-Ctau_C`
488bb8a0c61SJames Wright  - Stabilization continuity constant, $C_c$
489bb8a0c61SJames Wright  - `1.0`
490bb8a0c61SJames Wright  -
491ea10196cSJeremy L Thompson
492bb8a0c61SJames Wright* - `-Ctau_M`
493bb8a0c61SJames Wright  - Stabilization momentum constant, $C_m$
494bb8a0c61SJames Wright  - `1.0`
495bb8a0c61SJames Wright  -
496bb8a0c61SJames Wright
497bb8a0c61SJames Wright* - `-Ctau_E`
498bb8a0c61SJames Wright  - Stabilization energy constant, $C_E$
499bb8a0c61SJames Wright  - `1.0`
500bb8a0c61SJames Wright  -
501ea10196cSJeremy L Thompson
502575f8106SLeila Ghaffari* - `-cv`
503575f8106SLeila Ghaffari  - Heat capacity at constant volume
504575f8106SLeila Ghaffari  - `717`
505575f8106SLeila Ghaffari  - `J/(kg K)`
506ea10196cSJeremy L Thompson
507575f8106SLeila Ghaffari* - `-cp`
508575f8106SLeila Ghaffari  - Heat capacity at constant pressure
509575f8106SLeila Ghaffari  - `1004`
510575f8106SLeila Ghaffari  - `J/(kg K)`
511ea10196cSJeremy L Thompson
512575f8106SLeila Ghaffari* - `-g`
513575f8106SLeila Ghaffari  - Gravitational acceleration
514575f8106SLeila Ghaffari  - `9.81`
515575f8106SLeila Ghaffari  - `m/s^2`
516ea10196cSJeremy L Thompson
517575f8106SLeila Ghaffari* - `-lambda`
518575f8106SLeila Ghaffari  - Stokes hypothesis second viscosity coefficient
519575f8106SLeila Ghaffari  - `-2/3`
520575f8106SLeila Ghaffari  -
521ea10196cSJeremy L Thompson
522575f8106SLeila Ghaffari* - `-mu`
523575f8106SLeila Ghaffari  - Shear dynamic viscosity coefficient
524575f8106SLeila Ghaffari  - `75`
525575f8106SLeila Ghaffari  -  `Pa s`
526a515125bSLeila Ghaffari
527575f8106SLeila Ghaffari* - `-k`
528575f8106SLeila Ghaffari  - Thermal conductivity
529575f8106SLeila Ghaffari  - `0.02638`
530575f8106SLeila Ghaffari  - `W/(m K)`
531*edd152dcSJed Brown
532*edd152dcSJed Brown* - `-newtonian_unit_tests`
533*edd152dcSJed Brown  - Developer option to test properties
534*edd152dcSJed Brown  - `false`
535*edd152dcSJed Brown  - boolean
536575f8106SLeila Ghaffari:::
537a515125bSLeila Ghaffari
538*edd152dcSJed Brown
539af8870a9STimothy Aiken#### Density current
540af8870a9STimothy Aiken
541bb8a0c61SJames WrightThe Density Current problem the following command-line options are available in
542bb8a0c61SJames Wrightaddition to the Newtonian Ideal Gas options:
543bb8a0c61SJames Wright
544bb8a0c61SJames Wright:::{list-table} Density Current Runtime Options
545bb8a0c61SJames Wright:header-rows: 1
546bb8a0c61SJames Wright
547bb8a0c61SJames Wright* - Option
548bb8a0c61SJames Wright  - Description
549bb8a0c61SJames Wright  - Default value
550bb8a0c61SJames Wright  - Unit
551bb8a0c61SJames Wright
552bb8a0c61SJames Wright* - `-center`
553bb8a0c61SJames Wright  - Location of bubble center
554bb8a0c61SJames Wright  - `(lx,ly,lz)/2`
555bb8a0c61SJames Wright  - `(m,m,m)`
556bb8a0c61SJames Wright
557bb8a0c61SJames Wright* - `-dc_axis`
558bb8a0c61SJames Wright  - Axis of density current cylindrical anomaly, or `(0,0,0)` for spherically symmetric
559bb8a0c61SJames Wright  - `(0,0,0)`
560bb8a0c61SJames Wright  -
561bb8a0c61SJames Wright
562bb8a0c61SJames Wright* - `-rc`
563bb8a0c61SJames Wright  - Characteristic radius of thermal bubble
564bb8a0c61SJames Wright  - `1000`
565bb8a0c61SJames Wright  - `m`
566bb8a0c61SJames Wright
567bb8a0c61SJames Wright* - `-theta0`
568bb8a0c61SJames Wright  - Reference potential temperature
569bb8a0c61SJames Wright  - `300`
570bb8a0c61SJames Wright  - `K`
571bb8a0c61SJames Wright
572bb8a0c61SJames Wright* - `-thetaC`
573bb8a0c61SJames Wright  - Perturbation of potential temperature
574bb8a0c61SJames Wright  - `-15`
575bb8a0c61SJames Wright  - `K`
576bb8a0c61SJames Wright
577bb8a0c61SJames Wright* - `-P0`
578bb8a0c61SJames Wright  - Atmospheric pressure
579bb8a0c61SJames Wright  - `1E5`
580bb8a0c61SJames Wright  - `Pa`
581bb8a0c61SJames Wright
582bb8a0c61SJames Wright* - `-N`
583bb8a0c61SJames Wright  - Brunt-Vaisala frequency
584bb8a0c61SJames Wright  - `0.01`
585bb8a0c61SJames Wright  - `1/s`
586bb8a0c61SJames Wright:::
587bb8a0c61SJames Wright
588575f8106SLeila GhaffariThis problem can be run with:
589ea10196cSJeremy L Thompson
590575f8106SLeila Ghaffari```
591bb8a0c61SJames 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
592bb8a0c61SJames Wright```
593bb8a0c61SJames Wright
594af8870a9STimothy Aiken#### Channel flow
595af8870a9STimothy Aiken
596bb8a0c61SJames WrightThe Channel problem the following command-line options are available in
597bb8a0c61SJames Wrightaddition to the Newtonian Ideal Gas options:
598bb8a0c61SJames Wright
599bb8a0c61SJames Wright:::{list-table} Channel Runtime Options
600bb8a0c61SJames Wright:header-rows: 1
601bb8a0c61SJames Wright
602bb8a0c61SJames Wright* - Option
603bb8a0c61SJames Wright  - Description
604bb8a0c61SJames Wright  - Default value
605bb8a0c61SJames Wright  - Unit
606bb8a0c61SJames Wright
607bb8a0c61SJames Wright* - `-umax`
608bb8a0c61SJames Wright  - Maximum/centerline velocity of the flow
609bb8a0c61SJames Wright  - `10`
610bb8a0c61SJames Wright  - `m/s`
611bb8a0c61SJames Wright
612bb8a0c61SJames Wright* - `-theta0`
613bb8a0c61SJames Wright  - Reference potential temperature
614bb8a0c61SJames Wright  - `300`
615bb8a0c61SJames Wright  - `K`
616bb8a0c61SJames Wright
617bb8a0c61SJames Wright* - `-P0`
618bb8a0c61SJames Wright  - Atmospheric pressure
619bb8a0c61SJames Wright  - `1E5`
620bb8a0c61SJames Wright  - `Pa`
621*edd152dcSJed Brown
622*edd152dcSJed Brown* - `-body_force_scale`
623*edd152dcSJed Brown  - Multiplier for body force (`-1` for flow reversal)
624*edd152dcSJed Brown  - 1
625*edd152dcSJed Brown  -
626bb8a0c61SJames Wright:::
627bb8a0c61SJames Wright
628bb8a0c61SJames WrightThis problem can be run with the `channel.yaml` file via:
629bb8a0c61SJames Wright
630bb8a0c61SJames Wright```
631bb8a0c61SJames Wright./navierstokes -options_file channel.yaml
632bb8a0c61SJames Wright```
633bb8a0c61SJames Wright```{literalinclude} ../../../../../examples/fluids/channel.yaml
634bb8a0c61SJames Wright:language: yaml
635bb8a0c61SJames Wright```
636bb8a0c61SJames Wright
637af8870a9STimothy Aiken#### Blasius boundary layer
638af8870a9STimothy Aiken
639bb8a0c61SJames WrightThe Blasius problem the following command-line options are available in
640bb8a0c61SJames Wrightaddition to the Newtonian Ideal Gas options:
641bb8a0c61SJames Wright
642bb8a0c61SJames Wright:::{list-table} Blasius Runtime Options
643bb8a0c61SJames Wright:header-rows: 1
644bb8a0c61SJames Wright
645bb8a0c61SJames Wright* - Option
646bb8a0c61SJames Wright  - Description
647bb8a0c61SJames Wright  - Default value
648bb8a0c61SJames Wright  - Unit
649bb8a0c61SJames Wright
650bb8a0c61SJames Wright* - `-Uinf`
651bb8a0c61SJames Wright  - Freestream velocity
652bb8a0c61SJames Wright  - `40`
653bb8a0c61SJames Wright  - `m/s`
654bb8a0c61SJames Wright
655bb8a0c61SJames Wright* - `-delta0`
656bb8a0c61SJames Wright  - Boundary layer height at the inflow
657bb8a0c61SJames Wright  - `4.2e-4`
658bb8a0c61SJames Wright  - `m`
659bb8a0c61SJames Wright
660bb8a0c61SJames Wright* - `-theta0`
661bb8a0c61SJames Wright  - Reference potential temperature
662bb8a0c61SJames Wright  - `288`
663bb8a0c61SJames Wright  - `K`
664bb8a0c61SJames Wright
665bb8a0c61SJames Wright* - `-P0`
666bb8a0c61SJames Wright  - Atmospheric pressure
667bb8a0c61SJames Wright  - `1.01E5`
668bb8a0c61SJames Wright  - `Pa`
669bb8a0c61SJames Wright
67098b448e2SJames Wright* - `-platemesh_refine_height`
67198b448e2SJames Wright  - Height at which `-platemesh_Ndelta` number of elements should refined into
672bb8a0c61SJames Wright  - `5.9E-4`
673bb8a0c61SJames Wright  - `m`
674bb8a0c61SJames Wright
67598b448e2SJames Wright* - `-platemesh_Ndelta`
67698b448e2SJames Wright  - Number of elements to keep below `-platemesh_refine_height`
677bb8a0c61SJames Wright  - `45`
678bb8a0c61SJames Wright  -
679bb8a0c61SJames Wright
68098b448e2SJames Wright* - `-platemesh_growth`
681bb8a0c61SJames Wright  - Growth rate of the elements in the refinement region
682bb8a0c61SJames Wright  - `1.08`
683bb8a0c61SJames Wright  -
684bb8a0c61SJames Wright
68598b448e2SJames Wright* - `-platemesh_top_angle`
686bb8a0c61SJames Wright  - Downward angle of the top face of the domain. This face serves as an outlet.
687bb8a0c61SJames Wright  - `5`
688bb8a0c61SJames Wright  - `degrees`
689493642f1SJames Wright
690493642f1SJames Wright* - `-stg_use`
691493642f1SJames Wright  - Whether to use stg for the inflow conditions
692493642f1SJames Wright  - `false`
693493642f1SJames Wright  -
69498b448e2SJames Wright
69598b448e2SJames Wright* - `-platemesh_y_node_locs_path`
69698b448e2SJames Wright  - Path to file with y node locations. If empty, will use mesh warping instead.
69798b448e2SJames Wright  - `""`
69898b448e2SJames Wright  -
699bb8a0c61SJames Wright:::
700bb8a0c61SJames Wright
701bb8a0c61SJames WrightThis problem can be run with the `blasius.yaml` file via:
702bb8a0c61SJames Wright
703bb8a0c61SJames Wright```
704bb8a0c61SJames Wright./navierstokes -options_file blasius.yaml
705bb8a0c61SJames Wright```
706bb8a0c61SJames Wright
707bb8a0c61SJames Wright```{literalinclude} ../../../../../examples/fluids/blasius.yaml
708bb8a0c61SJames Wright:language: yaml
709575f8106SLeila Ghaffari```
710493642f1SJames Wright
711493642f1SJames Wright#### STG Inflow for Flat Plate
712493642f1SJames Wright
713493642f1SJames WrightUsing the STG Inflow for the blasius problem adds the following command-line
714493642f1SJames Wrightoptions:
715493642f1SJames Wright
716493642f1SJames Wright:::{list-table} Blasius Runtime Options
717493642f1SJames Wright:header-rows: 1
718493642f1SJames Wright
719493642f1SJames Wright* - Option
720493642f1SJames Wright  - Description
721493642f1SJames Wright  - Default value
722493642f1SJames Wright  - Unit
723493642f1SJames Wright
724493642f1SJames Wright* - `-stg_inflow_path`
725493642f1SJames Wright  - Path to the STGInflow file
726493642f1SJames Wright  - `./STGInflow.dat`
727493642f1SJames Wright  -
728493642f1SJames Wright
729493642f1SJames Wright* - `-stg_rand_path`
730493642f1SJames Wright  - Path to the STGRand file
731493642f1SJames Wright  - `./STGRand.dat`
732493642f1SJames Wright  -
733493642f1SJames Wright
734493642f1SJames Wright* - `-stg_alpha`
735493642f1SJames Wright  - Growth rate of the wavemodes
736493642f1SJames Wright  - `1.01`
737493642f1SJames Wright  -
738493642f1SJames Wright
739493642f1SJames Wright* - `-stg_u0`
740493642f1SJames Wright  - Convective velocity, $U_0$
741493642f1SJames Wright  - `0.0`
742493642f1SJames Wright  - `m/s`
743493642f1SJames Wright
744493642f1SJames Wright* - `-stg_mean_only`
745493642f1SJames Wright  - Only impose the mean velocity (no fluctutations)
746493642f1SJames Wright  - `false`
747493642f1SJames Wright  -
748493642f1SJames Wright
74929ea39e3SJames Wright* - `-stg_strong`
75029ea39e3SJames Wright  - Strongly enforce the STG inflow boundary condition
75129ea39e3SJames Wright  - `false`
75229ea39e3SJames Wright  -
75329ea39e3SJames Wright
754493642f1SJames Wright:::
755493642f1SJames Wright
756493642f1SJames WrightThis problem can be run with the `blasius.yaml` file via:
757493642f1SJames Wright
758493642f1SJames Wright```
759493642f1SJames Wright./navierstokes -options_file blasius.yaml -stg_use true
760493642f1SJames Wright```
761493642f1SJames Wright
762493642f1SJames WrightNote the added `-stg_use true` flag. This overrides the `stg: use: false`
763493642f1SJames Wrightsetting in the `blasius.yaml` file, enabling the use of the STG inflow.
764