Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Anisotropic pressure multigrid results

Scope and frozen protocol

Measured 2026-10-31 on one AMD EPYC 9V74 solver thread; host exposes 9 CPUs, 8-CPU quota and 8 GiB memory limit. Both cores use Rust stable 1.99.1 and locked dependencies. Baseline core is merged PR #13, main 2ddf17d. The old point core has only two measurement overlays: the identical shared pressure_probe.rs and an unused empty multigrid/line.rs source-fingerprint marker; its algorithm is unchanged. The candidate adds symmetric line/small-plane relaxation and semicoarsening; IC(0) remains default. See the plan and algorithm and API.

Rough exact pressure is sin(0.73*i) + 0.3*cos(0.17*i), centered in closed domains; the fine operator generates its RHS. NumPy independently checks the returned vector, with separate dense operator/Galerkin/block references in the Rust tests. Each of 18 shapes has one warmup plus three balanced timed triplets (IC(0), merged point MG, candidate MG). Each child makes one cold and one cached solve. All use tolerance 1e-14, maximum 1200 iterations, independent RMS recovery <=1e-8 and true relative residual <=1.1e-12. Repeated work and result/source signatures must agree. These are pressure fixtures, not accepted flow or experimental validation.

All 216 child records (432 successful pressure solves) passed. Maximum independent recovery error across all methods was 1.844e-10; maximum true relative residual was 1.036e-14. No gate was relaxed. An initial pilot at 1e-12 failed the recovery bound on the most stretched grid for IC(0) and the candidate; its rows are retained separately and excluded from this campaign. Tightening the common solver tolerance preceded the formal measurements.

Cached pressure solves

Times are medians in milliseconds, excluding output and hashing. A speedup greater than one favors the candidate. Iterations are IC(0)/point/candidate. The first three rows keep point arithmetic and have bit-identical point and candidate pressure vectors. Short timing samples can vary substantially.

ShapeIterationsIC(0) msPoint msCandidate msPoint/candidateIC(0)/candidate
isotropic60 / 8 / 81.5571.0291.0840.95×1.44×
near-isotropic122 / 13 / 1314.8497.29413.6190.54×1.09×
threshold25108 / 24 / 2423.69227.68925.2781.10×0.94×
thin10092 / 45 / 521.11348.4115.6948.50×3.71×
thin40086 / 83 / 518.59887.4346.23014.03×2.99×
cube100147 / 46 / 5504.977881.392141.5816.23×3.57×
slab100118 / 51 / 648.116106.36015.5206.85×3.10×
plate64126 / 49 / 11109.486211.56152.7954.01×2.07×
plate256199 / 94 / 12378.140997.147144.4996.90×2.62×
thin1600152 / 150 / 19143.281664.697149.8414.44×0.96×
thin6400162 / 278 / 18147.7851313.360136.8729.60×1.08×
review-stretched161 / 1169 / 17146.1095245.237137.49938.15×1.06×
odd87 / 108 / 145.82836.6455.3736.82×1.08×
periodic145 / 257 / 78.77381.9552.80729.19×3.13×
outlet92 / 102 / 136.34934.0824.4207.71×1.44×
stiff-two-cell95 / 50 / 94.48111.9231.7146.96×2.61×
long-domain220 / 54 / 2326.07927.40612.0052.28×2.17×
short-stiff-axis204 / 57 / 6174.028244.17832.0477.62×5.43×

On the 15 block-selected shapes, cached solves are 2.28–38.15× faster than merged point MG. Against IC(0), the range is 0.96–5.43×: at thin1600 IC(0) is about 4.6% faster; on review-stretched, the large point-MG improvement buys only about 6% over IC(0). Fewer iterations alone do not establish a useful speedup. Near-isotropic’s initial short samples have large spread (candidate 7.25–16.53 ms), despite unchanged arithmetic and field hashes; do not interpret that row as an algorithmic isotropic gain.

A follow-up investigated this spread without replacing any original row: one warmup plus five timed triplets on the three point controls, unchanged binaries/fields/gates (54 more child records, all accepted). Point/candidate cached medians were 1.081/1.086 ms isotropic, 7.763/7.692 ms near-isotropic, and 24.985/25.871 ms at threshold25. The point/candidate ratios were 1.00/1.01/0.97 respectively. This supports treating the large initial near-isotropic difference as timing variation; no isotropic speedup is claimed.

Cold cost and memory

