AFTD Auto-Formalizing Theoretical Domains

lowMul3Target1

def

The target function z_1 : (Fin 6 → Bool) → ZMod 2 of the 3-bit low-half multiplier, given by z_1(x) = a_0 * b_1 + a_1 * b_0 = x(0) * x(4) + x(1) * x(3).

Statement

def lowMul3Target1 : (Fin 6 → Bool) → ZMod 2
Defined in
arXiv:2611.15992 Section 2 (Targets)
Verified
16 Nov 2026
Axioms
none listed
Used by 1
  • lowMul3TargetsThe set of target bits {z_0, z_1, z_2} of the three-bit low-half multiplier.

Read back from the Lean

The declaration lowMul3Target1 defines a function from Fin 6 → Bool to ZMod 2. It is defined using pointwise addition and multiplication of functions into ZMod 2: for any x : Fin 6 → Bool, it evaluates to (if x 0 then (1 : ZMod 2) else 0) * (if x 4 then 1 else 0) + (if x 1 then 1 else 0) * (if x 3 then 1 else 0). In other words, identifying true with 1 and false with 0 in $\mathbb{Z}/2\mathbb{Z}$, it computes $(x_0 \cdot x_4) + (x_1 \cdot x_3)$.

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- The second output bit z_1 = a_0 * b_1 + a_1 * b_0 of the three-bit low-half multiplier. -/
def lowMul3Target1 : (Fin 6 → Bool) → ZMod 2 := (fun x => if x 0 then (1 : ZMod 2) else 0) * (fun x => if x 4 then 1 else 0) +
   (fun x => if x 1 then 1 else 0) * (fun x => if x 3 then 1 else 0)
See it in the graphDiscuss this resultChallenge it