There is a theorem which says that there exists two irrationals $x, y$ such that $x^y$ is rational.
An interesting proof in classical logic is the following:
Consider $u = \sqrt{2}^{\sqrt{2}}$.
If $u$ is rational then we use $(x,y) = (\sqrt{2},\sqrt{2})$.
Otherwise, we notice that $u^\sqrt{2} = 2$ and use $(x,y) = (u,\sqrt{2})$.
I'd like to implement that proof in Lean (3) (the irrationality of $\sqrt{2}$ is already proven in mathlib).
I managed to write a signature of my theorem (execute):
import data.real.irrational
import analysis.special_functions.pow.real
open classical
theorem classical_logic_existence : ∃ x y : ℝ, irrational x ∧ irrational y ∧ ¬ (irrational (x.rpow y)) :=
sorry
My questions are:
- How can I use
x^y
instead of(x.rpow y)
? (just replacing it produces an error) - How would I implement my proof in Lean? I have no idea how to write the case disjunction and so on...
^
is just notation introduced somewhere, try to import a less basic file and you should get it. Concerning the real question, have you read TPIL or any other basic reference? $\endgroup$simp
can probably do it. I don't see whysimp
should do it automatically, it's easy, but there is no reason to have pow_two as asimp
lemma. $\endgroup$