Repository navigation
Coupling instructions: say what the exported flux columns hold (the outward traction is -q) - #71
Merged
Merged
Conversation
…sk's files The served Dirichlet-Neumann participants export normal_fluxes, and dump them into interface_level<k>.csv, as minus the conormal derivative on their own outward normal: -(k grad u) . n_own for heat, which is the outward normal flux, and -(sigma . n_own) for elasticity, which is MINUS the outward traction. The instructions that send the agent from these columns to the task's interface files after a converged coupling said nothing about the sign, so a file that asked for the outward traction sigma . n received its negative. What the coupling exchanges is unchanged. - coupling_knowledge: FLUX_COLUMNS_SIGN (the rule, per contract kind) and FLUX_COLUMNS_SIGN_SHORT (one sentence for text repeated per level); the vector contract (section 6a, rule 2) and the elastic variant's intro say that the outward traction is -q. - consolidated: the rule in couple_levels' all-converged next_step and in couple()'s `reporting`; the interface tables' _how_to_use carries the short rule; the converged-level leads, the SAVE-VERBATIM verdict and the couple docstring qualify the q columns; interface tables name one column per entry (x, y, u1, u2, q1, q2) where six columns were headed "x, y, u, qn"; the thermo-elastic exchange is written [q_n, q_x, q_y] (also in the 4C deck grammar note). - result_audit: the rule in the deliverables brief (ladder step 4) and in the missing-fields finding; the deliverable-flux finding says what the q columns hold. - elastic contracts (FEniCSx, DUNE-fem, FEBio): the console line names the exported traction qx, qy with its definition instead of tx, ty; FEBio's dump block states what its qx, qy columns hold, as the others do. - tests/test_exchanged_traction_is_not_the_outward_traction.py runs the scikit-fem elastic contract (both interface orientations, both roles) and the scikit-fem heat contract on fields with closed-form stress and flux, and a real converged couple_levels and couple of two elastic sides, and checks the replies against the measured columns. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
🟢 Approval recommended
The reporting and header changes preserve numerical exchange behavior, with regression coverage and no identified blocking issues.
0 open findings
What changed in this PR
Clarifies how openPASO converts exported interface fluxes into reported quantities, without changing the numerical exchange.
Changes:
- States that elastic outward traction is
-qthroughout reporting guidance. - Gives vector CSV columns individual names and clarifies participant log labels.
- Adds regression tests for flux signs and converged coupling replies.
| File | Description |
|---|---|
| tests/test_exchanged_traction_is_not_the_outward_traction.py | Tests sign conventions and reporting guidance. |
| src/tools/result_audit.py | Adds sign guidance to deliverable instructions. |
| src/tools/coupling_knowledge.py | Defines shared flux-sign explanations. |
| src/tools/consolidated.py | Updates reporting guidance and vector CSV headers. |
| src/backends/fourc/deck_grammar.py | Clarifies exchange notation in documentation. |
| data/coupling_participants/participant_fenics_elastic.py | Clarifies exported traction log labels. |
| data/coupling_participants/participant_febio_elastic.py | Clarifies log labels and dump comments. |
| data/coupling_participants/participant_dune_elastic.py | Clarifies exported traction log labels. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
Problem
The served Dirichlet–Neumann participant templates export
normal_fluxes, and dump them intointerface_level<k>.csv, as minus the conormal derivative on their own outward normal:-(k grad u) · n_own, which is the outward normal flux;-(σ · n_own), which is minus the outward traction.That convention is right for the exchange. But the instructions that send the agent from these columns to the files its task asks for, after a converged coupling, said nothing about the sign. So a file that asked for the outward traction
σ · nreceived its negative. The coupled solution itself was not affected; only the reported interface traction was.What this changes
What the coupling exchanges is unchanged. Every place that points the agent from the exported columns to its own output files now states the sign:
coupling_knowledge:FLUX_COLUMNS_SIGN(the rule, per contract kind) andFLUX_COLUMNS_SIGN_SHORT(one sentence for text repeated per level);-q.consolidated:couple_levels' all-convergednext_stepand incouple()'sreporting;_how_to_usecarries the short rule;coupledocstring qualify theqcolumns;x, y, u1, u2, q1, q2) where six columns were headedx, y, u, qn;[q_n, q_x, q_y](also in the 4C deck grammar note).result_audit:qcolumns hold.qx, qywith its definition, instead oftx, ty;qx, qycolumns hold, as the others do.Tests
New:
tests/test_exchanged_traction_is_not_the_outward_traction.py. It runs:couple_levelsandcoupleof two elastic sides.The contracts run on fields with closed-form stress and flux, and the test checks the replies against the measured columns.
Local run on this branch, which is on top of
main(da6f80a):pytest tests/, without the LangGraph test: 99 passed, 13 skipped;tests/test_web_search_reports_a_block.pyin the LangGraph environment: 11 passed.🤖 Generated with Claude Code