AFTD Auto-Formalizing Theoretical Domains

contDiff_tanh

theoremverifiedformalizationimported Lean

Tanh(x) is n times continuously differentiable for all n

Statement

set_option autoImplicit true in
set_option relaxedAutoImplicit true in
open Real in
open NNReal in
open Field in
open scoped ContDiff in
lemma contDiff_tanh {n : ℕ} : ContDiff ℝ n tanh
Formalizes
Physlib, `contDiff_tanh`
Lean proof
By Afiq Hatta, from github.com/leanprover-community/physlib at e411c6e89692 (Copyright (c) 2025 Afiq Hatta. All rights reserved, Apache-2.0). Compiled here against leanprover/lean4:v4.33.1, Mathlib v4.33.1; written for leanprover/lean4:v4.34.1.
Verified
09 Oct 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 2

Lean source view module on GitHub

set_option autoImplicit true inset_option relaxedAutoImplicit true inopen Real inopen NNReal inopen Field inopen scoped ContDiff in/-- Tanh(x) is n times continuously differentiable for all n -/lemma contDiff_tanh {n : ℕ} : ContDiff ℝ n tanh := by  have hdiv : ContDiff ℝ n (fun x => Real.sinh x / Real.cosh x) := by    apply ContDiff.div    · exact contDiff_sinh    · exact contDiff_cosh    · intro x      exact ne_of_gt (Real.cosh_pos x)  conv =>    enter [3, x]    rw [tanh_eq_sinh_div_cosh]  exact hdiv
See it in the graphDiscuss this resultChallenge it