Theorem: Nat.sum_range_choose_halfway
File: Mathlib/Data/Nat/Choose/Sum.lean

tactic: linarith [mem_range.1 hi]
state_before: R : Type u_1
m i : ℕ
hi : i ∈ range (m + 1)
⊢ i ≤ 2 * m + 1
state_after: no goals

tactic: rw [two_mul, this]
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 * ∑ i ∈ range (m + 1), (2 * m + 1).choose i =
    ∑ i ∈ range (m + 1), (2 * m + 1).choose i + ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i)
state_after: no goals

tactic: rw [range_eq_Ico, sum_Ico_reflect]
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ ∑ i ∈ range (m + 1), (2 * m + 1).choose i + ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) =
    ∑ i ∈ range (m + 1), (2 * m + 1).choose i + ∑ i ∈ Ico (m + 1) (2 * m + 2), (2 * m + 1).choose i
state_after: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ ∑ i ∈ Ico 0 (m + 1), (2 * m + 1).choose i +
      ∑ j ∈ Ico (2 * m + 1 + 1 - (m + 1)) (2 * m + 1 + 1 - 0), (2 * m + 1).choose j =
    ∑ i ∈ Ico 0 (m + 1), (2 * m + 1).choose i + ∑ i ∈ Ico (m + 1) (2 * m + 2), (2 * m + 1).choose i

case h
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ m + 1 ≤ 2 * m + 1 + 1

tactic: congr
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ ∑ i ∈ Ico 0 (m + 1), (2 * m + 1).choose i +
      ∑ j ∈ Ico (2 * m + 1 + 1 - (m + 1)) (2 * m + 1 + 1 - 0), (2 * m + 1).choose j =
    ∑ i ∈ Ico 0 (m + 1), (2 * m + 1).choose i + ∑ i ∈ Ico (m + 1) (2 * m + 2), (2 * m + 1).choose i
state_after: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 * m + 1 + 1 - (m + 1) = m + 1

tactic: have A : m + 1 ≤ 2 * m + 1 := by omega
state_before: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 * m + 1 + 1 - (m + 1) = m + 1
state_after: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 + 1 - (m + 1) = m + 1

tactic: rw [add_comm, add_tsub_assoc_of_le A, ← add_comm]
state_before: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 + 1 - (m + 1) = m + 1
state_after: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 - (m + 1) + 1 = m + 1

tactic: congr
state_before: case e_a.e_s.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 - (m + 1) + 1 = m + 1
state_after: case e_a.e_s.e_a.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 - (m + 1) = m

tactic: rw [tsub_eq_iff_eq_add_of_le A]
state_before: case e_a.e_s.e_a.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 - (m + 1) = m
state_after: case e_a.e_s.e_a.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 = m + (m + 1)

tactic: ring
state_before: case e_a.e_s.e_a.e_a
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
A : m + 1 ≤ 2 * m + 1
⊢ 2 * m + 1 = m + (m + 1)
state_after: no goals

tactic: omega
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ m + 1 ≤ 2 * m + 1
state_after: no goals

tactic: omega
state_before: case h
R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ m + 1 ≤ 2 * m + 1 + 1
state_after: no goals

tactic: omega
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ m + 1 ≤ 2 * m + 2
state_after: no goals

tactic: rw [Nat.pow_succ, pow_mul, mul_comm]
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 ^ (2 * m + 1) = 2 * 4 ^ m
state_after: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 * (2 ^ 2) ^ m = 2 * 4 ^ m

tactic: rfl
state_before: R : Type u_1
m : ℕ
this : ∑ i ∈ range (m + 1), (2 * m + 1).choose (2 * m + 1 - i) = ∑ i ∈ range (m + 1), (2 * m + 1).choose i
⊢ 2 * (2 ^ 2) ^ m = 2 * 4 ^ m
state_after: no goals