Repository navigation
feat(cable): finite-EI lines with two moving ends, between two floaters or two objects, TURBINES rows turning both end frames - #75
Conversation
…e route A finite-EI line whose End B is a Coupled/Vessel point (a cable shared by two floaters, a TURBINES shared line) now runs on the production cubic-Hermite route with both ends driven, standalone. - HFMF boundary: End B (internal node 1) is a second host-driven end (CD_HFMF_Set_Moving_End_B): UpdateStates, SetCoupledKinematics and Preflight take its kinematics (ub_*), the step prescribes both ends' translations, End B's connection direction and torsion frame are held by its own parent and turn with it (prepare_parent_end shared by both ends), CalcOutput returns the End B load and moment, the mirror carries End B's parent frame. A moving End B left exactly at rest is held, so it is the Fixed End B bit for bit. - Deck builder: a moving End B's static problem is the Fixed End B's at its position, so the statics, seeds, continuations and audits are unchanged; its Ez and Nx are in its parent's axes. asLaid is refused by name on such a line. - Standalone march: End B moves with the motion table (motionFile rows, the vesselMotion/vesselRAO vessel and its rotation, TURBINES rows); the roll column rolls either end, Phi = Pretwist(B) - Pretwist(A) - roll(A) - roll(B). - Deck rules: a finite-EI line may join two Coupled/Vessel points; END CONNECTIONS and torsion accept a Coupled/Vessel End B; nModes holds a moving End B. The Python deck validator mirrors the rules. - The compatibility (Cosserat) route is retired for these decks. In the whole suite and the examples it ran only refusal tests; on four shared-line decks it failed to converge or reached a compressive static state (-6.1e8 N), where the Hermite route runs all four. Its VIV, CurvX/CurvY, AnchFz, Point<P>F, STIFFENERS, ATTACHMENTS and GJ|K refusals are lifted with it. - With the torsion routes (one restrained end, torsion on rod ends, the mixed deck): line_torsion_at_b beside line_torsion_at_a; the roll column twists only an end restrained in torsion (line_roll_twist), and check_motion_roll_lines, shared with the mixed deck, takes the points to accept the roll of a Coupled/Vessel End B restrained in torsion. A torsional END CONNECTION on a rod End A needs a Fixed End B (refused by name, mirrored in deck_file.py); an End B on a rod end stays refused. Gates (tests/test_two_moving_ends): a held Coupled End B writes the Fixed End B's files byte for byte (also with clamped, twisted ends and for nModes); mirror symmetry 3.9e-11 m and 4.2e-5 N of 2.8e4 N; rigid translation 3.8e-10 m and 4.4e-5 N of 1.6e4 N; End B driving equals the reversed line driven at End A to 1.0e-3 N, with turning finite and clamped connections to 1.8e-5 N and 4.4e-7 N m; equal end-frame rolls keep the torque to 3.4e-6 N m, opposite rolls change it by GJ 2 phi / L to 4.8e-6 N m (library parents 5.7e-13 N m); snapshot and mirror restarts bit-identical, with the nodal twist too. Examples A/B: 53/53 identical. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…pled aggregate The coupled aggregate (OpenFAST, FAST.Farm, the C API, the standalone mixed deck) builds a finite-EI line whose End B is a Coupled/Vessel point as a cable with two host-driven ends: End B takes a moving column of its own. - Moving set: [system points][End A of every cable][End B of every two-moving cable, in cable order][host rods][host bodies]; host rods and bodies never share a deck with a finite-EI cable, so no existing column moves. cable_col_b maps a cable to its End B column; GetMovingPointMesh returns End B's kinematics, load and moment (one evaluation for both ends), UpdateStates_Moving preflights and transfers both ends, Step_Moving steps them (cable_two_ends, safe in the cables' parallel loop). - FAST.Farm: the turbine map gives the End B column End B's turbine; End B's static orientation is that of its turbine (farm_ptfm_init) or of the platform (ptfm_init); coupled_positions take the End B columns after the fairleads. - OpenFAST glue: formal linearisation of such a line fails closed by name. - Python deck validator: the aggregate rule accepts a Coupled/Vessel End B. - With the torsion routes: a cable with a moving End B steps through cable_two_ends, every other cable through step_cable (the roll columns of the mixed deck); OpenFAST linearisation of torsion stays, beside the refusal of a line with two moving ends. Gates (tests/test_two_moving_ends): a FAST.Farm aggregate (n_turbines = 2) maps the shared line's End A to turbine 1 and End B to turbine 2 and, driven by prescribed turbine motions, reports the standalone TURBINES deck's end tensions to 6.8e-3 N of 1.9e4 N (static solves to 1e-6 and 1e-8); host orientations rolling the two columns oppositely change the torque by GJ 2 phi / L to 3.4e-13 N m, equal rolls keep it to 2.3e-13 N m. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
With every standalone finite-EI deck on the cubic-Hermite route (a line with two moving ends included), the deck plumbing of the Cosserat compatibility route was unreachable: its model type (FiniteDeckModel), builder, march, motion transfer, output rows, line files, range sampling and init summaries, and the fmodels branches of the shared row writer and range setup. They are removed (1339 lines); the Cosserat library modules and their own tests stay. No reachable code changes: the full suite passes and the examples A/B is 53/53 identical. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
… moving points After the rebase onto the C API host rotations (#70) a handle from CableDyn_InitDeckRotating passes each block's rotation to the aggregate, which hands End B's column to End B's frame: a C API host turns End B's torsion and connection frame with its own block. Gate (python/tests/test_host_rotation.py): the clamped straight torsion line between two Coupled points, End A rolled by +phi and End B by -phi at 60 deg/s, returns -GJ 2 phi / L to block 1 and +GJ 2 phi / L to block 2 and twists by -2 phi at every step (1e-6 GJ); equal rolls of both ends return no torque. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…ints CableDyn_GetCoupledLayout refused every deck with a finite-EI line whose End B is a Coupled point: it required the moving set to be the system points plus one fairlead per cable and filled only the End A blocks. It now accepts the End B columns (nsys + ncable + ncable_b) and names each cable_col_b block with the line's End B point as CD_C_POINT_COUPLED. Docs: the C API layout reference and the Python coupled_layout docstring. Gate (python/tests/test_two_moving_ends_capi.py, the documented host recipe: GetCoupledLayout, drive the coupled blocks, Step, CalcOutput and GetCoupledMoments): the layout is ((1, coupled), (2, coupled)); held at rest the two ends carry the submerged weight, -w L / 2 each to 1e-6, and mirror each other to 1e-8; the End A load equals the same line's with a Fixed End B to 1e-6; a 2 m surge of the End B block moves node 1 there and changes both end loads. The layout call fails on the old code. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
end_b_held compared the End B target rotated into the cable's solve frame with the committed node 1 position bit for bit. A host that reads End B back in global axes (CD_HFMF_GetEndBKinematics: the standalone march without a motionFile) hands over the rotated committed position, which the rotation round trip at a non-zero chord heading need not return exactly: such an End B was prescribed instead of held, and a slack cable at a 37 deg heading drifted 1e-3 N from its Fixed End B twin from t = 6.65 s. The target now holds End B when it equals the committed position in the solve frame or in the global frame. Gate (tests/test_two_moving_ends, Z): the 360 m slack cable over a 300 m span at a 37 deg heading on an 80 m seabed, 20 s, writes the Fixed End B's .out byte for byte with a held Coupled End B, without a motionFile (failed before) and with End A surging under motion rows that hold End B. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
- A standalone TURBINES deck built its cables without the ends' parent orientations, while the FAST.Farm aggregate passes ptfm_zyx_dcm(farm_ptfm_init): an end on a Turbine<J> point now takes its Ez and Nx in that turbine's axes, turned by its PtfmInit rotation (turbine_end_dcm, End A and End B), so the two routes start from the same equilibrium. Named result change (CHANGELOG Changed): TURBINES decks whose turbines start rotated and whose lines carry end connections or torsion. - set_host_objects: the host rod and body column offsets include the End B columns (they never share a deck with a finite-EI cable today). - Python deck validator: mirrors the native staticsFriction asLaid refusal on a finite-EI line with a moving End B. - Docs: the endpoint rules and the motionFile roll paragraph (driver_format, file_formats) for a line between two moving points: Phi = Pretwist(B) - Pretwist(A) - roll(A) - roll(B). Gate (tests/test_two_moving_ends, FP): turbines yawed +15 and -8 deg by PtfmInit, the clamped line twisted 90 deg between them; the standalone TURBINES run and the FAST.Farm aggregate (host passing each turbine's orientation) agree in FairTen, AnchTen, Torq at both ends and the end curvatures to 7.6e-9 at every step. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
A standalone TURBINES deck moved a finite-EI line end on a Turbine<J> point with x + R(q) p but held its END CONNECTIONS and torsion frames at their start orientation. The motion table now keeps each turbine's rotation, angular velocity and acceleration per row (turb_rot, turb_omega, turb_alpha), and the row-1 kinematics and the march pass them to End A and End B as parent orientations (turbine_end_rotation), as vesselMotion and the OpenFAST and FAST.Farm hosts do. Ends on other points keep held frames. Named result change (CHANGELOG Changed): TURBINES decks whose rows rotate the turbines and whose finite-EI lines carry end connections or torsion. On a clamped line twisted 90 deg between turbines rolling 10 deg in opposite senses over 1 s the end torque at 1 s is 613.6 N m (788.1 N m before); the tensions change by under 5e-7. No example deck uses TURBINES rows. Gate (tests/test_two_moving_ends, FR): that deck standalone against the FAST.Farm aggregate with the same rotations as host orientations: largest relative channel difference 3.4e-8 at every step (2.2e-1 before), and the rolls change the torque by more than 1 %. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
The multibody march drove a finite-EI cable at End A only and refused any End B
that was not Fixed. End B may now be a Rigid6 body point or a rod end as well:
- MultibodyMarch carries End B's attachment (cab_kind_b, cab_obj_b, cab_off_b),
its connection/torsion frame (cab_clamp_b) and its loads; the cable is built
with a moving End B in its object's frame and driven at both ends
(mb_cable_drive); End B's force, connection moment and torque return to its
object in every load path (staggered corrector, monolithic group residual,
row scales, object output wrenches, Point<P>F, Rod<N> loads), and the
torsion turn limit holds End B's body too (an end free in torsion is not
limited).
- Monolithic step: such a cable is re-stepped at every outer iteration (cab_imp)
and its finite-difference end-load derivative spans the junction coordinates
of both objects' groups (cable_columns_two), so the cable's end-to-end
stiffness couples the two bodies in the one Newton matrix of the step. Chosen
over a partitioned iteration on evidence: on a stiff taut cable (EA 1e8 N)
between 200 kg bodies at dtM 0.05 s, dropping the cross-group blocks took 9.2
mean outer iterations and 300 step halvings over 100 steps, against 3.9 and
none; on the gate decks both converge alike. A cable is re-stepped when it is
connected at an end on a moving object or joins two moving objects; a pinned
cable with one moving end is coupled at the predictor whichever end that is,
and an end on a fixed rod's end needs no re-step. The tightened cable Newton
tolerance applies to the re-stepped cables only.
- Staggered step: a cable between two objects with pinned ends is stepped with
both predicted attachments; a connected or torsional end on a body or rod
needs bodyScheme monolithic, at either end (a torsion frame at a
bending-pinned End A included: the staggered scheme held the frame still
while the body turned and could spin it through +-180 deg).
- Statics (bodyIC static): the clamped-end passes of solve_body_equilibrium
correct both ends of a cable between two objects to the cubic-Hermite end
loads (the core reports End B's surrogate force), with the torque stiffness
at each end about its own object. Each load entry keeps its line (eline),
so the non-convergence report names the line and the end; the passes of a
deck with such a line are accelerated by Anderson mixing of the last six
passes (a stiff EI 1e6 clamped cable between two unequal moored bodies, out
of their plane, did not converge in 60 plain passes and now converges in 8,
in either direction, to the same equilibrium). Decks without such a line
keep the plain passes bit for bit. CD_Body_Static_Pass_Limit, a
verification hook, limits the passes.
- Validation: END CONNECTIONS and torsion admit End B on a body point or a rod
end (end_b_holds_frame); the march refuses an End B on a Free/Connect point,
a Point3 buoy or a Coupled/Vessel point by name. TURBINES rows keep their
rotations only for a deck whose line ends carry a connection or torsion
frame (read_motion_file with_turbine_frames). The Python validator mirrors
the rules (_check_multibody_cable_ends), and its staticsFriction asLaid
check strips the option value's quotes as the native parser does.
- The multibody probe records body 2, End B's loads and the cable's linear
momentum (CD_HermiteCable_Dyn_Momentum).
Where this meets the torsion routes (a line restrained at one end, a torsional
END CONNECTION on a Fixed rod end or a Body<N> rod end):
- check_torsion_line takes the union of both scopes: restrained at both ends,
End B Fixed, Coupled/Vessel or a Rigid6 body point; End A on a Fixed rod or
a Body<N> rod. Two cases neither route solves are refused by name: torsion
at an End B on a rod end ("... on a rod end is not supported at End B ...")
and a rod End A restrained in torsion with a moving End B ("... on a rod
end needs a Fixed End B ..."). ROD_END_B_NOTE is gone: a bending END
CONNECTION takes any End B that holds a frame. deck_file.py mirrors both.
- The restrained end decides, not any torsion on the line: line_torsion_at_a
and line_torsion_at_b drive connected_end, cab_clamp_b, the End B staggered
refusal and the static pass tolerance and pinned-end skip; clamp_object_frame
takes the Fixed-rod normal nx0 of the end it frames and end_b.
Gates (tests/test_cable_between_bodies, all refused on the old code):
symmetry of two mirrored bodies (monolithic clamped and staggered pinned) to the
output precision; a body joined to a 1e15 kg body equals the body-to-Fixed line
of the established route to 8e-9 (clamped, and twisted 90 deg); two free bodies
without external load keep the total linear momentum to 3e-5 and the energy to
0.2 %; a 90 deg twist returns equal and opposite torques GJ Phi/L (sum below
2e-10 N m) and counter-rotates the bodies; a moored pair starts balanced and
drifts below the output precision over 5 s, and its connection moments turn it
from the pinned pitch; a body-to-rod-end cable runs; the refusals name the
cause. P: the stiff pair converges forward and reversed to one equilibrium,
and with two passes allowed fails closed naming LINE 7 (its End B). D: a
Fixed-to-rod-end line and its reversal write one output (the torsion routes
turn a Fixed-to-rod line around, as a Fixed-to-body line is), and a body's
cable to a fixed rod's end writes the output of the same cable to a Fixed
point. R: the staggered refusal of a torsion frame at a body End A.
test_rod_end_torsion and test_deck_native_parity take the End B rod-end
refusal and the shared staggered message.
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…nuation The Coupled/Vessel End B refusal of the multibody march ended its CALL with "; &" and put RETURN on the continuation line, so the statement after the semicolon began with the continuation. Intel ifx 2025.3.2 warns (#5151, "Continuation character illegal as first non_blank in statement"); gfortran accepts it. RETURN now stands on its own line. Introduced by the multibody commit of this series (a finite-EI line between two objects). Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…xed deck
On the standalone mixed deck (EI = 0 and finite-EI lines, marched on the
coupled aggregate) the motion table reaches the cables through
build_aggregate_motion, which enumerated both ends of each finite-EI line
together, in deck POINT order. The aggregate's moving set of a deck with a line
between two moving points is [system points][End A of every cable][End B of
every cable with a moving End B], so a deck whose End B point came before End
A's in POINTS (or with two such cables) was refused ("the prescribed motion of
moving point 2 is not keyed to that point"), and where the orders happened to
agree cable_two_ends stepped the cable without any imposed twist: the roll
columns did not twist the line.
- build_aggregate_motion follows the moving-set order of the two-ends layout:
one column per cable End A, then the moving End B of each cable between two
moving points (moving_end_b_point, as apply_coupled_positions and
fill_turbine_of_moving count them), each taking the roll column when that
end is restrained in torsion (line_torsion_at_a, line_torsion_at_b).
- cable_two_ends takes the imposed twist; a cable with a moving End B solved in
torsion steps with Phi_0 - roll(A) - roll(B), as the standalone cubic-Hermite
route does (line_roll_twist). Decks without a line between two moving points
keep their columns and steps unchanged.
Gate 8 (tests/test_mixed_route_torsion): the gate 3 line (twisted 90 deg) with
End B on a Coupled point, beside a chain, both ends rolled by the roll column.
Rolled oppositely (a rigid roll about the line's axis) Twist1 stays 90 deg
exactly and Torq = GJ Phi / L at both ends to 3.4e-6 N m; rolled equally (15
deg each) Twist1 = 90 - 2 roll to 5.0e-7 deg and the torque to 4.7e-6 N m (the
old code: 30 deg and 262 N m); the same with End B's point listed first in
POINTS to the same figures (the old code refused the deck).
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
|
@codex review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Already looking forward to the next diff. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
CD_HFMF_Refresh_Acceleration tests self%moving_b .AND. .NOT. end_b_at_rest(self); Fortran does not short-circuit, so end_b_at_rest indexed v and a at pdof_b = 0 on every cable without a moving End B. Release builds read a stray value that the condition then discarded; the checked Debug build stops on it (24 tests on the Linux Debug job). end_b_at_rest now returns at rest when End B is not driven, before any index. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
A Rod<N>A/B end point keeps its rod's id in body_id, where a Body<N> point keeps its body's. collect_body_point_indices took every point with the body's id while count_body_point_refs counts the Body<N> points only: with a rod numbered as the body, a rod end POINT row listed before the body's points became the body's first attachment point, and the list overran its allocation (also in 0.3.0). The collection now takes the Body<N> points only, as they are counted. New gate body_rod_numbering: a free Rigid6 body on three legs with a pinned arm rod, its tether on an explicit Rod<N>B POINT listed first; the deck with the arm as Rod1 and as Rod3 now writes the same outputs bit for bit (Release and checked Debug). Before, 200 of 203 rows differed: the arm turned 172 deg in pitch, the body 1.06 deg and 0.14 m in surge, and a leg tension moved 3.0 kN in 1 s. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
|
@codex review |
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
GitHub retires the `macos-14` runner image on 2 November 2026, and its scheduled brownouts already cancel the `wheels / macos` job (#73, #74, #75: "Cancelled after 1s", annotated as a macOS 14 brownout, actions/runner-images#13518). - `.github/workflows/wheels.yml`: the macOS wheel builds on `macos-15` with `MACOSX_DEPLOYMENT_TARGET=15.0`, the oldest macOS its Homebrew gfortran and OpenBLAS bottles support there, so delocate accepts the bundled libraries. The wheel tag becomes `macosx_15_0_arm64` (0.3.0: `macosx_14_0_arm64`). - The installation page, the README and the CHANGELOG (`Changed`) say the macOS wheel needs macOS 15 or newer on Apple silicon; on macOS 14, build from source. No code change. Docs build with warnings as errors locally; the `wheels / macos` job of this PR is the build and smoke test of the new wheel. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…, on lines as long as their span and on bodies with pinned cables (#77) ## What changed Six accuracy items from the open list, rebased onto dev (#73 torsion linearisation, control and modal analysis, #74 torsion on the mixed deck, at one end and on a rod end, #75 lines with two moving ends, #76), one commit that closes where they meet dev's newer routes, and four fixes from an independent review. - **Dry weight of an `EI = 0` line above the surface.** With a seabed the march gives the part of a line above the still-water level its dry weight; the static start kept its buoyancy. `CD_Static_Line_Equilibrium` now carries the dry part as a fixed point on the wetted lengths. A chain hung from 5 m above the surface starts in the march's equilibrium (holds to 1e-10; before 1e-3 of its fairlead load in the first step), and the coupled and standalone starts agree to 1.4e-8 (before 2.4e-4). - **The same dry weight in the force balance of `Connect`/`Free` points, bodies and rods** (`solve_body_equilibrium_core`, its warm and cold line solves, the new `CD_Static_Line_Dry_Load`). A 50 t `Connect` point hung by two chains from 10 m above the surface holds its position over 2 s (before it sank 1.1e-2 m). An `EI = 0` chain between two moving objects across the surface, a body point 5 m above it and a `Connect` clump, holds both (before 5.5e-3 m). In that balance a finite-EI line, carried without its bending stiffness, now takes its dry weight with or without a seabed, as its cubic-Hermite cable does: a body with a light pinned cable 5 m above the surface on a deck without a seabed holds its heave to 7e-6 m (before 2.8e-3 m). - **`ATTACHMENTS` above the surface.** The march loads an attachment above the free surface with its weight alone, while the attachment polish and the torsion stage after it kept its buoyancy. Each solve now takes every attachment's load for the side of the surface its node is on, and the final solve is repeated until no attachment changes side. A 500 kg, 0.2 m³ module 3 m above the surface held the fairlead load over 1 s to the output's 8 digits, restrained in torsion as well (before it moved by up to 6.1e-2). An attachment carried above and below the surface on alternate solves (a net-buoyant module that would float, which a point attachment cannot represent) fails closed, and the message leads with that attachment's index, Mass and Volume. - **A pinned cable with `ATTACHMENTS` in the body static balance.** The object solve left a bending-pinned End A free in torsion to its cable without bending stiffness, which carries no attachments. Such a line now takes the static passes of a connected end. On a moored body with a 2 t clump on a pinned cable the body holds its pose (before it drifted by up to 2.9e-2 m and 0.20 deg in 5 s). - **Current gradient in the finite-EI static tangent.** A depth profile is sampled at the node elevations and a current grid at the node positions, so the drag moves with the nodes. The Newton tangent now carries that: the drag tangent matches central differences to 4e-10 to 1.7e-9 (before 5e-2 to 0.2), also at the twisted equilibrium of a line restrained in torsion with `GJ|K` (4.3e-10, before 5.4e-2). The equilibria do not change beyond the solver tolerance; Newton converges faster in strong shear (16 instead of 23 iterations). - **Force-scale floor for a finite-EI line as long as its span.** The static start of a neutral line whose length equals its span failed with neutral or drag-area `ATTACHMENTS`: the polish stalled at the round-off of the axial forces. For a line whose chord is at least its length, the convergence scale now includes that floor over the tolerance, as on the `EI = 0` path. Such lines now start straight and unloaded, also between two moving ends, restrained in torsion at both ends or at End A only, and with a chord 1e-8 longer than the line (0.1 N to 2.2e-7 N). All of these failed on dev. - Docs: the linearisation at an accelerating coupled point (`doc/openfast.rst`, `VALIDATION.md`), and the carry spin of a held end section, measured and left out (`doc/theory.rst`; the modal analysis and the OpenFAST linearisation of #73 leave it out as well). ## Review fixes - **The attachment with no static side is named** (`attachment_static_polish`, `torsion_after_attachments`): a 200 kg, 2 m³ module 50 m along a slack cable stopped with only "the homotopy stopped at load fraction 0.625000"; every later failure now leads with the attachment that crossed the surface (`static_dry_weight` 9). On dev the same deck ran with the module 4.5 m above the surface and its buoyancy kept. - **A pinned cable with `ATTACHMENTS` on a `Point3` buoy** is refused by the existing `Point3` message instead of an END CONNECTIONS message for a deck without that row (`line_attachments` 10). - **The body passes of a pinned cable with `ATTACHMENTS` are Anderson-mixed**, as the passes of a line between two objects are: on a spar rod with a 1500 kg clump on a pinned cable the plain passes diverged (end-load change 2.9 of the force scale after 60) and the deck stopped; they now converge in 26 and the rod holds to 8 digits over 3 s (`line_attachments` 11). - **Every bending-pinned finite-EI line on a Rigid6 body or a rod end takes the (mixed) passes**, with or without attachments: the stand-in without bending stiffness put a spar rod's start 5.7e-2 m off equilibrium (7e-2 m drift and a 2.3 % leg tension change in 3 s); it now holds to 8 digits after 4 passes (`line_attachments` 12; before 1.8e-4 m in 0.1 s). This changes the static start of user decks with a pinned finite-EI cable on a free body or rod by the bending share of the end force; no example deck has one. - **Body passes that do not hinge on round-off** (after the Linux Release job failed `line_attachments` 11 with no convergence in 60 passes, where Windows took 26): the core solve's stand-in cable now carries the line's `ATTACHMENTS` smeared as net weight, as the Hermite statics smear them, so the passes correct only the lumped, surface-side, drag and bending differences (the whole 15 kN clump load before); a failed pass set is repeated once on the stand-in without attachments; and the Anderson column-drop bound is 1e-6 instead of 1e-10 (a pinned end's residual spans fewer directions than the history, so later columns were round-off with coefficients near 1e12). Gate 11 converges in 6 passes, geometrically. New gate 13: the same deck with a leg anchor moved 1 ulp either way gives the same rod pose to 1e-9 m in 6 passes each (before 26, no convergence after 60, 26). Across a 45-deck sweep of rod and body decks (clump mass, cable length, rod mass, start offsets, 1-ulp and 1e-14 m moves) 42 converge, 34 before; the two-object decks are unchanged. Gates 11 and 12 march at `dtM` 0.002 s, because the explicit coupling of a cable to a free rod on this branch is unstable at 0.01 s (fixed separately in the next PR). - Known and left: the as-laid friction reference still takes an attachment's net in-water weight, which matters only where the seabed rises above `z = 0`. ## Rebase notes - Conflicts were only in `CHANGELOG.md` (entries kept side by side), `doc/openfast.rst` (the torsion linearisation paragraph of #73 kept, and the zero-frequency paragraph replaced by this branch's operating-point version) and `doc/theory.rst` (the carry-spin paragraph placed before #74's free-end section). The source files merged cleanly. `cached_line_solve`, `prepare_line` and `warm_line_solve` sit on #75's two-ends object solve unchanged: the line cache already treats both ends alike. - The carry-spin commit message no longer says the modal analysis refuses torsion. ## Gates - `static_dry_weight` 1-8: gates 1-5 as before. Gate 6: a module above the surface, plain and restrained in torsion (0; before 6.1e-2), and a submerged module as guard. Gate 7: a pinned cable above the surface on a body without a seabed (7e-6 m; before 2.8e-3 m). Gate 8: an `EI = 0` chain between a body above the surface and a `Connect` point (0; before 5.5e-3 m). - `line_attachments` 8 (continued) and 9: two moving ends, torsion at one or both ends, and a chord above the length, each of which failed on dev; the pinned cable with a clump on a moored body (1e-9 m; before 2.9e-2 m). - `hermite_static_current_gradient` 1-5, `nodal_twist_dynamic` (carry spin). ## Checks - Full ctest (Release): 344 of 344 pass (also after the review fixes; base now dev 1a8a606, #76 touched only CI and docs). On the checked Debug build (`-fcheck=all`) the added and touched tests and their neighbours pass, 12 of 12: `static_dry_weight`, `line_attachments`, `hermite_static_current_gradient`, `nodal_twist_dynamic`, `hermite_cable_static`, `hermite_torsion_static`, `torsion_attachments`, `torsion_one_end`, `rod_end_torsion`, `clamped_cable_ends`, `cable_between_bodies`, `bodies_rods`. - pytest `python/tests` and `tests`, with the native parity tests on (`CABLEDYN_TEST_DRIVER`): 2179 passed, 75 skipped. - ruff check and format are clean. Strict mypy shows only dev's 3 numpy-stub notes. pre-commit and Sphinx `-W` are clean, and no symbol is both in a `PUBLIC` list and declared `PUBLIC`. - Example A/B against dev 357f9eb: 53 of 53 identical. No example has a line or attachment above the water, a finite-EI line in a profile or grid current, a line as long as its span, or a pinned cable with `ATTACHMENTS` on a body. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
…plicitly (#78) ## What changed The monolithic multibody step (`bodyScheme monolithic`, the default) coupled a finite-EI cable pinned to a moving object (a Rigid6 `Body<N>` point or a free or pinned `Rod<N>` end, the other end held) at the Newmark predictor: the cable was stepped once per step with the predicted attachment motion and its end force was held through the outer iterations. That is an explicit, partitioned coupling. Its step amplification exceeds 1 once `K_e dt^2 / m_e` is above about 0.85 (1.5 at 1.3, 2.5 at 2), with `K_e` the cable's condensed dynamic end stiffness and `m_e` the object's effective mass along the cable. A light object on a stiff cable therefore left a balanced static start. A 3 t free rod spar with a 55 m cable (`EA` 5e8 N, 40 elements) pinned at its upper end, at `dtM` 0.01 s: - the step change of the cable tension alternated in sign and grew 2.3 times per step; - the tension rose from 11 kN past 1 MN in 0.7 s; - the rod end moved 6.3 m in 2 s. The start was not at fault. It is a stable equilibrium of the march: - the same deck with an `EI = 0` cable stays at rest to 1e-10 m; - with the cable clamped (`Rigid`, already coupled implicitly) it stays at rest to 1e-7 m; - the staggered scheme holds it. **The fix.** In `src/CableDyn_DeckDriver.f90`, every cable with an end on an object the march moves now sets `cab_imp`. This covers pinned or connected ends, End A or End B, bodies and free or pinned rods. Such a cable is re-stepped at every outer iteration with its end stiffness in the Newton matrix, as clamped cables and cables between two objects already were. A cable with no moving end is still stepped once. The staggered scheme and the OpenFAST and C-API routes are unchanged. **Docs.** - `doc/driver_format.md`: the multibody route bullet. - `doc/theory.rst`: the monolithic scheme paragraph, now with the stability criterion of the old coupling, and the clamped-cable paragraph. - `CHANGELOG.md`: an `[Unreleased]` Fixed entry. The #75 Added entry no longer says a pinned cable is "coupled at the predictor". ## Gates New CTest `pinned_cable_light_object`. On dev e760bc6, 14 of its gates fail. | Gate | dev e760bc6 | this branch | |---|---|---| | H: spar rod, cable pinned at the upper end (2 s): rod end move / tension change | 6.3 m / 161 times the start | 1e-10 m / 2.7e-8 | | H: same, in a 0.5 m/s current | 5.4 m / 472 times | 6.3e-4 m / 1.2e-4 (a slow swing of the start in the current, the same on the staggered scheme) | | H: cable pinned at the lower end | 6.5 m / 5596 times | 1.8e-10 m / 3.4e-8 | | D: cable from a fixed rod's end to the free rod (End B on the moving object) | 6.1 m / 1190 times | 2e-7 m / 9e-8 | | D: cable written from its anchor | the same output byte for byte | the same output byte for byte | | B: 4 t Rigid6 buoy with a pinned keel cable (4 s) | 0.22 m / 38 times | 1e-9 m / 3.3e-8 | | S: monolithic vs staggered, upper / lower end | 6.0 / 6.5 m apart | 1e-10 / 1.7e-10 m, tensions to 2.7e-8 / 3.4e-8 | | E: controls (`EI = 0` cable; cable clamped at upper / lower end) | at rest | at rest: 1e-10 m; 1e-7 / 3e-9 m | Gate tolerances: - 1e-5 m and 1e-5 of the tension; the positions are written to 8 digits, so 1e-6 m at the rod's depth; - 2e-3 m and 1e-3 in the current; - 1e-5 m for the staggered comparison. `line_attachments` 11 and 12 had to march at `dtM` 0.002 s on #77 because of this coupling. They are back at `dtM` 0.01 s, over 1 s instead of 0.3 s: | Gate | dev e760bc6 at `dtM` 0.01 s | this branch | |---|---|---| | 11: spar rod, pinned cable with a 1500 kg clump | 0.82 m / leg tension 13 times | 1e-7 m / 2.9e-7 | | 12: the same without the clump | 1.3 m / 4.4 times | 0 m / 3.8e-8 | Over 3 s the clump deck holds to 1.1e-6 m; dev moves it 15 m. ## Example A/B (reference driver built at e760bc6) 52 of 53 example decks are identical. `mixed_body_rods_points` changes; it is a 150 t buoy with a pinned power cable, the one example with a pinned cable on a moving object: - body surge changes by up to 3.5e-5 m (7e-6 of its 5.2 m range); - `Rod2Ry` changes by 2.3e-4 deg; - the cable top tension `FairTen8` changes by 0.6 N of 8.1 kN. The new run is the more accurate one. Against the same deck at `dtM` / 4, the body surge error falls from 3.7e-5 m to 1.6e-6 m and the pitch error from 1.1e-4 to 2.2e-5 deg. The cable tension error, 17 N, comes from the cable's own time step and does not change. The deck runs about 45 % longer (6.8 s to 9.8 s), because the cable is now stepped once per outer iteration instead of once per step. ## Checks - Full ctest (Release): 345 of 345 pass. - Checked Debug build (`-fcheck=all`, `--timeout 5400`): `pinned_cable_light_object`, `line_attachments`, `static_dry_weight`, `cable_between_bodies`, `monolithic_gates`, `clamped_cable_ends`, `body_rod_physics`, `bodies_rods` and `driver_clamped_cable_pinned_rod` pass, 9 of 9. - pytest `python/tests` and `tests`: with the native parity tests on (`CABLEDYN_TEST_DRIVER`), 2179 passed, 75 skipped. - ruff check and format are clean. Strict mypy shows only dev's 3 numpy-stub notes. - pre-commit and Sphinx `-W` are clean. `dup_public`: 0 duplicates. ## Notes - The slow drift in a current (6.3e-4 m in 2 s, 1.3e-3 m at most over 6 s, then turning back) is the same on the staggered scheme. The `EI = 0` cable in the same current holds to 1e-10 m. So it is a small static-versus-dynamic difference of the finite-EI cable in a current, not part of this coupling, and is left for the open list. - If the 45 % cost on decks with a pinned cable on a heavy body matters, the old coupling could be kept where `K_e dt^2 / m_e` is safely below 0.85. That needs estimates of `K_e` and `m_e`; this change takes the uniformly implicit coupling for robustness. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
A finite-EI (cubic-Hermite) line may now have two moving ends: End B on a
Coupled/Vessel point (a cable shared by two floaters, a FAST.Farm shared
line), standalone, in OpenFAST, FAST.Farm and the C API, and End B on a
Rigid6 body point or a rod end on the standalone multibody march (a cable
between two objects). Both ends are driven, carry END CONNECTIONS and torsion,
and return their loads to their hosts or objects.
Base: dev e992e9f (#74); the series is rebased onto it from 6195432 (#71),
past #72, #73 and #74.
own parent frame, end connection and torsion frame (the frames of both ends
turn with their parents), its mirror block in the restart state, and a held
End B (at rest, target equal to the committed position in either frame) that
steps exactly as a Fixed End B.
column drive End B as End A; Phi = Pretwist(B) - Pretwist(A) - roll(A) -
roll(B), the roll of an end free in torsion twisting nothing. TURBINES
decks start each end's Ez/Nx in its turbine's PtfmInit axes and turn both
frames with the rows' rotations, as FAST.Farm does.
(cable_col_b), the turbine map, host orientations at both ends,
CableDyn_GetCoupledLayout with the End B blocks; OpenFAST linearisation of
such a cable fails closed (the linearisation of torsion from feat(torsion): OpenFAST linearisation, active line control and modal analysis of lines restrained in torsion #73 stays for
every other line). On the standalone mixed deck the roll columns of both
ends twist the line.
monolithic step re-steps a cable between two objects at every outer
iteration and couples both objects' junction coordinates through its
finite-difference end-to-end stiffness in the one Newton matrix; the
static passes balance both objects on the cubic-Hermite end loads,
accelerated by Anderson mixing (a stiff EI 1e6 clamped cable between two
unequal moored bodies, out of their plane: 8 passes either direction, where
the plain passes diverged); the staggered scheme takes pinned ends. A
pinned cable with one moving end is coupled at the predictor whichever end
that is, and an end on a fixed rod's end is the Fixed end there, so the
result does not depend on the line's direction. A partitioned coupling was
measured and not taken: on a stiff taut cable (EA 1e8 N) between 200 kg
bodies at dtM 0.05 s it needed 9.2 mean outer iterations and 300 step
halvings over 100 steps, the joint form 3.9 and none. An End B on a
Free/Connect point, a Point3 buoy or a Coupled/Vessel point stays refused
there by name.
admit those End B points; staticsFriction asLaid is refused on a moving
End B.
Where it meets the torsion routes of #73/#74 (one restrained end, torsion on
Fixed and
Body<N>rod ends, prescribed motion on the mixed deck):refused by name, natively and in deck_file.py: torsion at an End B on a rod
end, and a rod End A restrained in torsion with a moving End B. A bending
END CONNECTION takes any End B that holds a frame (ROD_END_B_NOTE is gone).
(line_torsion_at_a/line_torsion_at_b): connected_end, cab_clamp_b, the End B
staggered refusal, the static pass tolerance and pinned-end skip, the roll
columns, and the torsion turn limit of both bodies (an end free in torsion
is not limited). clamp_object_frame takes the Fixed-rod normal of the end it
frames;
Rod<N>connection moments include End B.(End A columns, then End B columns) and cable_two_ends imposes
Phi_0 - roll(A) - roll(B). Before, a deck whose End B point came first was
refused and otherwise the roll did not twist the line (gate 8 below).
write one output, since feat(torsion): torsion on the mixed deck, at one restrained end and on a Fixed rod end, the routes combined #74 turns a Fixed-to-rod line around as dev turns a
Fixed-to-body line.
Result changes:
test decks reached it, all refusals or a run-only smoke; on four
shared-line decks it failed to converge (three) or reached a static
FairTen of -6.1e8 N (one), and the Hermite route runs all four. Decks with
a line between two moving points now run on the Hermite route.
bodyScheme staggered (it ran with the frame held still and could spin the
body through +-180 deg); the monolithic scheme turns it with the body.
Turbine<J>point takes Ez and Nx inthe turbine's axes (turned by PtfmInit) and its frames turn with the
TURBINES rows. Decks whose turbines start rotated or whose rows rotate,
with end connections or torsion, change: on a clamped line twisted 90 deg
between turbines rolling 10 deg in opposite senses the end torque at 1 s is
613.6 N m (788.1 N m before), tensions within 5e-7. No example uses
TURBINES rows.
Gates:
files byte for byte (also at a 37 deg chord heading and in the modes); a
symmetric cable whose ends move apart stays mirror-symmetric (4e-11 m); a
rigid translation keeps the end loads (4e-5 N of 1.6e4 N); End B driven
equals the reversed line driven at End A (1e-3 N; turning clamped End B
2e-5 N, 4e-7 N m); equal rolls keep the torque (3e-6 N m), opposite rolls
change it by GJ (2 phi)/L (5e-6 N m); restarts bit-identical; FAST.Farm
aggregate vs standalone: shared line 7e-3 N of 1.9e4 N, yawed turbines with
torsion 7.6e-9, rolling turbines 3.4e-8 in every channel.
(monolithic clamped and staggered pinned, to the output precision); a body
joined to a 1e15 kg body equals the body-to-Fixed line of the established
route to 8e-9 (clamped, and twisted 90 deg); two free bodies with no
external load keep the total linear momentum to 3e-5 and the energy to
0.2 %; a 90 deg twist returns equal and opposite torques GJ Phi/L (sum
below 2e-10 N m); a moored pair starts balanced and stays at rest, its
connection moments turning it from the pinned pitch; the stiff unequal pair
converges forward and reversed to one equilibrium the still dynamics hold,
and with its passes limited fails closed naming the line; either direction
of a Fixed-point-to-rod-end cable gives the same output, and an End B on a
fixed rod's end is the Fixed End B; a body-to-rod-end cable runs; refusals
name their cause (the staggered torsion End A included).
Coupled points beside a chain, both ends rolled by the roll column: rolled
oppositely the twist stays 90 deg exactly (torque GJ Phi/L to 3.4e-6 N m);
rolled equally 15 deg it is 90 - 2 roll to 5.0e-7 deg (4.7e-6 N m; the old
code 30 deg and 262 N m); End B's point listed first gives the same figures
(the old code refused the deck).
rod-end refusal and the shared staggered message.
of a connected or torsional end at either end, and the two new torsion
refusals.
driven through the documented host recipe, the asLaid mirror.
Commits: the two-moving-ends commits rebased one by one, the three multibody
commits (a finite-EI line between two objects, its review fixes, the Python
mirror) as one with the torsion-route integration, then the Intel ifx #5151
continuation fix and the mixed-deck roll fix with gate 8.
Two fixes from the checked Debug CI job:
end_b_at_restno longer indexespdof_bwhen End B is not driven(Fortran does not short-circuit
moving_b .AND. .NOT. end_b_at_rest(...);Release read a stray value it then discarded, Debug stopped on it).
(also in 0.3.0): a
Rod<N>A/Bend point keeps its rod's id where aBody<N>point keeps its body's, and the body's point list took both. Newgate
body_rod_numbering: the same deck with the arm rod numbered 1 and 3now writes identical outputs; before, 200 of 203 rows differed (arm pitch
172 deg, body pitch 1.06 deg, a leg tension 3.0 kN in 1 s).
The 25 tests the Debug job failed and the new gate pass on a local checked
Debug build.
Full ctest (341/341) and pytest (python/tests and tests with the native
driver: 2179 passed, 75 skipped) pass; ruff check/format and mypy clean (the
three numpy-stub notes dev already has aside), pre-commit clean, docs build
with warnings as errors, no symbol both in a PUBLIC list and declared PUBLIC.
A/B against the reference driver: 53 of 53 examples byte-identical.