Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@ All notable changes to CableDyn are recorded in this file. The format follows
and the restore, and the SeaState sampling into the node queries, the grid checks and the
hand-over of the fields. Results do not change.

### Changed

- OpenFAST: `CalcOutput` no longer evaluates the reactions of the finite-EI cables when it saves
the committed kinematics before transferring the current ones; it discarded them. With a
248-element power cable in the IEA-15 VolturnUS-S mooring this cuts `CalcOutput` from 41 s to
25 s and the 600 s run from 227 s to 212 s. Results do not change.

## [0.2.0] - 2026-10-20

### Added
Expand Down
11 changes: 10 additions & 1 deletion src/CableDyn_OpenFAST_Aggregate.f90
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ SUBROUTINE CD_AGG_TurbineOfMoving(self, turbine_of, ErrStat, ErrMsg)
END SUBROUTINE CD_AGG_TurbineOfMoving

SUBROUTINE CD_AGG_GetMovingPointMesh(self, position, velocity, acceleration, load, ErrStat, ErrMsg, &
orientation, moment, angular_velocity, angular_acceleration)
orientation, moment, angular_velocity, angular_acceleration, cable_loads)
!! Copy the moving-point state and loads out. System columns come from
!! CD_FMF_GetMovingPointMesh; each cable column carries its coupled-node
!! position/velocity/acceleration (committed state) and its fairlead reaction from
Expand All @@ -581,11 +581,19 @@ SUBROUTINE CD_AGG_GetMovingPointMesh(self, position, velocity, acceleration, loa
CHARACTER(*), INTENT(OUT) :: ErrMsg
REAL(wp), INTENT(OUT), OPTIONAL :: orientation(:, :, :), moment(:, :)
REAL(wp), INTENT(OUT), OPTIONAL :: angular_velocity(:, :), angular_acceleration(:, :)
! .FALSE. skips the reactions of the finite-EI cables (one full residual assembly each) and
! returns their load and moment columns as zero: for a caller that wants only the
! kinematics, such as the OpenFAST CalcOutput saving the committed kinematics. The
! reactions write only the cable's scratch, so the other outputs are unchanged.
LOGICAL, INTENT(IN), OPTIONAL :: cable_loads

INTEGER :: c, col, es
REAL(wp) :: y_fair(3)
LOGICAL :: want_cable_loads
CHARACTER(1024) :: em

want_cable_loads = .TRUE.
IF (PRESENT(cable_loads)) want_cable_loads = cable_loads
position = CD_ZERO
velocity = CD_ZERO
acceleration = CD_ZERO
Expand Down Expand Up @@ -664,6 +672,7 @@ SUBROUTINE CD_AGG_GetMovingPointMesh(self, position, velocity, acceleration, loa
CALL map_hfmf_status(es, em, ErrStat, ErrMsg)
RETURN
END IF
IF (.NOT. want_cable_loads) CYCLE
IF (PRESENT(moment)) THEN
CALL CD_HFMF_CalcOutput(self%cables(c), y_fair, es, em, moment(:, col))
ELSE
Expand Down
7 changes: 5 additions & 2 deletions src/openfast/CableDyn_OF.f90
Original file line number Diff line number Diff line change
Expand Up @@ -2224,10 +2224,13 @@ SUBROUTINE CD_CalcOutput( t, u, p, x, xd, z, other, y, m, ErrStat, ErrMsg )
! evaluations, probes), and committing those boundary kinematics would move the
! module's committed state. Save the committed coupled kinematics, transfer,
! evaluate, restore: the direct-feedthrough loads keep their semantics and the
! committed state is untouched on exit.
! committed state is untouched on exit. The save needs only the kinematics: the
! cable reactions (a full cable assembly each) are skipped, and ws_fld is overwritten
! by the loads evaluated below.
CALL CD_AGG_GetMovingPointMesh( Inst(id)%agg, Inst(id)%sv_pos, Inst(id)%sv_vel, Inst(id)%sv_acc, &
Inst(id)%ws_fld, es, em, orientation=Inst(id)%sv_orient, &
angular_velocity=Inst(id)%sv_omega, angular_acceleration=Inst(id)%sv_alpha )
angular_velocity=Inst(id)%sv_omega, angular_acceleration=Inst(id)%sv_alpha, &
cable_loads=.FALSE. )
IF (es /= CD_AGG_OK) THEN
CALL SetErrStat( ErrID_Fatal, 'CableDyn mooring module: '//TRIM(em), ErrStat, ErrMsg, RoutineName ); RETURN
END IF
Expand Down
10 changes: 10 additions & 0 deletions tests/test_openfast_aggregate.f90
Original file line number Diff line number Diff line change
Expand Up @@ -1222,6 +1222,16 @@ SUBROUTINE case_cable_no_advance_transfer()
CALL require(NORM2(l1(:, 1) - l0m(:, 1)) < 1.0e-6_wp, 'transfer:mooring-load-unchanged')
WRITE (*, '(A,ES12.4,A,ES12.4)') 'no-advance transfer: cable |dLoad| = ', &
NORM2(l1(:, ccol) - l0m(:, ccol)), ' N; mooring |dLoad| = ', NORM2(l1(:, 1) - l0m(:, 1))
! A kinematics-only read (cable_loads = .FALSE., the OpenFAST CalcOutput save) returns the
! same kinematics and mooring load bit for bit, zero cable load, and leaves the cable's next
! reaction unchanged.
CALL CD_AGG_GetMovingPointMesh(agg, pos, vel, acc, l0m, es, em, cable_loads=.FALSE.)
CALL require(es == CD_AGG_OK, 'transfer:mesh-kinematics-only: '//TRIM(em))
CALL require(ALL(pos == p1) .AND. ALL(vel == v1) .AND. ALL(acc == a1), 'transfer:kinematics-only-same-kinematics')
CALL require(ALL(l0m(:, 1) == l1(:, 1)), 'transfer:kinematics-only-mooring-load')
CALL require(ALL(l0m(:, ccol) == 0.0_wp), 'transfer:kinematics-only-cable-load-zero')
CALL CD_AGG_GetMovingPointMesh(agg, pos, vel, acc, l0m, es, em)
CALL require(es == CD_AGG_OK .AND. ALL(l0m == l1), 'transfer:kinematics-only-leaves-reaction')
CALL CD_AGG_End(agg, es, em)
END SUBROUTINE case_cable_no_advance_transfer

Expand Down
Loading