uor-foundation 0.3.0

UOR Foundation — typed Rust traits for the complete ontology. Import and implement.
Documentation
// @generated by uor-crate from uor-ontology — do not edit manually

//! `convergence/` namespace — Hopf convergence tower: four levels R, C, H, O corresponding to the four normed division algebras of dimensions 1, 2, 4, 8. Each level carries a Hopf fibration fiber and Betti signature..
//!
//! Space: Kernel

use crate::HostTypes;

/// A level in the convergence tower. Four instances: R (dim 1), C (dim 2), H (dim 4), O (dim 8).
pub trait ConvergenceLevel<H: HostTypes> {
    /// The dimension of the division algebra at this level (1, 2, 4, or 8).
    fn algebra_dimension(&self) -> u64;
    /// The Betti number signature at this convergence level.
    fn betti_signature(&self) -> &H::HostString;
    /// Associated type for `HopfFiber`.
    type HopfFiber: HopfFiber<H>;
    /// The Hopf fiber associated with this convergence level.
    fn fiber_type(&self) -> &Self::HopfFiber;
    /// The characteristic identity at this convergence level (existence, feedback, choice, self-reference).
    fn characteristic_identity(&self) -> &H::HostString;
    /// Human-readable name of this convergence level.
    fn level_name(&self) -> &H::HostString;
}

/// The fiber of the Hopf fibration at a convergence level. Four instances: S⁰, S¹, S³, S⁷.
pub trait HopfFiber<H: HostTypes> {
    /// The dimension of the Hopf fiber sphere.
    fn fiber_dimension(&self) -> u64;
    /// The total space of the Hopf fibration.
    fn total_space(&self) -> &H::HostString;
    /// The base space of the Hopf fibration.
    fn base_space(&self) -> &H::HostString;
    /// The fiber sphere designation (e.g. S⁰, S¹).
    fn fiber_sphere(&self) -> &H::HostString;
}

/// The unresolved structure at a convergence level. The β_{2^k−1} = 1 Betti number that persists.
pub trait ConvergenceResidual<H: HostTypes> {
    /// The persistent Betti number at this residual.
    fn residual_betti(&self) -> u64;
    /// The dimension at which the residual persists.
    fn residual_dimension(&self) -> u64;
}

/// The subspace U(1) ⊂ SU(2) selected when pairwise interaction converges.
pub trait CommutativeSubspace<H: HostTypes> {
    /// Associated type for `CommutativeSubspace`.
    type CommutativeSubspaceTarget: CommutativeSubspace<H>;
    /// The commutative subspace selected by pairwise convergence.
    fn subspace_ref(&self) -> &Self::CommutativeSubspaceTarget;
    /// Associated type for `Commutator`.
    type Commutator: crate::bridge::observable::Commutator<H>;
    /// Reference to the commutator pair for this convergence.
    fn commutator_ref(&self) -> &Self::Commutator;
}

/// The subspace H ⊂ O selected when triple interaction converges.
pub trait AssociativeSubalgebra<H: HostTypes> {
    /// Associated type for `AssociativeSubalgebra`.
    type AssociativeSubalgebraTarget: AssociativeSubalgebra<H>;
    /// The associative subalgebra selected by triple convergence.
    fn subalgebra_ref(&self) -> &Self::AssociativeSubalgebraTarget;
    /// Associated type for `AssociatorTriple`.
    type AssociatorTriple: crate::bridge::interaction::AssociatorTriple<H>;
    /// Reference to the associator triple for this convergence.
    fn associator_ref(&self) -> &Self::AssociatorTriple;
}

/// Level 0: R (reals), dimension 1, existence.
pub mod l0_state {
    /// `algebraDimension`
    pub const ALGEBRA_DIMENSION: i64 = 1;
    /// `bettiSignature`
    pub const BETTI_SIGNATURE: &str = "[1]";
    /// `characteristicIdentity`
    pub const CHARACTERISTIC_IDENTITY: &str = "existence";
    /// `fiberType` -> `hopf_S0`
    pub const FIBER_TYPE: &str = "https://uor.foundation/convergence/hopf_S0";
    /// `levelName`
    pub const LEVEL_NAME: &str = "R";
}

