Skip to content

feat(capi): step decks in moving water in-process - #88

Merged
SMI-Lab-Inha merged 6 commits into
devfrom
feat/capi-host-fluid
Nov 7, 2026
Merged

SMI-Lab-Inha merged 6 commits into
devfrom
feat/capi-host-fluid

Conversation

@SMI-Lab-Inha

Copy link
Copy Markdown
Owner

Summary

On a deck with finite-EI lines, bodies or rods, the C API and Python ran in still water only: a deck current was refused and no call reached the line nodes. This adds moving water to in-process stepping (ABI 1.4).

  • Deck current: a steady current, WaterKin CurrentMod 1 table or MoorDyn-C Currents 1 profile is marched in-process, in the static start and in every step, also from host start positions.
  • Host field: CableDyn_SetHostFluid before the initialization, then CableDyn_NFluidNodes, CableDyn_GetFluidNodePositions and CableDyn_UpdateFluidFields (Python set_host_fluid, n_fluid_nodes, fluid_node_positions, update_fluid_fields). A steady deck current then sets the static start only, and the host's field is the whole water of the march.
  • Convention: that of the standalone march and OpenFAST: sampled at t + dt at the step-start nodes and held over the step. The first field, at t = 0, sets the start acceleration, on EI = 0 lines too. A step without a field is refused.
  • SaveState/RestoreState carry the field. examples/python/step_in_moving_water.py is a complete loop.

OpenFAST and the standalone driver are unchanged: the new aggregate arguments are optional and they pass none of them.

Checks

Stepped in current and regular waves against the standalone driver on the same motion:

Case NRMSE
Finite-EI, deck current 1.9e-7
Finite-EI, host field, 61 and 301 nodes 1.7e-7
EI = 0, host field 2.2e-7
Stiffener, as-laid friction, host field below the 1e-5 gate

These are at the digits of the driver's output. A step at 301 nodes takes 3.5 ms including CalcOutput, plus 0.3 ms for the host's field.

  • CTest 359 of 359 on the default kernel and with OPENBLAS_CORETYPE=Prescott; pytest passes; no new compiler warnings.
  • A restore after a different field steps bit-identically, on a plain deck and with a stiffener and as-laid friction.

On a deck with finite-EI lines, bodies or rods the C API and Python ran in
still water only: a deck current was refused, and no call reached the line
nodes.

- A steady deck current (current, WaterKin CurrentMod 1, MoorDyn-C
  Currents 1) is marched in-process, in the static start and in every
  step, also from host start positions.
- A host can supply the ambient fluid at every node instead (ABI 1.4):
  CableDyn_SetHostFluid before the initialization, then
  CableDyn_NFluidNodes, CableDyn_GetFluidNodePositions and
  CableDyn_UpdateFluidFields; in Python set_host_fluid, n_fluid_nodes,
  fluid_node_positions and update_fluid_fields. A steady deck current
  then sets the static start only, as a host's current does in OpenFAST.
- The field follows the standalone march and OpenFAST: sampled at t + dt
  at the step-start nodes and held over the step. The first field, at
  t = 0, sets the start acceleration, on EI = 0 lines too, and a step
  without a field is refused.

Stepped in current and regular waves, a cable matches the standalone
driver to the digits of its output (NRMSE 2e-7), with a stiffener and
as-laid seabed friction too; SaveState and RestoreState carry the field.

Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
@SMI-Lab-Inha

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 7, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-07T12:42:16.733610Z 8b30aa2 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@read-the-docs-community

read-the-docs-community Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Documentation build overview

📚 CableDyn | 🛠️ Build #35718740 | 📁 Comparing 8b30aa2 against latest (3d04008)

  🔍 Preview build  

8 files changed · ± 8 modified

± Modified

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: e801cc33af

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
@SMI-Lab-Inha

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b733ee3ce9

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

Comment thread src/CableDyn_CAPI.f90 Resolved
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
@SMI-Lab-Inha

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Chef's kiss.

Reviewed commit: 8b30aa2bcf

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

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".

@SMI-Lab-Inha
SMI-Lab-Inha merged commit b11904f into dev Nov 7, 2026
21 checks passed
@SMI-Lab-Inha
SMI-Lab-Inha deleted the feat/capi-host-fluid branch November 7, 2026 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant