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
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,22 @@ All notable changes to CableXSec are recorded in this file. The format follows

### Added

- Torsional wire stress in the fatigue path. `compute_fatigue` and `compute_conductor_fatigue`
take `twist_rate_per_m`, the material twist rate of the cable [rad/m], positive in the sense
that tightens a right-hand (Z) lay. Every armour wire gains the axial stress of its helix strain
`s r sin(a) cos(a) tau` (Knapp 1981, Eqs. 2 and 11, fixed radii). With a tension history the
tension is held, so the strain also changes by `-K_et tau / K_ee`. Every conductor ring wire
gains the strain of the laid core and of the ring twisting with the cable. The reader forms the
rate from CableDyn's `Twist<L>N<J>` channels: `CableDynSectionHistory.twist_rate_per_m` is the
element rate inside an element and the mean of the two element rates on a deck node, the
definition CableDyn uses for `Torq<L>N<J>`. `twist_stress_coefficient` gives the stress per unit
rate. The sea-state batch applies it with `SeaStateBatchOptions(twist_stress=True)`.
`TorsionalStressWarning` is issued in two cases: CableDyn writes twist or torque at a section
but not the `Twist` channels its rate needs (the warning names them), or a batch omits a
history's twist rate. `section_channels` lists the extra node. Without the input, every result
is unchanged, bit for bit. Verification row TQ-FT; no measured wire strain under torsion is in
the validation set yet.

- `validation/scripts/benchmark_throughput.py`: one-core throughput of sea-state fatigue on
the 66 kV template (direction-tied and distributed models, every wire or 12 positions, 4 or
32 fibres), the damage differences from an earlier build, and the sea-state batch time
Expand Down
1 change: 1 addition & 0 deletions VALIDATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ afterwards: a comparison that misses its target is reported as failed.
| **CF** | Laid-core friction limits | closed forms, rotation equivariance | ≤1.0e-4 | per check | Pass |
| **FR** | Fretting regime: Mindlin energy, Fouvry transition, Cattaneo strip | closed forms, numerical Masing loop | ≤7.8e-12 | <1e-9 to <1e-12 | Pass |
| **TQ** | Torque constant of a strand; coupled section; mirror lay | Feyrer, Example 2.8; Knapp (1981) | −0.11 %; −1.3e-6; 0 | ±0.2 %; <1e-4; <1e-9 | Pass |
| **TQ-FT** | Twist-rate wire stress of the fatigue path: stress and damage, torque and tension carried by the wires, mirror lay, zero twist | Knapp (1981), Eqs. 2, 11; `K_et`, `K_tt` | 4.5e-15; 2.2e-16; 0; 0 | <1e-12; <1e-12; <1e-12; 0 | Pass |
| **A11** | Moment–curvature energy closure | loop area against closed form | 0.082 % | <0.1 % | Pass |
| **σ_B** | Radial-fibre bending stress | Ménard and Cartraud (2023), Eq. 14 | 0 | <1e-6 % | Pass |
| **M-rec, M-rec-3core** | Assembled per-wire moment against the section engine | cross-engine | 0.000 % | <2 % | Pass |
Expand Down
14 changes: 13 additions & 1 deletion doc/benchmarks.md
Original file line number Diff line number Diff line change
Expand Up @@ -2584,7 +2584,7 @@ and 0.092 against 0.035/0.044 and 0.054/0.063.
over-prediction comes from what the one-way anchored chain does with it
(SV11-SPLIT), not from the profile.

## Torque balance and twist under tension (gap 3.5: TQ, TQ-KL, TQ-UJ)
## Torque balance and twist under tension (gap 3.5: TQ, TQ-KL, TQ-UJ, TQ-FT)

