Valence
Valence is the inductive type with three constructors that labels harmonic intervals or experience states by the sign of their ledger skew. Music theorists and chemists cite it when mapping ratios to positive or negative deviations and when counting valence electrons in shell closures. The declaration is a direct inductive enumeration that derives decidable equality and representation instances with no further proof obligations.
claimLet $V$ be the inductive type whose elements are the three constructors positive, negative, and neutral.
background
The MusicTheory.Valence module works with real ratios $r$ that represent musical intervals. The sibling function ledgerSkew satisfies ledgerSkew(1) = 0, ledgerSkew(r) > 0 for r > 1, ledgerSkew(r) < 0 for r < 1, and ledgerSkew(1/r) = -ledgerSkew(r). classifyValence thresholds these skew values to return an element of Valence. The module imports HarmonicModes and Mathlib; it has no upstream theorem dependencies.
proof idea
The declaration is a direct inductive definition that introduces the three nullary constructors and lets Lean derive the DecidableEq and Repr instances automatically.
why it matters in Recognition Science
classifyValence consumes Valence to assign discrete labels to interval ratios. distToNextClosure in PeriodicTable uses the same type to mark noble-gas closures where valence equals period length. QualiaSpace in UltimateIsomorphism includes a valence field of type State → ℝ that is discretized via this type. The definition therefore supplies the discrete sign axis that links the eight-tick harmonic octave to chemical periodicity and to qualia modeling.
scope and limits
- Does not define any arithmetic operations on its constructors.
- Does not embed numerical thresholds or skew functions inside the type.
- Does not relate valence constructors to specific interval ratios such as majorThird.
- Does not enforce any ordering or lattice structure on the three cases.
formal statement (Lean)
81inductive Valence
82 | positive
83 | negative
84 | neutral
85 deriving DecidableEq, Repr
86