Skip to content

Commit da5dfad

Browse files
authored
perf(hermite): assemble a cable reaction from its node's elements (#37)
The reaction of a finite-EI cable at a node (the fairlead load the OpenFAST module returns on every CalcOutput) assembled the residual and the added mass of the whole line and multiplied the whole mass by the acceleration, to read three rows. With a 248-element power cable this was 20 s of a 212 s coupled run. assemble_residual takes an optional node_only with a caller residual R_out: it assembles only the elements that reach the node and the node's own terms (attachments, contact, end connection), each in the order of the full assembly, so the node's rows are bit-identical and the model's scratch is not touched. The contact and attachment assemblies take node bounds, and contact writes through the residual it is given. The reaction builds the node's rows of the added mass from the same one or two element matrices and forms the inertia column by column as band_matvec does. A line with torsion, which couples every element, keeps the full assembly, as does full_assembly = .TRUE. test_hermite_node_reaction compares the two at every node, bit for bit, on hand-built cables with every load section (contact with friction on a controlled seabed, attachments, axial damping, drag, added mass, Airy waves or a held field, finite, rigid or no end connections) at scattered states, and along a coupled trajectory of the IEA-15 MW mixed mooring example, also after a fairlead transfer; it fails when the inertia sum is reordered. All 51 examples write byte-identical outputs, and the coupled chain-only and mixed OpenFAST runs write byte-identical outputs, the mixed one in 194 s instead of 212 s. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
1 parent 8c1f525 commit da5dfad

4 files changed

Lines changed: 446 additions & 43 deletions

File tree

‎CHANGELOG.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,10 @@ All notable changes to CableDyn are recorded in this file. The format follows
2626
the committed kinematics before transferring the current ones; it discarded them. With a
2727
248-element power cable in the IEA-15 VolturnUS-S mooring this cuts `CalcOutput` from 41 s to
2828
25 s and the 600 s run from 227 s to 212 s. Results do not change.
29+
- The reaction of a finite-EI cable at a node (the fairlead load the OpenFAST module returns)
30+
is assembled from the one or two elements that reach the node instead of the whole line,
31+
bit-identical to the full assembly (lines with torsion keep the full assembly). In the same
32+
run this cuts `CalcOutput` to 9 s and the run to 194 s. Results do not change.
2933

3034
## [0.2.0] - 2026-10-20
3135

‎CMakeLists.txt‎

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1084,6 +1084,17 @@ set_tests_properties(openfast_touchdown PROPERTIES
10841084
# Other BLAS implementations ignore this environment variable.
10851085
ENVIRONMENT "OPENBLAS_CORETYPE=Sandybridge")
10861086

1087+
# The reaction of a finite-EI cable assembles only the rows of its node: bit-identical to the
1088+
# full assembly at every node, with every load section, on hand-built cables and along a
1089+
# coupled trajectory of the same deck, and without touching the model's scratch.
1090+
add_executable(test_hermite_node_reaction tests/test_hermite_node_reaction.f90)
1091+
target_link_libraries(test_hermite_node_reaction PRIVATE cabledyn_core)
1092+
add_test(NAME hermite_node_reaction
1093+
COMMAND test_hermite_node_reaction ${CMAKE_SOURCE_DIR}/examples/iea15mw_umaine_mixed_cabledyn.dat)
1094+
set_tests_properties(hermite_node_reaction PROPERTIES
1095+
LABELS "fortran;unit;dynamic;openfast;contact"
1096+
ENVIRONMENT "OPENBLAS_CORETYPE=Sandybridge")
1097+
10871098
# The same deck initialises without a static compression/mesh note: the touchdown
10881099
# contact kink is element-local, the smoothed element-mean axial force is tensile.
10891100
add_executable(test_flagship_compression_note tests/test_flagship_compression_note.f90)

0 commit comments

Comments
 (0)