Script `validation/scripts/check_torque_balance.py`, tests `tests/test_torque_balance.py`, rows TQ,
TQ-KL and TQ-UJ of the scorecard. `torque_balance` solves the coupled radial
Expand All @@ -2604,6 +2604,18 @@ moments (Costello 1997, Example 3.1: −5% torque for a seven-wire strand).
| TQ5 | A | Mirror lay: every lay direction reversed (armour and laid cores) on the 1×37 rope and the 66 kV template | < 1e-9 relative | torque and twist reverse, wire stresses and balance ratio unchanged (0 and below 1e-9) | PASS |
| TQ6 | I | `fixed_radius` against `xsec_stiffness` (`EA_N`, `EA_torsion_coupling`, `GJ_Nm2`); solved 66 kV template against the fixed-radius torque coefficient | identical; < 1% | identical; 1.5026 against 1.5251 mm (−1.5%); EA 607 against 638 MN | FAIL (since the insulation screens carry load in both models; −0.5% when the fixed-radius model left them out) |
| TQ7 | I | Design round trip on the 66 kV template: zero torque coefficient at the returned lay angle; free twist and stress redistribution then vanish | < 1e-9 m; < 1e-12; < 1e-3 Pa | 1.3e-13 m; below 1e-12; below 1e-3 Pa | PASS |
| TQ8 (TQ-FT) | A, I | Twist-rate wire stress of the fatigue path, `eps cos^2(a) + s R tau sin(a) cos(a)` (Knapp 1981, Eq. 11 with a radially rigid core, the twist strain of Eq. 2), tension held, `eps = (T - K_et tau)/K_ee`: (a) 66 kV template armour, 60 kN and a twist history without bending, recovered stress and per-wire damage against the closed form from the schema data; (b) Feyrer 1×37 rope, whose helical layers alone carry `K_et` and `K_tt`: torque `sum s n A sigma R sin(a)` and tension of the fatigue wire stresses at (10 kN, 2e-3 rad/m) against `K_et eps + K_tt tau` and `T`; (c) every lay reversed and the twist negated, with biaxial bending; (d) zero twist against no twist input, armour fibres and conductor azimuths | < 1e-12; < 1e-12; < 1e-12; 0 | (a) 3.6e-16 and 4.5e-15; (b) 2.2e-16 and 0; (c) 0; (d) 0 | PASS |

TQ8 was registered before the implementation was run. It checks the
arithmetic and the consistency with the stiffness matrix, not a measurement:
no TQ row measures wire strain under torsion. Utting and Jones (1987, Part II,
Figs 5 and 6) give mean helical-wire surface strains against the torsional end
restraint, in figures only and including the wire bending, which the fatigue
term leaves out. They are a candidate row for later. Against the solved radial
section of the 66 kV template (`solve_cable_radial_state`, 1e-3 rad/m
prescribed at 0 and 50 kN, tension held), the fixed-radius twist stress is
within 6 % on the inner armour (−3.88 against −3.66 and −3.89 MPa) and within
1 % on the outer armour (+2.62 against +2.64 and +2.61 MPa).

The excess over the Machida–Durelli theory is the omitted bending and
twisting moments of the wires, which scale with `(d / 2r)²` (0.23 for these
Expand Down
78 changes: 74 additions & 4 deletions doc/global_local_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,9 @@ torsion); where a later release changed a channel, the item says so.
returns, per section at unstretched arc length `s` from End A:
`time_s`, `effective_tension_N`, `rotation_curvature_x_1_m`,
`rotation_curvature_y_1_m`, `curvature_norm_1_m`, `elevation_m`,
`external_pressure_Pa`, `torque_Nm`, `twist_rad`, the labels of the frame,
curvature source and tension source, and a provenance record. The read also
`external_pressure_Pa`, `torque_Nm`, `twist_rad`, `twist_rate_per_m`
(Section 2.2), the labels of the frame, curvature source and tension source,
and a provenance record. The read also
returns the digests of every file read and the consistency checks.

**Curvature vector.** `curvature_source="tangent"` splines the tangents of
Expand Down Expand Up @@ -296,8 +297,9 @@ nodes cannot be placed: the positions are read at the deck nodes,
channels the tangent source needs for the section frame: `Dec`/`Azi` on the
window, `Ten`, `Curv` and `p{x,y,z}` at the bracketing nodes, and
`Twist`/`Torq` on a line CableDyn solves in torsion (`torsion_solved`;
CableDyn refuses them on any other line). The arc frame also needs the
line's `p` flag. Adding `t` gives the element tensions.
CableDyn refuses them on any other line), with `Twist` also at the node before
a section that lies on a deck node (its twist rate, Section 2.2). The arc frame
also needs the line's `p` flag. Adding `t` gives the element tensions.

### 2.1 CableDyn 0.4.0 signed curvature components

Expand Down Expand Up @@ -341,6 +343,68 @@ recorded where written). A station given by a rounded arc length a few
micrometres off its node needs the next node's channels too; the error names
the node and its arc length.

