g_math 0.4.2

Multi-domain fixed-point arithmetic with geometric extension: Lie groups, manifolds, ODE solvers, tensors, fiber bundles — zero-float, 0 ULP transcendentals
Documentation
[package]
name = "g_math"
version = "0.4.2"
edition = "2021"
description = "Multi-domain fixed-point arithmetic with geometric extension: Lie groups, manifolds, ODE solvers, tensors, fiber bundles — zero-float, 0 ULP transcendentals"
authors = ["Niels Erik Toren"]
license = "MIT OR Apache-2.0"
readme = "README.md"
repository = "https://github.com/nierto/gMath"
homepage = "https://github.com/nierto/gMath"
documentation = "https://docs.rs/g_math"
keywords = ["fixed-point", "arithmetic", "precision", "mathematics", "no-float"]
categories = ["mathematics", "algorithms"]
build = "build.rs"

[build-dependencies]
# Pure Rust BigInt for build-time table generation
# Used for exp/ln/trig lookup tables and rational arithmetic constants
num-bigint = "0.4"
num-traits = "0.2"
num-rational = "0.4"
num-integer = "0.1"

[dependencies]
# Optional: arbitrary-precision rational arithmetic (BigInt tier 8)
num-traits = { version = "0.2", optional = true }
num-bigint = { version = "0.4", optional = true }
num-integer = { version = "0.1", optional = true }
# Optional: serde serialization support
serde = { version = "1", features = ["derive"], optional = true }
# Optional: rayon row-parallel TQ1.9 matvec
rayon = { version = "1.10", optional = true }
# Optional: gmath!() proc-macro for compile-time literal parsing (published separately)
# g_math_macros = { path = "g_math_macros", optional = true }

[dev-dependencies]
criterion = "0.4"
proptest = "1.0"
approx = "0.5"
num-bigint = "0.4"
num-rational = "0.4"

[features]
default = []

# Optional: BigInt tier 8 in RationalNumber (unbounded precision)
infinite-precision = ["dep:num-bigint", "dep:num-traits", "dep:num-integer"]

# Deployment profiles (select compute precision via GMATH_PROFILE env var)
realtime = []      # Q16.16, 4 decimals, i32 storage, i64 compute
compact = []       # Q32.32, 9 decimals, i64 storage, i128 compute
embedded = []      # Q64.64, 19 decimals
balanced = []      # Q128.128, 38 decimals
scientific = []    # Q256.256, 77 decimals

# Feature gates for optional subsystems
legacy-tests = []        # Enable compilation of legacy test suites
rebuild-tables = []      # Regenerate lookup tables from build.rs (~20 min)
serde = ["dep:serde"]    # Serialize/Deserialize impls for FixedPoint, FixedVector, FixedMatrix, Tensor
inference = ["dep:rayon"] # TQ1.9 ternary inference ops + rayon row-parallel matvec
# macros = ["dep:g_math_macros"]    # gmath!() — deferred to separate crate publish

[lints.rust.unexpected_cfgs]
level = "warn"
check-cfg = [
    'cfg(table_format, values("q16_16", "q32_32", "q64_64", "q128_128", "q256_256", "q512_512"))',
    'cfg(q16_16)', 'cfg(q32_32)', 'cfg(q64_64)', 'cfg(q128_128)', 'cfg(q256_256)', 'cfg(q512_512)',
    'cfg(feature, values("rebuild-tables", "serde", "inference"))',
]

[profile.release]
debug = false
lto = true
codegen-units = 1
opt-level = 3

[profile.bench]
debug = true
lto = true
opt-level = 3