Cold time includes setup and solve. Hierarchy MiB counts retained numeric/index vector capacities and level records, excluding the exact face signature, reporting handles, grid, outer PCG vectors, allocator and construction temporary storage. Peak RSS is the complete candidate child, including JSON output; it is not a hierarchy-only memory number. Preflight adds a further 512 bytes per cell to the existing 1024-byte MG allowance, before its 25% margin, when the block policy is selected.

ShapeCold IC(0) msCold point msCold candidate msPoint hierarchy MiBCandidate hierarchy MiBCandidate peak RSS MiB
isotropic1.6834.5984.3490.480.483.39
near-isotropic14.99428.20427.5802.042.046.96
threshold2525.70262.80465.6513.263.2610.69
thin10021.19490.09729.5073.266.2613.68
thin40019.831142.24037.6773.266.2613.71
cube100575.6532659.865651.83252.6895.23169.95
slab10050.982296.26265.7907.1012.5025.37
plate64111.984551.616288.29814.0924.6548.56
plate256396.8391997.226651.08429.8849.3194.73
thin1600135.0501046.937273.98914.0928.3151.71
thin6400165.3411622.962256.80414.0928.3151.67
review-stretched141.5635725.831274.64914.0928.3151.75
odd6.24656.79715.1031.402.576.49
periodic9.08399.55111.8221.372.426.15
outlet6.62056.99013.7501.402.576.52
stiff-two-cell4.77218.4819.7360.781.254.77
long-domain25.22643.39423.5621.542.897.62
short-stiff-axis182.163517.239146.81113.5223.2046.79

Cold candidate solves are often slower than IC(0). Retaining weak-axis modes also retains larger coarse grids and operators. Setup and operator complexity remain explicit P2c work; this implementation does not claim universal cold or low-memory superiority.

Shape definitions

All meshes are uniform within each axis. Grid counts and domain lengths are separate; this is not support for graded/nonuniform meshes. Wall fixtures use wall x/z, periodic y and no moving wall; periodic uses periodic x/y and wall z; outlet uses open x, periodic y, wall z and imposed initial x velocity. Every exact input JSON is retained. Labels are mnemonics, not acceptance gates.

ShapeCells x,y,zDomain m x,y,zx boundary
isotropic24, 2, 241.0, 1.0, 1.0wall
near-isotropic96, 2, 244.0, 0.1, 1.0wall
threshold2564, 2, 641.0, 0.1, 0.2wall
thin10064, 2, 641.0, 0.1, 0.1wall
thin40064, 2, 641.0, 0.1, 0.05wall
cube10048, 48, 481.0, 1.0, 0.1wall
slab10032, 32, 161.0, 1.0, 0.05wall
plate6464, 8, 641.0, 1.0, 1.0wall
plate25664, 16, 641.0, 4.0, 1.0wall
thin160064, 8, 641.0, 1.0, 0.2wall
thin640064, 8, 641.0, 1.0, 0.1wall
review-stretched64, 8, 641.0, 1.0, 0.02wall
odd33, 5, 171.0, 1.0, 0.1wall
periodic31, 5, 170.05, 1.0, 1.0periodic
outlet33, 5, 171.0, 1.0, 0.1open
stiff-two-cell32, 2, 321.0, 0.001, 1.0wall
long-domain128, 2, 16100.0, 1.0, 1.0wall
short-stiff-axis64, 64, 81.0, 1.0, 0.01wall

Accepted coupled anisotropic flow

Square-domain Re=100 cavity, 64x2x12, canonical flow numerics; one warmup and three alternating timed IC(0)/MG pairs per mode. Limits are 600 s/20000 steps. Archive integrity and independent field audits must pass. The steady row also retains the existing 0.06 Ghia screen. The transient row means completion to 1 s, not convergence to steady flow. Both methods repeat their work and fields. All 16 child records pass. Total solver time includes setup; workflow time also includes launch, archive and checking work.

ModeSteps bothIC(0)/MG PCG workSolver IC(0)/MG sSolver speedupWorkflow IC(0)/MG sWorkflow speedupGhia error
steady4950477,555 / 59,31523.632 / 16.7511.41×23.722 / 16.8431.41×0.04298755
transient29728,846 / 3,4791.546 / 0.9421.64×1.642 / 1.0481.57×not steady

Maximum pairwise velocity difference is 2.22e-16 m/s and pressure difference 5.01e-15 m²/s²; predeclared bounds are 1e-8 and 1e-7 with the same gauge. Steady stopping steps are unchanged. This throughput fixture’s 0.04299 Ghia error does not reach the 0.01 accuracy objective; it is not a matched-accuracy OpenFOAM comparison. It compares the candidate with IC(0), while the isolated pressure suite additionally compares the merged point algorithm.