### 2.2 Twist rate and the torsional wire stress

A twist of the cable stresses its helical wires, not only the frame. With plane
sections and fixed layer radii a wire of lay angle `a`, helix radius `R` and lay
sign `s` (+1 right hand, Z; −1 left hand, S) strains by

```text
eps_w = eps cos^2(a) + s R tau sin(a) cos(a)
```

under the cable strain `eps` and the twist rate `tau` (Knapp 1981, Eq. 11 with a
radially rigid core and the twist strain of its Eq. 2). `compute_fatigue(...,
twist_rate_per_m=tau)` adds this stress to every armour wire, the same for every
wire of a layer: the bending slip and the friction stress are unchanged, on
every friction model. With `tension_N` the tension is held, so the strain also
changes by `−K_et tau / K_ee` with the fixed-radius coupling `K_et` and
`EA_fixed = K_ee` of `compute_stiffness`. This is the section law `T = EA eps +
K tau`, `M = GJ tau + K eps` that CableDyn solves with `GJ|K`, so a deck
whose `EA`, `GJ` and `K` are the section's `K_ee`, `K_tt` and `K_et` gives
CableXSec the strain CableDyn has. `compute_conductor_fatigue(...,
twist_rate_per_m=tau)` adds the twist strain of the laid core, `(r_c tan(b) −
K_et/K_ee) tau`, to the conductor axis, and the twist of the ring wires about it.

**Input: the twist rate, not the torque.** The reader forms
`twist_rate_per_m` from `Twist<L>N<J>` alone. CableDyn's element twist is
`Twist_{k+1} − Twist_k = M L_0/GJ − (K/GJ)(l − L_0)`, the material twist of
the element, so `(Twist_{k+1} − Twist_k)/L_0` is its kinematic twist rate per
unstretched length. A section inside an element takes that element's rate, from
the two `Twist` channels the frame needs already. A section on a deck node takes
the mean of its two elements' rates, the definition CableDyn uses for
`Torq<L>N<J>`, and needs `Twist` at the node and at both neighbours (one
element at a line end). The torque is not converted:

- it includes the Kelvin–Voigt torsional damping (`GJ|K|Bt`);
- under a bend stiffener it is the section torque, not the cable's share;
- its conversion would need a torsional law, while the twist rate is the global
model's own kinematics, like the curvature.

`Torq` is a consistency check instead: `Torq = GJ tau + K eps` with `eps =
(Ten − K tau)/EA`, to the print precision of the `Twist` channels.

**Signs.** CableDyn's `Twist` is right-handed about the End A → End B
tangent, so `tau > 0` tightens a right-hand lay: CableXSec's sign (Section 12
of the local analysis guide), with no flip. A right-hand (Z) armour layer takes
tension and a left-hand (S) layer compression under a positive twist rate.

**Deck outputs for the torsional stress.** At every station on deck node `J`
write `Twist<L>N<J−1>`, `Twist<L>N<J>` and `Twist<L>N<J+1>` (the end node and
its neighbour at a line end), and `Torq<L>N<J>` for the check. Where CableDyn
writes twist or torque at a section but not these channels, the reader warns
(`TorsionalStressWarning`, naming them) and `twist_rate_per_m` is `None`.
`checks["twist_rate"]` records the elements used for each section.

**Limits.** The term is the linear fixed-radius helix strain. It leaves out
the radial contraction of the layers (on the 66 kV template the solved radial
section gives the same twist stress within 6 %), the opening of a contact
under a twist that unloads a layer, the twist's change of the interlayer
contact pressure (the friction caps follow the tension), and the bending and
twisting of the individual wires. No measured wire strain under torsion is in
the validation set; row TQ-FT verifies the arithmetic and the consistency with
`K_et` and `K_tt` ([benchmarks.md](benchmarks.md)).

## 3. Sea-state batch

