Repository navigation
The semi-Lagrangian history starts and records at its nodes, one route on any number of ranks; a simplex box returns points onto its boundary - #1252
Conversation
… route on any number of ranks The nodal history evaluated its start velocity, and serially recorded the field, at nodes nudged 0.1% toward the centroid of their closest cell. The nudge moved a static field at every record (x + y by 7.498e-5 in two SLCN steps) and made serial take a different route from parallel. The record now copies a mesh-variable field on every rank count, and the trace starts at the nodes. The integration-point history's evaluate fallback drops its nudge too, and an unused nudge helper goes. Underworld development team with AI support from Claude Code
…-3 inside it The clamp moved a point a round-off outside to 1e-3 inside and left one a round-off inside where it was: a 1e-3 jump at the wall. Without the nudge, a trace-back foot on a free-slip wall (v.n is round-off there) landed either side of it, and two runs of one problem that differ in round-off differed by 4e-9 (test_1053, ETD-2). StructuredQuadBox already snaps onto the boundary; the simplex box now does the same. Underworld development team with AI support from Claude Code
…view of #1248) Underworld development team with AI support from Claude Code
|
Review from the Underworld development team with AI support from Claude Code (H1: review and parallel test runs on a 96-thread Linux workstation (Intel Xeon Gold 6240R, AVX-512; MPICH)) Verdict on 264dbce: ready to merge on green from this review.
The one finding worth a follow-up predates this PR (finding 1). The head has since moved to c6330cc, a merge of development (#1246, #1249, #1244). The PR's own changes are unchanged; MethodAll four PR files under
Every run printed
Field changes were measured by a pytest plugin. After each test, it saved every live mesh variable on both builds, and the two builds were then compared field by field. Each figure is the largest and the RMS difference, divided by the field's largest magnitude. The errors against exact or reference solutions come from copies of the benchmark tests that print the quantity each test asserts on. (a) Answers, development (1901a46) against the PR, serialSolved fields:
Errors against the exact or reference solution:
Every benchmark test passes on both builds. (b) A static field, and np 1 against np 3The triangle is #1237's, with two static SLCN steps of x + y (
(c) The swarm effect of the snapA wall probe on the unit simplex box (cell size 0.1) was run at np 1, 2 (band and default) and 3 (band and default):
All swarm, tracer and particle tests run passed identically on both builds:
(d) #745This is #745's channel as the author rebuilt it: Wi 5, the integration-point history with no inflow value, Δt 1/120. The script was copied unchanged and run on both builds. The peak deviatoric stress:
The failure without an inflow value is still there, so the snap does not fix #745, as the PR says. The two t 1.83 values differ from the author's (35.2 and 45.2), as expected once the runs have blown up. The route that does fix #745, Findings
Spot checks and what was not run
Logs kept by the reviewer. Underworld development team with AI support from Claude Code |
The nodal semi-Lagrangian history no longer nudges its nodes. It records the field and starts its trace at the nodes themselves, by one route on any number of ranks. This builds on #1237's route agreement: the ranks still agree on the route with a logical AND, and serial now takes the same copy route as parallel. No issue was filed; this body is the report.
Measurements are by H7 (the stress-history desk, a Claude session on a 96-thread Linux workstation: Intel Xeon Gold 6240R, MPICH), except where the parallel review's numbers are named.
The nudge
SemiLagrangianmoved every node 0.1% toward the centroid of its closest cell (_centroid_shifted_node_coords) for two things:The closest cell a rank can see depends on the partition. So the nudge made serial and parallel take different routes, and it moved a static field at every record. The parallel review measured this on #1237's empty-rank triangle: two SLCN steps of$x + y$ , with no flow and that value on the boundary.
What changes:
_centroid_shifted_node_coordsbecomes_node_coords_nd: the nodes themselves.psi_fnis evaluated at the nodes.IntegrationPointSemiLagrangian's evaluate fallback drops its own nudge.Test:$x + y$ stays put to 100 times the solve tolerance (1e-8). Development fails it serially at exactly 7.498e-5. On this branch: serial 2 passed; np 3: 3 passed,
test_1244, serial and at np 3 (with and without the empty rank). A statictest_1236included.The SLCN partition dependence (the #1239 review's finding)
One SLCN level-set step on
test_1105's rotation box at 1/32, with the mass correction and reinitialisation off and a fixed ε. Every node is gathered by position. Largest np 1 against np 2 difference:The nudge is the part that a tighter tolerance cannot remove, and this PR removes it. What remains at the default tolerance is the solve's own residual: about 2e-5, present at nearly every node, and gone at 1e-12. Whether that residual is biased toward partition seams is being measured separately.
Over a full revolution of
test_1105's rotation (200 steps), the transport tolerance makes no difference to the accuracy. At 1e-4 and at 1e-10 alike: indicator mismatch 0.00304, band share 0.15804, L2 distance from the start 0.010024.An unstructured simplex box returns a point onto its boundary (its own commit)
Without the nudge, a trace foot on a free-slip wall, where$v \cdot n$ is round-off, sits within round-off of the wall.
UnstructuredSimplexBox.return_coords_to_boundsmoved a point outside the box to 1e-3 inside it and left a point inside where it was: a 1e-3 jump at the wall.test_1053's ETD-2 case runs one problem twice, as a constant and as a uniform expression. The two runs differ by round-off in the velocity. Their feet were 1.8e-15 apart until one landed either side of the wall and they came back 1.0e-3 apart. The end velocities then differed by 4.4e-9 relative (development: 1.4e-13), against the test's 1e-10.The simplex box now returns a point onto the boundary, as
StructuredQuadBoxalready does; that is the precedent. This changes where a swarm particle that left a simplex box is put back: onto the wall, not 1e-3 inside it.test_1245checks this in 2-D and 3-D: a point a round-off outside each wall returns exactly onto it, and a point a round-off inside is left alone. It fails on development.#745 blamed this same clamp for an integration-point history blowing up at a channel inlet. I rebuilt #745's channel from the issue, since its script was not public: 2.2 × 0.41, simplex box at 0.05, Maxwell, Wi 5, DEVSS η/4, Δt 1/120, integration-point history, with no inflow value set. Its inlet peak:
So this PR does not fix #745: the inset was not the whole of it. #745 stays fixed by the inflow-value route (f6d3259), which this does not touch.
Also here
test_1109covers a non-symmetricTENSORhistory's split advection, from the review of #1248. All four columns are checked against a scalar history of each component.Tests
test_1053,1106,1109,1244and1245on the final head: 23 passed.test_1244andtest_1236at np 3: 3 passed.scripts/test.shrunstest_1244at np 3.Checklist (UW3 Style Charter)
level_1andtier_a/tier_bmarkers;test_1244andtest_1245fail on development (S8)Underworld development team with AI support from Claude Code