Repository navigation
The nodal stress history carries the stress it stores (#735, #1009) - #1231
Merged
Merged
Conversation
The nodal semi-Lagrangian history refreshed its commit snapshot before the trace-back, so the stored stress was rebuilt every step from the field that had not moved. On development the default history behaved exactly as stress_transport="none": a stress turned 0.5 rad by rigid rotation stays where it was made (error 0.000 against the unmoved stress, 1.538 against the rotated one). update_pre_solve now refreshes the snapshot after the carry, and the Eulerian flavours' snapshot request takes effect. Ported from bugfix/stress-snapshot-order-735 (913694e) and bugfix/backward-nodes-snapshot-order (adb20e9); the test is renumbered 1106. Underworld development team with AI support from Claude Code
🔍 Architectural Review ChecklistThank you for submitting an architectural review! Reviewers should validate: Design & Architecture
Implementation
Testing & Validation
Documentation
Review Process: See CODE-REVIEW-PROCESS.md Approval: This PR merge = Review formally approved |
|
✅ Test Suite: success |
The test's materials sit on a swarm that is never advected, and its closed forms keep the stress at its point; it passed with the default carried history only while the nodal history did not move. Carried, the pure shear brings material A's stress across the interface into B's sample point (15-23% at step 6). stress_transport="none" states what the closed forms assume: 23 passed. Underworld development team with AI support from Claude Code
|
✅ Test Suite: success |
This was referenced Nov 19, 2026
Member
Author
|
Second-desk review of #1231, by H3 (the units desk, a Claude session doing second reviews), at 5f5a395. Runs were on a 96-thread Linux workstation (single system image; Intel Xeon Gold 6240R, AVX-512; MPICH). Verdict: the fix is right and the tests show it. The findings below are in the docs, comments and PR description; none is in the code's behaviour. What I checked
Findings
Underworld development team with AI support from Claude Code |
…pment Underworld development team with AI support from Claude Code
|
✅ Test Suite: success |
|
✅ Test Suite: success |
6 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The nodal semi-Lagrangian stress history, the Stokes viscoelastic default, refreshed its commit snapshot before the trace-back (
ddt.py,SemiLagrangian.update_pre_solve). As a result, every step rebuilt the stored stress from the field that had not moved. Ondevelopmentthe default history behaves exactly asstress_transport="none".This PR refreshes the snapshot after the carry. The Eulerian flavours' snapshot request now takes effect as well: Stokes asked for it before their projection existed, and the request lapsed.
It is ported from
bugfix/stress-snapshot-order-735(913694e, on hold since 2026-11-08, #1009) andbugfix/backward-nodes-snapshot-order(adb20e9, with its adversarial review indocs/reviews/2026-10/). It cherry-picks cleanly onto 4ab522a. The new test is renumberedtest_1106, because 1102 is taken.Measurements are by H7 (the stress-history desk, a Claude session on a 96-thread Linux workstation: Intel Xeon Gold 6240R, MPICH), serial unless stated.
The defect and the regression test
test_1106: a stored stress turned 0.5 rad by eight steps of rigid rotation on a 1/16 simplex box.development4ab522anone, developmenttest_1106fails 6 of its 9 tests on development (H3's review run at 4ab522a):assert 0.0 > 1.0);enable_source_snapshot did nothing, the lapsed request);"none"reading its history frozen. On this branch it passes serial and at np 2 (9 passed). The stress, VEP-stability, initial-history, restart and thin-sheet suites (test_1106,test_1059,test_1052×2,test_1063_stress_history_restart,test_1076) give 55 passed.Waters and King: #1009's bias is the nodal trace's own error
#1009 found the port biased on Waters and King, and that bias is why the port was held. The exact solution has$u\cdot\nabla\sigma\equiv 0$ , so a history that does not move is exact there. The control below forces the stress history's trace velocity to $(u, 0)$ , which removes the discrete transverse velocity from the trace. It uses the
test_1060setup: pure Maxwell,NavierStokes, BDF-1, centre velocity.The peak transverse velocity$\max|v_y|$ over the run is:
With the transverse part of the trace removed, the fixed history reproduces development to 2e-5 at 1/16 at every time, and recovers nine-tenths of the gap at 1/32. The bias therefore comes from the trace sampling the stored stress off the node's own height through the discrete$v_y$ , which the carried stress then feeds back. It is the nodal scheme's own error, which the defect hid, and not a fault in the fix. Carried, the nodal history does not converge on this case at fixed Courant number (2.30e-3 at 1/16, 3.03e-3 at 1/32 at t 2).
Two things are open:
The default moves off the nodal history in a follow-up PR (integration point, smoothed), so this residual is not the default's.
Update:
test_1054relied on the defect (5f5a395)The multimaterial test failed on this branch (15-23% at step 6) and passes on development. Its materials sit on a swarm that is never advected, and its closed forms hold the stress at its point. Carried by the pure shear, the history brings material A's stress across the interface into B's sample point. The same test fails with the integration-point history, so the cause is that the history moves, not the nodal scheme. The test now sets
stress_transport = "none", which states what its closed forms assume: 23 passed. All 18 viscoelastic test files that do not set a transport give 153 passed on this branch, serial.Existing tests that change
test_1059:VARYING_SL2is re-pinned from 0.87325 to 0.87163. The old baseline was set while the nodal history did not move. Carried, it is 4.3e-4 from the Eulerian value at the same step, where it used to be 1.2e-3. The test's comment says so.test_1054: pinsstress_transport = "none"(see the update above).test_1052: only docstrings change. The shear-box tests cannot see the snapshot order.Docs
stress-transport.md: the warning now gives the measured defect and says every nodal result from 2026-04-25 to now was taken on it (The nodal semi-Lagrangian stress history carries ~50% too much stress at a no-slip wall: two independent transports converge together, it stays flat elsewhere #735's wall excess among them). The Waters and King section now drops "nodal converges as the step falls" and gives the table above; Nodal stress history on Waters and King: a bias and stalled convergence on the #735 port branch #1009 found the earlier claim, and the claim that Waters and King was "not affected", false.transport-schemes.md: the The nodal semi-Lagrangian stress history carries ~50% too much stress at a no-slip wall: two independent transports converge together, it stays flat elsewhere #735 and Eulerian stress history blows up at a shear-wave reflection (Waters & King start-up) #749 rulings are marked as measured on the defect, which ends at this PR (a94ffb0, from H3's review).Closes #1009. Refs #735: its wall excess was measured on the defect and is to be re-measured on this branch before #735 is closed.
Checklist (UW3 Style Charter)
level_2andtier_amarkers; it fails on development (S8).array/.dataas the surrounding code does (S7)test_1106at np 2 (S11)Underworld development team with AI support from Claude Code