Current library: Alpha v34, 4,223 checked-use theorems; Stable remains 432. Historical first admissions, original proof editions, and non-admitted aliases are preserved. Exact original first-admission records.
Statement with defined notation
∀ b. ∀ c. ∀ z. ∀ e. ∀ l. ∀ n. ∀ m. BitCount(b,c,l,n) → BitCount(z,e,l,m) → (∀ x. ∀ y. ∀ k. Lt(x,l) → BetaAt(b,c,x,y) → BetaAt(z,e,x,k) → y = 0 ∧ k = 1 ∨ y = 1 ∧ k = 0) → n + m = lEvery purple notation token opens its conservative definition. This is a reading surface; the compiler expands the statement before the unchanged kernel checks it.
Definitions used by this theorem
In the theorem statement
5 occurrences
In local proof propositions
7 occurrences
Exact expanded native-PA statement
forall b c z e l n m. (((exists ff_u_complement_left_sum ff_v_complement_left_sum. ((((exists ff_h_complement_left_sum_start. ff_h_complement_left_sum_start + S (0) = S ((S (0)) * ff_v_complement_left_sum)) /\ exists ff_q_complement_left_sum_start. ff_u_complement_left_sum = ff_q_complement_left_sum_start * S ((S (0)) * ff_v_complement_left_sum) + (0))) /\ ((((exists ff_h_complement_left_sum_terminal. ff_h_complement_left_sum_terminal + S (n) = S ((S (l)) * ff_v_complement_left_sum)) /\ exists ff_q_complement_left_sum_terminal. ff_u_complement_left_sum = ff_q_complement_left_sum_terminal * S ((S (l)) * ff_v_complement_left_sum) + (n))) /\ forall ff_i_complement_left_sum. (exists ff_lt_complement_left_sum_bound. ff_lt_complement_left_sum_bound + S ff_i_complement_left_sum = l) -> exists ff_a_complement_left_sum ff_r_complement_left_sum ff_s_complement_left_sum. ((((exists ff_h_complement_left_sum_summand. ff_h_complement_left_sum_summand + S (ff_a_complement_left_sum) = S ((S (ff_i_complement_left_sum)) * c)) /\ exists ff_q_complement_left_sum_summand. b = ff_q_complement_left_sum_summand * S ((S (ff_i_complement_left_sum)) * c) + (ff_a_complement_left_sum))) /\ ((((exists ff_h_complement_left_sum_partial. ff_h_complement_left_sum_partial + S (ff_r_complement_left_sum) = S ((S (ff_i_complement_left_sum)) * ff_v_complement_left_sum)) /\ exists ff_q_complement_left_sum_partial. ff_u_complement_left_sum = ff_q_complement_left_sum_partial * S ((S (ff_i_complement_left_sum)) * ff_v_complement_left_sum) + (ff_r_complement_left_sum))) /\ ((((exists ff_h_complement_left_sum_successor. ff_h_complement_left_sum_successor + S (ff_s_complement_left_sum) = S ((S (S ff_i_complement_left_sum)) * ff_v_complement_left_sum)) /\ exists ff_q_complement_left_sum_successor. ff_u_complement_left_sum = ff_q_complement_left_sum_successor * S ((S (S ff_i_complement_left_sum)) * ff_v_complement_left_sum) + (ff_s_complement_left_sum))) /\ ff_s_complement_left_sum = ff_r_complement_left_sum + ff_a_complement_left_sum)))))) /\ (forall ff_i_complement_left_bits. (exists ff_lt_complement_left_bits_bound. ff_lt_complement_left_bits_bound + S ff_i_complement_left_bits = l) -> exists ff_bit_complement_left_bits. ((((exists ff_h_complement_left_bits_decoded. ff_h_complement_left_bits_decoded + S (ff_bit_complement_left_bits) = S ((S (ff_i_complement_left_bits)) * c)) /\ exists ff_q_complement_left_bits_decoded. b = ff_q_complement_left_bits_decoded * S ((S (ff_i_complement_left_bits)) * c) + (ff_bit_complement_left_bits))) /\ (ff_bit_complement_left_bits = 0 \/ ff_bit_complement_left_bits = 1))))) -> (((exists ff_u_complement_right_sum ff_v_complement_right_sum. ((((exists ff_h_complement_right_sum_start. ff_h_complement_right_sum_start + S (0) = S ((S (0)) * ff_v_complement_right_sum)) /\ exists ff_q_complement_right_sum_start. ff_u_complement_right_sum = ff_q_complement_right_sum_start * S ((S (0)) * ff_v_complement_right_sum) + (0))) /\ ((((exists ff_h_complement_right_sum_terminal. ff_h_complement_right_sum_terminal + S (m) = S ((S (l)) * ff_v_complement_right_sum)) /\ exists ff_q_complement_right_sum_terminal. ff_u_complement_right_sum = ff_q_complement_right_sum_terminal * S ((S (l)) * ff_v_complement_right_sum) + (m))) /\ forall ff_i_complement_right_sum. (exists ff_lt_complement_right_sum_bound. ff_lt_complement_right_sum_bound + S ff_i_complement_right_sum = l) -> exists ff_a_complement_right_sum ff_r_complement_right_sum ff_s_complement_right_sum. ((((exists ff_h_complement_right_sum_summand. ff_h_complement_right_sum_summand + S (ff_a_complement_right_sum) = S ((S (ff_i_complement_right_sum)) * e)) /\ exists ff_q_complement_right_sum_summand. z = ff_q_complement_right_sum_summand * S ((S (ff_i_complement_right_sum)) * e) + (ff_a_complement_right_sum))) /\ ((((exists ff_h_complement_right_sum_partial. ff_h_complement_right_sum_partial + S (ff_r_complement_right_sum) = S ((S (ff_i_complement_right_sum)) * ff_v_complement_right_sum)) /\ exists ff_q_complement_right_sum_partial. ff_u_complement_right_sum = ff_q_complement_right_sum_partial * S ((S (ff_i_complement_right_sum)) * ff_v_complement_right_sum) + (ff_r_complement_right_sum))) /\ ((((exists ff_h_complement_right_sum_successor. ff_h_complement_right_sum_successor + S (ff_s_complement_right_sum) = S ((S (S ff_i_complement_right_sum)) * ff_v_complement_right_sum)) /\ exists ff_q_complement_right_sum_successor. ff_u_complement_right_sum = ff_q_complement_right_sum_successor * S ((S (S ff_i_complement_right_sum)) * ff_v_complement_right_sum) + (ff_s_complement_right_sum))) /\ ff_s_complement_right_sum = ff_r_complement_right_sum + ff_a_complement_right_sum)))))) /\ (forall ff_i_complement_right_bits. (exists ff_lt_complement_right_bits_bound. ff_lt_complement_right_bits_bound + S ff_i_complement_right_bits = l) -> exists ff_bit_complement_right_bits. ((((exists ff_h_complement_right_bits_decoded. ff_h_complement_right_bits_decoded + S (ff_bit_complement_right_bits) = S ((S (ff_i_complement_right_bits)) * e)) /\ exists ff_q_complement_right_bits_decoded. z = ff_q_complement_right_bits_decoded * S ((S (ff_i_complement_right_bits)) * e) + (ff_bit_complement_right_bits))) /\ (ff_bit_complement_right_bits = 0 \/ ff_bit_complement_right_bits = 1))))) -> (forall i a d. (exists h. h + S i = l) -> (((exists ff_h_complement_left_entry. ff_h_complement_left_entry + S (a) = S ((S (i)) * c)) /\ exists ff_q_complement_left_entry. b = ff_q_complement_left_entry * S ((S (i)) * c) + (a))) -> (((exists ff_h_complement_right_entry. ff_h_complement_right_entry + S (d) = S ((S (i)) * e)) /\ exists ff_q_complement_right_entry. z = ff_q_complement_right_entry * S ((S (i)) * e) + (d))) -> ((a = 0 /\ d = 1) \/ (a = 1 /\ d = 0))) -> n + m = lProof neighborhood
Direct theorem prerequisites
PA0048 bit_count_zero PA0042 bit_count_succ_decompose PA002O le_succ PA001A le_refl PA000E add_succ_leftDirect theorem dependents
Definition-aware tactic body
Only local propositions introduced by have or suffices are compacted. The untrusted compiler re-expands each one before the original tactic script is replayed; defined notation is never accepted by the kernel. Open the exact replay line beneath every changed command.
Read the argument
Proof checkpoints
This is a reading aid, not a new proof or a proof-tree certificate. Checkpoint groups are consecutive commands, not inferred branch boundaries. Every step links to the preserved script.
Named ingredients (5)
01Fix variables and assumptionsL1–4
02Induction on lL5–10
03Establish hnL11–18
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply bit count zero.
04Establish hmL19–28
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply bit count zero.
05Calculate and transport equalitiesL29–29
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L29
simp
06Fix variables and assumptionsL30–34
07Establish hleft_decompL35–43
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply bit count succ decompose.
- L35
have hleft_decomp : ∃ a. ∃ r. BetaAt(b,c,l,a) ∧ (BitCount(b,c,l,r) ∧ ((a = 0 ∨ a = 1) ∧ n = r + a))Definitions: BetaAt(b,c,l,a)BitCount(b,c,l,r)Original native command in the exact edition - L36
specialize bit_count_succ_decompose b - L37
specialize bit_count_succ_decompose c - L38
specialize bit_count_succ_decompose l - L39
specialize bit_count_succ_decompose (S l) - L40
specialize bit_count_succ_decompose n - L41
apply bit_count_succ_decompose - L42
refl - L43
exact hleft
08Separate the logical casesL44–48
09Establish hright_decompL49–57
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply bit count succ decompose.
- L49
have hright_decomp : ∃ d. ∃ s. BetaAt(z,e,l,d) ∧ (BitCount(z,e,l,s) ∧ ((d = 0 ∨ d = 1) ∧ m = s + d))Definitions: BetaAt(z,e,l,d)BitCount(z,e,l,s)Original native command in the exact edition - L50
specialize bit_count_succ_decompose z - L51
specialize bit_count_succ_decompose e - L52
specialize bit_count_succ_decompose l - L53
specialize bit_count_succ_decompose (S l) - L54
specialize bit_count_succ_decompose m - L55
apply bit_count_succ_decompose - L56
refl - L57
exact hright
10Separate the logical casesL58–62
11Establish hprefix_complementL63–72
Establish this local claim before using it. It is not an additional assumption.
- L63
have hprefix_complement : ∀ i. ∀ a. ∀ d. Lt(i,l) → BetaAt(b,c,i,a) → BetaAt(z,e,i,d) → a = 0 ∧ d = 1 ∨ a = 1 ∧ d = 0Definitions: Lt(i,l)BetaAt(b,c,i,a)BetaAt(z,e,i,d)Original native command in the exact edition - L64
intro i - L65
intro a - L66
intro d - L67
intro hi - L68
intro ha - L69
intro hd - L70
specialize hcomplement i - L71
specialize hcomplement a - L72
specialize hcomplement d
12Use earlier factsL73–79
13Establish hprefixL80–86
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply IH.
14Establish hlastL87–96
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply hcomplement.
- L87
have hlast : ((x = 0 /\ x2 = 1) \/ (x = 1 /\ x2 = 0)) - L88
specialize hcomplement l - L89
specialize hcomplement x - L90
specialize hcomplement x2 - L91
apply hcomplement - L92
specialize le_refl (S l) - L93
exact le_refl - L94
exact hleft_decomp_witness_witness_left - L95
exact hright_decomp_witness_witness_left - L96
rewrite hleft_decomp_witness_witness_right_right_right
15Calculate and transport equalitiesL97–97
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L97
rewrite hright_decomp_witness_witness_right_right_right
16Separate the logical casesL98–99
17Calculate and transport equalitiesL100–102
18Separate the logical casesL103–103
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L103
cases hlast_right
19Calculate and transport equalitiesL104–106
20Use earlier factsL107–108
21Calculate and transport equalitiesL109–109
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L109
trans S (x1 + x3)
22Use earlier factsL110–110
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L110
exact add_succ_left
Original defined command ledger · 112 lines
- 0001
intro b - 0002
intro c - 0003
intro z - 0004
intro e - 0005
induction l - 0006
intro n - 0007
intro m - 0008
intro hleft - 0009
intro hright - 0010
intro hcomplement - 0011
have hn : n = 0 - 0012
specialize bit_count_zero b - 0013
specialize bit_count_zero c - 0014
specialize bit_count_zero 0 - 0015
specialize bit_count_zero n - 0016
apply bit_count_zero - 0017
refl - 0018
exact hleft - 0019
have hm : m = 0 - 0020
specialize bit_count_zero z - 0021
specialize bit_count_zero e - 0022
specialize bit_count_zero 0 - 0023
specialize bit_count_zero m - 0024
apply bit_count_zero - 0025
refl - 0026
exact hright - 0027
rewrite hn - 0028
rewrite hm - 0029
simp - 0030
intro n - 0031
intro m - 0032
intro hleft - 0033
intro hright - 0034
intro hcomplement - 0035
have hleft_decomp : ∃ a. ∃ r. BetaAt(b,c,l,a) ∧ (BitCount(b,c,l,r) ∧ ((a = 0 ∨ a = 1) ∧ n = r + a))Exact native replay line
have hleft_decomp : exists a r. (((exists ff_h_complement_left_last. ff_h_complement_left_last + S (a) = S ((S (l)) * c)) /\ exists ff_q_complement_left_last. b = ff_q_complement_left_last * S ((S (l)) * c) + (a))) /\ ((((exists ff_u_complement_left_prefix_sum ff_v_complement_left_prefix_sum. ((((exists ff_h_complement_left_prefix_sum_start. ff_h_complement_left_prefix_sum_start + S (0) = S ((S (0)) * ff_v_complement_left_prefix_sum)) /\ exists ff_q_complement_left_prefix_sum_start. ff_u_complement_left_prefix_sum = ff_q_complement_left_prefix_sum_start * S ((S (0)) * ff_v_complement_left_prefix_sum) + (0))) /\ ((((exists ff_h_complement_left_prefix_sum_terminal. ff_h_complement_left_prefix_sum_terminal + S (r) = S ((S (l)) * ff_v_complement_left_prefix_sum)) /\ exists ff_q_complement_left_prefix_sum_terminal. ff_u_complement_left_prefix_sum = ff_q_complement_left_prefix_sum_terminal * S ((S (l)) * ff_v_complement_left_prefix_sum) + (r))) /\ forall ff_i_complement_left_prefix_sum. (exists ff_lt_complement_left_prefix_sum_bound. ff_lt_complement_left_prefix_sum_bound + S ff_i_complement_left_prefix_sum = l) -> exists ff_a_complement_left_prefix_sum ff_r_complement_left_prefix_sum ff_s_complement_left_prefix_sum. ((((exists ff_h_complement_left_prefix_sum_summand. ff_h_complement_left_prefix_sum_summand + S (ff_a_complement_left_prefix_sum) = S ((S (ff_i_complement_left_prefix_sum)) * c)) /\ exists ff_q_complement_left_prefix_sum_summand. b = ff_q_complement_left_prefix_sum_summand * S ((S (ff_i_complement_left_prefix_sum)) * c) + (ff_a_complement_left_prefix_sum))) /\ ((((exists ff_h_complement_left_prefix_sum_partial. ff_h_complement_left_prefix_sum_partial + S (ff_r_complement_left_prefix_sum) = S ((S (ff_i_complement_left_prefix_sum)) * ff_v_complement_left_prefix_sum)) /\ exists ff_q_complement_left_prefix_sum_partial. ff_u_complement_left_prefix_sum = ff_q_complement_left_prefix_sum_partial * S ((S (ff_i_complement_left_prefix_sum)) * ff_v_complement_left_prefix_sum) + (ff_r_complement_left_prefix_sum))) /\ ((((exists ff_h_complement_left_prefix_sum_successor. ff_h_complement_left_prefix_sum_successor + S (ff_s_complement_left_prefix_sum) = S ((S (S ff_i_complement_left_prefix_sum)) * ff_v_complement_left_prefix_sum)) /\ exists ff_q_complement_left_prefix_sum_successor. ff_u_complement_left_prefix_sum = ff_q_complement_left_prefix_sum_successor * S ((S (S ff_i_complement_left_prefix_sum)) * ff_v_complement_left_prefix_sum) + (ff_s_complement_left_prefix_sum))) /\ ff_s_complement_left_prefix_sum = ff_r_complement_left_prefix_sum + ff_a_complement_left_prefix_sum)))))) /\ (forall ff_i_complement_left_prefix_bits. (exists ff_lt_complement_left_prefix_bits_bound. ff_lt_complement_left_prefix_bits_bound + S ff_i_complement_left_prefix_bits = l) -> exists ff_bit_complement_left_prefix_bits. ((((exists ff_h_complement_left_prefix_bits_decoded. ff_h_complement_left_prefix_bits_decoded + S (ff_bit_complement_left_prefix_bits) = S ((S (ff_i_complement_left_prefix_bits)) * c)) /\ exists ff_q_complement_left_prefix_bits_decoded. b = ff_q_complement_left_prefix_bits_decoded * S ((S (ff_i_complement_left_prefix_bits)) * c) + (ff_bit_complement_left_prefix_bits))) /\ (ff_bit_complement_left_prefix_bits = 0 \/ ff_bit_complement_left_prefix_bits = 1))))) /\ ((a = 0 \/ a = 1) /\ n = r + a)) - 0036
specialize bit_count_succ_decompose b - 0037
specialize bit_count_succ_decompose c - 0038
specialize bit_count_succ_decompose l - 0039
specialize bit_count_succ_decompose (S l) - 0040
specialize bit_count_succ_decompose n - 0041
apply bit_count_succ_decompose - 0042
refl - 0043
exact hleft - 0044
cases hleft_decomp - 0045
cases hleft_decomp_witness - 0046
cases hleft_decomp_witness_witness - 0047
cases hleft_decomp_witness_witness_right - 0048
cases hleft_decomp_witness_witness_right_right - 0049
have hright_decomp : ∃ d. ∃ s. BetaAt(z,e,l,d) ∧ (BitCount(z,e,l,s) ∧ ((d = 0 ∨ d = 1) ∧ m = s + d))Exact native replay line
have hright_decomp : exists d s. (((exists ff_h_complement_right_last. ff_h_complement_right_last + S (d) = S ((S (l)) * e)) /\ exists ff_q_complement_right_last. z = ff_q_complement_right_last * S ((S (l)) * e) + (d))) /\ ((((exists ff_u_complement_right_prefix_sum ff_v_complement_right_prefix_sum. ((((exists ff_h_complement_right_prefix_sum_start. ff_h_complement_right_prefix_sum_start + S (0) = S ((S (0)) * ff_v_complement_right_prefix_sum)) /\ exists ff_q_complement_right_prefix_sum_start. ff_u_complement_right_prefix_sum = ff_q_complement_right_prefix_sum_start * S ((S (0)) * ff_v_complement_right_prefix_sum) + (0))) /\ ((((exists ff_h_complement_right_prefix_sum_terminal. ff_h_complement_right_prefix_sum_terminal + S (s) = S ((S (l)) * ff_v_complement_right_prefix_sum)) /\ exists ff_q_complement_right_prefix_sum_terminal. ff_u_complement_right_prefix_sum = ff_q_complement_right_prefix_sum_terminal * S ((S (l)) * ff_v_complement_right_prefix_sum) + (s))) /\ forall ff_i_complement_right_prefix_sum. (exists ff_lt_complement_right_prefix_sum_bound. ff_lt_complement_right_prefix_sum_bound + S ff_i_complement_right_prefix_sum = l) -> exists ff_a_complement_right_prefix_sum ff_r_complement_right_prefix_sum ff_s_complement_right_prefix_sum. ((((exists ff_h_complement_right_prefix_sum_summand. ff_h_complement_right_prefix_sum_summand + S (ff_a_complement_right_prefix_sum) = S ((S (ff_i_complement_right_prefix_sum)) * e)) /\ exists ff_q_complement_right_prefix_sum_summand. z = ff_q_complement_right_prefix_sum_summand * S ((S (ff_i_complement_right_prefix_sum)) * e) + (ff_a_complement_right_prefix_sum))) /\ ((((exists ff_h_complement_right_prefix_sum_partial. ff_h_complement_right_prefix_sum_partial + S (ff_r_complement_right_prefix_sum) = S ((S (ff_i_complement_right_prefix_sum)) * ff_v_complement_right_prefix_sum)) /\ exists ff_q_complement_right_prefix_sum_partial. ff_u_complement_right_prefix_sum = ff_q_complement_right_prefix_sum_partial * S ((S (ff_i_complement_right_prefix_sum)) * ff_v_complement_right_prefix_sum) + (ff_r_complement_right_prefix_sum))) /\ ((((exists ff_h_complement_right_prefix_sum_successor. ff_h_complement_right_prefix_sum_successor + S (ff_s_complement_right_prefix_sum) = S ((S (S ff_i_complement_right_prefix_sum)) * ff_v_complement_right_prefix_sum)) /\ exists ff_q_complement_right_prefix_sum_successor. ff_u_complement_right_prefix_sum = ff_q_complement_right_prefix_sum_successor * S ((S (S ff_i_complement_right_prefix_sum)) * ff_v_complement_right_prefix_sum) + (ff_s_complement_right_prefix_sum))) /\ ff_s_complement_right_prefix_sum = ff_r_complement_right_prefix_sum + ff_a_complement_right_prefix_sum)))))) /\ (forall ff_i_complement_right_prefix_bits. (exists ff_lt_complement_right_prefix_bits_bound. ff_lt_complement_right_prefix_bits_bound + S ff_i_complement_right_prefix_bits = l) -> exists ff_bit_complement_right_prefix_bits. ((((exists ff_h_complement_right_prefix_bits_decoded. ff_h_complement_right_prefix_bits_decoded + S (ff_bit_complement_right_prefix_bits) = S ((S (ff_i_complement_right_prefix_bits)) * e)) /\ exists ff_q_complement_right_prefix_bits_decoded. z = ff_q_complement_right_prefix_bits_decoded * S ((S (ff_i_complement_right_prefix_bits)) * e) + (ff_bit_complement_right_prefix_bits))) /\ (ff_bit_complement_right_prefix_bits = 0 \/ ff_bit_complement_right_prefix_bits = 1))))) /\ ((d = 0 \/ d = 1) /\ m = s + d)) - 0050
specialize bit_count_succ_decompose z - 0051
specialize bit_count_succ_decompose e - 0052
specialize bit_count_succ_decompose l - 0053
specialize bit_count_succ_decompose (S l) - 0054
specialize bit_count_succ_decompose m - 0055
apply bit_count_succ_decompose - 0056
refl - 0057
exact hright - 0058
cases hright_decomp - 0059
cases hright_decomp_witness - 0060
cases hright_decomp_witness_witness - 0061
cases hright_decomp_witness_witness_right - 0062
cases hright_decomp_witness_witness_right_right - 0063
have hprefix_complement : ∀ i. ∀ a. ∀ d. Lt(i,l) → BetaAt(b,c,i,a) → BetaAt(z,e,i,d) → a = 0 ∧ d = 1 ∨ a = 1 ∧ d = 0Exact native replay line
have hprefix_complement : forall i a d. (exists h. h + S i = l) -> (((exists ff_h_complement_prefix_left. ff_h_complement_prefix_left + S (a) = S ((S (i)) * c)) /\ exists ff_q_complement_prefix_left. b = ff_q_complement_prefix_left * S ((S (i)) * c) + (a))) -> (((exists ff_h_complement_prefix_right. ff_h_complement_prefix_right + S (d) = S ((S (i)) * e)) /\ exists ff_q_complement_prefix_right. z = ff_q_complement_prefix_right * S ((S (i)) * e) + (d))) -> ((a = 0 /\ d = 1) \/ (a = 1 /\ d = 0)) - 0064
intro i - 0065
intro a - 0066
intro d - 0067
intro hi - 0068
intro ha - 0069
intro hd - 0070
specialize hcomplement i - 0071
specialize hcomplement a - 0072
specialize hcomplement d - 0073
apply hcomplement - 0074
specialize le_succ (S i) - 0075
specialize le_succ l - 0076
apply le_succ - 0077
exact hi - 0078
exact ha - 0079
exact hd - 0080
have hprefix : x1 + x3 = l - 0081
specialize IH x1 - 0082
specialize IH x3 - 0083
apply IH - 0084
exact hleft_decomp_witness_witness_right_left - 0085
exact hright_decomp_witness_witness_right_left - 0086
exact hprefix_complement - 0087
have hlast : ((x = 0 /\ x2 = 1) \/ (x = 1 /\ x2 = 0)) - 0088
specialize hcomplement l - 0089
specialize hcomplement x - 0090
specialize hcomplement x2 - 0091
apply hcomplement - 0092
specialize le_refl (S l) - 0093
exact le_refl - 0094
exact hleft_decomp_witness_witness_left - 0095
exact hright_decomp_witness_witness_left - 0096
rewrite hleft_decomp_witness_witness_right_right_right - 0097
rewrite hright_decomp_witness_witness_right_right_right - 0098
cases hlast - 0099
cases hlast_left - 0100
rewrite hlast_left_left - 0101
rewrite hlast_left_right - 0102
simp - 0103
cases hlast_right - 0104
rewrite hlast_right_left - 0105
rewrite hlast_right_right - 0106
simp - 0107
specialize add_succ_left x1 - 0108
specialize add_succ_left x3 - 0109
trans S (x1 + x3) - 0110
exact add_succ_left - 0111
rewrite hprefix - 0112
refl