Theorem: LO.FirstOrder.Arith.Model.Nuon.ext_add₂_bexp (Arithmetization/OmegaOne/Nuon.lean)

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)){L}[i + j] = S₂{L}[j]
Tactic:
have hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖)) := exp_bexp_of_lt (mul_len_lt_len_hash $ le_trans le_self_add hij)
State after:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)){L}[i + j] = S₂{L}[j]

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)){L}[i + j] = S₂{L}[j]
Tactic:
calc  (S₁ + S₂ * bexp (I # L) (i * ‖L‖)){L}[i + j]
    = (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) ((i + j) * ‖L‖) % (L # 1)                    := by rw [ext_eq_hash_of_le hij]
  _ = (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖) / bexp (I # L) (j * ‖L‖) % (L # 1) := by
    simp [←div_mul, add_mul]; congr 2; exact bexp_add (by simp [←add_mul, mul_len_lt_len_hash hij])
  _ = S₂ / bexp (I # L) (j * ‖L‖) % (L # 1)                                                          := by
    congr 2; rw [div_add_mul_self, div_eq_zero_of_lt] <;> simp [hie.lt_iff_len_le.mpr hS₁, hie.range_pos]
  _ = S₂{L}[j]                                                                                       := ext_eq_hash_of_le (le_trans le_add_self hij)
State after:
no goals

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)){L}[i + j] =
    (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) ((i + j) * ‖L‖) % L # 1
Tactic:
rw [ext_eq_hash_of_le hij]
State after:
no goals

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) ((i + j) * ‖L‖) % L # 1 =
    (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖) / bexp (I # L) (j * ‖L‖) % L # 1
Tactic:
simp [←div_mul, add_mul]
State after:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖ + j * ‖L‖) % L # 1 =
    (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / (bexp (I # L) (i * ‖L‖) * bexp (I # L) (j * ‖L‖)) % L # 1

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖ + j * ‖L‖) % L # 1 =
    (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / (bexp (I # L) (i * ‖L‖) * bexp (I # L) (j * ‖L‖)) % L # 1
Tactic:
congr 2
State after:
case e_a.e_a
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ bexp (I # L) (i * ‖L‖ + j * ‖L‖) = bexp (I # L) (i * ‖L‖) * bexp (I # L) (j * ‖L‖)

State before:
case e_a.e_a
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ bexp (I # L) (i * ‖L‖ + j * ‖L‖) = bexp (I # L) (i * ‖L‖) * bexp (I # L) (j * ‖L‖)
Tactic:
exact bexp_add (by simp [←add_mul, mul_len_lt_len_hash hij])
State after:
no goals

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ i * ‖L‖ + j * ‖L‖ < ‖I # L‖
Tactic:
simp [←add_mul, mul_len_lt_len_hash hij]
State after:
no goals

State before:
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖) / bexp (I # L) (j * ‖L‖) % L # 1 =
    S₂ / bexp (I # L) (j * ‖L‖) % L # 1
Tactic:
congr 2
State after:
case e_a.e_a
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖) = S₂

State before:
case e_a.e_a
M : Type u_1
inst✝⁵ : Zero M
inst✝⁴ : One M
inst✝³ : Add M
inst✝² : Mul M
inst✝¹ : LT M
inst✝ : M ⊧ₘ* 𝐈𝚫₀ + 𝛀₁
L I i j S₁ S₂ : M
hij : i + j ≤ ‖I‖
hS₁ : ‖S₁‖ ≤ i * ‖L‖
hie : Exponential (i * ‖L‖) (bexp (I # L) (i * ‖L‖))
⊢ (S₁ + S₂ * bexp (I # L) (i * ‖L‖)) / bexp (I # L) (i * ‖L‖) = S₂
Tactic:
rw [div_add_mul_self, div_eq_zero_of_lt] <;> simp [hie.lt_iff_len_le.mpr hS₁, hie.range_pos]
State after:
no goals