NLA-lib Explorer

NLAlib.Ops.StoredScalar.full_laws

Library Β· theorem

The composed lowering supplies every higher primitive law from a scalar-only model and a leaf tree that, as a matrix-vector routine (NLAlib.Ops.StoredOperator.matvecRoutine), meets the specification read off the stored-operator contract. No whole-program execution is a premise.

NLAlib.Ops.StoredScalar.full_laws {π•œ : Type} [RCLike π•œ]
  {I : Ops.Interp Ops.ScalarOnly.Operation Ops.CmpTst π•œ} {dataLength : β„• β†’ β„• β†’ β„•}
  {matrix : (m n : β„•) β†’ List π•œ β†’ Matrix (Fin m) (Fin n) π•œ}
  (body : Ops.Stmt Ops.ScalarOnly.Operation Ops.CmpTst) (hS : Ops.IsScalar Ops.RCLikeBlas.machine I)
  (hStar : Ops.RCLikeStar.IsExact I) (hDraw : Ops.IsSample I)
  (hIndex : Ops.IsIndexLit Ops.RCLikeBlas.machine I) (hCmp : Ops.IsCmp (⇑RCLike.re) I)
  (hLeaf :
    (Ops.StoredOperator.matvecRoutine dataLength body).Meets I
      (Ops.Routine.Spec.ofRel
        (Ops.StoredOperator.functions dataLength matrix Ops.StoredOperatorOp.matvec).rel fun x ↦
        True)) :
  have J :=
    I.link
      (Ops.ExactLinearScalar.table.comp
        (Ops.StoredScalar.table (Ops.StoredOperator.matvecRoutine dataLength body)));
  Ops.IsScalar Ops.RCLikeBlas.machine J ∧
    Ops.RCLikeBlas.IsExact J ∧
      Ops.StoredOperator.IsExact dataLength matrix J ∧
        Ops.IsSample J ∧ Ops.IsIndexLit Ops.RCLikeBlas.machine J ∧ Ops.IsCmp (⇑RCLike.re) J

Full source on GitHub

Import NLAlib.Ops.Profiles.StoredScalar.