Trust checks for the distance and the expansion of its square #
Checks of distJet, midJet and the fifth-order expansions IsRiemMetric.dist_sq_expansion and
IsRiemMetric.dist_sq_expansion_midpoint (Lightlike/Regge/Geodesic/DistExpansion.lean), and of
distJet5 and the sixth-order expansions IsRiemMetric.dist_sq_expansion6 and
IsRiemMetric.dist_sq_expansion_midpoint6 (Lightlike/Regge/Geodesic/Quintic.lean,
Lightlike/Regge/Geodesic/Sixth.lean), against exactly known distances, and wrong models shown to
fail; and checks of the link with Mathlib's Riemannian distance
(Lightlike/Regge/Geodesic/Riemannian.lean).
Sheared planes #
shearBy q is the metric [[1 + q(y₀)², q(y₀)], [q(y₀), 1]] on ℝ², the pullback of the
Euclidean metric by the shear map φ(y) = (y₀, y₁ + p(y₀)) with p' = q (shearMapBy). It is
flat, but in these coordinates it has an off-diagonal entry, non-zero first and second derivatives
and the Christoffel symbol Γ¹₀₀ = q'(y₀) (christoffel_shearBy). Its distance is
|φ(y) - φ(x)| (dist_shearBy): the preimage of the straight segment is admissible with that
length, and every admissible curve maps to a curve at least that long. Both jets and the
quintic term quint are computed in closed form for any q (jetWith_shearBy,
midJetWith_shearBy, quint_shearBy).
Known values #
- The quadratic shear
shear(p(s) = s²/2). The squared distance is a polynomial of degree four inw, and it equals the jet exactly at every point (dist_sq_shear:d(x, x + w)² = distJet x w;dist_sq_shear_midpoint:d(m - Δ/2, m + Δ/2)² = midJet m Δ). - The cubic shear
cubicShear(p(s) = s³/6). At the originΓ = 0but the second derivatives of the metric do not vanish, and the remainders are exactlyd(0, w)² - distJet 0 w = w₀⁶/36(dist_sq_cubicShear_zero) andd(-Δ/2, Δ/2)² - midJet 0 Δ = Δ₀⁶/576(dist_sq_cubicShear_midpoint_zero). - Sixth order. On the cubic shear the remainders are exactly
d(x, x + w)² - distJet5 x w = w₀⁶/36(dist_sq_cubicShear_sixth) andd(m - Δ/2, m + Δ/2)² - midJet m Δ = Δ₀⁶/576(dist_sq_cubicShear_midpoint) at every point, whereΓ,∂gandquint = x₀ w₀⁵/6do not vanish. On the quartic shearquarticShear(p(s) = s⁴/24) at the origin only the third derivative of the metric is non-zero, andd(0, w)² - distJet5 0 w = w₀⁸/576(dist_sq_quarticShear_zero), which checks the coefficient1/24of the third derivative inquint. Both sixth-order bounds are sharp: the remainders are notO(‖w‖⁷)(dist_sq_expansion6_sharp,dist_sq_expansion_midpoint6_sharp). - The Euclidean metric: both jets are
|w|²(distJet_euclid,midJet_euclid), andd(x, x + w)² = distJet x w(dist_sq_euclid).
The coefficients are forced #
jetWith a b and midJetWith a b are the jets with free coefficients a of the second
derivative of the metric and b of the Christoffel term (distJet = jetWith (1/6) (1/12),
midJet = midJetWith (1/24) (1/12)). The quadratic shear alone fixes only 2a - b; together
with the cubic shear the fifth-order bound forces a = 1/6, b = 1/12
(jetWith_coeffs_forced) and a = 1/24, b = 1/12 (midJetWith_coeffs_forced).
Wrong models #
- Dropping the Christoffel term (
b = 0) leaves an errort⁴/12alongw = (t, 0)on the quadratic shear, so the fifth-order bound fails at every point (jetWith_noChr_shear_fails,midJetWith_noChr_shear_fails). This matches the numerical control inscripts/regge/distance_expansion_check.py, where the remainder of the model without the Christoffel term has order 4 instead of 5. - Dropping the quintic term (
distJetin place ofdistJet5) leaves the errorx₀ t⁵/6 + t⁶/36on the cubic shear, so the sixth-order bound fails at every point withx₀ ≠ 0(distJet_cubicShear_not_sixth).
Non-vacuity #
- The hypotheses of both expansion theorems hold for the quadratic shear on the closed unit ball
(
shear_dist_sq_expansion,shear_dist_sq_expansion_midpoint). - The hypotheses of
IsRiemMetric.exists_localJet3and of both sixth-order expansion theorems hold for the cubic shear on the closed unit ball, where the remainders are not zero (cubicShear_exists_localJet3,cubicShear_dist_sq_expansion6,cubicShear_dist_sq_expansion_midpoint6).
Mathlib's Riemannian distance #
- Known value (Mathlib). For the Euclidean metric on
ℝⁿthe Riemannian distance of our bundle is Mathlib's Riemannian distance of the inner product spaceEuclideanSpace ℝ (Fin n)between the same points (riemannianEDist_euclid), which Mathlib proves to be the Euclidean distance. - Known value. For the quadratic shear the Riemannian distance from
0to(1, 0)is√5/2(riemannianEDist_shear). Wrong input: the Euclidean metric gives1between the same points (riemannianEDist_shear_ne_euclid). - The connecting curve is needed. On the punctured line
{x₀ ≠ 0}no admissible curve joins-1and1(intermediate value theorem), so the Riemannian distance is⊤whiledistis the junk value0(riemannianEDist_puncturedLine). The hypothesis ofIsRiemMetric.riemannianEDist_eqcannot be dropped.
Sheared planes #
The sheared plane with shear p, written through q = p': the pullback of the
Euclidean metric of ℝ² by φ(y) = (y₀, y₁ + p(y₀)), i.e.
g = Dφᵀ Dφ = [[1 + q(y₀)², q(y₀)], [q(y₀), 1]].
Equations
- Lightlike.Geodesic.shearBy q y = !![1 + q (y 0) ^ 2, q (y 0); q (y 0), 1]
Instances For
The Christoffel symbols of the sheared metric: Γ¹₀₀ = q'(x₀), all others vanish.
The jets with free coefficients #
The jet family g(w, w) + ½ ∂_w g(w, w) + a ∂_w ∂_w g(w, w) - b g(Γ(w, w), Γ(w, w)) at x;
distJet is jetWith (1/6) (1/12) (jetWith_distJet).
Equations
- One or more equations did not get rendered due to their size.
Instances For
The midpoint jet family g(Δ, Δ) + a ∂_Δ ∂_Δ g(Δ, Δ) - b g(Γ(Δ, Δ), Γ(Δ, Δ)) at m;
midJet is midJetWith (1/24) (1/12) (midJetWith_midJet).
Equations
- One or more equations did not get rendered due to their size.
Instances For
The jet family on a sheared plane, in closed form.
The midpoint jet family on a sheared plane, in closed form.
The distance of a sheared plane #
The shear map is C¹ if p is.
Along a differentiable curve the squared speed in the sheared metric is the Euclidean squared speed of the image under the shear map.
The length of a C¹ curve in a sheared plane is the Euclidean length of its image.
Known value. The distance of a sheared plane is the Euclidean distance of the images under the shear map: the preimage of the straight segment is admissible with that length, and every admissible curve is at least that long.
The quadratic and the cubic shear #
The quadratic shear: p(s) = s²/2, q(s) = s, i.e. g = [[1 + y₀², y₀], [y₀, 1]],
with Γ¹₀₀ = 1.
Equations
- Lightlike.Geodesic.shear = Lightlike.Geodesic.shearBy fun (s : ℝ) => s
Instances For
The cubic shear: p(s) = s³/6, q(s) = s²/2, i.e.
g = [[1 + y₀⁴/4, y₀²/2], [y₀²/2, 1]], with Γ¹₀₀ = y₀.
Equations
- Lightlike.Geodesic.cubicShear = Lightlike.Geodesic.shearBy fun (s : ℝ) => s ^ 2 / 2
Instances For
(s²/2)' = s.
(s³/6)' = s²/2.
The quadratic shear is a Riemannian metric on the plane.
Trust check (exact). On the quadratic shear the squared distance between m ∓ Δ/2
equals the midpoint jet midJet (the remainder of
IsRiemMetric.dist_sq_expansion_midpoint vanishes identically).
Trust check (exact). On the cubic shear at the origin, where Γ = 0 but the second
derivatives of the metric do not vanish, the remainder of the jet is exactly w₀⁶/36.
The coefficients are forced #
The coefficients of distJet are forced. If a jet jetWith a b satisfies the
fifth-order bound at the origin of both the quadratic and the cubic shear, then a = 1/6 and
b = 1/12. The quadratic shear along (t, 0) gives 2a - b = 1/4; the cubic shear along
(t, t) gives 2a = 1/3.
The coefficients of midJet are forced. If a midpoint jet midJetWith a b satisfies
the fifth-order bound about the origin of both the quadratic and the cubic shear, then
a = 1/24 and b = 1/12. The quadratic shear along (t, 0) gives b = 2a; the cubic shear
along (t, t) gives 2a = 1/12.
Wrong models #
Wrong model fails. Without its Christoffel term (b = 0) the jet is off by t⁴/12 along
w = (t, 0) on the quadratic shear, so the fifth-order expansion fails at every point.
Wrong model fails. Without its Christoffel term (b = 0) the midpoint jet is off by
t⁴/12 along Δ = (t, 0) on the quadratic shear, so the fifth-order midpoint expansion fails
at every point.
The Euclidean metric and non-vacuity #
Non-vacuity. The hypotheses of IsRiemMetric.dist_sq_expansion hold for the quadratic
shear and the closed unit ball.
Non-vacuity. The hypotheses of IsRiemMetric.dist_sq_expansion_midpoint hold for the
quadratic shear and the closed unit ball.
The expansions to sixth order #
∂_p ∂_l ∂_k g_ij of the sheared metric.
The quintic term quint on a sheared plane, in closed form:
q₁ q₂ w₀⁵/6 + q₃ w₀⁴ (w₁ + q w₀)/12 at x₀. It is the term of order five of the exact squared
distance w₀² + (w₁ + p(x₀ + w₀) - p(x₀))².
The quartic shear: p(s) = s⁴/24, q(s) = s³/6, with Γ¹₀₀ = y₀²/2. At the origin
the metric is Euclidean to second order and only its third derivative ∂₀³ g₀₁ = 1 is
non-zero.
Equations
- Lightlike.Geodesic.quarticShear = Lightlike.Geodesic.shearBy fun (s : ℝ) => s ^ 3 / 6
Instances For
(s⁴/24)' = s³/6.
Trust check (exact). On the cubic shear the remainder of the sixth-order expansion
IsRiemMetric.dist_sq_expansion6 is exactly w₀⁶/36, at every point x. Here
quint = x₀ w₀⁵/6 is non-zero away from x₀ = 0, and the Christoffel symbols and the first two
derivatives of the metric all enter.
Trust check (exact). On the quartic shear at the origin, where only the third derivative
of the metric is non-zero, the remainder of IsRiemMetric.dist_sq_expansion6 is exactly
w₀⁸/576: the term (1/24) ∂_w ∂_w ∂_w g(w, w) = w₀⁴ w₁/12 of quint is the whole term of
order five of the squared distance.
Trust check (exact). On the cubic shear the remainder of the midpoint expansion
IsRiemMetric.dist_sq_expansion_midpoint6 is exactly Δ₀⁶/576, at every midpoint m: the
terms of order three and five vanish about the midpoint although the Christoffel symbols and the
first derivatives of the metric do not vanish at m when m₀ ≠ 0.
The order six is sharp. On the cubic shear the remainder of
IsRiemMetric.dist_sq_expansion6 is not O(‖w‖⁷) at any point (it is t⁶/36 along
w = (t, 0)).
The order six is sharp about the midpoint. On the cubic shear the remainder of
IsRiemMetric.dist_sq_expansion_midpoint6 is not O(‖Δ‖⁷) at any midpoint (it is t⁶/576
along Δ = (t, 0)).
Wrong model fails. Without its quintic term the jet distJet does not give the
sixth-order expansion: on the cubic shear at a point with x₀ ≠ 0 the remainder along
w = (t, 0) is x₀ t⁵/6 + t⁶/36, which is not O(‖w‖⁶).
The cubic shear is a Riemannian metric on the plane.
Non-vacuity. The hypotheses of IsRiemMetric.exists_localJet3 hold for the cubic shear
and the closed unit ball.
Non-vacuity. The hypotheses of IsRiemMetric.dist_sq_expansion6 hold for the cubic shear
and the closed unit ball, where the remainder is not zero (dist_sq_cubicShear_sixth).
Non-vacuity. The hypotheses of IsRiemMetric.dist_sq_expansion_midpoint6 hold for the
cubic shear and the closed unit ball, where the remainder is not zero
(dist_sq_cubicShear_midpoint).
Mathlib's Riemannian distance #
The Euclidean metric on ℝⁿ, viewed as the open set ⊤.
Known value (Mathlib). For the Euclidean metric on ℝⁿ, Mathlib's Riemannian distance
of our bundle is Mathlib's Riemannian distance of the inner product space
EuclideanSpace ℝ (Fin n) between the same points, i.e. the Euclidean distance.
The quadratic shear on the plane, viewed as the open set ⊤.
Known value. For the quadratic shear, Mathlib's Riemannian distance from 0 to (1, 0)
is √5/2: the shear map sends the two points to 0 and (1, 1/2).
Wrong input gives a different answer. The Euclidean metric gives Mathlib's Riemannian
distance 1 between the same two points, not the value √5/2 of the shear.
The punctured line {x ∈ ℝ¹ | x₀ ≠ 0}, an open set with two components.
Equations
Instances For
-1 lies in the punctured line.
1 lies in the punctured line.
No admissible curve in the punctured line joins -1 and 1: by the intermediate value
theorem every continuous curve from -1 to 1 passes through 0.
The hypothesis of IsRiemMetric.riemannianEDist_eq is needed. On the punctured line no
admissible curve joins -1 and 1, so Mathlib's Riemannian distance is ⊤ while dist is
the junk value 0.