Decide the marked nonnegative subspace test on complementary real bases
OpenSmaleNinth.real_complementary_marked_deciderFor complementary real row bases on the ordinary tape, construct one deterministic native RAM that determines whether the first row space contains a nonnegative vector with positive first coordinate. The instruction count is polynomial in ambient dimension, independently of all scalar entries.
Preamble
import Definitions.Def_OAILP_Geometry_GramEncoding import Definitions.Def_OAILP_RAM_Basic import Mathlib.Data.Real.Basic import Mathlib.LinearAlgebra.Matrix.Rank open Matrix OAI.Optimization.LinearProgramming OAI.Optimization.LinearProgramming.Geometry open scoped Matrix
Formal statement
theorem SmaleNinth.real_complementary_marked_decider :
∃ (p : RAM.Program) (c e : ℕ), ∀ (r s : ℕ) (hn : 0 < r+s)
(D : Matrix (Fin r) (Fin (r+s)) ℝ) (E : Matrix (Fin s) (Fin (r+s)) ℝ),
LinearIndependent ℝ D.row → LinearIndependent ℝ E.row → D*Eᵀ = 0 →
∃ k, ∃ tr : Fin (k+1) → RAM.State ℝ, k ≤ RAM.polyBound c e (r+s) ∧
RAM.Trace p (RAM.start [r,s] (encodedGramInput D++encodedGramInput E)) k tr ∧
∃ bit : Bool, (tr (Fin.last k)).output = some bit.toNat ∧
(bit = true ↔ ∃ z ∈ Submodule.span ℝ (Set.range D.row), 0 ≤ z ∧ 0 < z ⟨0,hn⟩) := by sorrySource