Encyclopedia Cost Cost Ndim Xcoordinates Det X Hessian Matrix2 Ne Zero Of Generic
ARTICLE 2 claims 2 theorems
Cost Ndim Xcoordinates Det X Hessian Matrix2 Ne Zero Of Generic
A machine-checked theorem identifies exactly when a two-component cost model's curvature matrix stays invertible, and when it collapses.
A nondegeneracy condition
In the Recognition Science framework, a cost function assigns a nonnegative number to each possible state of a system, and the framework's central theorem forces that cost to take a specific form. For a system described by two positive coordinates, the curvature of this cost is encoded in a 2 by 2 matrix called the Hessian. The determinant of that matrix, a single number computed from its entries, tells whether the curvature is genuinely two-dimensional or whether it flattens out along some direction.
The declaration det_xHessianMatrix2_ne_zero_of_generic proves a precise condition for this determinant to be nonzero. The theorem states that if both coordinates are nonzero, if the two weights are nonzero, if the weighted aggregate R = a x + b y is not equal to 1, and if a secondary algebraic expression involving the weights and R is also nonzero, then the determinant is nonzero. In plain terms, away from a specific neutral locus and away from a secondary discriminant surface, the cost curvature is nondegenerate: it has full rank and no flat direction.
The theorem's companion result, det_xHessianMatrix2_zero_cost, shows what happens at the neutral locus where R = 1: the determinant vanishes. At that point the Hessian collapses to a rank-one outer product, meaning the curvature flattens along one direction. Together the two theorems delimit the generic case from the degenerate one. The framework's library proves these statements in a machine-checked formal system, so the algebra is verified beyond hand calculation.
What the declaration does not claim is equally important. It does not assert that the Hessian is positive definite, only that its determinant is nonzero; the matrix could have mixed curvature signs. It does not describe the behavior of the cost function itself, only the local curvature at a point. And it does not extend to systems with more than two coordinates; the determinant formula is specific to the 2 by 2 case. The theorem is a local algebraic fact about the model's geometry, not a statement about global minima or dynamics.
THEOREM det_xHessianMatrix2_ne_zero_of_generic · IndisputableMonolith/Cost/Ndim/XCoordinates.lean
/-- Away from the neutral locus and the secondary discriminant factor, the
`2 × 2` `x`-coordinate Hessian is nondegenerate. -/
theorem det_xHessianMatrix2_ne_zero_of_generic (a b x y : ℝ)
(hx : x ≠ 0) (hy : y ≠ 0)
(ha : a ≠ 0) (hb : b ≠ 0)
(hR1 : aggregate (vec2 a b) (vec2 x y) ≠ 1)
(hdisc :
(aggregate (vec2 a b) (vec2 x y)) ^ 2 * a
+ (aggregate (vec2 a b) (vec2 x y)) ^ 2 * b
- (aggregate (vec2 a b) (vec2 x y)) ^ 2
+ a + b + 1 ≠ 0) :
Matrix.det (xHessianMatrix2 a b x y) ≠ 0 := by
let R := aggregate (vec2 a b) (vec2 x y)
have hR : R ≠ 0 := (aggregate_pos (vec2 a b) (vec2 x y)).ne'
have hRp1 : R + 1 ≠ 0 := by
have hpos : 0 < R := by simp [R]
linarith
have hden : 4 * R ^ 2 * x ^ 2 * y ^ 2 ≠ 0 := by
have hR2 : R ^ 2 ≠ 0 := pow_ne_zero 2 hR
have hx2 : x ^ 2 ≠ 0 := pow_ne_zero 2 hx
have hy2 : y ^ 2 ≠ 0 := pow_ne_zero 2 hy
have h4R : 4 * R ^ 2 ≠ 0 := mul_ne_zero (by norm_num) hR2
have h4Rx : 4 * R ^ 2 * x ^ 2 ≠ 0 := mul_ne_zero h4R hx2
exact mul_ne_zero h4Rx hy2
rw [det_xHessianMatrix2_formula a b x y hx hy]
refine div_ne_zero ?_ hden
refine neg_ne_zero.mpr ?_
refine mul_ne_zero ?_ hdisc
refine mul_ne_zero ?_ hRp1
refine mul_ne_zero ?_ (sub_ne_zero.mpr hR1)
exact mul_ne_zero ha hb
THEOREM det_xHessianMatrix2_zero_cost · IndisputableMonolith/Cost/Ndim/XCoordinates.lean
/-- The neutral locus `aggregate = 1` is a degeneracy locus in the `2 × 2`
model. -/
theorem det_xHessianMatrix2_zero_cost (a b x y : ℝ)
(hx : x ≠ 0) (hy : y ≠ 0)
(hR : aggregate (vec2 a b) (vec2 x y) = 1) :
Matrix.det (xHessianMatrix2 a b x y) = 0 := by
rw [det_xHessianMatrix2_formula a b x y hx hy]
simp [hR]
What this page does not claim
The theorem does not assert positive definiteness of the Hessian, only a nonzero determinant. The theorem does not describe the cost function's global behavior, only its local curvature at a point. The theorem does not extend to systems with more than two coordinates.
Verify this page
Every tagged claim above names its theorem. To check one yourself rather than trust this page, elaborate the source module with Lean 4 and audit its axiom basis:
$ lake env lean IndisputableMonolith/Cost/Ndim/XCoordinates.lean
expected axiom basis: [propext, Classical.choice, Quot.sound] (the Lean kernel's standard three; no RS-specific axioms)
A page whose claims cannot be reproduced this way does not ship. In production, every anchor links to the exact declaration in the public source release, and this block carries the build receipt for the page itself.
Derived articles
This page is generated by a question-recursion engine: the questions its answers raise become the next pages. The current agenda, with open targets marked red:
- What geometric or dynamical significance does the nondegeneracy of the Hessian carry for the cost function's critical points?
- Does the secondary discriminant factor in the determinant formula have an independent interpretation in the framework?
- How does the determinant formula generalize to three or more coordinates, if at all?
MACHINE LAYER · GROUNDED CLAIM TABLE · CLICK TO EXPAND
THEOREM det_xHessianMatrix2_ne_zero_of_generic · IndisputableMonolith/Cost/Ndim/XCoordinates.lean
/-- Away from the neutral locus and the secondary discriminant factor, the `2 × 2` `x`-coordinate Hessian is nondegenerate. -/ theorem det_xHessianMatrix2_ne_zero_of_generic (a b x y : ℝ) (hx : x ≠ 0) (hy : y ≠ 0) (ha : a ≠ 0) (hb : b ≠ 0) (hR1 : aggregate (vec2 a b) (vec2 x y) ≠ 1) (hdisc : (aggregate (vec2 a b) (vec2 x y)) ^ 2 * a + (aggregate (vec2 a b) (vec2 x y)) ^ 2 * b - (aggregate (vec2 a b) (vec2 x y)) ^ 2 + a + b + 1 ≠ 0) : Matrix.det (xHessianMatrix2 a b x y) ≠ 0 := by let R := aggregate (vec2 a b) (vec2 x y) have hR : R ≠ 0 := (aggregate_pos (vec2 a b) (vec2 x y)).ne' have hRp1 : R + 1 ≠ 0 := by have hpos : 0 < R := by simp [R] linarith have hden : 4 * R ^ 2 * x ^ 2 * y ^ 2 ≠ 0 := by have hR2 : R ^ 2 ≠ 0 := pow_ne_zero 2 hR have hx2 : x ^ 2 ≠ 0 := pow_ne_zero 2 hx have hy2 : y ^ 2 ≠ 0 := pow_ne_zero 2 hy have h4R : 4 * R ^ 2 ≠ 0 := mul_ne_zero (by norm_num) hR2 have h4Rx : 4 * R ^ 2 * x ^ 2 ≠ 0 := mul_ne_zero h4R hx2 exact mul_ne_zero h4Rx hy2 rw [det_xHessianMatrix2_formula a b x y hx hy] refine div_ne_zero ?_ hden refine neg_ne_zero.mpr ?_ refine mul_ne_zero ?_ hdisc refine mul_ne_zero ?_ hRp1 refine mul_ne_zero ?_ (sub_ne_zero.mpr hR1) exact mul_ne_zero ha hbThe theorem states that if both coordinates are nonzero, if the two weights are nonzero, if the weighted aggregate R = a x + b y is not equal to 1, and if a secondary algebraic expression involving the weights and R is also nonzero, then the determinant is nonzero. det_xHessianMatrix2_ne_zero_of_generic · IndisputableMonolith/Cost/Ndim/XCoordinates.leanTHEOREM det_xHessianMatrix2_zero_cost · IndisputableMonolith/Cost/Ndim/XCoordinates.lean
/-- The neutral locus `aggregate = 1` is a degeneracy locus in the `2 × 2` model. -/ theorem det_xHessianMatrix2_zero_cost (a b x y : ℝ) (hx : x ≠ 0) (hy : y ≠ 0) (hR : aggregate (vec2 a b) (vec2 x y) = 1) : Matrix.det (xHessianMatrix2 a b x y) = 0 := by rw [det_xHessianMatrix2_formula a b x y hx hy] simp [hR]At that point the Hessian collapses to a rank-one outer product, meaning the curvature flattens along one direction. det_xHessianMatrix2_zero_cost · IndisputableMonolith/Cost/Ndim/XCoordinates.lean