Skip to main content

Thermodynamic Coherence Engine (TCE)

The TCE is the certification gate of BRIK-64. Every program must pass through it before compilation completes. If the TCE returns Φ_c < 1.000, compilation is aborted — not warned, not flagged, aborted. The TCE operationalizes a deep insight: a correct program is a closed thermodynamic circuit. It dissipates only the energy mandated by the Landauer Limit for the information it processes. Any excess dissipation is evidence of unnecessary computation — irreversibility, branching entropy, or structural incoherence.

The TCE Operator

𝒯_CE(C) = (E_c, H_d, S_d, C_s, ETC, ΔN, Φ_c)
Given a certified circuit C (in CPF form), the TCE computes 7 scalar metrics and one binary certification result.

E_c — Circuit Energy

Normalized energy consumption of the circuit relative to the Landauer minimum. E_c = 0 means the circuit dissipates exactly the Landauer minimum — physically optimal. E_c = 1 means infinite wasteful dissipation. Threshold: E_c < 1.0 required.

H_d — Decision Entropy

Shannon entropy of the branching structure ( nodes) in the EVA tree. High H_d means the program has many unpredictable branches — hard to reason about, hard to certify at scale. Threshold: H_d < 0.25 required.

S_d — Structural Disorder

Measure of compositional irregularity: how much the EVA tree deviates from a balanced, regular structure. Programs with deeply nested irregular conditionals have high S_d. Threshold: S_d < 0.15 required.

C_s — Coherence Score

The primary coherence metric. Measures how “closed” the circuit is — whether all information paths terminate, whether all branches are accounted for, whether the EVA structure is complete. Threshold: C_s > 0.90 required.

ETC — Entropic Termination Coefficient

Normalized measure of termination certainty. ETC = 0 means provably terminating; ETC = 1 means the circuit has no termination proof. For BRIK-64, all circuits must terminate (all monomers are O(1), all loops are bounded). Threshold: ETC < 0.95 required.

ΔN — Landauer Gap

The excess energy dissipation above the Landauer Limit, normalized. ΔN = 0 means the program runs at the physical minimum — it erases exactly the bits that must be erased to compute its output, and no more. Threshold: ΔN < 0.10 required for certified status.

Φ_c — Circuit Coherence

The master metric. Computed from H_d, ΔN, and ETC. Φ_c = 1.000 means the circuit is thermodynamically closed — certified. Any value less than 1.000 means the circuit is open — not certified.

Ω — Certification Flag

Binary output: Ω = 1 (certified) or Ω = 0 (not certified). Ω = 1 ↔ Φ_c = 1.000 AND ΔN = 0.000 AND C_s = 1.000. There is no Ω = 0.9. There is no partial certification.

The Φ_c Formula

Φ_c = (1 - H_d / H_max) · (1 - ΔN) · (1 - ETC / ETC_max)
Where:
  • H_max is the maximum possible decision entropy for a circuit of this size (log₂ of branch count)
  • ETC_max = 1.0 (the maximum possible entropic termination coefficient)
For Φ_c = 1.000, all three factors must equal 1.000 simultaneously:
  • H_d / H_max = 0 → zero decision entropy → no unpredictable branching
  • ΔN = 0 → zero Landauer gap → minimum possible energy
  • ETC / ETC_max = 0 → proven termination → ETC = 0
This is an extremely tight constraint. It is the point of BRIK-64.

The Landauer Limit

The Landauer Limit is a fundamental result in physics and information theory:
Every irreversible bit erasure dissipates at minimum k_B · T · ln(2) ≈ 2.87 × 10⁻²¹ J at room temperature (T = 300K).
E_min = k_B · T · ln(2)
      = 1.38064852 × 10⁻²³ J/K · 300 K · 0.693147
      ≈ 2.87 × 10⁻²¹ J  per irreversible bit operation
The Landauer Gap (ΔN) measures how far your program’s actual energy dissipation exceeds this minimum. A program with ΔN = 0 performs only the irreversible operations that are mathematically necessary to compute its output. Every unnecessary branch, every unused variable, every redundant computation increases ΔN. In practice, ΔN is computed symbolically from the CPF (not by measuring actual hardware energy). The TCE performs static Landauer analysis: it counts the irreversible operations in the EVA tree and compares to the theoretical minimum for the function being computed.

