Surfaces and curvature
A surface is three formulas in two parameters. surface returns its two fundamental forms, its normal, and its Gaussian, mean and principal curvatures, as formulas and as certified values, and says what kind of point each point is.
const torus = surface(["(2 + cos(v))*cos(u)", "(2 + cos(v))*sin(u)", "sin(v)"], ["u", "v"]);
torus.first(); // { E: "cos(v)^2 + 4*cos(v) + 4", F: "0", G: "1" }
torus.gaussian(); // "cos(v)/(cos(v) + 2)"
torus.at(0, 0).kind; // "elliptic" the outer rim
torus.at(0, "pi").kind; // "hyperbolic" the inner rim
torus.area({ u: [0, "2*pi"], v: [0, "2*pi"] }); // an interval around 8π²
The first fundamental form
With the surface and its partial derivatives,
These three functions hold everything that can be measured inside the surface. A curve on it has speed ; the angle between two directions comes from the same form; and area is
The parametrisation is regular where . At a point where that fails (the poles of a sphere in latitude and longitude) at refuses.
The second fundamental form and curvature
With unit normal ,
Cut the surface with a plane through the normal: the curvature of the section is the normal curvature in that direction. Its largest and smallest values over all directions are the principal curvatures , and
is the Gaussian curvature and the mean curvature. The sign of depends on which way the normal points; does not.
| kind | condition | the surface near the point |
|---|---|---|
| elliptic | lies on one side of its tangent plane, like a dome | |
| hyperbolic | crosses its tangent plane, like a saddle | |
| parabolic | , not planar | curved in one direction only, like a cylinder |
| planar | flat to second order |
An enclosure can prove or . It cannot prove , so parabolic and planar are reported only when the formulas vanish exactly at the point; otherwise kind is null.
The Theorema Egregium
is defined through the normal, which is about how the surface sits in space. Gauss found that it can be computed from alone: bend a sheet of paper without stretching it and stays 0 everywhere. intrinsicGaussian() computes from the first form by way of the Christoffel symbols and the curvature tensor, and it agrees with gaussian().
Because of that, the curvature makes sense for a metric with no surface behind it; see Geodesics and Gauss-Bonnet.
| call | returns |
|---|---|
| surface(components, [u, v], { params }) | Surface (a Metric with a normal) |
| s.first(), s.second(), s.normal() | { E, F, G }, { L, M, N }, r_u × r_v, as formulas |
| s.gaussian(), s.mean(), s.intrinsicGaussian() | formulas |
| s.at(u, v, { digits = 15 }) | { point, normal, E, F, G, L, M, N, gaussian, mean, principal, kind } |
| s.area(region, { digits = 8 }), s.totalCurvature(region) | RationalInterval; region { u: [a, b], v: [lo(u), hi(u)] } |
@ratmath/analytic and Core's R, Rational, RationalInterval in scope. The last line's value is shown; PRINT(…) adds lines, TEX(…) typesets math.