/// Level 1: C (complex), dimension 2, feedback.
pub mod l1_memory {
    /// `algebraDimension`
    pub const ALGEBRA_DIMENSION: i64 = 2;
    /// `bettiSignature`
    pub const BETTI_SIGNATURE: &str = "[1,1]";
    /// `characteristicIdentity`
    pub const CHARACTERISTIC_IDENTITY: &str = "feedback";
    /// `fiberType` -> `hopf_S1`
    pub const FIBER_TYPE: &str = "https://uor.foundation/convergence/hopf_S1";
    /// `levelName`
    pub const LEVEL_NAME: &str = "C";
}

/// Level 2: H (quaternions), dimension 4, choice.
pub mod l2_agency {
    /// `algebraDimension`
    pub const ALGEBRA_DIMENSION: i64 = 4;
    /// `bettiSignature`
    pub const BETTI_SIGNATURE: &str = "[1,0,0,1]";
    /// `characteristicIdentity`
    pub const CHARACTERISTIC_IDENTITY: &str = "choice";
    /// `fiberType` -> `hopf_S3`
    pub const FIBER_TYPE: &str = "https://uor.foundation/convergence/hopf_S3";
    /// `levelName`
    pub const LEVEL_NAME: &str = "H";
}

/// Level 3: O (octonions), dimension 8, self-reference.
pub mod l3_self {
    /// `algebraDimension`
    pub const ALGEBRA_DIMENSION: i64 = 8;
    /// `bettiSignature`
    pub const BETTI_SIGNATURE: &str = "[1,0,0,0,0,0,0,1]";
    /// `characteristicIdentity`
    pub const CHARACTERISTIC_IDENTITY: &str = "self-reference";
    /// `fiberType` -> `hopf_S7`
    pub const FIBER_TYPE: &str = "https://uor.foundation/convergence/hopf_S7";
    /// `levelName`
    pub const LEVEL_NAME: &str = "O";
}

/// Hopf fiber S⁰: dimension 0, total space S¹, base pt.
pub mod hopf_s0 {
    /// `baseSpace`
    pub const BASE_SPACE: &str = "pt";
    /// `fiberDimension`
    pub const FIBER_DIMENSION: i64 = 0;
    /// `fiberSphere`
    pub const FIBER_SPHERE: &str = "S⁰";
    /// `totalSpace`
    pub const TOTAL_SPACE: &str = "";
}

/// Hopf fiber S¹: dimension 1, total space S³, base S².
pub mod hopf_s1 {
    /// `baseSpace`
    pub const BASE_SPACE: &str = "";
    /// `fiberDimension`
    pub const FIBER_DIMENSION: i64 = 1;
    /// `fiberSphere`
    pub const FIBER_SPHERE: &str = "";
    /// `totalSpace`
    pub const TOTAL_SPACE: &str = "";
}

/// Hopf fiber S³: dimension 3, total space S⁷, base S⁴.
pub mod hopf_s3 {
    /// `baseSpace`
    pub const BASE_SPACE: &str = "S⁴";
    /// `fiberDimension`
    pub const FIBER_DIMENSION: i64 = 3;
    /// `fiberSphere`
    pub const FIBER_SPHERE: &str = "";
    /// `totalSpace`
    pub const TOTAL_SPACE: &str = "S⁷";
}

/// Hopf fiber S⁷: dimension 7, total space S¹⁵, base S⁸.
pub mod hopf_s7 {
    /// `baseSpace`
    pub const BASE_SPACE: &str = "S⁸";
    /// `fiberDimension`
    pub const FIBER_DIMENSION: i64 = 7;
    /// `fiberSphere`
    pub const FIBER_SPHERE: &str = "S⁷";
    /// `totalSpace`
    pub const TOTAL_SPACE: &str = "S¹⁵";
}