Repository navigation
Preserve nodal loads when merging duplicate nodes - #371
Open
Tonylo-lab wants to merge 1 commit into
Open
Tonylo-lab wants to merge 1 commit into
Tonylo-lab wants to merge 1 commit into
Conversation
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.
merge_duplicate_nodes()redirects connected elements and merges support conditions, but discards loads on removed nodes. In a one-unit cantilever, coincident tip nodes carrying FY=-10 and FY=-20 produce a support reaction of 10 after merging instead of 30; a moment on the removed node is also lost.Append the removed node's loads to the surviving node before deletion. Add two focused tests to the existing node-merge tests: preserving loads across a multi-node merge (including identical loads, different cases, an unrelated node and a repeated merge), and checking actual cantilever force/moment reactions for two load combinations. Add one short changelog entry.
The analysis regression uses exactly coincident nodes. This change preserves load records; it does not add a coordinate-offset moment correction for nodes merged within a nonzero tolerance.
Validation on Windows / Python 3.12.15:
pytest Testing/test_node_merge.py Testing/test_mesh_regeneration.py Testing/test_delete_mesh.py Testing/test_loads.py Testing/test_reactions.py Testing/test_reanalysis.py -q: 28 passed, 2 subtests passed.git diff --check: passed.Not run: the full test suite, graphical visualization validation, or other platforms/Python versions.
AI assistance: OpenAI Codex assisted with investigation, the patch and regression tests. The concrete diff and validation results were presented for approval before submission.