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
15 changes: 15 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,21 @@ All notable changes to CableXSec are recorded in this file. The format follows
component limit of the envelope (the `yielding` mode of the conductor layer), separate from
conductor fracture. The 66 kV template page no longer says the envelope lacks it (it governs
the template's capacity, Section 4.6).
- The interstitial filler of a trefoil bundle twists as separate lobes with their own warping,
not about the cable axis. The solved section added the filler's polar moment about the cable
axis to the twist rigidity, as if the filler were bonded to the ring with no warping, although
it touches the cores and the ring through frictionless contacts that carry no axial shear and
the three outer interstices are disjoint. `saint_venant_rigidity` (in
`cablexsec.mechanics.trefoil_section`) solves the warping of the filler lobes on the section
mesh; cores (about their centres) and bonded ring layers (about the cable axis) are unchanged.
The filler term falls from 7.9 to 0.32 kN m² on the Chae, Nam and Shim (2023) cable, whose free
torsional stiffness at the source's twist of 0.125 rad/m (unwinding) falls from 89.5 to
81.9 kN m² at an armour pitch of 1.8 m and from 58.1 to 50.5 kN m² at 3.0 m; and from 3.6 to
0.14 kN m² on the Su et al. (2026) 35 kV cable, whose torsional stiffness with the ends fixed
axially becomes 199.5 / 177.0 kN m² (clockwise / anticlockwise; FE 209.5 / 201.2, test
209.8 / 201.3; previously 203.0 / 180.5). The band of that anticlockwise check is widened
from 12 to 13 % and stated. New validation row TQ-SV checks the warping solver against the
series solution of a rectangle and the polar moment of a mirrored annulus sector.
- `export_bending_law` keeps the stick stiffness at every tension. Its geometric curvature grid
started at `1e-4 κ_max` whatever the tension, so a slip onset below that floor (66 kV template,
`κ_max` 0.4 1/m: outer armour 7.3e-6 1/m and inner 2.3e-5 1/m at 10 kN) was inside the first
Expand Down
8 changes: 4 additions & 4 deletions doc/howto.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ share of 200 kN, twist held (solved route)
share of 200 kN, twist free (solved route)
cu_conductor 0.301
mdpe_filler 0.006
inner_armour 0.357
outer_armour 0.322
inner_armour 0.359
outer_armour 0.320
sum of all layers 1.000
```

Expand Down Expand Up @@ -185,11 +185,11 @@ cable coiled into a static tank with one twist per turn.

<!-- howto-output: howto_05_coiling.py -->
```text
D = 14.4 m: kappa = twist = 0.1389 1/m, torque 12.43 kN m
D = 14.4 m: kappa = twist = 0.1389 1/m, torque 11.37 kN m
armour wire centre -223.6 to -188.3 MPa, surface -280.5 to -132.7 MPa
bird-caging capacity 231.7 MPa, buckling 0.965, yield 0.701
governing: armour (radial), utilisation 0.965, elastic True
D = 8.0 m: kappa = twist = 0.2500 1/m, torque 22.37 kN m
D = 8.0 m: kappa = twist = 0.2500 1/m, torque 20.47 kN m
armour wire centre -402.6 to -338.9 MPa, surface -505.0 to -238.9 MPa
bird-caging capacity 231.7 MPa, buckling 1.737, yield 1.262
governing: armour (radial), utilisation 1.737, elastic False
Expand Down
3 changes: 2 additions & 1 deletion doc/radial_model.md
Original file line number Diff line number Diff line change
Expand Up @@ -206,6 +206,7 @@ The section state minimises the small-strain elastic energy per axial metre with
- `filler="solid"`: meshed in the outer interstices with unilateral contact.
- `"void"`: flooded or loose yarn.
- `"auto"`: as declared. The central interstice is void.
- Saint-Venant twist rigidity: the bonded ring layers twist about the cable axis and each core about its own centre (both exact for annuli). The filler lobes touch cores and ring through frictionless contacts that carry no axial shear, so they twist as separate bodies with their own warping (`saint_venant_rigidity`, validation row TQ-SV), not with their polar moment about the cable axis. The filler then adds 0.32 kN m² to the Chae, Nam and Shim (2023) cable instead of 7.9 kN m², and 0.14 kN m² instead of 3.6 kN m² to the Su et al. (2026) 35 kV cable.
- Stranded conductors whose metal area differs from the envelope, nested strands and corrugated shells are rejected, as in A3. The 220 kV template and CIGRE TB 880 are therefore unsupported.

### 3.5 Limits
Expand Down Expand Up @@ -248,7 +249,7 @@ The section state minimises the small-strain elastic energy per axial metre with
| Knapp (1979) coupling | k12 / k21 (non-symmetric) | Lies between k12 and k21 | — |
| Su et al. (2026) 35 kV, EA tension (twist fixed, 500 kN secant) | FE 615.4 MN; test 631.7 MN | 608.7 MN | −1.1 % FE; −3.6 % test (no-interaction bound about +30 %) |
| Su et al. (2026) 35 kV, EA compression | FE 329.7 MN | 298.4 MN | −9.5 % |
| Su et al. (2026) 35 kV, GJ (axial strain fixed) | FE 209.5 / 201.2 kN m² | 203.0 / 180.5 | −3.1 % / −10.3 % |
| Su et al. (2026) 35 kV, GJ (axial strain fixed) | FE 209.5 / 201.2 kN m²; test 209.8 / 201.3 kN m² | 199.5 / 177.0 | −4.8 % / −12.0 % FE (the filler bonded to the ring without warping gave 203.0 / 180.5) |
| Su et al. (2026) 35 kV, interfaces at 100 kN | Source analytical model, Table 10 (kPa): 432.8, 283.9, 173.3, 176.4, 74.5; separation at armour 4 | 365.0, 255.6, 158.7, 161.9, 76.7; same separation | −16 % to +3 % |
| Ménard and Cartraud (2023), P = 0.3 MPa | 46 kN/m inner sheath | 26.6 (void interstices) to 72.0 (fully filled) kN/m | Bracket only |

Expand Down
139 changes: 131 additions & 8 deletions src/cablexsec/mechanics/trefoil_section.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,15 @@
(for a hollow core, the mean of the two bore points on the mirror axis).
The cross-section plane of the core is taken as the cable cross-section
(an error of order 1 - cos beta). Layers inside a core are bonded. Ring and
filler share the cable extension. Twist rigidities of the ring and filler
assume no interface slip; each core adds its own St Venant rigidity with
twist cos²beta tau. No ovalisation of the ring from non-uniform outer
pressure is modelled: layers outside the ring are coupled through the mean
radial displacement of its outer surface and apply uniform pressure.
filler share the cable extension. The Saint-Venant twist rigidity follows
the contact model: the bonded ring layers twist about the cable axis; each
core adds its own rigidity about its centre with twist cos²beta tau; the
filler, which touches cores and ring through frictionless contacts that
carry no axial shear, twists as separate lobes with their own warping
(:func:`saint_venant_rigidity`), not about the cable axis. No ovalisation
of the ring from non-uniform outer pressure is modelled: layers outside the
ring are coupled through the mean radial displacement of its outer surface
and apply uniform pressure.

A small grounded stabilising stiffness is added to every in-plane degree of
freedom so that a core or filler that is separated from all its neighbours
Expand All @@ -43,6 +47,8 @@
import numpy as np
import scipy.sparse as sp
from numpy.typing import NDArray
from scipy.sparse.csgraph import connected_components
from scipy.sparse.linalg import spsolve

from cablexsec.exceptions import CableInputError
from cablexsec.mechanics.concentric_section import ElasticAnnulus
Expand All @@ -52,6 +58,7 @@
"TrefoilBundle",
"TrefoilModel",
"build_trefoil_model",
"saint_venant_rigidity",
]

