Call budgets of programs over one side of a sum #
A program over spec₁, embedded in spec₁ ⊕ₒ spec₂ by OracleComp.liftLeft, makes only left
calls. A budget for its calls therefore bounds the embedded program under any cost on the sum
that charges each left call at most its original cost (IsCostBounded.liftLeft); in particular,
the embedded program makes no call that a cost charging nothing on the left counts. The same
holds on the right (IsCostBounded.liftRight).
Main results #
Cslib.OracleComp.IsCostBounded.liftLeft,Cslib.OracleComp.IsCostBounded.liftRight: budgets transfer to embedded programs.Cslib.OracleComp.IsCostBounded.liftLeft_of_cost_inl_eq_zero,Cslib.OracleComp.IsCostBounded.liftRight_of_cost_inr_eq_zero: an embedded program has zero cost on the other side.
A budget n for a left program under cost₁ is a budget for its embedding under every cost
on the sum charging each left call .inl q at most cost₁ q.
A budget n for a right program under cost₂ is a budget for its embedding under every cost
on the sum charging each right call .inr q at most cost₂ q.
A left program makes no call that a cost charging nothing on the left counts.
A right program makes no call that a cost charging nothing on the right counts.