Appearance
Reflux policy: troubled against always
| ID | Group | Milestone | Backends | Figure | Regression |
|---|---|---|---|---|---|
| E2 (E1) | Seam studies | M6 (#68) | FNL (flags checked equal to the CPU's); AO euler-tq: CPU, FNL | yes | — |
Case and scope
The Berger–Colella reflux keeps a 2:1 seam conservative, and caps the composite at second order (AO, B1): it replaces the coarse face flux by the restricted fine one everywhere. B2 showed in a prototype that a sensor-gated reflux recovers the order and keeps the shocks in place (D-M6-4: go). E1 builds [numerics] reflux_policy = troubled; E2 measures it against always on the four checks of the plan: the smooth order (A1), the shock crossings (A3), the integral drift (A4) and the seam divergence (A2).
Models and numerics
| Item | Choice | Code |
|---|---|---|
reflux_policy = always | default: every seam face cell takes the restricted fine flux | apply_reflux_to_stage_forest, adam_flume_cpu_object.F90 |
reflux_policy = troubled | the reflux applies only at the seam face cells flagged in a stage of the step: those the positivity limiter blended, and those where the WENO-5 sensor | flag_troubled_seam_cells, adam_flume_cpu_object.F90 and adam_flume_fnl_object.F90; seam_weno5_sensor, adam_flume_seam_sync_object.F90; FLUX_CORRECTION_SENSOR_TAU, adam_flume_parameters.F90 |
| Key | [numerics] reflux_policy, with reflux = .true. | adam_flume_numerics_object.F90 |
| Seam operators | default (mean + tricubic) or lagrange6 + quintic | C1, D1 |
| Scheme, time | as in each baseline case | numerics |
Initial and boundary conditions
| Check | Setup |
|---|---|
| A1 | the AO euler and mhd ladders, lagrange6 + quintic (euler-tq) |
| A3 | the AS crossings, Sod and RJ2a, c2f and f2c |
| A4 | the AL vortex (c2f |
| A2 | the AD cpaw, |
FNL, 2 ranks.
Input files
| File | Role |
|---|---|
src/tests/flume/verification/amr-order/check.sh --legs euler-tq | the AO leg under troubled with lagrange6 + quintic: orders euler-q6 baseline plus 2 % |
src/tests/flume/verification/amr-order/make_amr_order.py --reflux-policy troubled | the other AO runs |
src/tests/flume/verification/amr-shock/make_amr_shock.py --reflux-policy troubled | the crossings |
src/tests/flume/verification/make_doc_runs.sh <runs> seams, make_doc_figures.py --only reflux-policy | re-runs the crossings e2-troubled-{c2f,f2c} and d-quintic-{c2f,f2c} (CPU); the AO ladders from the kept work directories |
bash
cd src/tests/flume/verification/amr-order && ./check.sh --legs euler-tq
FLUME_EXE=$PWD/../../../../../exe/adam_flume_fnl ./check.sh --legs euler-tqThe A2 and A4 runs under troubled: amr-divb/make_amr_divb.py --reflux-policy troubled and amr-log/check.sh --reflux-policy troubled (issue #85 R2b; before, the policy was added to the inputs by hand).
Results

CPU. Left: the AO ladder, troubled with lagrange6 + quintic at the order of the run without reflux (6.11), today's operators at 2. Centre and right: the Sod shock after the crossing, lagrange6 + quintic under always and troubled: the same profile (the shock faces are flagged, so they are refluxed).
| Check | always | troubled |
|---|---|---|
| AO euler, default operators, N = 256: L1, order | ||
AO euler, lagrange6 + quintic, N = 256: L1, order | ||
| AO mhd, default operators, N = 256: L1, order | ||
| AO face cells flagged, N = 64 / 128 / 256 | — | 3–5 % / 0–0.6 % / 0 % |
| A3 shock position (Sod, RJ2a, c2f and f2c) | reference | equal within |
| A3 plateau and band defects | reference | within 1 % (RJ2a c2f band +44 %) |
| A3 mass drift | ||
| A4 drift, vortex N = 64 to | ||
| A4 drift, Sod c2f | ||
| CPAW D_flux seam floor, N = 64 / 128 (growth) |
On FNL the flags equal the CPU's to the cell.
Related cases: B2 is the prototype; AL measured the sensor's false positives; G3a uses troubled as the #78 workaround.
Findings
- The reflux was what capped the high-order seam operators. With
lagrange6andquinticthe reflux on (always) holds the vortex at second order,; under troubledno smooth face is flagged once resolved and the run is sixth order,, the error of the uniform coarse run (67 times smaller). AO leg euler-tqasserts it. - Shocks are unchanged: positions equal to
cells, defects within 1 % but one band value; the flags cover 35 to 42 % of the face-cell steps of a crossing. - Conservation is the price: an unflagged face keeps its flux mismatch, so the integrals drift at the reflux-off rate on smooth flows (
per period at , bounded but one component accumulating) and by across a shock. - MHD: the D_flux seam floor is bounded and 1.4 times lower at
(83 against 119 times the uniform floor). - Decision (D-M6-2, owner): the default stays
always, exactly conservative;troubledis the opt-in that makes the high-order seam operators worth their cost with the reflux on.