Exact expanded PA statement
forall k b e s. exists z c. (((exists h. h + S s = S ((S k) * c)) /\ exists q. z = q * S ((S k) * c) + s) /\ forall i a. (exists h. h + S i = k) -> ((exists h. h + S a = S ((S i) * e)) /\ exists q. b = q * S ((S i) * e) + a) -> ((exists h. h + S a = S ((S i) * c)) /\ exists q. z = q * S ((S i) * c) + a))Structural proof guide
Generated structural guide
Rebase an arbitrary decoded prefix and append one exact natural value.
Use the direct prerequisites bounded_common_multiple_exists, scaled_bounded_common_multiple, bounded_beta_exclusive_recode_invariant, le_refl, beta_modulus_nonzero, binary_crt_fold_step, new_value_lt_scaled_base, beta_value_lt_scaled_base, beta_at_of_mod_eq_bound as previously established PA formulas.
The proof proceeds by case analysis (9), intermediate claims (10).
Referenced ingredients
Proof neighborhood
Direct dependencies
PA000K bounded_common_multiple_exists PA000L scaled_bounded_common_multiple PA002I bounded_beta_exclusive_recode_invariant PA001A le_refl PA000U beta_modulus_nonzero PA0028 binary_crt_fold_step PA002Q new_value_lt_scaled_base PA002T beta_value_lt_scaled_base PA002W beta_at_of_mod_eq_boundDirect dependents
PA002Y beta_range_succ_extend PA003G beta_prefix_sum_trace_exists PA003W beta_prefix_product_trace_exists PA0044 beta_repeat_succ_extend PA004J beta_prefix_replace_exists PA0073 gauss_signed_half_prefix_extend PA007D beta_magnitude_predecessor_recode_exists PA007F beta_sign_factor_prefix_extend PA007K beta_pointwise_mul_prefix_extend PA008B prime_mul_index_map_exists_up_to PA008C beta_successor_lift_exists PA008R prime_scaled_inverse_prefix_extend PA0093 finite_inverse_choice_prefix_extend PA009K beta_prefix_append_two_exists PA00A5 prime_inverse_prefix_extend PA00BX beta_division_prefix_extend PA00DC eisenstein_row_indicator_prefix_extend PA00DI eisenstein_rectangle_row_count_prefix_extend PA00E8 eisenstein_transposed_column_prefix_extend PA00EH eisenstein_transposed_column_count_prefix_extend PA00EW eisenstein_successor_row_split_prefix_extendFormal native tactic body
Dependencies are introduced as named hypotheses before line 1. Linked names are exact direct references. This Stable checked-use theorem is independently kernel-checked when replayed.
- 0001
intro k - 0002
intro b - 0003
intro e - 0004
intro s - 0005
have hC : exists C. (~(C = 0) /\ forall t. (exists h. S t + S h = S k) -> exists q. C = S t * q) - 0006
specialize bounded_common_multiple_exists k - 0007
exact bounded_common_multiple_exists - 0008
cases hC - 0009
cases hC_witness - 0010
have hcm2 : forall t. (exists h. S t + S h = S k) -> exists q. x * S (b + s) = S t * q - 0011
specialize scaled_bounded_common_multiple k - 0012
specialize scaled_bounded_common_multiple x - 0013
specialize scaled_bounded_common_multiple (S (b + s)) - 0014
apply scaled_bounded_common_multiple - 0015
exact hC_witness_right - 0016
have hall : forall n. (exists h. h + n = k) -> exists P z. (~(P = 0) /\ ((forall i. (exists h. h + S i = n) -> exists q. P = S ((S i) * (x * S (b + s))) * q) /\ ((forall i a. (exists h. h + S i = n) -> ((exists h. h + S a = S ((S i) * e)) /\ exists q. b = q * S ((S i) * e) + a) -> exists u v. z + S ((S i) * (x * S (b + s))) * u = a + S ((S i) * (x * S (b + s))) * v) /\ forall j. (exists g. g + n = j) -> (exists h. h + j = k) -> forall d. (exists u. P = d * u) -> (exists v. S ((S j) * (x * S (b + s))) = d * v) -> d = 1))) - 0017
specialize bounded_beta_exclusive_recode_invariant k - 0018
specialize bounded_beta_exclusive_recode_invariant (x * S (b + s)) - 0019
specialize bounded_beta_exclusive_recode_invariant b - 0020
specialize bounded_beta_exclusive_recode_invariant e - 0021
apply bounded_beta_exclusive_recode_invariant - 0022
exact hcm2 - 0023
have hinv : exists P z. (~(P = 0) /\ ((forall i. (exists h. h + S i = k) -> exists q. P = S ((S i) * (x * S (b + s))) * q) /\ ((forall i a. (exists h. h + S i = k) -> ((exists h. h + S a = S ((S i) * e)) /\ exists q. b = q * S ((S i) * e) + a) -> exists u v. z + S ((S i) * (x * S (b + s))) * u = a + S ((S i) * (x * S (b + s))) * v) /\ forall j. (exists g. g + k = j) -> (exists h. h + j = k) -> forall d. (exists u. P = d * u) -> (exists v. S ((S j) * (x * S (b + s))) = d * v) -> d = 1))) - 0024
specialize hall k - 0025
apply hall - 0026
specialize le_refl k - 0027
exact le_refl - 0028
cases hinv - 0029
cases hinv_witness - 0030
cases hinv_witness_witness - 0031
cases hinv_witness_witness_right - 0032
cases hinv_witness_witness_right_right - 0033
have hcop : forall d. (exists u. x1 = d * u) -> (exists v. S ((S k) * (x * S (b + s))) = d * v) -> d = 1 - 0034
specialize hinv_witness_witness_right_right_right k - 0035
apply hinv_witness_witness_right_right_right - 0036
specialize le_refl k - 0037
exact le_refl - 0038
specialize le_refl k - 0039
exact le_refl - 0040
have hnew0 : ~(S ((S k) * (x * S (b + s))) = 0) - 0041
specialize beta_modulus_nonzero (x * S (b + s)) - 0042
specialize beta_modulus_nonzero k - 0043
exact beta_modulus_nonzero - 0044
have hfold : exists z2. ((forall m a. (exists q. x1 = m * q) -> (exists u v. x2 + m * u = a + m * v) -> exists r t. z2 + m * r = a + m * t) /\ exists q r. z2 + S ((S k) * (x * S (b + s))) * q = s + S ((S k) * (x * S (b + s))) * r) - 0045
specialize binary_crt_fold_step x1 - 0046
specialize binary_crt_fold_step (S ((S k) * (x * S (b + s)))) - 0047
specialize binary_crt_fold_step x2 - 0048
specialize binary_crt_fold_step s - 0049
apply binary_crt_fold_step - 0050
exact hinv_witness_witness_left - 0051
exact hnew0 - 0052
exact hcop - 0053
cases hfold - 0054
cases hfold_witness - 0055
exists x3 - 0056
exists x * S (b + s) - 0057
split - 0058
specialize beta_at_of_mod_eq_bound x3 - 0059
specialize beta_at_of_mod_eq_bound (x * S (b + s)) - 0060
specialize beta_at_of_mod_eq_bound k - 0061
specialize beta_at_of_mod_eq_bound s - 0062
apply beta_at_of_mod_eq_bound - 0063
specialize new_value_lt_scaled_base b - 0064
specialize new_value_lt_scaled_base s - 0065
specialize new_value_lt_scaled_base x - 0066
specialize new_value_lt_scaled_base k - 0067
apply new_value_lt_scaled_base - 0068
exact hC_witness_left - 0069
exact hfold_witness_right - 0070
intro i - 0071
intro a - 0072
intro hi - 0073
intro hati - 0074
have hmi : exists q. x1 = S ((S i) * (x * S (b + s))) * q - 0075
specialize hinv_witness_witness_right_left i - 0076
apply hinv_witness_witness_right_left - 0077
exact hi - 0078
have hzold : exists u v. x2 + S ((S i) * (x * S (b + s))) * u = a + S ((S i) * (x * S (b + s))) * v - 0079
specialize hinv_witness_witness_right_right_left i - 0080
specialize hinv_witness_witness_right_right_left a - 0081
apply hinv_witness_witness_right_right_left - 0082
exact hi - 0083
exact hati - 0084
have hznew : exists u v. x3 + S ((S i) * (x * S (b + s))) * u = a + S ((S i) * (x * S (b + s))) * v - 0085
specialize hfold_witness_left (S ((S i) * (x * S (b + s)))) - 0086
specialize hfold_witness_left a - 0087
apply hfold_witness_left - 0088
exact hmi - 0089
exact hzold - 0090
specialize beta_at_of_mod_eq_bound x3 - 0091
specialize beta_at_of_mod_eq_bound (x * S (b + s)) - 0092
specialize beta_at_of_mod_eq_bound i - 0093
specialize beta_at_of_mod_eq_bound a - 0094
apply beta_at_of_mod_eq_bound - 0095
specialize beta_value_lt_scaled_base b - 0096
specialize beta_value_lt_scaled_base e - 0097
specialize beta_value_lt_scaled_base i - 0098
specialize beta_value_lt_scaled_base a - 0099
specialize beta_value_lt_scaled_base x - 0100
specialize beta_value_lt_scaled_base s - 0101
specialize beta_value_lt_scaled_base i - 0102
apply beta_value_lt_scaled_base - 0103
exact hati - 0104
exact hC_witness_left - 0105
exact hznew