```python
Expand Down Expand Up @@ -410,6 +474,11 @@ result.sections["sag"].long_term.annual_damage, result.sections["sag"].life_year
the wider tolerance; a 10-column row gives no `GJ` and is not compared. A
mismatch stops the batch unless `allow_property_mismatch=True` is
declared, and the comparison is written to the manifest either way.
- Torsional wire stress: `twist_stress=True` passes each section's
`twist_rate_per_m` (Section 2.2) to `compute_fatigue`; on a line CableDyn
solves in torsion a section without it is refused. With the default `False`
a section whose history has a twist rate warns (`TorsionalStressWarning`)
that the stress is omitted, and the result is that of earlier releases.
- Workers: `workers` processes, one numerical thread each, spawned, at most
one per run; there is no upper limit, so choose the count for the machine
(the runs are independent and the batch scales with the worker count while
Expand Down Expand Up @@ -458,6 +527,7 @@ Paths are relative to the JSON file; unknown keys are rejected.
| Rigid heading rotation of the configuration | components unchanged (1e-9) |
| Bending plane turning about the hang-off tangent by `φ(t)` (arc frame) | `κ(−sin φ, cos φ)` within 5e-6 1/m |
| Material twist of a restrained line | axes turned by the `Twist` channel; components `κ(sin φ, cos φ)` |
| Twist rate from `Twist` channels of two element rates (1e-3 and 3e-3 rad/m) | inside each element its rate, on the node their mean (1e-12); missing neighbour channels named |
| Tangent placement on a non-uniform mesh (0.2 m then 0.3 m elements): node tangents of a finite-EI line; chords of an `EI = 0` line and, with `tangent_placement="chord"`, of a finite-EI line | curvature within 1e-4 of `κ` at End A, the mesh junction and End B; node tangents read as chords give more than 1.5 `κ` at End A |
| Tension between element mid-arcs, hydrostatic pressure, `T_e − p_o A_o` | exact for a linear field; elevation within 1e-7 m |
| Round trip through the time-history CSV path: section history written as a CSV export (`x curvature`, `y curvature`, `Wall tension`) and read with `read_time_history_csv` | identical `LoadCaseSeries` (1e-12) and identical fixed-fibre damage |
Expand Down
5 changes: 4 additions & 1 deletion doc/user_guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,10 @@ for screening.
`cx.fatigue_from_series`): the damage of every armour wire at fixed fibres
round the wire, and of the conductors and metallic sheaths with fatigue data
(`cx.compute_conductor_fatigue`, `cx.compute_shell_fatigue`), with the
{term}`critical wire and fibre`.
{term}`critical wire and fibre`. A twist-rate history (`twist_rate_per_m`,
rad/m, positive tightening a right-hand lay) adds the torsional stress of
the armour and conductor wires; a CableDyn section history carries it as
`twist_rate_per_m` ([global–local guide](global_local_guide.md), Section 2.2).
- **{term}`Long-term fatigue <long-term fatigue>`** (`cx.compute_long_term_fatigue`): the damage over a
{term}`scatter diagram`, one `FatigueLoadCase` per {term}`sea state` with its probability.
- **Armour fretting**, **core screen fatigue** and **tape fatigue** of a load
Expand Down
2 changes: 2 additions & 0 deletions src/cablexsec/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,7 @@
DirectionTiedFrictionWarning,
FrictionModelFallbackWarning,
MissingClampingStateWarning,
TorsionalStressWarning,
UnmodelledPolymerSofteningWarning,
)

Expand Down Expand Up @@ -589,6 +590,7 @@
"UnevaluatedFatigueCurveWarning",
"UnvalidatedModelWarning",
"MissingClampingStateWarning",
"TorsionalStressWarning",
"UnmodelledPolymerSofteningWarning",
"CableXSecError",
"CableInputError",
Expand Down
70 changes: 70 additions & 0 deletions src/cablexsec/analysis/conductor_fatigue.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@

from __future__ import annotations

import dataclasses
import math
import warnings
from collections.abc import Sequence
Expand Down Expand Up @@ -138,6 +139,7 @@
ConductorRing,
PressureTransmission,
StrandSlipParameters,
StrandSlipResult,
conductor_axial_stiffness,
conductor_ring_parameters,
interface_line_loads,
Expand All @@ -152,6 +154,7 @@
"ConductorFatigueResult",
"TrellisContact",
"assess_conductor_fatigue",
"ring_twist_strain_per_rate",
"trellis_contact",
"trellis_force_ratio",
]
Expand Down Expand Up @@ -557,6 +560,38 @@ def _trellis_critical_distance(
return best, best_e, best_x


def ring_twist_strain_per_rate(
ring: ConductorRing, axis_strain_per_twist_m: float
) -> float:
"""Axial wire strain of a ring per unit twist rate [m] ([Knapp1981] Eq. 11).

``cos^2(a) e_tau + s r sin(a) cos(a)``: the conductor axis strain
``e_tau tau`` resolved along the wire and the helix strain of the ring
twisting with the conductor (fixed radii, radially rigid support).
"""
a = ring.lay_angle_rad
c = math.cos(a)
return (
c * c * axis_strain_per_twist_m
+ ring.lay_sign * ring.r_helix_m * math.sin(a) * c
)


def _with_twist_strain(
ring: ConductorRing,
result: StrandSlipResult,
twist: FloatArray,
axis_strain_per_twist_m: float,
) -> StrandSlipResult:
"""Add the uniform twist strain of a ring to its axial and total strain."""
strain = ring_twist_strain_per_rate(ring, axis_strain_per_twist_m) * twist
return dataclasses.replace(
result,
axial_strain=result.axial_strain + strain[None, :],
strain=result.strain + strain[None, :],
)


def assess_conductor_fatigue(
rings: Sequence[ConductorRing],
E_Pa: float,
Expand Down Expand Up @@ -584,6 +619,8 @@ def assess_conductor_fatigue(
mean_stress: MeanStressSpec | None = None,
scf: ComponentSCF | None = None,
critical_distance: CriticalDistanceSpec | None = None,
twist_rate_per_m: ArrayLike | None = None,
axis_strain_per_twist_m: float | None = None,
) -> ConductorFatigueResult:
"""Bulk and trellis-fretting damage of every ring of a stranded conductor.

Expand Down Expand Up @@ -648,6 +685,19 @@ def assess_conductor_fatigue(
mean-stress correction against ``sn_bulk``. The ring damage is then
the larger of the bulk and the trellis value (the trellis value
already contains the bulk stress). Exclusive with ``swt_const``.
twist_rate_per_m : array_like or None, optional
Twist rate of the conductor [rad/m], positive in the sense that
tightens a right-hand lay; it adds the uniform axial strain
``cos^2(a) e_tau tau + s r sin(a) cos(a) tau`` to every wire of a
ring ([Knapp1981] Eqs. 2 and 11, fixed radii), with ``e_tau =
axis_strain_per_twist_m`` the strain of the conductor axis per unit
twist rate (required with the twist rate). It does not change the
ring contact. ``None`` (default) leaves the result unchanged, bit for
bit.
axis_strain_per_twist_m : float or None, optional
Axial strain of the conductor axis per unit twist rate [m]: for a
laid core of a cable, ``r_c tan(b) - K_et/K_ee`` with the tension held
(:func:`cablexsec.compute_conductor_fatigue`).

Returns
-------
Expand All @@ -667,6 +717,23 @@ def assess_conductor_fatigue(
if reference_tension_N is None:
peak = 0.0 if tension is None else float(np.max(np.abs(tension)))
reference_tension_N = peak if peak > 0 else 1.0
twist = None
if twist_rate_per_m is not None:
twist = np.asarray(twist_rate_per_m, dtype=np.float64)
if twist.shape != kx.shape or not np.isfinite(twist).all():
raise CableInputError(
"twist_rate_per_m must be finite and match the curvature histories"
)
if axis_strain_per_twist_m is None or not math.isfinite(
axis_strain_per_twist_m
):
raise CableInputError(
"twist_rate_per_m requires a finite axis_strain_per_twist_m"
)
elif axis_strain_per_twist_m is not None:
raise CableInputError(
"axis_strain_per_twist_m is used only with twist_rate_per_m"
)
if swt_const is not None:
warnings.warn(
"conductor trellis fretting (per-slip-cycle SWT) is not validated: "
Expand Down Expand Up @@ -724,6 +791,9 @@ def assess_conductor_fatigue(
cd_face = np.full(n_rings, np.nan)
for i, (ring, params) in enumerate(zip(rings, parameters, strict=True)):
result = strand_slip_strain(params, kx, ky, tension, theta_rad=theta)
if twist is not None:
assert axis_strain_per_twist_m is not None # checked above
result = _with_twist_strain(ring, result, twist, axis_strain_per_twist_m)
# Compaction indentations raise the stress of the whole wire section
# (axial and bending parts alike) by the ring's factor (gap CF3).
compaction = ring.compaction_scf
Expand Down
Loading
Loading