Certification Thresholds

MetricThresholdMeaning if violated
E_c< 1.0Circuit exceeds normalized energy bound
H_d< 0.25Too much branching entropy
S_d< 0.15Structure too irregular
C_s> 0.90Circuit not sufficiently coherent
ETC< 0.95Termination not sufficiently proven
ΔN< 0.10Landauer gap too large
Φ_c= 1.000Master certification condition
The thresholds for E_c, H_d, S_d, C_s, ETC, and ΔN are necessary but not sufficient conditions. A circuit can satisfy all individual thresholds and still fail Φ_c = 1.000 if the combined product falls short. The formula is multiplicative — all three factors of Φ_c must simultaneously equal 1.

Ω = 1: The Binary Certification

Ω = 1  ↔  Φ_c = 1.000  AND  ΔN = 0.000  AND  C_s = 1.000
This is the Digital Circuitality condition. When Ω = 1:
  • The program is a closed circuit
  • It has no information leaks
  • It terminates on all inputs
  • It dissipates only the Landauer-minimum energy
  • Its behavior is fully determined by its inputs
  • Its hash is stable across all machines and all time
When Ω = 0, the program is an open circuit. It leaks information, or fails to terminate on some input, or dissipates excess energy. There is no middle ground. This is intentionally strict. An analogy from aviation: a plane is either airworthy or it is not. There is no “87% airworthy.” The Φ_c = 1 requirement is the formal equivalent.

TCE Example Output

{
  "circuit": "hash_file",
  "tce": {
    "E_c":  0.042,
    "H_d":  0.000,
    "S_d":  0.031,
    "C_s":  1.000,
    "ETC":  0.000,
    "ΔN":   0.000,
    "Φ_c":  1.000
  },
  "omega": 1,
  "certified": true,
  "certification_id": "sha256:7229cfcde9613de42eda4dd207da3bac80d2bf2b5f778f3270c2321e8e489e95"
}
{
  "circuit": "classify_with_loop",
  "tce": {
    "E_c":  0.731,
    "H_d":  0.412,
    "S_d":  0.289,
    "C_s":  0.734,
    "ETC":  0.110,
    "ΔN":   0.341,
    "Φ_c":  0.321
  },
  "omega": 0,
  "certified": false,
  "error": "H_d=0.412 exceeds threshold 0.25. S_d=0.289 exceeds threshold 0.15. C_s=0.734 below threshold 0.90. Φ_c=0.321 != 1.000. Compilation aborted."
}

Compositionality

The TCE is compositional with respect to EVA Algebra. You never need to re-certify a program from scratch after combining two certified sub-circuits.

Sequential (⊗)

TCE(A ⊗ B).E_c  = TCE(A).E_c  + TCE(B).E_c   (additive)
TCE(A ⊗ B).H_d  = TCE(A).H_d  + TCE(B).H_d   (additive)
TCE(A ⊗ B).Φ_c  = 1.000   if  TCE(A).Φ_c = 1.000 AND TCE(B).Φ_c = 1.000
                                               (closure theorem)

Parallel (∥)

TCE(A ∥ B).E_c  = TCE(A).E_c  + TCE(B).E_c   (additive — independent thermal units)
TCE(A ∥ B).ΔN   = max(TCE(A).ΔN, TCE(B).ΔN)  (worst-case Landauer gap)
TCE(A ∥ B).Φ_c  = 1.000   if  TCE(A).Φ_c = 1.000 AND TCE(B).Φ_c = 1.000

Conditional (⊕)

TCE(A ⊕ B).H_d  = H(p_A, p_B) + p_A·TCE(A).H_d + p_B·TCE(B).H_d
                  where H(p_A, p_B) = -p_A·log₂(p_A) - p_B·log₂(p_B)
TCE(A ⊕ B).Φ_c  = 1.000   if  TCE(A).Φ_c = 1.000 AND TCE(B).Φ_c = 1.000
                              AND H(p_A, p_B) < H_max threshold
