Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Unit reformulation of the vampire law.

Proved
Bestiary.fangPair_int_congr

by raver1975 · Sep 11, 2026 · Mathlib c5ea003 (Lean v4.30.0)

aether-catalognovelty

Unit reformulation of the vampire law. For any base-b same-digit factorization (b ≥ 2), the decremented fangs multiply to 1 modulo b - 1: (x - 1)(y - 1) ≡ 1 [ZMOD (b - 1)]. Equivalently each x - 1, y - 1 is a unit modulo b - 1.

theorem Bestiary.fangPair_int_congr(b x y : ℕ) (hb : 2 ≤ b) (h : IsFangPair b x y) :
    ((x : ℤ) - 1) * ((y : ℤ) - 1) ≡ 1 [ZMOD ((b : ℤ) - 1)] := by sorry

Formalization Note Transplanted verbatim from the Aether Catalog source Novelty/VampireCongruence.lean; the statement is byte-identical to the source declaration, elaborated with autoImplicit disabled in the platform environment.

Preamble
-- Thm stub generated from Novelty/VampireCongruence.lean
import Mathlib
import Definitions.Def_Novelty_VampireNumbers

/-!
# The Unit Reformulation of the Vampire Law

Building on `Novelty.VampireNumbers`, this file records the *integer* face of the
vampire law.  The base-`b` law `x * y ≡ x + y [MOD (b - 1)]` (proved as
`Bestiary.fangPair_prod_modEq`) is, over `ℤ`, equivalent to

`(x - 1) * (y - 1) ≡ 1 [ZMOD (b - 1)]`,

i.e. *each fang, decremented by one, is a unit modulo `b - 1`.*  This is the sharp
algebraic obstruction that makes vampire (and werewolf/zombie) numbers scarce:
the pair `(x - 1, y - 1)` must be a pair of mutually-inverse residues.

-- !-- Lab Notes -- !--
Hypothesis (Hypothesizer): the additive congruence `xy ≡ x+y` should have a
cleaner multiplicative shadow.  Since `(x-1)(y-1) = xy - x - y + 1`, the law is
exactly `(x-1)(y-1) ≡ 1`.  Conjecture: this is the *only* residue obstruction —
every residue pair with `(x-1)(y-1) ≡ 1 (mod b-1)` is realized by some genuine
fang pair (left as a future direction).

Experiment (Experimenter): `1260 = 21·60`, `(21-1)(60-1) = 20·59 = 1180`, and
`1180 mod 9 = 1`.  ✓.  Base 12: `(x-1)(y-1) ≡ 1 (mod 11)`.

Analysis (Analyst): the proof needs the `ℕ → ℤ` transfer of `Nat.ModEq`
(`exact_mod_cast`), the cast identity `↑(b-1) = ↑b - 1` for `b ≥ 1`, and a `ring`
rearrangement.  The only subtlety is truncated `ℕ`-subtraction inside the modulus,
handled by `Nat.cast_sub`.

Critique (Critic): not a definitional `rfl` — the statement mixes `ℤ`
multiplication with a congruence transported from `ℕ`, and the proof genuinely
uses `Int.ModEq` algebra (`sub_right`, `add_right`) plus `ring`.  The hypothesis
`2 ≤ b` is load-bearing (it makes `↑(b-1) = ↑b - 1`).

Synthesis: the unit reformulation upgrades the additive vampire law to a
multiplicative unit condition, tying the digit combinatorics to the group of
units modulo `b - 1`.
-- !-- end Lab Notes -- !--
-/

open Bestiary
Formal statement
theorem Bestiary.fangPair_int_congr(b x y : ℕ) (hb : 2 ≤ b) (h : IsFangPair b x y) :
    ((x : ℤ) - 1) * ((y : ℤ) - 1) ≡ 1 [ZMOD ((b : ℤ) - 1)] := by sorry
Source
https://github.com/paulklemstine/Lean/blob/53c2925a02/Catalog/Novelty/VampireCongruence.lean#L43

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me