Add linear geometry, sphere, SO(n), and quaternion type core - #45
Add linear geometry, sphere, SO(n), and quaternion type core#45isomorphisms wants to merge 8 commits into
Conversation
|
I split the requested high-dimensional rotation/reflection verification onto a fresh stacked branch, |
|
Classification: SUPERSEDED by #51. #51 preserved the useful geometry line through the reconciled named-space/Euclidean model, including orthogonal and special-orthogonal structure, sphere/CPn topology facts, and the sound theorem boundary. #51 deliberately did not retain the unchecked certified sphere-action wrapper. No unique implementation from this PR remains pending here; the discussion remains useful historical context for the reconciliation. |
Scope
Bounded second-pass type-system slice centered on finite-dimensional linear algebra and standard geometry. This is stacked on #44 (
examples/units-time-intervals) so this PR's diff is geometry-only.Dimensioned linear algebra / semantic embeddings
ExactRealVector nmakes ambient dimension a type index;The executable coordinate samples use integers embedded in
R^nso the tests are exact and do not choose a floating-point policy. This is not a claim that real coordinates are integers.O(n), SO(n), rotations, reflections
Preserving/Reversing);SO(n)result type;c=0,s=1);Spheres
UnitSpherePoint nmeansS^nin ambientR^(n+1);O(n+1)actions preserve sphere membership at the type boundary;S^0case;chi(S^n)=1+(-1)^n(odd 0, even 2), without falsely claiming odd/even spheres have different additive cohomology ranks.Quaternions / SO(3)
SO(3)boundary.CP^n / standard topology facts
2n;CP^n = S^(2n+1)/S^1;S^2and(R^n)^+ ~= S^none-point compactification.The last items model the intended #42 theorem-index boundary: named checked facts may contribute typed consequences; the compiler is not pretending to rediscover their proofs.
Tests-first history
f799d79663f320a26421a9f2a24207de3af540d397951746363b9ee7e6c4b9b9470fde5dbbeff768edric008, added to./edric test6b46694b26328ae4b71134ce8b52bdb8c00fb4e8Deliberately deferred
General real-scalar representation, arbitrary Householder/Givens parameters, imported-matrix orthogonality certification, subspaces/projections, full
CP^nquotient equality, the cohomology ring, and theorem-provenance machinery.Verification
The first real compiler run (#8) successfully compiled and executed
edric008and produced exactlylinear geometry type core: ok. The workflow failed only because the committed golden file lacked the executable's terminal newline. No mathematical/type test failed and no implementation weakening was needed. Commit6b46694b26328ae4b71134ce8b52bdb8c00fb4e8fixes that one-byte golden mismatch.Exact-head
Edric type-system smokerun 33278264928 andEdric wrapperrun 33278264952 both passed. The compiler receipt and whole workflow are green at6b46694b26328ae4b71134ce8b52bdb8c00fb4e8.Related: #42, #44.
Competing mathematical model
#44 → #45 → #47 is one strict experimental stack. Independent PR #46 uses a different model: this branch has rank-indexed Euclidean coordinate vectors and a direct dot product, while #46 has nominally named spaces and permits contraction only between
Covector spaceandVector space, with no implicit metric. Both currently occupytests/idris2/basic/edric008, so choosing between them is not a mechanical merge.