Skip to main content

Module elevation

Module elevation 

Source
Expand description

Elevation laws and the composition of a planar curve with one.

A road or rail centreline is authored as two independent laws: a planar layout carrying the transition spirals, and a vertical profile giving height as a function of distance along that layout. The 3D centreline is their composition. This module holds the vertical half and the pairing; the planar half is an ordinary Curve2.

§Height is a function of PLAN distance, not 3D arc length

The vertical profile a surveyor writes is indexed by chainage measured on the horizontal layout, so height_at takes plan distance. The two differ whenever the grade is non-zero, because ds3 = sqrt(1 + g^2) ds_plan. Over a 120 m curve at a 2% entry grade the 3D length exceeds the plan length by 12.5 mm, which reads the profile 0.35 mm off if the distances are confused. That is small but it is a systematic misreading, not noise, and it compounds along a chain of segments.

Naming the convention here means a consumer never has to guess which distance a law is written in.

§Closed forms here, quadrature in an evaluator

A polynomial and a circular arc in the (d, z) plane have closed-form heights and grades, so ElevationLaw::height_at and ElevationLaw::grade_at answer them here. A profile given by its curvature against its own arc length (ElevationLaw::Intrinsic, the clothoid between two grades) does not: its height is the Fresnel-type integral the CurvatureLaw module refuses to compute, followed by an inversion of plan distance against arc length. This crate stores that law exactly and reports None for it; an evaluator that can state its quadrature tolerance reads it (axiolid-evaluate’s elevation module).

Structs§

Elevated3
A planar curve carrying an independent elevation law.

Enums§

ElevationLaw
Height as a function of distance along the plan.