The conditional case is where H_d accumulates. A certified branch () requires that even the branching entropy itself is bounded. This prevents combinatorial explosion of conditional logic.

TCE in the Compiler Pipeline

1

CPF arrives at TCE

The planner produces a CPF document with EVA annotations for every sub-expression. The TCE receives the entire CPF — not just individual functions.
2

Per-monomer metric computation

Each monomer has pre-computed TCE values (stored in the Coq proof metadata). The TCE retrieves these base values: E_c(MC_00.ADD8) = 0.001, etc.
3

Bottom-up composition

The TCE walks the EVA tree bottom-up, applying the composition formulas above. At each interior node (⊗, ∥, ⊕), it combines the child metrics into parent metrics.
4

Φ_c computation and gate

At the root of the EVA tree, the TCE computes Φ_c using the formula above. If Φ_c = 1.000 AND ΔN = 0.000 AND C_s = 1.000, compilation proceeds. Otherwise, compilation is aborted with a detailed diagnostic.
5

Certification ID emission

If Ω = 1, the TCE emits a Certification ID: the SHA-256 of the CPF document plus all metric values. This ID is embedded in the compiled binary header and in the ELF .note section. It is the unforgeable proof of certification.

Connection to Hardware: The BPU

In the future BPU (BRIK Processing Unit) architecture, the TCE is not software — it is silicon. The BPU contains:
  • 64 monomer execution units (one per Core monomer)
  • An EVA Router that enforces ⊗/∥/⊕ composition at the gate level
  • A TCE Unit: a dedicated on-die circuit that computes Φ_c in hardware, before the program is allowed to run
The key insight of the BPU: when Ω = 1, the only possible failure mode is a hardware error in the silicon substrate. Modern silicon has an error rate of approximately 10⁻¹⁹ per operation. This is the floor.
  • RLHF and alignment training teach an AI to want to do right
  • The BPU prevents it from doing wrong
  • Education fails. Physics does not.
For a certified BRIK-64 program running on a BPU:
P(incorrect output) ≤ 10⁻¹⁹ per operation
This is not an approximation or an aspiration. It is a consequence of Ω = 1 and the physics of complementary CMOS logic.

Relationship to Digital Circuitality

Digital Circuitality is the formal property that Ω = 1 describes: a program that behaves like a physical circuit. The TCE is the instrument that measures Digital Circuitality. The TCE metrics correspond to circuit properties:
TCE metricCircuit analogy
E_cCircuit power dissipation
H_dSignal path entropy (routing complexity)
S_dStructural disorder (irregular gate arrangements)
C_sCircuit closure (no open terminals)
ETCPropagation delay certainty
ΔNExcess heat (Joule heating above minimum)
Φ_cThe “circuit closed” indicator
A hardware engineer’s instinct: a circuit either works or it doesn’t. The TCE gives software the same rigorous binary characterization.

Coq Proofs for TCE

The TCE bounds and composition laws are formally proven:
theory/papers/tce_bounds.v          — Threshold proofs: E_c, H_d, S_d bounds
theory/papers/tce_composition.v     — Compositionality lemmas (⊗, ∥, ⊕)
theory/papers/tce_landauer.v        — Landauer gap formalization and ΔN = 0 characterization
theory/papers/tce_phi_formula.v     — Φ_c formula proof (monotonicity, boundary conditions)
theory/papers/tce_omega_binary.v    — Proof that Ω is strictly binary (no intermediate values)
Key theorem from tce_omega_binary.v:
Theorem omega_is_binary : forall (C : Circuit),
  omega C = 1 \/ omega C = 0.
Proof.
  intros C.
  destruct (phi_c_eq_one_dec C) as [H | H].
  - left. apply omega_one_iff. exact H.
  - right. apply omega_zero_iff. exact H.
Qed.
There is no third value for Ω. This theorem is what makes the certification claim meaningful — and what makes BRIK-64 fundamentally different from test coverage, fuzzing, or model checking approaches that produce confidence scores rather than proofs.