Skip to content

SubDyn: include Guyan/rigid-body inertia in SIM and in member-load fixed-end moments - #3556

Merged
andrew-platt merged 6 commits into
OpenFAST:rc-5.0.1from
luwang00:b/SD_SIM_Fg
Dec 3, 2026
Merged

andrew-platt merged 6 commits into
OpenFAST:rc-5.0.1from
luwang00:b/SD_SIM_Fg

Conversation

@luwang00

@luwang00 luwang00 commented Nov 28, 2026 •

Copy link
Copy Markdown
Collaborator

This PR is ready for merging.

Feature or improvement description

Fixes three related problems in how SubDyn handles distributed inertial loads.

  1. Static-improvement method (SIM, SttcSolve=True) left out the Guyan/rigid-body inertial load.
    The SIM correction of the truncated Craig-Bampton modes only used the external and gravity loads $F_L$. It missed the inertial load on the internal nodes caused by the acceleration of the transition pieces or of the floating body, $\bar{M}_{LG}\ddot{U}_G$ with $\bar{M}_{LG} = (M_{LL}\Phi_R + M_{LR})\,T_I\,G$. The retained modes already receive this load through MMB, so the static responses of the retained and truncated modes were inconsistent. As a result, member loads depended on Nmodes and were non-zero in free fall.

    • New parameter SLG $= K_{LL}^{-1}\bar{M}_{LG} - \Phi_m\Omega_m^{-2}M_{mB}$, computed once in SetParameters.
    • GetUFulls now computes UL_SIM = (KLL^-1 - PhiM OmegaM^-2 PhiM^T) F_L - SLG * udotdot_TP. At that point udotdot_TP already holds the Guyan acceleration $\ddot U_G$, so no new misc variable was needed.
    • This applies to all three configurations: fixed-bottom, floating with a single TP that is also the rigid-body reference point, and floating with a dedicated reference point (TPID=0) plus coupled TPs.
  2. The member-load output (ElementForce) used gravity-only fixed-end moments.
    For beam elements, the equivalent nodal moments subtracted from $K_e u_e$ are now recomputed at every call. They include both the self-weight and the inertial (d'Alembert) load. They are taken from the element consistent mass matrix $M_e$, which is the same matrix used to assemble the system mass matrix:

    $F_{eq}(4:6)=[M_e(G−R_{g2b}\ddot{U}_e)](4:6)$,   $F_{eq}(10:12)=[M_e(G−R_{g2b}\ddot{U}_e)](10:12)$

    Here, $\ddot{U}_e$ holds all 12 nodal accelerations of the element, translations and rotations. $G$ is gravity at the translational DOFs and zero at the rotational DOFs. Everything is resolved in the frame of $K_e u_e$: the rigid-body frame for floating structures and the global frame for fixed-bottom structures.

    • Consistent with nodal equilibrium. $M_e$ is the same matrix used in the equations of motion, so the recovered moments satisfy nodal equilibrium of the finite-element model, including the rotational-acceleration and rotary-inertia terms. For example, a free tip with no applied moment reads zero to round-off when all modes are retained or SIM is used, with zero damping.

    • Gravity case unchanged. For gravity alone, $M_e G$ reduces exactly to the self-weight vector from ElemG $(\pm ρAgL^2/12)$, so results for a structure at rest are unchanged.

    • Frame fix. This also fixes a frame inconsistency introduced in SubDyn output improvements: beam self-weight consistency, end-node forces, and revolute joint fixes #3356. The floating self-weight moments were computed in the global frame and then combined with $K_e u_e$, which is in the body frame.

    • Forces unchanged. Element forces are still recovered by averaging and extrapolation, because the hydrodynamic loads are mapped as lumped nodal loads.

    • Review change. Following the Copilot review, $M_e$ replaces the earlier linear-load formula from this PR, $M_{1,2}=\pm L^2/60\hat{t}\times(\ldots)$, which used only the translational accelerations at the element end points. $M_e$ is now stored alongside $K_e$ for each output node (new field MeshAuxDataType%Me).

Documentation: the SubDyn theory sections "Static-Improvement Method" and "Nodal Loads Calculation" were rewritten to match the implementation.

  1. Floating joints with multiple rotational DOF sets.
    For floating structures, GetUFulls converted only the first rotational DOF set of each node to absolute global motion. Revolute, universal and spherical joints have one such set per connected element. The others stayed as elastic body-frame values, without the rigid-body angular velocity or acceleration, which gave incorrect member moments and MαNβRA*e outputs. All rotational DOF sets are now converted.

    In a test with a floating revolute joint and steady TP angular acceleration, the error that was linear in the acceleration is gone. What remains grows with the acceleration squared: it is the $\dot{ω}\times u_e$ term, which the output kinematics include but the modal equations leave out.

Related issue, if one exists

Closes #3552 and #3085. Related to #3356 (floating member-load moments).

Impacted areas of the software

  • SubDyn with SttcSolve=True: SIM displacements of the internal nodes. These enter SubDyn's member-load and nodal outputs and, for fixed-bottom structures, the reaction-node motion in the y3 mesh passed to SoilDyn. The y2 mesh (HydroDyn) and the y3 motion passed to MoorDyn don't include SIM, so they are unchanged.
  • SubDyn member-load outputs (MαNβFK*, MαNβMK*, ReactF*, ReactM*, AllOuts): beam fixed-end moments, for all structures (fixed-bottom and floating), with or without SIM.
  • The TP reaction (Y1) and the retained-mode equations are not affected.
  • Registry: new parameter SLG and new field MeshAuxDataType%Me in SubDyn_Registry.txt and the regenerated SubDyn_Types.f90.

Additional supporting information

The derivation is documented in the updated theory manual. The inertial load on the internal DOFs is $-\bar M_{LR}\ddot U_R$, from the second block row of the full equations with $U_L=\Phi_R U_R+\Phi_L q_L$. Treating the truncated modes quasi-statically gives $U_{L,SIM} = (K_{LL}^{-1}-\Phi_m\Omega_m^{-2}\Phi_m^T)(F_L - \bar M_{LR}\ddot U_R)$.

Known limitation, left for a follow-up: the centripetal load from the angular velocity of a floating body is included neither in the modal equations nor in SIM.

This PR points to the dev branch because it requires test cases without coupled transition pieces. However, the fix should be backported to rc-5.0.1.

Generative AI usage

Analysis, implementation, verification scripts and documentation were developed with AI assistance.

Co-authored-by: Anthropic Claude claude@anthropic.com
Assisted by: GitHub Copilot support@github.com

The equations have been reproduced by human, and the implementation manually checked.

Test results, if applicable

Stand-alone SubDyn driver tests on a Y-frame (3 circular beam members, NDiv=3). Each case was run for Nmodes = 0 / 6 / 20 / all, with SIM on and off:

  • Floating, TP0 only (rigid-body reference point, no coupled TP):
    • Free fall: maximum member load ≈ 1e-9 for all Nmodes/SIM combinations (before the fix: up to 3.4e4).
    • Constant applied force: M2N1FKxe = −456 N for every Nmodes with SIM.
  • Fixed-bottom (base clamped, TP at the Y joint), steady TP acceleration $a_x$ = 1 m/s²:
    • With SIM, the cantilever root loads are 6940.2–6940.5 N and 49074–49076 N·m for all Nmodes. The analytical values are $\rho A L$ = 6940.45 N and $\rho A L^2/2$ = 49076.4 N·m.
    • Without SIM, Nmodes=0 gives 0 and Nmodes=6 gives 6420 N.
    • A general 6-DOF acceleration also gives the same loads for all Nmodes with SIM.
  • Floating, single TP (also the rigid-body reference point):
    • Same steady accelerations: the same analytical results, with deviation 0.00 from the all-modes run for Nmodes = 6/20.
    • Free fall: maximum member load ≈ 1e-9.
  • Floating, TP0 + coupled TP (InputsMod=2):
    • Free fall: maximum member load ≈ 0.1 N, which comes from rounding in the input file.
    • Prescribed TP1 acceleration ramped smoothly to $a_x$ = 1 m/s²: member 3 root = 6940.45 N / 49076.4 N·m, and member 2 at the Y joint = 11848.10 N (analytical $\rho A(L_1+L_3)$ = 11848.09 N), for all Nmodes with SIM.

After rebasing to rc-5.0.1, a total of 11 r-tests involving SubDyn failed. This is expected, because the SIM-dependent outputs and the member moment channels change:

 22 - 5MW_OC3Mnpl_DLL_WTurb_WavesIrr
 23 - 5MW_OC3Mnpl_DLL_WTurb_WavesIrr_IceDyn
 24 - 5MW_OC3Mnpl_DLL_WTurb_WavesIrr_IceFloe
 25 - 5MW_OC3Mnpl_DLL_WTurb_WavesIrr_Restart
 26 - 5MW_OC3Trpd_DLL_WSt_WavesReg
 27 - 5MW_OC4Jckt_DLL_WTurb_WavesIrr_MGrowth
 53 - OC6_phaseII
 55 - OC7_PhaseII_VolturnUS_Strip
 56 - OC7_PhaseII_VolturnUS_PotFlow
 88 - 5MW_OC3Mnpl_Linear
140 - SD_PendulumDamp

The changes are generally moderate except for SD_PendulumDamp. The new results are aligned with expectation.

Note that additional tests on the dev branch will need to be rebaselined when merging rc-5.0.1 into dev after this fix.

  • r-test branch merging required

To-do

  • Review the failing SubDyn r-test SD_PendulumDamp.
  • Run the OpenFAST glue-code r-tests that use SubDyn (fixed-bottom jacket/monopile with SIM, floating cases) and review the differences.
  • Update the r-test baselines.
  • Consider adding an r-test for a floating structure with SIM and acceleration-driven member loads, for example the free fall or constant TP acceleration cases above. [Requires dev. Deferred for now.]

@jjonkman jjonkman left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes make sense to me.

Quick question: you mention that the centripetal terms are ignored; how hard would it be to include these?

@RBergua

RBergua commented Nov 30, 2026

Copy link
Copy Markdown
Contributor

The changes on SIM and member-load output bending moments look good to me.

Regarding the SIM, I'm compiling OpenFAST dev with this PR and checking the results against issue #3085 For reference, this corresponds to the model available in this r-test: https://github.com/OpenFAST/r-test/tree/rc-5.0.1/glue-codes/openfast/OC7_PhaseII_VolturnUS_Strip. The input to reproduce the regular waves is also availble in the HydroData folder: LC41_resampled.Elev

Comment for my own reference in the future...
The beam self-weight moments were computed in the global (earth-fixed) frame but subtracted from Ke·Ue, which is expressed in the body (rigid-body/Guyan) frame. These two frames only give the same result when the moment is aligned with the platform's rotation axis.

This explains why the bug was not detected by the SD_SelfWeight_FloatingSystem r-test (https://github.com/OpenFAST/r-test/tree/rc-5.0.1/modules/subdyn/SD_SelfWeight_FloatingSystem). In that test, the beam rotates only about the global y-axis, and the self-weight moment is also always aligned the y-axis. A rotation about y does not change a vector along y, so the moment has the same components in both frames.

However, if the platform also rotates in roll or yaw, the moment is no longer along the rotation axis, and the global and body components differ.

The new implementation fixes this by computing gravity in the body frame, so the self-weight moment and Ke·Ue are expressed in the same reference frame.

@luwang00

luwang00 commented Dec 1, 2026 •

Copy link
Copy Markdown
Collaborator Author

@jjonkman I'm also inclined to include the centripetal forcing on the elastic modes due to rigid-body/Guyan motion with this PR, but first, I want to make sure the results look reasonable with the fix already implemented before making more changes.

@RBergua Let us know how it goes. Also, please take a look at your OC6 Phase II r-test. I'm seeing some new high-frequency oscillations in the soil force. The Guyan acceleration now directly drives the quasi-static modes, and I believe SubDyn receives the full deflection with SIM included. This might explain the changes.

@RBergua

RBergua commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

@luwang00: I confirm that SoilDyn uses the Y3 mesh that includes the full elastic displacements (Guyan+CB+SIM). See for reference: #3304. I will try to figure out the implications with the updated SIM.

@RBergua

RBergua commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

I have tested the SIM for the OC7 Phase II model (VolturnUS).

Below I show the structural loads in the upstream pontoon during a regular wave condition. I'm using the 3 directions of interest for this pontoon: axial force, vertical force, and vertical bending moment. This was illustrated in detail in #3085

All the results shown below have been generated using OpenFAST dev. Looking at the axial load (the one where we observed the main differences initially), we can observe that without the SIM fix, if we include a relatively low number of Craig-Bampton modes (e.g., Nmodes = 8, solid red line), the output presents a phase lag and amplitude difference compared to all other solutions. We were forced to include a large amount of Craig-Bampton modes (e.g., Nmodes=50) to get something close to the expected behavior (see dotted red line).

Now, with the SIM fix, the outputs with Nmodes = 8 (solid green line) or Nmodes = 50 (black dotted line) are aligned. This indicates that it's not necessary to include a large number of Craig-Bampton modes anymore. This makes physical sense because the 8 Craig-Bampton modes already include a frequency range much larger than the excitation frequency (regular waves with a frequency of 0.074 Hz). So, including those additional modes should not have an impact in the response.

The vertical force outputs confirm the proper behavior when using the proposed SIM fix. Note how previously, to reproduce the expected behavior, we needed a large number of Craig Bampton modes.
image

So, this confirms that this PR fixes issue #3085.

Next, I will look at the challenges of the proposed SIM fix for fixed-bottom systems (i.e., SoilDyn/SubDyn coupling). I will take a look at the OC6 Phase II model for that.

@andrew-platt
andrew-platt marked this pull request as ready for review December 2, 2026 17:27
luwang00 and others added 2 commits December 2, 2026 10:37
…-end moments (OpenFAST#3552)

Static improvement method (SIM):
- The quasi-static correction of the truncated CB modes only used the
  external load F_L and missed the inertial load from the Guyan/rigid-body
  acceleration, M_bar_LG * Udotdot_G with M_bar_LG = (M_LL PhiR + M_LR) TI [G].
  The retained modes already see this load through MMB.
- New parameter SLG = KLL^-1 M_bar_LG - PhiM KMM^-1 MMB, built in
  SetParameters; GetUFulls subtracts SLG * udotdot_TP from UL_SIM.
- Applies to fixed-bottom, single-TP floating, and TP0 + coupled TPs.

Member outputs (ElementForce):
- Beam fixed-end bending moments are recomputed at every call from the
  distributed self-weight and inertial load w = rho*A*(g - a), linear along
  the element, instead of gravity only.
- The load is resolved in the frame of Ke*X_e (rigid-body frame if floating),
  which also fixes the missing Rg2b in the floating self-weight moments.

Verified on a Y-frame for Nmodes = 0/6/20/all: free-fall member loads are ~0,
and quasi-static loads under TP/rigid-body acceleration are independent of
Nmodes with SIM and match the analytical cantilever values.

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
- Static-Improvement Method: rederive the correction from the full modal
  expansion with the effective load F_L - (M_LL PhiR + M_LR) Udotdot_R,
  giving U_L,SIM = (KLL^-1 - PhiM OmegaM^-2 PhiM^T) F_L - S_LG Udotdot_G.
  Describe Udotdot_G and G for fixed-bottom, single-TP floating, and
  TP0 + coupled TPs, and remove the outdated GuyanLoadCorrection remark
  and the broken leftover derivation.
- Nodal loads: the equivalent fixed-end moments now include the inertial
  load, w = rho*A*(g - Rg2b*a), linear along the element, recomputed at
  every time step.

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@andrew-platt
andrew-platt changed the base branch from dev to rc-5.0.1 December 2, 2026 17:41
@RBergua

RBergua commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

One small comment regarding the impacted areas of the software in the description of this PR, at the moment it reads as:
SubDyn with SttcSolve=True: SIM displacements of the internal nodes. These enter the member-load outputs and, for fixed-bottom structures, the y2 motion mesh passed to HydroDyn.
I believe this part is not fully accurate. I understand that the y2 mesh only includes Guyan+CB (https://github.com/luwang00/openfast/blob/2fcbbc9b65b9f5523ee6f44e39d55473dba80cb8/modules/subdyn/src/SubDyn.f90#L901).
It's the y3 mesh the one that adds the SIM for the reaction nodes (SoilDyn use)(https://github.com/luwang00/openfast/blob/2fcbbc9b65b9f5523ee6f44e39d55473dba80cb8/modules/subdyn/src/SubDyn.f90#L911).

@luwang00

luwang00 commented Dec 2, 2026

Copy link
Copy Markdown
Collaborator Author

@RBergua Good catch on the y2 mesh comment. Just corrected above.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The inertial-moment calculation omits rotational-acceleration contributions, producing a spurious free-tip moment; it must use all 12 acceleration DOFs and the theory equations must be updated accordingly.

1 open issue
What changed in this PR

This PR addresses SubDyn’s missing Guyan/rigid-body inertia in static-improvement corrections and member-load moments, targeting mode-dependent loads and nonzero free-fall loads.

Changes:

  • Adds the SLG parameter and acceleration-dependent static correction.
  • Recomputes beam fixed-end moments from gravity and inertia in the appropriate frame.
  • Updates the theory documentation.
File Description
modules/​subdyn/​src/​SubDyn.f90 Computes and applies the inertial static correction.
modules/​subdyn/​src/​SubDyn_Types.f90 Adds SLG storage and lifecycle support.
modules/​subdyn/​src/​SubDyn_Registry.txt Registers the new SLG parameter.
modules/​subdyn/​src/​SubDyn_Output.f90 Revises beam fixed-end moment recovery.
docs/​source/​user/​subdyn/​theory.rst Documents revised static corrections and member loads.

Review effort: Balanced

Comment thread modules/subdyn/src/SubDyn_Output.f90 Resolved
@RBergua

RBergua commented Dec 2, 2026

Copy link
Copy Markdown
Contributor

After discussing the high frequency content in the fixed-bottom systems with @luwang00, it seems that some spikes appear for secondary channels, which have very small values.
image

These outputs come from to the OC6 Phase II model available in the r-test. The load case is gravity-only in still water conditions, so I would expect a smooth, low frequency response. The spikes seem to occur at the same times in the baseline and the fixed SIM, so they probably come from the solver and not from the physics although now they could get slightly amplified.

One of the main outputs, the vertical force at the seabed location, differs slightly during the initial transient.
image

I understand that this is a real effect. The structure moves downwards under its own weight, and the SIM now includes the resulting axial acceleration. Before this PR that contribution was missing, and Nmodes = 5 did not capture it.

Good agreement is observed for the fore-aft bending moment at the seabed:
image

Compute the self-weight and inertial equivalent nodal moments in the
member-load recovery from the rotational rows of the consistent element
mass matrix, Me*(G - a_e), using all 12 nodal acceleration DOFs resolved
in the frame of Ke*X_e. This includes the rotational-acceleration and
rotary-inertia contributions omitted by the previous linear-load
fixed-end moments, so the recovered moments satisfy the nodal
equilibrium of the FE model (e.g., zero moment at a free tip with all
modes or SIM). For gravity alone, Me*G reduces exactly to the ElemG
self-weight vector.

The element mass matrix is now stored with Ke for member outputs
(new MeshAuxDataType%Me). Theory manual equations updated accordingly.

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Floating revolute, universal, and spherical joints can produce incorrect member moments because subsequent rotational triplets remain in the elastic body frame and omit rigid-body angular acceleration.

1 open issue
1 resolved since last review

Review effort: Balanced

Comment thread modules/subdyn/src/SubDyn_Output.f90 Resolved
…ulls

For floating structures, GetUFulls only converted the first rotational
triplet of each node from elastic body-frame motion to absolute global
motion. Revolute, universal, and spherical joints carry one rotational
triplet per connected element, so the remaining triplets kept elastic
body-frame rotations, angular velocities, and angular accelerations
without the rigid-body contributions. These were then rotated again in
the member-load recovery (and the MaNbRA*e outputs), giving incorrect
member moments.

Loop over every rotational triplet of the node, applying the same
rotation composition, rigid-body angular velocity, and angular
acceleration (including the Omega x elastic angular velocity term)
as for the first triplet.

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

Changes to structural motion and recovered loads require independent review of the numerical derivation and regression baselines, with coupled-runtime validation unavailable and the r-test merge still pending.

No open issues 🎉

1 resolved since last review

Review effort: Balanced

@andrew-platt
andrew-platt merged commit bfebb4a into OpenFAST:rc-5.0.1 Dec 3, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai assisted AI written with strong human guidance. Module: SubDyn Type: Bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants