Appearance
Accuracy across 2:1 seams
| ID | Group | Milestone | Backends | Figure | Regression |
|---|---|---|---|---|---|
| VV-8 | Dissipative terms (M4) | M4 (#65) | CPU, FNL | yes | — |
Case and scope
The diagonal shear wave of VV-1 and the diagonal Ohmic wave of VV-5 on a quadtree with its centre refined 2:1, against the exact linear solution.
What the case catches: conservation says nothing about accuracy, and a seam can conserve (VV-7) and still degrade the order. The case measures the order of the composite grid, and, with the reflux off, whether the dissipative flux crossing the seam is the one the register replaces.
Models and numerics
| Item | Choice | Code |
|---|---|---|
| Equations | Euler with mhd-none) with | models, ideal MHD |
| Dissipative fluxes | dissipative_order = 4 | add_dissipative_fluxes_o4, add_resistive_fluxes_o4, adam_flume_cpu_dissipation_kernels.F90; numerics |
| Inviscid fluxes | WENO5 flux splitting, characteristic variables | compute_residuals_weno, adam_flume_cpu_object.F90 |
| Time | runge-kutta-ssp-54, CFL 0.2 | adam_rk_object.F90 |
| Coarse ghosts | mean restriction (a coarse ghost is the mean of the fine point values under it) | boundary conditions |
| Fine ghosts | the tricubic coarse-to-fine fill | boundary conditions |
| Reflux | Berger–Colella reflux of point-value fluxes; off on the negative control | accumulate_seam_fluxes, reflux_stage, adam_flume_cpu_object.F90; adam_flux_register_object.F90 |
Initial and boundary conditions
| Item | Value |
|---|---|
| Domain | |
| Grid | quadtree, |
| Ranks | 2 |
| Initial condition | sine-wave at 45°: shear mode, magnetic mode, |
| Boundaries | periodic on the extrapolation on the |
| Final time | |
| Error measure | RMS against the exact linear solution, weighted by the cell area |
Input files
| File | Role |
|---|---|
src/tests/flume/verification/viscous/waves.py | make --refine 0.25 0.25 0.75 0.75 --ratio 4 [--reflux false] writes each input; oracle judges the ladder |
src/tests/flume/verification/viscous/check.sh --legs vv8 | runs the three ladders (--np N; FLUME_EXE selects the backend) |
make_doc_figures.py (fig_viscous_fields) | the figure, from the CPU work directories of viscous/check.sh |
bash
cd src/tests/flume/verification/viscous && ./check.sh --legs vv8 # CPU
FLUME_EXE=$PWD/../../../../../exe/adam_flume_fnl ./check.sh --legs vv8 # FNLResults

Top: the diagonal shear wave and its pointwise error on the uniform
Oracle: order
| Leg | N (finest) | RMS error | Order |
|---|---|---|---|
| shear, | 48 / 96 / 192 | +1.96, +1.98 | |
| shear, | 48 / 96 / 192 | +1.99, +1.99 | |
| Ohmic, | 48 / 96 / 192 | +1.97, +1.86 | |
| Ohmic, | 48 / 96 | round-off | |
| Ohmic, no reflux | 48 / 96 / 192 | +1.00, +1.02 |
CPU and FNL identical (2 ranks). The rows without coefficients are probes, not legs of check.sh.
Related cases: conservation across the same seams is VV-7; the inviscid order across static 2:1 seams, measured and then lifted in M6, is order across seams.
Findings
- The composite grid is second order, against fourth on a uniform grid. The rows without coefficients say where that comes from. The shear wave is second order without viscosity too: its seam error is the inviscid one. With the mean restriction and the Berger–Colella reflux of point-value fluxes (a conservative but
-inconsistent coarse flux), the composite error is second order (issue #68 F1: each of the two caps the order at 2 on its own; the #21 bound on restriction-compatible prolongations does not apply to the tricubic fill). - A static field has no inviscid flux at first order, so the Ohmic composite at
stays at round-off, and the Ohmic composite error is the dissipative flux crossing the seam: second order with reflux, first without (the gradient of mean-restricted ghosts is an error, which the reflux replaces by the fine flux). - The plan in #65 asked for the seam error "within a stated factor of the uniform fine run"; between a second-order seam and a fourth-order interior that factor grows with
, so the leg asserts the order instead. - The error maps show where the seam error lives. On the uniform grid the error of the shear wave is smooth and spread over the domain, near
. On the refined grid the Ohmic error is a ring on the 2:1 faces, two orders above the rest of the domain: the dissipative flux at the face. The shear error fills the refined box and its surroundings instead, being the inviscid seam error that the flow carries and the viscosity spreads.