Hosted reproduction

The manual external=anisotropy job ran both campaigns on a GitHub runner (AMD EPYC 7763, 4 CPUs, ubuntu-24.04; run 41268224744) at commit 8ebee01, whose solver code is the code measured above. The job builds the merged point core from main 2ddf17d with the same two measurement overlays. All kernel and flow records passed, and all 16 flow archives verified after a zip round trip.

Every shape repeated the recorded iteration counts for all three methods, and the coupled runs repeated the recorded steps, PCG work and Ghia error. Reused kernel times (medians, ms) and speedups of the candidate:

ShapeIC(0)PointCandidatePoint/candidateIC(0)/candidate
isotropic1.9141.2211.2031.01×1.59×
near-isotropic16.3018.2398.2711.00×1.97×
threshold2525.20026.99827.1660.99×0.93×
thin10021.60649.9346.3977.81×3.38×
thin40020.31391.6086.42514.26×3.16×
cube100494.481847.348117.4167.22×4.21×
slab10053.578113.89815.2767.46×3.51×
plate64119.990222.67847.2554.71×2.54×
plate256392.266935.114113.8988.21×3.44×
thin1600144.321682.025113.4706.01×1.27×
thin6400153.7921332.020112.21311.87×1.37×
review-stretched153.5595373.320108.43849.55×1.42×
odd6.77740.3605.9216.82×1.14×
periodic10.56891.2852.89831.50×3.65×
outlet6.76435.9495.1217.02×1.32×
stiff-two-cell5.41413.1131.9806.62×2.73×
long-domain26.19228.79212.5492.29×2.09×
short-stiff-axis199.073251.83830.4838.26×6.53×

On this runner the candidate’s cached solves beat IC(0) on all 15 block-selected shapes (1.14–6.53×), including thin1600, where IC(0) was faster on the recording host. Against merged point MG the range is 2.29–49.55×.

ModeSteps bothIC(0)/MG PCG workSolver IC(0)/MG sSolver speedupWorkflow IC(0)/MG sWorkflow speedupGhia error
steady4950477,555 / 59,31526.861 / 19.1071.41×26.941 / 19.2181.40×0.04298755
transient29728,846 / 3,4791.600 / 1.1281.42×1.706 / 1.2061.42×not steady

The opt-in multigrid cavity accuracy sweep (external=accuracy with native_pressure=multigrid, AMD EPYC 9V74, 4 CPUs; run 41267955525) accepted all 20 records with unchanged Ghia errors. Native/OpenFOAM solver time was 6.85× at 24² and 10.99× at 48² (workflow 3.60× and 9.79×), close to the same-host comparison. Native still misses the 0.01 target through 48², so no equal-accuracy ratio exists.

Identity, reproduction and limits

Shared-probe source fingerprints (different scope from the CLI build SHA):

  • point_mg: 694a65b070e537d1026368517e9d0ffdea6621bef04a293e562ffe0f4571677e.
  • candidate_mg: a00c21b56c2ba635d9888da064309c8dc65c47966dc816c0337ba1b71451cfd1.

The raw evidence records executable/input/producer SHA-256 values, compiler, host limits, every child, returned pressure vectors, hierarchy dimensions, block bandwidth/storage, work, RSS, repeated profiles and complete native flow archives. The guide gives local and opt-in CI commands. The tables above come from the recording host; the hosted reproduction above ran on a GitHub runner.

Verification passes 75 Rust release tests on minimum 1.88.0 and stable 1.99.1, with all-target Clippy warnings denied, plus 396 distinct Python tests per normal/optimized mode across 16 suites. The 23 runtime-dependent tests were rerun with the pinned real backend, with no skips. The existing scalar/flow verification, Poiseuille, empty-ABL, manual examples and masked SciPy reference pass. A block-selected 12x4x12 checkpoint replay produces bit-identical fields to the uninterrupted run; a forced one-iteration pressure failure retains the whole initial state, with attempted work visible in the validated profile.

Mask support, component-preserving transfers, narrow passages and the 27k/93k canyon gate are still open. Anisotropy selection is a fixed spacing heuristic, not a guarantee for every aspect ratio or arbitrary modified face matrix. No OpenFOAM code is copied. No flow/transport/turbulence model or scientific tolerance changes. The fresh overall gap and remaining stages keep pressure throughput, accuracy and physical qualification distinct.