Exact expanded first-order arithmetic statement
forall F z. (exists dst_positive_code_empty_sum dst_positive_scale_empty_sum dst_negative_code_empty_sum dst_negative_scale_empty_sum dst_positive_sum_empty_sum dst_negative_sum_empty_sum. (((F) = (((((dst_positive_code_empty_sum) + (dst_positive_scale_empty_sum)) * S ((dst_positive_code_empty_sum) + (dst_positive_scale_empty_sum)) + ((dst_positive_scale_empty_sum) + (dst_positive_scale_empty_sum))) + (((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) * S ((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) + ((dst_negative_scale_empty_sum) + (dst_negative_scale_empty_sum)))) * S ((((dst_positive_code_empty_sum) + (dst_positive_scale_empty_sum)) * S ((dst_positive_code_empty_sum) + (dst_positive_scale_empty_sum)) + ((dst_positive_scale_empty_sum) + (dst_positive_scale_empty_sum))) + (((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) * S ((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) + ((dst_negative_scale_empty_sum) + (dst_negative_scale_empty_sum)))) + ((((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) * S ((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) + ((dst_negative_scale_empty_sum) + (dst_negative_scale_empty_sum))) + (((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) * S ((dst_negative_code_empty_sum) + (dst_negative_scale_empty_sum)) + ((dst_negative_scale_empty_sum) + (dst_negative_scale_empty_sum)))))) /\ (((exists fs_u_dst_empty_sumpositive fs_v_dst_empty_sumpositive. ((((exists fs_h_dst_empty_sumpositive_body_start. fs_h_dst_empty_sumpositive_body_start + S (0) = S ((S (0)) * fs_v_dst_empty_sumpositive)) /\ exists fs_q_dst_empty_sumpositive_body_start. fs_u_dst_empty_sumpositive = fs_q_dst_empty_sumpositive_body_start * S ((S (0)) * fs_v_dst_empty_sumpositive) + (0))) /\ ((((exists fs_h_dst_empty_sumpositive_body_terminal. fs_h_dst_empty_sumpositive_body_terminal + S (dst_positive_sum_empty_sum) = S ((S (0)) * fs_v_dst_empty_sumpositive)) /\ exists fs_q_dst_empty_sumpositive_body_terminal. fs_u_dst_empty_sumpositive = fs_q_dst_empty_sumpositive_body_terminal * S ((S (0)) * fs_v_dst_empty_sumpositive) + (dst_positive_sum_empty_sum))) /\ forall fs_i_dst_empty_sumpositive_body_steps. (exists fs_lt_dst_empty_sumpositive_body_steps_bound. fs_lt_dst_empty_sumpositive_body_steps_bound + S fs_i_dst_empty_sumpositive_body_steps = 0) -> exists fs_a_dst_empty_sumpositive_body_steps fs_r_dst_empty_sumpositive_body_steps fs_s_dst_empty_sumpositive_body_steps. ((((exists fs_h_dst_empty_sumpositive_body_steps_summand. fs_h_dst_empty_sumpositive_body_steps_summand + S (fs_a_dst_empty_sumpositive_body_steps) = S ((S (fs_i_dst_empty_sumpositive_body_steps)) * dst_positive_scale_empty_sum)) /\ exists fs_q_dst_empty_sumpositive_body_steps_summand. dst_positive_code_empty_sum = fs_q_dst_empty_sumpositive_body_steps_summand * S ((S (fs_i_dst_empty_sumpositive_body_steps)) * dst_positive_scale_empty_sum) + (fs_a_dst_empty_sumpositive_body_steps))) /\ ((((exists fs_h_dst_empty_sumpositive_body_steps_partial. fs_h_dst_empty_sumpositive_body_steps_partial + S (fs_r_dst_empty_sumpositive_body_steps) = S ((S (fs_i_dst_empty_sumpositive_body_steps)) * fs_v_dst_empty_sumpositive)) /\ exists fs_q_dst_empty_sumpositive_body_steps_partial. fs_u_dst_empty_sumpositive = fs_q_dst_empty_sumpositive_body_steps_partial * S ((S (fs_i_dst_empty_sumpositive_body_steps)) * fs_v_dst_empty_sumpositive) + (fs_r_dst_empty_sumpositive_body_steps))) /\ ((((exists fs_h_dst_empty_sumpositive_body_steps_successor. fs_h_dst_empty_sumpositive_body_steps_successor + S (fs_s_dst_empty_sumpositive_body_steps) = S ((S (S fs_i_dst_empty_sumpositive_body_steps)) * fs_v_dst_empty_sumpositive)) /\ exists fs_q_dst_empty_sumpositive_body_steps_successor. fs_u_dst_empty_sumpositive = fs_q_dst_empty_sumpositive_body_steps_successor * S ((S (S fs_i_dst_empty_sumpositive_body_steps)) * fs_v_dst_empty_sumpositive) + (fs_s_dst_empty_sumpositive_body_steps))) /\ fs_s_dst_empty_sumpositive_body_steps = fs_r_dst_empty_sumpositive_body_steps + fs_a_dst_empty_sumpositive_body_steps)))))) /\ (((exists fs_u_dst_empty_sumnegative fs_v_dst_empty_sumnegative. ((((exists fs_h_dst_empty_sumnegative_body_start. fs_h_dst_empty_sumnegative_body_start + S (0) = S ((S (0)) * fs_v_dst_empty_sumnegative)) /\ exists fs_q_dst_empty_sumnegative_body_start. fs_u_dst_empty_sumnegative = fs_q_dst_empty_sumnegative_body_start * S ((S (0)) * fs_v_dst_empty_sumnegative) + (0))) /\ ((((exists fs_h_dst_empty_sumnegative_body_terminal. fs_h_dst_empty_sumnegative_body_terminal + S (dst_negative_sum_empty_sum) = S ((S (0)) * fs_v_dst_empty_sumnegative)) /\ exists fs_q_dst_empty_sumnegative_body_terminal. fs_u_dst_empty_sumnegative = fs_q_dst_empty_sumnegative_body_terminal * S ((S (0)) * fs_v_dst_empty_sumnegative) + (dst_negative_sum_empty_sum))) /\ forall fs_i_dst_empty_sumnegative_body_steps. (exists fs_lt_dst_empty_sumnegative_body_steps_bound. fs_lt_dst_empty_sumnegative_body_steps_bound + S fs_i_dst_empty_sumnegative_body_steps = 0) -> exists fs_a_dst_empty_sumnegative_body_steps fs_r_dst_empty_sumnegative_body_steps fs_s_dst_empty_sumnegative_body_steps. ((((exists fs_h_dst_empty_sumnegative_body_steps_summand. fs_h_dst_empty_sumnegative_body_steps_summand + S (fs_a_dst_empty_sumnegative_body_steps) = S ((S (fs_i_dst_empty_sumnegative_body_steps)) * dst_negative_scale_empty_sum)) /\ exists fs_q_dst_empty_sumnegative_body_steps_summand. dst_negative_code_empty_sum = fs_q_dst_empty_sumnegative_body_steps_summand * S ((S (fs_i_dst_empty_sumnegative_body_steps)) * dst_negative_scale_empty_sum) + (fs_a_dst_empty_sumnegative_body_steps))) /\ ((((exists fs_h_dst_empty_sumnegative_body_steps_partial. fs_h_dst_empty_sumnegative_body_steps_partial + S (fs_r_dst_empty_sumnegative_body_steps) = S ((S (fs_i_dst_empty_sumnegative_body_steps)) * fs_v_dst_empty_sumnegative)) /\ exists fs_q_dst_empty_sumnegative_body_steps_partial. fs_u_dst_empty_sumnegative = fs_q_dst_empty_sumnegative_body_steps_partial * S ((S (fs_i_dst_empty_sumnegative_body_steps)) * fs_v_dst_empty_sumnegative) + (fs_r_dst_empty_sumnegative_body_steps))) /\ ((((exists fs_h_dst_empty_sumnegative_body_steps_successor. fs_h_dst_empty_sumnegative_body_steps_successor + S (fs_s_dst_empty_sumnegative_body_steps) = S ((S (S fs_i_dst_empty_sumnegative_body_steps)) * fs_v_dst_empty_sumnegative)) /\ exists fs_q_dst_empty_sumnegative_body_steps_successor. fs_u_dst_empty_sumnegative = fs_q_dst_empty_sumnegative_body_steps_successor * S ((S (S fs_i_dst_empty_sumnegative_body_steps)) * fs_v_dst_empty_sumnegative) + (fs_s_dst_empty_sumnegative_body_steps))) /\ fs_s_dst_empty_sumnegative_body_steps = fs_r_dst_empty_sumnegative_body_steps + fs_a_dst_empty_sumnegative_body_steps)))))) /\ (exists ge_balance_positive_empty_sumresult ge_balance_negative_empty_sumresult. (((((z) = 2 * (ge_balance_positive_empty_sumresult) /\ (ge_balance_negative_empty_sumresult) = 0) \/ exists ge_signed_half_empty_sumresultdecode. (((z) = 2 * ge_signed_half_empty_sumresultdecode + 1 /\ (ge_balance_positive_empty_sumresult) = 0) /\ (ge_balance_negative_empty_sumresult) = S ge_signed_half_empty_sumresultdecode))) /\ ((dst_positive_sum_empty_sum) + ge_balance_negative_empty_sumresult = (dst_negative_sum_empty_sum) + ge_balance_positive_empty_sumresult))))))))) -> z = 0Constructive proof overview
Generated structural guide
The empty signed prefix sum is exactly canonical zero, regardless of the packed component streams.
The unchanged tactic script uses 2 declared prerequisites and contains 36 exact native proof lines.
Public research checkpoint: original HA and independently compiled Lean verified; not Alpha-enrolled, no Alpha checked-use authority; not Stable
Proof neighborhood
Direct dependencies
beta_sum_zero Alpha theorem; checked-use authorized signed_balance_zero_iff Alpha theorem; checked-use authorizedDirect dependents
Formal native tactic body
Dependencies are introduced as named hypotheses before line 1. Local theorem links identify exact declared prerequisites. The literal dependency-closed bundle is checked by original HA and the independently compiled Lean verifier. Public delivery grants no Alpha checked-use authority or Stable membership.
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.
01Fix variables and assumptionsL1–3
02Separate the logical casesL4–12
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L4
cases h - L5
cases h_witness - L6
cases h_witness_witness - L7
cases h_witness_witness_witness - L8
cases h_witness_witness_witness_witness - L9
cases h_witness_witness_witness_witness_witness - L10
cases h_witness_witness_witness_witness_witness_witness - L11
cases h_witness_witness_witness_witness_witness_witness_right - L12
cases h_witness_witness_witness_witness_witness_witness_right_right
03Establish hpL13–18
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply beta sum zero.
04Establish hnL19–24
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply beta sum zero.
05Establish hzeroL25–30
Establish this local claim before using it. It is not an additional assumption. The following proof commands apply signed balance zero iff.
06Separate the logical casesL31–31
Follow the explicit conjunction, disjunction, witness, or contradiction step recorded below.
- L31
cases hzero
07Use earlier factsL32–32
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L32
apply hzero_right
08Calculate and transport equalitiesL33–33
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L33
trans 0
09Use earlier factsL34–34
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L34
exact hp
10Calculate and transport equalitiesL35–35
Carry out the recorded arithmetic or equality steps; inspect the exact commands for their direction and premises.
- L35
symm
11Use earlier factsL36–36
Instantiate or apply named facts and discharge the corresponding proof obligations.
- L36
exact hn
Original exact command ledger · 36 lines
- 0001
intro F - 0002
intro z - 0003
intro h - 0004
cases h - 0005
cases h_witness - 0006
cases h_witness_witness - 0007
cases h_witness_witness_witness - 0008
cases h_witness_witness_witness_witness - 0009
cases h_witness_witness_witness_witness_witness - 0010
cases h_witness_witness_witness_witness_witness_witness - 0011
cases h_witness_witness_witness_witness_witness_witness_right - 0012
cases h_witness_witness_witness_witness_witness_witness_right_right - 0013
have hp : x4 = 0 - 0014
specialize beta_sum_zero (x) - 0015
specialize beta_sum_zero (x1) - 0016
specialize beta_sum_zero (x4) - 0017
apply beta_sum_zero - 0018
exact h_witness_witness_witness_witness_witness_witness_right_left - 0019
have hn : x5 = 0 - 0020
specialize beta_sum_zero (x2) - 0021
specialize beta_sum_zero (x3) - 0022
specialize beta_sum_zero (x5) - 0023
apply beta_sum_zero - 0024
exact h_witness_witness_witness_witness_witness_witness_right_right_left - 0025
have hzero : (z = 0 -> x4 = x5) /\ (x4 = x5 -> z = 0) - 0026
specialize signed_balance_zero_iff (z) - 0027
specialize signed_balance_zero_iff (x4) - 0028
specialize signed_balance_zero_iff (x5) - 0029
apply signed_balance_zero_iff - 0030
exact h_witness_witness_witness_witness_witness_witness_right_right_right - 0031
cases hzero - 0032
apply hzero_right - 0033
trans 0 - 0034
exact hp - 0035
symm - 0036
exact hn