case inl
p : ℝ
hp : 0 ≤ p
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p

case inr
p : ℝ
hp : p < 0
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
p : ℝ
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
cases' le_or_lt 0 p with hp hp
case inl
p : ℝ
hp : 0 ≤ p
⊢ (Summable fun k => 2 ^ ↑k * (↑(2 ^ k) ^ p)⁻¹) ↔ 1 < p

case inl.h_nonneg
p : ℝ
hp : 0 ≤ p
⊢ ∀ (n : ℕ), 0 ≤ (↑n ^ p)⁻¹

case inl.h_mono
p : ℝ
hp : 0 ≤ p
⊢ ∀ ⦃m n : ℕ⦄, 0 < m → m ≤ n → (↑n ^ p)⁻¹ ≤ (↑m ^ p)⁻¹
case inl
p : ℝ
hp : 0 ≤ p
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
rw [← summable_condensed_iff_of_nonneg]
case inl
p : ℝ
hp : 0 ≤ p
⊢ ‖2 * (2 ^ p)⁻¹‖ < 1 ↔ 1 < p
case inl
p : ℝ
hp : 0 ≤ p
⊢ (Summable fun k => 2 ^ ↑k * (↑(2 ^ k) ^ p)⁻¹) ↔ 1 < p
simp_rw [Nat.cast_pow, Nat.cast_two, ← rpow_nat_cast, ← rpow_mul zero_lt_two.le, mul_comm _ p,
  rpow_mul zero_lt_two.le, rpow_nat_cast, ← inv_pow, ← mul_pow,
  summable_geometric_iff_norm_lt_1]
case inl
p : ℝ
hp : 0 ≤ p
⊢ ‖2 ^ 1 * (2 ^ p)⁻¹‖ < 1 ↔ 1 < p
case inl
p : ℝ
hp : 0 ≤ p
⊢ ‖2 * (2 ^ p)⁻¹‖ < 1 ↔ 1 < p
nth_rw 1 [← rpow_one 2]
case inl
p : ℝ
hp : 0 ≤ p
⊢ 2 = 0 ∧ 1 - p ≠ 0 ∨ 1 < 2 ∧ 1 - p < 0 ∨ 2 < 1 ∧ 0 < 1 - p ↔ 1 < p
case inl
p : ℝ
hp : 0 ≤ p
⊢ ‖2 ^ 1 * (2 ^ p)⁻¹‖ < 1 ↔ 1 < p
rw [← division_def, ← rpow_sub zero_lt_two, norm_eq_abs,
  abs_of_pos (rpow_pos_of_pos zero_lt_two _), rpow_lt_one_iff zero_lt_two.le]
no goals
case inl
p : ℝ
hp : 0 ≤ p
⊢ 2 = 0 ∧ 1 - p ≠ 0 ∨ 1 < 2 ∧ 1 - p < 0 ∨ 2 < 1 ∧ 0 < 1 - p ↔ 1 < p
norm_num
case inl.h_nonneg
p : ℝ
hp : 0 ≤ p
n : ℕ
⊢ 0 ≤ (↑n ^ p)⁻¹
case inl.h_nonneg
p : ℝ
hp : 0 ≤ p
⊢ ∀ (n : ℕ), 0 ≤ (↑n ^ p)⁻¹
intro n
no goals
case inl.h_nonneg
p : ℝ
hp : 0 ≤ p
n : ℕ
⊢ 0 ≤ (↑n ^ p)⁻¹
exact inv_nonneg.2 (rpow_nonneg_of_nonneg n.cast_nonneg _)
case inl.h_mono
p : ℝ
hp : 0 ≤ p
m n : ℕ
hm : 0 < m
hmn : m ≤ n
⊢ (↑n ^ p)⁻¹ ≤ (↑m ^ p)⁻¹
case inl.h_mono
p : ℝ
hp : 0 ≤ p
⊢ ∀ ⦃m n : ℕ⦄, 0 < m → m ≤ n → (↑n ^ p)⁻¹ ≤ (↑m ^ p)⁻¹
intro m n hm hmn
no goals
case inl.h_mono
p : ℝ
hp : 0 ≤ p
m n : ℕ
hm : 0 < m
hmn : m ≤ n
⊢ (↑n ^ p)⁻¹ ≤ (↑m ^ p)⁻¹
exact
  inv_le_inv_of_le (rpow_pos_of_pos (Nat.cast_pos.2 hm) _)
    (rpow_le_rpow m.cast_nonneg (Nat.cast_le.2 hmn) hp)
case inr
p : ℝ
hp : p < 0
⊢ ¬Summable fun n => (↑n ^ p)⁻¹
case inr
p : ℝ
hp : p < 0
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
suffices ¬Summable (fun n => (n ^ p)⁻¹ : ℕ → ℝ) by
  have : ¬1 < p := fun hp₁ => hp.not_le (zero_le_one.trans hp₁.le)
  simpa only [this, iff_false]
p : ℝ
hp : p < 0
this✝ : ¬Summable fun n => (↑n ^ p)⁻¹
this : ¬1 < p
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
p : ℝ
hp : p < 0
this : ¬Summable fun n => (↑n ^ p)⁻¹
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
have : ¬1 < p := fun hp₁ => hp.not_le (zero_le_one.trans hp₁.le)
no goals
p : ℝ
hp : p < 0
this✝ : ¬Summable fun n => (↑n ^ p)⁻¹
this : ¬1 < p
⊢ (Summable fun n => (↑n ^ p)⁻¹) ↔ 1 < p
simpa only [this, iff_false]
case inr
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
⊢ False
case inr
p : ℝ
hp : p < 0
⊢ ¬Summable fun n => (↑n ^ p)⁻¹
intro h
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : k ≠ 0
⊢ False
case inr
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
⊢ False
obtain ⟨k : ℕ, hk₁ : ((k ^ p)⁻¹ : ℝ) < 1, hk₀ : k ≠ 0⟩ :=
  ((h.tendsto_cofinite_zero.eventually (gt_mem_nhds zero_lt_one)).and
      (eventually_cofinite_ne 0)).exists
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : k ≠ 0
⊢ k = 0
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : k ≠ 0
⊢ False
apply hk₀
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : 0 < ↑k
⊢ k = 0
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : k ≠ 0
⊢ k = 0
rw [← pos_iff_ne_zero, ← @Nat.cast_pos ℝ] at hk₀
no goals
case inr.intro.intro
p : ℝ
hp : p < 0
h : Summable fun n => (↑n ^ p)⁻¹
k : ℕ
hk₁ : (↑k ^ p)⁻¹ < 1
hk₀ : 0 < ↑k
⊢ k = 0
simpa [inv_lt_one_iff_of_pos (rpow_pos_of_pos hk₀ _), one_lt_rpow_iff_of_pos hk₀, hp,
  hp.not_lt, hk₀] using hk₁