Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/lean_action_ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
- uses: actions/checkout@v4
- name: Test documentation checker
run: python3 -m unittest discover -s scripts -p 'test_*.py'
- name: "Source hygiene"
run: python3 -B scripts/check_hygiene.py --check-simp
- uses: leanprover/lean-action@v1
with:
build-args: "--wfail --iofail @complexitylib @mathlib/mk_all @/checkInitImports @mathlib/lint-style"
Expand Down
5 changes: 4 additions & 1 deletion Complexity/Computability/Circuit/Boolean/CarryLookahead.lean
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,10 @@ def step (k distance : ℕ) : Circuit signature (k + k) (k + k) :=
(Circuit.pi fun i => (propagateFormula k distance i).toCircuit)

@[simp] theorem size_step (k distance : ℕ) : (step k distance).size = 3 * k := by
simp [step, generateFormula, propagateFormula, Formula.size_toCircuit]
simp only [step, generateFormula, Fin.natAdd_eq_addNat, propagateFormula, Circuit.size_append,
Circuit.size_pi, Formula.size_toCircuit, Formula.size_or, Formula.size_input, Formula.size_and,
add_zero, zero_add, Nat.reduceAdd, Finset.sum_const, Finset.card_univ, Fintype.card_fin,
smul_eq_mul, mul_one]
omega

theorem depth_step_le (k distance : ℕ) : (step k distance).depth ≤ 2 := by
Expand Down
Loading