Braided torus
Geometry
Three tubes are woven into one closed circular braid. A single strand no longer follows the ring: its centreline is a helix that rises and falls around the torus, and the other two are the same curve shifted by 2π/3.
C_k(u) = ((R + a cos(ωu + φ_k)) cos u, (R + a cos(ωu + φ_k)) sin u, a sin(ωu + φ_k))φ_k = 2πk/3, k = 0,1,2
ω is the number of twists per loop, so the three strands cross each other ω times around the ring. Each strand is a tube of radius ρs swept along its own centreline with a numeric Frenet frame: T = dC/du, N = dT/du, B = T × N, giving P(u,v) = C(u) + ρs(cos v·N + sin v·B).
Strand k takes the base hue rotated by spread·(k−1) degrees, so a spread of zero braids one colour and larger values separate the strands into closely related tones. ρs is clamped to 0.45a so the tubes stay side by side instead of swallowing each other.