FloatArray = NDArray[np.float64]
Expand Down Expand Up @@ -534,8 +541,27 @@ def filler_node(j: int, t: int) -> int:
2 + 2 * nodes.keys[("core", 0, 2 * n_phi)],
)

# Filler nodes of the 60 degree mirror boundary, by mesh key: they lie
# off the exact line when the cores do not touch (rc sin 60 > a).
mirror_filler = np.array(
[
index
for key, index in nodes.keys.items()
if key[0] == "filler" and key[1] == 2 * n_theta
],
dtype=np.int64,
)
stiffness, load, twist_rigidity = _assemble(
xy, conn, props, axial_map, centre_dofs, n_dof, groups, rc, cb
xy,
conn,
props,
axial_map,
centre_dofs,
n_dof,
groups,
rc,
cb,
mirror_filler,
)
# Grounded stabilisation of in-plane freedoms.
e_min = float(np.min(props[:, 0]))
Expand Down Expand Up @@ -741,6 +767,84 @@ def _mirror_transform(
return sp.csr_matrix((vals, (rows, cols)), shape=(n_dof, column))


def saint_venant_rigidity(
xy: FloatArray,
conn: NDArray[np.int64],
shear_modulus: FloatArray,
*,
mirror_angles: tuple[float, ...] = (0.0, SECTOR),
mirror_nodes: NDArray[np.int64] | None = None,
) -> float:
"""Saint-Venant torsional rigidity [N m²] of a region of six-node triangles.

The twist is about the origin. The warping ``w = tau psi`` of the region
is free and minimises the shear energy, so the rigidity is
``int G |grad psi + (-y, x)|² dA``, which is the polar moment
``int G r² dA`` less the warping relief. Mirror nodes have ``psi = 0``
(torsion warping is antisymmetric about a mirror plane that contains the
twist axis): the nodes on a line through the origin at one of
``mirror_angles`` and the nodes listed in ``mirror_nodes`` (numbering of
``xy``), which a mesh gives for a mirror boundary whose nodes lie off the
exact line. A connected part of the region with no mirror node has its
first node held, which removes its rigid axial translation. ``conn``
lists the elements of the region in the node numbering of ``xy``;
``shear_modulus`` gives one value per element.
"""
conn = np.asarray(conn, dtype=np.int64)
shear_modulus = np.asarray(shear_modulus, dtype=np.float64)
if conn.size == 0 or not np.any(shear_modulus > 0.0):
# No region, or one without shear stiffness (a serving): no torsion.
return 0.0
nodes, inverse = np.unique(conn, return_inverse=True)
local = inverse.reshape(conn.shape)
n = len(nodes)
coords = xy[conn] # (ne, 6, 2)
ne = len(conn)
ke = np.zeros((ne, 6, 6))
fe = np.zeros((ne, 6))
polar = 0.0
for (shape, dshape), w in zip(_SHAPES, _QW, strict=True):
jac = np.einsum("ka,eki->eai", dshape, coords)
det = jac[:, 0, 0] * jac[:, 1, 1] - jac[:, 0, 1] * jac[:, 1, 0]
if np.any(det == 0):
raise CableInputError("degenerate element in the torsion region")
inv = np.empty_like(jac)
inv[:, 0, 0] = jac[:, 1, 1] / det
inv[:, 1, 1] = jac[:, 0, 0] / det
inv[:, 0, 1] = -jac[:, 0, 1] / det
inv[:, 1, 0] = -jac[:, 1, 0] / det
dn = np.einsum("ka,eia->eki", dshape, inv)
weight = w * np.abs(det) * shear_modulus
point = np.einsum("k,eki->ei", shape, coords)
x, y = point[:, 0], point[:, 1]
ke += np.einsum("e,eki,eli->ekl", weight, dn, dn)
fe += weight[:, None] * (dn[:, :, 0] * -y[:, None] + dn[:, :, 1] * x[:, None])
polar += float(np.sum(weight * (x * x + y * y)))
rows = np.repeat(local, 6, axis=1).ravel()
cols = np.tile(local, (1, 6)).ravel()
k = sp.csr_matrix((ke.ravel(), (rows, cols)), shape=(n, n))
f = np.zeros(n)
np.add.at(f, local.ravel(), fe.ravel())
pts = xy[nodes]
scale = max(1.0, float(np.max(np.abs(pts))))
fixed = np.zeros(n, dtype=bool)
for angle in mirror_angles:
distance = np.abs(pts[:, 0] * math.sin(angle) - pts[:, 1] * math.cos(angle))
fixed |= distance <= 1e-9 * scale
Comment on lines +831 to +833

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Preserve mirror constraints for rounded core geometries

For bundles whose core spacing is not exactly 2*a/sqrt(3), this coordinate test misses the filler nodes on the mesh's nominal 60° boundary. This affects shipped configurations: chae2023_coiling.yaml uses rc=0.040877 and a=0.0354, so the inner endpoint lies about 0.4 µm off the mirror line, exceeding the 1 nm tolerance. Only the ring endpoint is then constrained, leaving the rest of the half-lobe boundary free to warp and underestimating its torsional rigidity when multiplied by six. The existing _mirror_transform identifies this boundary using mesh keys instead; pass equivalent boundary information to the warping solver or project the nominal boundary onto the mirror line before solving.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Fixed in 4c25616: the filler nodes of the 60° mirror boundary are now taken from the mesh keys (as the in-plane mirror conditions do) and passed to saint_venant_rigidity as mirror_nodes. On the Chae cable the filler term rises from 0.17 to 0.32 kN m² with it; a new test moves the cores 0.2 % apart and keeps the filler term within 3 % of the touching case (the geometric test alone halved it).

if mirror_nodes is not None:
fixed |= np.isin(nodes, np.asarray(mirror_nodes, dtype=np.int64))
count, label = connected_components(k, directed=False)
for part in range(count):
members = np.flatnonzero(label == part)
if not np.any(fixed[members]):
fixed[members[0]] = True
free = ~fixed
if not np.any(free):
return polar
psi = spsolve(k[free][:, free].tocsc(), -f[free])
return polar + float(f[free] @ psi)


def _assemble(
xy: FloatArray,
conn: NDArray[np.int64],
Expand All @@ -751,8 +855,13 @@ def _assemble(
groups: dict[str, list[int]],
rc: float,
cb: float,
mirror_nodes: NDArray[np.int64] | None = None,
) -> tuple[sp.coo_matrix, FloatArray, float]:
"""Generalised plane-strain T6 stiffness, free-strain load, twist rigidity."""
"""Generalised plane-strain T6 stiffness, free-strain load, twist rigidity.

``mirror_nodes`` are the filler nodes of the 60 degree mirror boundary,
which lie off the exact line when the cores do not touch.
"""
ne = len(conn)
coords = xy[conn] # (ne, 6, 2)
e, nu, e0, carries = props[:, 0], props[:, 1], props[:, 2], props[:, 4]
Expand All @@ -778,6 +887,8 @@ def _assemble(
polar = np.zeros(ne)
core_set = set(groups.get("core", []))
is_core = np.array([i in core_set for i in range(ne)])
filler_set = set(groups.get("filler", []))
is_filler = np.array([i in filler_set for i in range(ne)])
for (shape, dshape), w in zip(_SHAPES, _QW, strict=True):
jac = np.einsum("ka,eki->eai", dshape, coords) # d(x_i)/d(xi_a)
det = jac[:, 0, 0] * jac[:, 1, 1] - jac[:, 0, 1] * jac[:, 1, 0]
Expand Down Expand Up @@ -808,7 +919,19 @@ def _assemble(
point[:, 0] ** 2 + point[:, 1] ** 2,
)
polar += weight * mu * r2 * carries
twist = float(np.sum(np.where(is_core, polar * cb**4, polar)))
# Cores about their own centres (exact for annuli), ring layers about the
# cable axis (exact for a bonded annulus stack). The filler lobes touch
# cores and ring through frictionless contacts, so they twist as separate
# bodies with their own warping, solved below.
twist = float(np.sum(np.where(is_core, polar * cb**4, 0.0)))
twist += float(np.sum(polar[~is_core & ~is_filler]))
if np.any(is_filler):
twist += saint_venant_rigidity(
xy,
conn[is_filler],
(mu * carries)[is_filler],
mirror_nodes=mirror_nodes,
)
dofs = np.zeros((ne, ndof_e), dtype=np.int64)
dofs[:, 0:12:2] = 2 + 2 * conn
dofs[:, 1:12:2] = 3 + 2 * conn
Expand Down
9 changes: 7 additions & 2 deletions tests/test_radial_benchmarks.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,14 @@ def test_su_2026_35kv_axial_and_torsional_stiffness():
for sign in (1, -1)
)
# Stiffer direction against the FE clockwise value, softer against the
# anticlockwise value.
# anticlockwise value (test, Table 6: 209.8 and 201.3). The filler lobes
# twist as separate bodies: -4.8 % and -12.0 %. The band of the softer
# direction was 12 % when the filler added its polar moment about the
# cable axis (-10.3 %); that bonded term is not supported by the
# frictionless filler contacts, and Su's own model without the filler
# gives -8.4 %, so the remaining gap is not the filler.
assert gj[1] == pytest.approx(209.5e3, rel=0.05)
assert gj[0] == pytest.approx(201.2e3, rel=0.12)
assert gj[0] == pytest.approx(201.2e3, rel=0.13)
# The no-radial-interaction bound is about 30 % stiffer than the FE.
rigid = 0.0
for layer in section.layers:
Expand Down
Loading
Loading