Documentation

Complexitylib.Classes.PPoly.Uniform.Unrolling.Generator.Primitive.Internal

Direct-unrolling generator primitives -- proof internals #

theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareRecentReference_spaceBoundByWidth_internal (reference : Fin WorkCount) (offset : ) {initialSpace : } {values : BinaryValues WorkCount} {width : } (havailable : ∀ (inputLength : ), values inputLength Work.available width inputLength) (hreference : ∀ (inputLength : ), values inputLength reference width inputLength) (hoffset : ∀ (inputLength : ), offset values inputLength Work.available) :
(prepareRecentReference reference offset).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareRecentReference_requires_internal (reference : Fin WorkCount) (offset : ) (values : BinaryValues WorkCount) (havailableReference : Work.available reference) (havailableCounter : Work.available Work.copyCounter) (hreferenceCounter : reference Work.copyCounter) :
(prepareRecentReference reference offset).requires values values Work.copyCounter = 0 offset values Work.available
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitRecentGate_sound_internal (op : AndOrOp) (negated₀ negated₁ : Bool) (offset₀ offset₁ : ) :
(emitRecentGate op negated₀ negated₁ offset₀ offset₁).Sound
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitRecentGate_requires_internal (op : AndOrOp) (negated₀ negated₁ : Bool) (offset₀ offset₁ : ) (values : BinaryValues WorkCount) :
(emitRecentGate op negated₀ negated₁ offset₀ offset₁).requires values values Work.copyCounter = 0 offset₀ values Work.available offset₁ values Work.available values Work.emitCounter = 0
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitRecentGate_effect_internal (op : AndOrOp) (negated₀ negated₁ : Bool) (offset₀ offset₁ : ) (values : BinaryValues WorkCount) :
(emitRecentGate op negated₀ negated₁ offset₀ offset₁).effect values = Function.update (Function.update (Function.update values Work.available (values Work.available + 1)) Work.reference₀ 0) Work.reference₁ 0
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitRecentGate_spaceBoundByWidth_internal (op : AndOrOp) (negated₀ negated₁ : Bool) (offset₀ offset₁ : ) {initialSpace : } {values : BinaryValues WorkCount} {width : } (havailable : ∀ (inputLength : ), values inputLength Work.available width inputLength) (hreference₀ : ∀ (inputLength : ), values inputLength Work.reference₀ width inputLength) (hreference₁ : ∀ (inputLength : ), values inputLength Work.reference₁ width inputLength) (hoffset₀ : ∀ (inputLength : ), offset₀ values inputLength Work.available) (hoffset₁ : ∀ (inputLength : ), offset₁ values inputLength Work.available) :
(emitRecentGate op negated₀ negated₁ offset₀ offset₁).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitRecentGate_emitted_internal (op : AndOrOp) (negated₀ negated₁ : Bool) (offset₀ offset₁ : ) (values : BinaryValues WorkCount) :
(emitRecentGate op negated₀ negated₁ offset₀ offset₁).emitted values = { op := op, input₀ := values Work.available - offset₀, input₁ := values Work.available - offset₁, negated₀ := negated₀, negated₁ := negated₁ }.encode
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareStateReference_spaceBoundByWidth_internal (stateIndex : ) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionStateRef (values inputLength Work.configBase) stateIndex width inputLength) :
(prepareStateReference stateIndex).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareHeadReference_spaceBoundByWidth_internal (stateCount : ) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionHeadRef stateCount (values inputLength Work.horizon) (values inputLength Work.configBase) (values inputLength Work.tapeIndex) (values inputLength Work.position) + values inputLength Work.tapeIndex + values inputLength Work.horizon + 1 width inputLength) :
(prepareHeadReference stateCount).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareCellReference_requires_internal (stateCount tapeCount : ) (values : BinaryValues WorkCount) (hcopy : values Work.copyCounter = 0) (hadd : values Work.addCounter = 0) (hmultiply : values Work.multiplyCounter = 0) :
(prepareCellReference stateCount tapeCount).requires values
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.prepareCellReference_spaceBoundByWidth_internal (stateCount tapeCount : ) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionCellRef stateCount tapeCount (values inputLength Work.horizon) (values inputLength Work.configBase) (values inputLength Work.tapeIndex) (values inputLength Work.position) (values inputLength Work.symbolIndex) + (values inputLength Work.tapeIndex * (values inputLength Work.horizon + 2) + values inputLength Work.position) + (values inputLength Work.horizon + 2) + tapeCount + values inputLength Work.tapeIndex + 4 width inputLength) :
(prepareCellReference stateCount tapeCount).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitStateReference_spaceBoundByWidth_internal (stateIndex : ) (negated : Bool) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionStateRef (values inputLength Work.configBase) stateIndex width inputLength) :
(emitStateReference stateIndex negated).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitHeadReference_spaceBoundByWidth_internal (stateCount : ) (negated : Bool) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionHeadRef stateCount (values inputLength Work.horizon) (values inputLength Work.configBase) (values inputLength Work.tapeIndex) (values inputLength Work.position) + values inputLength Work.tapeIndex + values inputLength Work.horizon + 1 width inputLength) :
(emitHeadReference stateCount negated).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitCellReference_spaceBoundByWidth_internal (stateCount tapeCount : ) (negated : Bool) {initialSpace : } {values : BinaryValues WorkCount} {width : } (hvalues : ∀ (inputLength : ) (index : Fin WorkCount), values inputLength index width inputLength) (hcap : ∀ (inputLength : ), transitionCellRef stateCount tapeCount (values inputLength Work.horizon) (values inputLength Work.configBase) (values inputLength Work.tapeIndex) (values inputLength Work.position) (values inputLength Work.symbolIndex) + (values inputLength Work.tapeIndex * (values inputLength Work.horizon + 2) + values inputLength Work.position) + (values inputLength Work.horizon + 2) + tapeCount + values inputLength Work.tapeIndex + 4 width inputLength) :
(emitCellReference stateCount tapeCount negated).SpaceBoundByWidthAt initialSpace values width
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitHeadReference_requires_internal (stateCount : ) (negated : Bool) (values : BinaryValues WorkCount) (hadd : values Work.addCounter = 0) (hmultiply : values Work.multiplyCounter = 0) (hemit : values Work.emitCounter = 0) :
(emitHeadReference stateCount negated).requires values
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitCellReference_requires_internal (stateCount tapeCount : ) (negated : Bool) (values : BinaryValues WorkCount) (hcopy : values Work.copyCounter = 0) (hadd : values Work.addCounter = 0) (hmultiply : values Work.multiplyCounter = 0) (hemit : values Work.emitCounter = 0) :
(emitCellReference stateCount tapeCount negated).requires values
theorem Complexity.CircuitUnrolling.Serializer.DirectGenerator.emitCellReference_emitted_internal (stateCount tapeCount : ) (negated : Bool) (values : BinaryValues WorkCount) :
(emitCellReference stateCount tapeCount negated).emitted values = (CircuitCode.RawGate.copy (transitionCellRef stateCount tapeCount (values Work.horizon) (values Work.configBase) (values Work.tapeIndex) (values Work.position) (values Work.symbolIndex)) negated).encode