code wiki / (root) / nx_fluid_seal.nx

nx_fluid_seal.nx

buildroot/runtime/nx_fluid_seal.nx

4776 B121 linesdepth 0pulls 0 transitivereach 15 importersview sourcekind librarytopic fluid
docsdependenciesstructsconstsfunctions

about

nx_fluid_seal.nx -- fluid/seal-integrity kernel (#4 of 4 -- COMPLETES the physics-kernel set). Independent leak detection for plumbing, brake fluid, coolant, hydraulics, refrigerant, tires -- anything that should hold pressure or stay sealed. Two universal independent signals, integer/no-float: - PRESSURE-DECAY TEST: isolate the system, watch pressure over time. A healthy seal holds; a failing seal DECAYS. Decay rate -> severity, on the seepage -> leak -> rapid-loss progression (catch it BEFORE catastrophe). - FLOW-WHILE-ISOLATED: any flow when the system is isolated = a leak path (the hidden slab-leak / continuous-drip a homeowner never sees). THE EXCEED: most fluid systems have NO independent leak detection -- you learn of a leak from water damage / low fluid / brake failure. This quantifies seal integrity early and continuously, vendor-independent. NEVER-BRICK (#26): reads pressure/flow, emits a verdict; writes nothing, actuates no valve. Read-only by construction. genealogy_id: project-maintenance-platform-sclass-2026-06-23 (kernel #4 -- set complete) license_tier: ORIGINAL nx_capability_claims: needs: [pointer_arithmetic] provides: [pressure_decay_leak_test, flow_while_isolated_leak, seal_integrity_verdict, early_progression_detect] safety: [no_floating_point, no_syscall, bounded_iteration, read_only_no_device_write, no_firmware_write_by_construction, sealed_enum_verdict] verdict: [sealed_enum_fluid, no_silent_failure] license: ORIGINAL kind: maintenance_runtime_primitive

dependencies 0 imports · 2 importers

nx_fluid_seal.nx nx_fluid_seal_test.nx nx_maint_unify.nx

imports: none

imported by: nx_fluid_seal_test.nxnx_maint_unify.nx

structs

50struct FluidSpec
57struct FluidEff

consts

34const NX_FLUID_INSUFFICIENT_DATA: i64 = 0
35const NX_FLUID_SEALED: i64 = 1 // holds pressure (decay within allowance)
36const NX_FLUID_SEEPAGE: i64 = 2 // small elevated decay -- monitor
37const NX_FLUID_LEAK: i64 = 3 // clear leak (decay over alarm, or flow-while-isolated)
38const NX_FLUID_RAPID_LOSS: i64 = 4 // burst / wide-open -- rapid decay
39const NX_FLUID_NO_PRESSURE: i64 = 5 // never reached test pressure (weak pump / big open leak)
40const NX_FLUID_BAD_ARG: i64 = 6
41const NX_FLUID_N: i64 = 7

functions

43func nx_fluid_verdict_is_valid(v: i64) -> i64
called by 1: main
66func nx_fluid_analyze(pressure: *i64, t_sec: *i64, n: i64, flow_when_isolated: i64,
called by 1: main