Documentation

CslibFrontier.Algorithms.WordRAM.TreeDecomposition.CSP.Join

Word-RAM join node handler #

This module certifies joinNodeProg (along with the private loop joinFillProg). It combines left and right child DP tables entrywise by projecting each left-bag assignment onto the right child bag via radixProjProg, and has no dependency on BagOps, ConstraintScan, LeafIntro, or Forget.

Main definitions #

Main results #

4. Join node handler (joinFillProg, joinNodeProg) #

Register arguments for the join node handler joinNodeProg.

  • q : ℕ

    Domain size q.

  • dLeft : ℕ

    Base address of the left child's 4-word descriptor slot.

  • dRight : ℕ

    Base address of the right child's 4-word descriptor slot.

  • dCur : ℕ

    Base address of the current node's 4-word descriptor slot.

Instances For

    Combine two child DP tables entrywise via radixProjProg and write the descriptor for a join node.

    theorem Cslib.Algorithms.WordRAM.TreeDecomposition.joinNodeProg_spec {w F_lo : ℕ} (counting : Bool) (a : JoinNodeArgs) (hq : 0 < a.q) {left right : SimpleGraph.NiceTree ℕ} {cs : List (ConstraintTable a.q)} {vars : List ℕ} {s : DataStructure.Memory.State} (hleft : NodeDescAt F_lo counting a.q cs vars left a.dLeft s) (hright : NodeDescAt F_lo counting a.q cs vars right a.dRight s) (hdCur : a.dCur + 4 ≤ F_lo) (hFlo : F_lo ≤ s.frontier) (hfit_peak : WordRAM.Fits w (s.frontier + a.q ^ (Lean.TreeDecomposition.bagList left).length)) (hfit_cap : WordRAM.Fits w (if counting = true then a.q ^ activeForgetCount vars (left.join right) else 1)) :

    Memory validity, framing, NodeDescAt, and cost bound for joinNodeProg.