Appearance
Integral drift and the WENO sensor near seams
| ID | Group | Milestone | Backends | Figure | Regression |
|---|---|---|---|---|---|
| AL (A4) | Seam accuracy and divergence | M6 (#68) | CPU, FNL (the two backends log the same values) | yes | — |
Case and scope
The reflux policy of Phase E (reflux_policy = troubled) turns the reflux off at the seam faces that a WENO sensor judges smooth. Two quantities decide whether that is safe and where its threshold sits, and no check logged either:
- how the conserved integrals drift when the reflux is off (bounded, or accumulating?);
- what the sensor reads on the seam faces of a smooth flow (false positives) and of a shock crossing (detections).
AL logs both on two legs, each run with the reflux on and off. It asserts only the conservation of the reflux; the rest is a log.
What the case catches:
- a reflux that stops conserving: with the reflux on, every logged integral must drift at most
.
Models and numerics
| Item | Choice | Code |
|---|---|---|
| Equations | compressible Euler, ideal gas, | models |
| Space | WENO5 (weno-u-5) flux splitting on characteristic variables | compute_residuals_weno, adam_flume_cpu_object.F90 |
| Time | vortex: SSP Runge–Kutta 5 stages (runge-kutta-ssp-54), CFL 0.4; sod: SSP Runge–Kutta 3 stages (runge-kutta-ssp-33), CFL 0.5 | adam_rk_object.F90 |
| Seam operators | mean restriction, tricubic fill | numerics |
| Reflux | Berger–Colella on, or off (--no-reflux, a measurement, not a supported configuration) | apply_reflux_to_stage_forest, adam_flume_cpu_object.F90 |
| Conservation history | [diagnostics] conservation_history_save | compute_conservation, adam_flume_cpu_object.F90 |
| Sensor (post-processing) | adam_weno_object (Jiang–Shu, | amr_log.py; adam_weno_object.F90; FLUX_CORRECTION_SENSOR_TAU, adam_flume_parameters.F90 |
| Boundaries | vortex: periodic in sod: extrapolation | boundary conditions |
Initial and boundary conditions
| Leg | Setup | Conserved integrals logged |
|---|---|---|
vortex | the AO Euler vortex: quadtree, quadrant | |
sod | the AS Sod c2f: octree, |
Both legs run with the reflux on and off, a checkpoint every 10 steps, 2 ranks.
Input files
| File | Role |
|---|---|
src/tests/flume/verification/amr-order/make_amr_order.py | the vortex inputs (--cells 64 --time-max 1.0 --it-save 10 [--no-reflux]) |
src/tests/flume/verification/amr-shock/make_amr_shock.py | the sod inputs (--cells 200 --side c2f --it-save 10 [--no-reflux]) |
src/tests/flume/verification/amr-log/amr_log.py | drift and sensor logs |
src/tests/flume/verification/make_doc_figures.py --only integral-drift | the figure, from the kept work directories of amr-log/check.sh (CPU) |
src/tests/flume/verification/amr-log/check.sh | runs the legs (--legs vortex,sod, --np N, --reflux-policy always|troubled, --keep) |
bash
cd src/tests/flume/verification/amr-log && ./check.sh # CPU: about 11 min
FLUME_EXE=$PWD/../../../../../exe/adam_flume_fnl ./check.sh # FNL: about 5 minLogs (amr_log.py):
- drift: the relative drift
of the integrals of the conservation history, its maximum, and its growth (the mean drift over the last quarter of the run over that of the second quarter: about 1 when bounded, for a linear drift; "a jump" when the second quarter holds less than 1 % of the maximum, as before a shock first crosses a face); - sensor: on every checkpoint,
of every face along every non-null axis, the minimum over , , (primitive variables) and over the two reconstructions beside the face, recomputed from the checkpoints, whose ghosts are filled right before the save as the stencils read them. Per region (the seam band, the faces within ngcof their own spacing from the 2:1 faces; the interior): the minimumand the fraction of faces below .
The default scheme weights its characteristic split fluxes, so the map is the sensor a seam policy would read, not a dump of the scheme's own weights.
Results

CPU, from the work directories amr-log/check.sh --keep and --reflux-policy troubled --keep leave: the relative drift of mass and energy per step. The reflux keeps both at round-off; without it the vortex drifts to troubled the smooth vortex drifts as without reflux, so the sensor leaves its seam faces unrefluxed, the Sod crossing only to
Drift (2 ranks):
| Leg | Bound, reflux on | Reflux on: max drift | Reflux off: max drift (mass, energy) | Reflux off: growth |
|---|---|---|---|---|
| vortex | 1.4 to 7.7 | |||
| sod | a jump at the crossing |
Sensor, faces with
| Leg | Seam band: largest (mean) fraction | Interior: largest (mean) fraction |
|---|---|---|
| vortex | 0.110 (0.053) | 0.051 (0.020) |
| sod | 1.000 (0.172) | 0.128 (0.078) |
Related cases: E2 builds the troubled policy on these logs; B2 is its scalar prototype; the reflux conservation on uniform-level seams is conservation across AMR seams.
Findings
- Without the reflux, a smooth flow's drift accumulates. Every seam crossing adds to it: by one period the vortex has lost about
of its mass and energy, and the growth (1.4 to 7.7) says the drift is not bounded. A shock adds in one crossing. The reflux keeps both at round-off. - The sensor detects the crossing shock. In the Sod run the seam band reads
until the shock reaches it, 67 to 100 % of its faces are below while the shock crosses ( to 0.152), and 0 to 13 % after, where the A3 defect sits. - It also flags smooth seam faces. On the vortex, up to 11 % of the band faces (mean 5 %) read
, 2.6 times the interior's mean fraction: the JS weights drop at the extrema of a smooth profile, and more so where the seam's second-order error adds kinks. For reflux_policy = troubleda false positive keeps the reflux, the conservative choice: the cost is the order on those faces, which Phase B2 measures. The threshold is not tuned here.