AFTD Auto-Formalizing Theoretical Domains

nae_arccos_cos_le

theoremverified

For every nonnegative x, arccos(cos x) ≤ x.

Statement

theorem nae_arccos_cos_le (x : ℝ) (hx : 0 ≤ x) : Real.arccos (Real.cos x) ≤ x
Source
arXiv:1211.0721, Section 3.3, p-computation rule analysis
Verified
14 Nov 2026
Axioms
Classical.choiceQuot.soundpropext
Used by 2
  • nae_p_schedule_potential_strongFor every triple (d, θ, q) in nae_p_schedule, 0 ≤ θ ≤ π, q ≥ 0, and θ ≤ πq(5/12)^d.
  • nae_p_schedule_potentialFor every triple (d, θ, q) reachable by the specified p-computation rule schedule, 0 ≤ θ ≤ π, q ≥ 0, and θ ≤ πq(15/32)^d.

The proof, explained

The proof splits into two cases based on whether $x \le \pi$. When $0 \le x \le \pi$, the arccosine function inverts cosine directly, so $\arccos(\cos x) = x \le x$. When $x > \pi$, the claim follows by chaining the universal upper bound $\arccos(\cos x) \le \pi$ with $\pi \le x$.

  1. We distinguish two cases: either $x \le \pi$ or $x > \pi$.

    We split into cases depending on whether the inequality $x \le \pi$ holds or not.

    line 2

      by_cases h : x ≤ Real.pi
  2. If $x \le \pi$, then $\arccos(\cos x) \le x$.

    Since $0 \le x$ (by assumption $hx$) and $x \le \pi$ (by assumption $h$), $\arccos(\cos x)$ equals $x$ by `Real.arccos_cos`. Rewriting with this identity turns the inequality into $x \le x$, which holds reflexively.

    line 3

    uses Real.arccos_cos

      · rw [Real.arccos_cos hx h]
  3. If $x > \pi$, then $\arccos(\cos x) \le x$.

    By `Real.arccos_le_pi`, $\arccos(\cos x) \le \pi$. From the case hypothesis $\neg(x \le \pi)$, `le_of_not_ge` gives $\pi \le x$. Transitivity of $\le$ (`le_trans`) combines these to conclude $\arccos(\cos x) \le x$.

    line 4

    uses le_trans, Real.arccos_le_pi, le_of_not_ge

      · exact le_trans (Real.arccos_le_pi _) (le_of_not_ge h)
Real.arccos_cos
For any $x \in \mathbb{R}$ such that $0 \le x$ and $x \le \pi$, $\arccos(\cos x) = x$.
Real.arccos_le_pi
For any $x \in \mathbb{R}$, $\arccos x \le \pi$.
le_of_not_ge
In a linear order, if $\neg(a \le b)$, then $b \le a$.
le_trans
In a preorder, if $a \le b$ and $b \le c$, then $a \le c$.

Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.

Lean source view module on GitHub

theorem nae_arccos_cos_le (x : ℝ) (hx : 0 ≤ x) : Real.arccos (Real.cos x) ≤ x := by  by_cases h : x ≤ Real.pi  · rw [Real.arccos_cos hx h]  · exact le_trans (Real.arccos_le_pi _) (le_of_not_ge h)
See it in the graphDiscuss this resultChallenge it