From 2143193bce9a3a33e803ba417e0d0212f65ac2d9 Mon Sep 17 00:00:00 2001 From: subfishzhou Date: Wed, 4 Jun 2025 22:25:35 +0200 Subject: [PATCH 1/3] Build jsonl & Bump to v4.20.0 & fix file name --- formal/{Munkers.lean => Munkres.lean} | 0 formal/{Pough.lean => Pugh.lean} | 0 formal/Rudin.lean | 2 +- formal/{Shakarachi.lean => Shakarchi.lean} | 0 lake-manifest.json | 24 +- lakefile.lean | 2 +- lean-toolchain | 2 +- proofnet_lean4.jsonl | 374 +++++++++++++++++++++ script/build_proofnet_jsonl.py | 141 ++++++++ 9 files changed, 530 insertions(+), 15 deletions(-) rename formal/{Munkers.lean => Munkres.lean} (100%) rename formal/{Pough.lean => Pugh.lean} (100%) rename formal/{Shakarachi.lean => Shakarchi.lean} (100%) create mode 100644 proofnet_lean4.jsonl create mode 100644 script/build_proofnet_jsonl.py diff --git a/formal/Munkers.lean b/formal/Munkres.lean similarity index 100% rename from formal/Munkers.lean rename to formal/Munkres.lean diff --git a/formal/Pough.lean b/formal/Pugh.lean similarity index 100% rename from formal/Pough.lean rename to formal/Pugh.lean diff --git a/formal/Rudin.lean b/formal/Rudin.lean index 8f8fd87..090632c 100644 --- a/formal/Rudin.lean +++ b/formal/Rudin.lean @@ -76,7 +76,7 @@ theorem exercise_1_18a (n : ℕ) (h : n > 1) (x : EuclideanSpace ℝ (Fin n)) -- R^n - : ∃ (y : EuclideanSpace ℝ (Fin n)), y ≠ 0 ∧ (inner x y) = (0 : ℝ) := + : ∃ (y : EuclideanSpace ℝ (Fin n)), y ≠ 0 ∧ (inner ℝ x y) = (0 : ℝ) := sorry theorem exercise_1_18b diff --git a/formal/Shakarachi.lean b/formal/Shakarchi.lean similarity index 100% rename from formal/Shakarachi.lean rename to formal/Shakarchi.lean diff --git a/lake-manifest.json b/lake-manifest.json index 63029ca..e9bac1b 100644 --- a/lake-manifest.json +++ b/lake-manifest.json @@ -1,21 +1,21 @@ {"version": "1.1.0", "packagesDir": ".lake/packages", "packages": - [{"url": "https://github.com/leanprover-community/mathlib4.git", + [{"url": "https://github.com/leanprover-community/mathlib4", "type": "git", "subDir": null, "scope": "", - "rev": "e04fe9d4ce0705c3e13ba74687cd32c8663792ad", + "rev": "c211948581bde9846a99e32d97a03f0d5307c31e", "name": "mathlib", "manifestFile": "lake-manifest.json", - "inputRev": null, + "inputRev": "v4.20.0", "inherited": false, "configFile": "lakefile.lean"}, {"url": "https://github.com/leanprover-community/plausible", "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "ebfb31672ab0a5b6d00a018ff67d2ec51ed66f3a", + "rev": "2ac43674e92a695e96caac19f4002b25434636da", "name": "plausible", "manifestFile": "lake-manifest.json", "inputRev": "main", @@ -25,7 +25,7 @@ "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "8d29bc2c3ebe1f863c2f02df816b4f3dd1b65226", + "rev": "6c62474116f525d2814f0157bb468bf3a4f9f120", "name": "LeanSearchClient", "manifestFile": "lake-manifest.json", "inputRev": "main", @@ -35,7 +35,7 @@ "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "c96401869916619b86e2e54dbb8e8488bd6dd19c", + "rev": "a11bcb5238149ae5d8a0aa5e2f8eddf8a3a9b27d", "name": "importGraph", "manifestFile": "lake-manifest.json", "inputRev": "main", @@ -45,17 +45,17 @@ "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "a602d13aca2913724c7d47b2d7df0353620c4ee8", + "rev": "21e6a0522cd2ae6cf88e9da99a1dd010408ab306", "name": "proofwidgets", "manifestFile": "lake-manifest.json", - "inputRev": "v0.0.53", + "inputRev": "v0.0.60", "inherited": true, "configFile": "lakefile.lean"}, {"url": "https://github.com/leanprover-community/aesop", "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "471ff276892c3451a1d693477107e9c3a0c8ab85", + "rev": "ddfca7829bf8aa4083cdf9633935dddbb28b7b2a", "name": "aesop", "manifestFile": "lake-manifest.json", "inputRev": "master", @@ -65,7 +65,7 @@ "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "d892d7a88ad0ccf748fb8e651308ccd13426ba73", + "rev": "2865ea099ab1dd8d6fc93381d77a4ac87a85527a", "name": "Qq", "manifestFile": "lake-manifest.json", "inputRev": "master", @@ -75,7 +75,7 @@ "type": "git", "subDir": null, "scope": "leanprover-community", - "rev": "242359385321fb424299299300c688f697f7ba5b", + "rev": "7a0d63fbf8fd350e891868a06d9927efa545ac1e", "name": "batteries", "manifestFile": "lake-manifest.json", "inputRev": "main", @@ -85,7 +85,7 @@ "type": "git", "subDir": null, "scope": "leanprover", - "rev": "dd423cf2b153b5b14cb017ee4beae788565a3925", + "rev": "f9e25dcbed001489c53bceeb1f1d50bbaf7451d4", "name": "Cli", "manifestFile": "lake-manifest.json", "inputRev": "main", diff --git a/lakefile.lean b/lakefile.lean index a54a2ba..3d15d2e 100644 --- a/lakefile.lean +++ b/lakefile.lean @@ -6,7 +6,7 @@ package «proofNet-lean4» { } require mathlib from git - "https://github.com/leanprover-community/mathlib4.git" + "https://github.com/leanprover-community/mathlib4.git" @ "v4.20.0" @[default_target] lean_lib «ProofNetLean4» { diff --git a/lean-toolchain b/lean-toolchain index 62e3298..52fe774 100644 --- a/lean-toolchain +++ b/lean-toolchain @@ -1 +1 @@ -leanprover/lean4:v4.18.0-rc1 +leanprover/lean4:v4.20.0 diff --git a/proofnet_lean4.jsonl b/proofnet_lean4.jsonl new file mode 100644 index 0000000..6c15b08 --- /dev/null +++ b/proofnet_lean4.jsonl @@ -0,0 +1,374 @@ +{"name": "Shakarchi_exercise_1_13a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13a {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).re = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Re}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Re}(f)=$ constant,\n$$\n\\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 .\n$$\nThus, in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\n3\nThus $f(z)$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_13b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13b {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).im = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Im}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Im}(f)=$ constant,\n$$\n\\frac{\\partial v}{\\partial x}=0, \\frac{\\partial v}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial u}{\\partial x}=\\frac{\\partial v}{\\partial y}=0 .\n$$\nThus in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\nThus $f$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_13c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13c {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, norm (f z) = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $|f|$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nWe first give a mostly correct argument; the reader should pay attention to find the difficulty. Since $|f|=\\sqrt{u^2+v^2}$ is constant,\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{gathered}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 \\\\\n(1.14) \\Rightarrow \\frac{\\partial v}{\\partial x}=\\frac{v}{u} \\frac{\\partial v}{\\partial y}\n\\end{gathered}\n$$\nPlug (1.15) into (1.13) and we get\n$$\n\\frac{u^2+v^2}{u} \\frac{\\partial v}{\\partial y}=0 .\n$$\nSo $u^2+v^2=0$ or $\\frac{\\partial v}{\\partial y}=0$.\n\nIf $u^2+v^2=0$, then, since $u, v$ are real, $u=v=0$, and thus $f=0$ which is constant.\n\nThus we may assume $u^2+v^2$ equals a non-zero constant, and we may divide by it. We multiply both sides by $u$ and find $\\frac{\\partial v}{\\partial y}=0$, then by (1.15), $\\frac{\\partial v}{\\partial x}=0$, and by Cauchy-Riemann, $\\frac{\\partial u}{\\partial x}=0$.\n$$\nf^{\\prime}=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0 .\n$$\nThus $f$ is constant.\nWhy is the above only mostly a proof? The problem is we have a division by $u$, and need to make sure everything is well-defined. Specifically, we need to know that $u$ is never zero. We do have $f^{\\prime}=0$ except at points where $u=0$, but we would need to investigate that a bit more.\nLet's return to\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{array}{r}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 .\n\\end{array}\n$$\nWe multiply the first equation $u$ and the second by $v$, and obtain\n$$\n\\begin{aligned}\nu^2 \\frac{\\partial v}{\\partial y}+u v \\frac{\\partial v}{\\partial x} & =0 \\\\\n-u v \\frac{\\partial v}{\\partial x}+v^2 \\frac{\\partial v}{\\partial y} & =0 .\n\\end{aligned}\n$$\nAdding the two yields\n$$\nu^2 \\frac{\\partial v}{\\partial y}+v^2 \\frac{\\partial v}{\\partial y}=0,\n$$\nor equivalently\n$$\n\\left(u^2+v^2\\right) \\frac{\\partial v}{\\partial y}=0 .\n$$\nWe now argue in a similar manner as before, except now we don't have the annoying $u$ in the denominator. If $u^2+v^2=0$ then $u=v=0$, else we can divide by $u^2+v^2$ and find $\\partial v / \\partial y=0$. Arguing along these lines finishes the proof.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19a (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z ^ i)) :\n ¬ ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum nz^n$ does not converge on any point of the unit circle.\n\\begin{proof}\n For $z \\in S:=\\{z \\in \\mathbb{C}:|z|=1\\}$ it also holds $z^n \\in S$ for all $n \\in \\mathbb{N}$ (since in this case $\\left.\\left|z^n\\right|=|z|^n=1^n=1\\right)$\nThus, the sequence $\\left(a_n\\right)_{n \\in \\mathbb{N}}$ with $a_n=n z^n$ does not converge to zero which is necessary for the corresponding sum $\\sum_{n \\in \\mathbb{N}} a_n$ to be convergent. Hence this sum does not converge.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19b (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i ^ 2)) :\n ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n^2$ converges at every point of the unit circle.\n\\begin{proof}\n Since $\\left|z^n / n^2\\right|=1 / n^2$ for all $|z|=1$, then $\\sum z^n / n^2$ converges at every point in the unit circle as $\\sum 1 / n^2$ does ( $p$-series $p=2$.)\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19c (z : ℂ) (hz : norm z = 1) (hz2 : z ≠ 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i)) :\n ∃ z, Tendsto s atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n$ converges at every point of the unit circle except $z = 1$.\n\\begin{proof}\n If $z=1$ then $\\sum z^n / n=\\sum 1 / n$ is divergent (harmonic series). If $|z|=1$ and $z \\neq 1$, write $z=e^{2 \\pi i t}$ with $t \\in(0,1)$ and apply Dirichlet's test: if $\\left\\{a_n\\right\\}$ is a sequence of real numbers and $\\left\\{b_n\\right\\}$ a sequence of complex numbers satisfying\n- $a_{n+1} \\leq a_n$\n- $\\lim _{n \\rightarrow \\infty} a_n=0$\n- $\\left|\\sum_{n=1}^N b_n\\right| \\leq M$ for every positive integer $N$ and some $M>0$,\nthen $\\sum a_n b_n$ converges. Let $a_n=1 / n$, so $a_n$ satisfies $a_{n+1} \\leq a_n$ and $\\lim _{n \\rightarrow \\infty} a_n=0$. Let $b_n=e^{2 \\pi i n t}$, then\n$$\n\\left|\\sum_{n=1}^N b_n\\right|=\\left|\\sum_{n=1}^N e^{2 \\pi i n t}\\right|=\\left|\\frac{e^{2 \\pi i t}-e^{2 \\pi i(N+1) t}}{1-e^{2 \\pi i t}}\\right| \\leq \\frac{2}{\\left|1-e^{2 \\pi i t}\\right|}=M \\text { for all } N\n$$\nThus $\\sum a_n b_n=\\sum z^n / n$ converges for every point in the unit circle except $z=1$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_26", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_26\n (f F₁ F₂ : ℂ → ℂ) (Ω : Set ℂ) (h1 : IsOpen Ω) (h2 : IsConnected Ω)\n (hF₁ : DifferentiableOn ℂ F₁ Ω) (hF₂ : DifferentiableOn ℂ F₂ Ω)\n (hdF₁ : ∀ x ∈ Ω, deriv F₁ x = f x) (hdF₂ : ∀ x ∈ Ω, deriv F₂ x = f x)\n : ∃ c : ℂ, ∀ x, F₁ x = F₂ x + c := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is continuous in a region $\\Omega$. Prove that any two primitives of $f$ (if they exist) differ by a constant.\n\\begin{proof}\n Suppose $F_1$ and $F_2$ are primitives of $F$. Then $(F_1-F_2)^\\prime = f - f = 0$, therefore $F_1$ and $F_2$ differ by a constant. \n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_2", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_2 :\n Tendsto (λ y => ∫ x in (0 : ℝ)..y, Real.sin x / x) atTop (𝓝 (Real.pi / 2)) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_{0}^{\\infty} \\frac{\\sin x}{x} d x=\\frac{\\pi}{2}$.\n\\begin{proof}\n We have $\\int_0^{\\infty} \\frac{\\sin x}{x} d x=\\frac{1}{2 * i} \\int_0^{\\infty} \\frac{e^{i * x}-e^{-i * x}}{x} d x=\\frac{1}{2 * i}\\left(\\int_0^{\\infty} \\frac{e^{i * x}-1}{x} d x-\\int_0^{\\infty} \\frac{e^{-i * x}-1}{x} d x=\\right.$ $\\frac{1}{2 * i} \\int_{-\\infty}^{\\infty} \\frac{e^{i * x}-1}{x} d x$. Now integrate along the big and small semicircles $C_0$ and $C_1$ shown below. For $C_0$ : we have that $\\int_{C_0} \\frac{1}{x} d x=\\pi * i$ and $\\left|\\int_{C_0} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $2 *\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right|+\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right|$ where $C_{00}$ and $C_{01}$ are shown below $\\left(C_{01}\\right.$ contains the part of $C_0$ that has points with imaginary parts more than $a$ and $C_{00}$ is one of the other 2 components). We have $\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $\\sup _{x \\in C_{00}}\\left(e^{i * x}\\right) / R * \\int_{C_{00}}|d x| \\leq e^{-a} * \\pi$ and $\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right| \\leq\\left|\\int_{C_{01}} \\frac{1}{x} d x\\right| \\leq$ $\\frac{1}{R} * C * a$ for some constant $C$ (the constant $C$ exists because the length of the curve approaches $a$ as $a / R \\rightarrow 0)$. Thus, the integral of $e^{i * x} / x$ over $C_0$ is bounded by $A * e^{-a}+B * a / R$ for some constants $A$ and $B$. Pick $R$ large and $a=\\sqrt{R}$ and note that the above tends to 0 . About the integral over $C_1$ : We have $e^{i * x}-1=1+O(x)$ for $x \\rightarrow 0$ (this is again from $\\sin (x) / x \\rightarrow 1$ ),\n4\nso $\\left|\\int_{C_1} \\frac{e^{i * x}-1}{x} d x\\right| \\leq O(1) *\\left|\\int_{C_1} d x\\right| \\rightarrow 0$ as $x \\rightarrow 0$. Thus, we only care about the integral over $C_{00}$ which is $-\\pi * i$. Using Cauchy's theorem we get that our integral equals $\\frac{1}{2 * i}(-(\\pi * i))=\\pi / 2$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_9\n {f : ℂ → ℂ} (Ω : Set ℂ) (b : Bornology.IsBounded Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (z : Ω) (hz : f z = z) (h'z : deriv f z = 1) :\n ∃ (f_lin : ℂ →L[ℂ] ℂ), ∀ x ∈ Ω, f x = f_lin x := sorry", "formal_proof": null, "informal_stmt": "Let $\\Omega$ be a bounded open subset of $\\mathbb{C}$, and $\\varphi: \\Omega \\rightarrow \\Omega$ a holomorphic function. Prove that if there exists a point $z_{0} \\in \\Omega$ such that $\\varphi\\left(z_{0}\\right)=z_{0} \\quad \\text { and } \\quad \\varphi^{\\prime}\\left(z_{0}\\right)=1$ then $\\varphi$ is linear.\n\\begin{proof}\n When $\\Omega$ is connected, if $\\varphi$ is not linear, then there exists $n \\geq 2$ and $a_n \\neq 0$, such that\n$$\n\\varphi(z)=z+a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nAs you have noticed, by induction, it follows that for every $k \\geq 1$,\n$$\n\\varphi^k(z)=z+k a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nLet $r>0$ be such that when $\\left|z-z_0\\right| \\leq r$, then $z \\in \\Omega$. Then by (1),\n$$\nk a_n=\\frac{1}{2 \\pi i} \\int_{\\left|z-z_0\\right|=r} \\frac{\\varphi^k(z)}{\\left(z-z_0\\right)^{n+1}} d z .\n$$\nSince $\\varphi^k(\\Omega) \\subset \\Omega$ and since $\\Omega$ is bounded, there exists $M>0$, independent of $k$, such that $\\left|\\varphi^k\\right| \\leq M$ on $\\Omega$. Then by (2),\n$$\nk\\left|a_n\\right| \\leq M r^{-n} .\n$$\nSince $k$ is arbitrary, $a_n=0$, a contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_13", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_13 {f : ℂ → ℂ}\n (hf : ∀ z₀ : ℂ, ∃ (s : Set ℂ) (c : ℕ → ℂ), IsOpen s ∧ z₀ ∈ s ∧\n ∀ z ∈ s, Tendsto (λ n => ∑ i ∈ range n, (c i) * (z - z₀)^i) atTop (𝓝 (f z₀))\n ∧ ∃ i, c i = 0) :\n ∃ (c : ℕ → ℂ) (n : ℕ), f = λ z => ∑ i ∈ range n, (c i) * z ^ n := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is an analytic function defined everywhere in $\\mathbb{C}$ and such that for each $z_0 \\in \\mathbb{C}$ at least one coefficient in the expansion $f(z) = \\sum_{n=0}^\\infty c_n(z - z_0)^n$ is equal to 0. Prove that $f$ is a polynomial.\n\\begin{proof}\nSay that at least one of the coefficients of the Taylor series vanishes is the same as saying that for every $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$.\nConsider $A_n:=\\left\\{z \\in \\mathbb{C}: f^{(n)}(z)=0\\right\\}$ for each $n \\in \\mathbb{N}$. Note that:\n$f$ is polynomial iff $A_n$ is not countable for some $n \\in \\mathbb{N}$.\nIndeed, if $f$ is polynomial of degree $n$, then $f^{(n+1)}(z)=0$ for all $z \\in \\mathbb{C}$, then $A_{n+1}=\\mathbb{C}$, so, $A_{n+1}$ is not countable. Conversely, if there is $n \\in \\mathbb{C}$ such that $A_n$ is not countable, then $A_n$ has a limit point, then by Identity principle we have $f^{(n)}(z)=0$ for all $z \\in \\mathbb{C}$, so, $f$ is a polynomial of degree at most $n-1$.\n\nTherefore, tt suffices to show that there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable. Indeed, consider $\\bigcup_{n \\in \\mathbb{N}} A_n$, by hypothesis for each $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$, then $\\mathbb{C} \\subseteq \\bigcup_{n \\in \\mathbb{N}} A_n$. Therefore, $\\bigcup_{n \\in \\mathbb{N}} A_n$ is not countable, then there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_3", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_3 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, Real.cos x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a) / a))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{\\cos x}{x^2 + a^2} dx = \\pi \\frac{e^{-a}}{a}$ for $a > 0$.\n\\begin{proof}\n $\\cos x=\\frac{e^{i x}+e^{-i x}}{2}$. changing $x \\rightarrow-x$ we see that we can just integrate $e^{i x} /\\left(x^2+a^2\\right)$ and we'll get the same answer. Again, we use the same semicircle and part of the real line. The only pole is $x=i a$, it has order 1 and the residue at it is $\\lim _{x \\rightarrow i a} \\frac{e^{i x}}{x^2+a^2}(x-i a)=\\frac{e^{-a}}{2 i a}$, which multiplied by $2 \\pi i$ gives the answer.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_4", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_4 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, x * Real.sin x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a)))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{x \\sin x}{x^2 + a^2} dx = \\pi e^{-a}$ for $a > 0$.\n\\begin{proof}\n$$\nx /\\left(x^2+a^2\\right)=x / 2 i a(1 /(x-i a)-1 /(x+i a))=1 / 2 i a(i a /(x-i a)+i a /(x+\n$$\n$i a))=(1 /(x-i a)+1 /(x+i a)) / 2$. So we care about $\\sin (x)(1 /(x-i a)+$ $1 /(x+i a)) / 2$. Its residue at $x=i a$ is $\\sin (i a) / 2=\\left(e^{-a}-e^a\\right) / 4 i$.?\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_9 : ∫ x in (0 : ℝ)..(1 : ℝ), Real.log (Real.sin (Real.pi * x)) = - Real.log 2 := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_0^1 \\log(\\sin \\pi x) dx = - \\log 2$.\n\\begin{proof}\nConsider\n$$\n\\begin{gathered}\nf(z)=\\log \\left(1-e^{2 \\pi z i}\\right)=\\log \\left(e^{\\pi z i}\\left(e^{-\\pi z i}-e^{\\pi z i}\\right)\\right)=\\log (-2 i)+\\pi z i+\\log \\\\\n(\\sin (\\pi z))\n\\end{gathered}\n$$\nThen we have\n$$\n\\begin{aligned}\n\\int_0^1 f(z) d z & =\\log (-2 i)+\\frac{i \\pi}{2}+\\int_0^1 \\log (\\sin (\\pi z)) d z \\\\\n& =\\int_0^1 \\log (\\sin (\\pi z)) d z+\\log (-2 i)+\\log (i) \\\\\n& =\\log (2)+\\int_0^1 \\log (\\sin (\\pi z)) d z\n\\end{aligned}\n$$\nNow it suffices to show that $\\int_0^1 f(z) d z=0$. Consider the contour $C(\\epsilon, R)$ (which is the contour given in your question) given by the following.\n1. $C_1(\\epsilon, R)$ : The vertical line along the imaginary axis from $i R$ to $i \\epsilon$.\n2. $C_2(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 0 .\n3. $C_3(\\epsilon)$ : Along the real axis from $(\\epsilon, 1-\\epsilon)$.\n4. $C_4(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 1 .\n5. $C_5(\\epsilon, R)$ : The vertical line from $1+i \\epsilon$ to $1+i R$.\n6. $C_6(R)$ : The horizontal line from $1+i R$ to $i R$.\n$f(z)$ is analytic inside the contour $C$ and hence $\\oint_C f(z)=0$. This gives us\n$$\n\\begin{aligned}\n\\int_{C_1(\\epsilon, R)} f d z+\\int_{C_2(\\epsilon)} f d z+\\int_{C_3(\\epsilon)} f d z+\\int_{C_4(\\epsilon)} f d z+\\int_{C_5(\\epsilon, R)} f d z+\\int_{C_6(R)} f d z \\\\\n=0\n\\end{aligned}\n$$\nNow the integral along 1 cancels with the integral along 5 due to symmetry. Integrals along 2 and 4 scale as $\\epsilon \\log (\\epsilon)$. Integral along 6 goes to 0 as $R \\rightarrow \\infty$. This gives us\n$$\n\\lim _{\\epsilon \\rightarrow 0} \\int_{C_3(\\epsilon)} f d z=0\n$$\nwhich is what we need.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_14", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_14 {f : ℂ → ℂ} (hf : Differentiable ℂ f)\n (hf_inj : Function.Injective f) :\n ∃ (a b : ℂ), f = (λ z => a * z + b) ∧ a ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that all entire functions that are also injective take the form $f(z) = az + b$, $a, b \\in \\mathbb{C}$ and $a \\neq 0$.\n\\begin{proof}\nLook at $f(1 / z)$. If it has an essential singularity at 0 , then pick any $z_0 \\neq 0$. Now we know that the range of $f$ is dense as $z \\rightarrow 0$. We also know that the image of $f$ in some small ball around $z_0$ contains a ball around $f\\left(z_0\\right)$. But this means that the image of $f$ around this ball intersects the image of $f$ in any arbitrarily small ball around 0 (because of the denseness). Thus, $f$ cannot be injective. So the singularity at 0 is not essential, so $f(1 / z)$ is some polynomial of $1 / z$, so $f$ is some polynomial of $z$. If its degree is more than 1 it is not injective (fundamental theorem of algebra), so the degree of $f$ is 1 .\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_22", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_22 (D : Set ℂ) (hD : D = ball 0 1) (f : ℂ → ℂ)\n (hf : DifferentiableOn ℂ f D) (hfc : ContinuousOn f (closure D)) :\n ¬ ∀ z ∈ (sphere (0 : ℂ) 1), f z = 1 / z := sorry", "formal_proof": null, "informal_stmt": "Show that there is no holomorphic function $f$ in the unit disc $D$ that extends continuously to $\\partial D$ such that $f(z) = 1/z$ for $z \\in \\partial D$.\n\\begin{proof}\n Consider $g(r)=\\int_{|z|=r} f(z) d z$. Cauchy theorem implies that $g(r)=0$ for all $r<1$. Now since $\\left.f\\right|_{\\partial D}=1 / z$ we have $\\lim _{r \\rightarrow 1} \\int_{|z|=r} f(z) d z=\\int_{|z|=1} \\frac{1}{z} d z=\\frac{2}{\\pi i} \\neq 0$. Contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_5_1", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_5_1 (f : ℂ → ℂ) (hf : DifferentiableOn ℂ f (ball 0 1))\n (hb : Bornology.IsBounded (Set.range f)) (h0 : f ≠ 0) (zeros : ℕ → ℂ) (hz : ∀ n, f (zeros n) = 0)\n (hzz : Set.range zeros = {z | f z = 0 ∧ z ∈ (ball (0 : ℂ) 1)}) :\n ∃ (z : ℂ), Tendsto (λ n => (∑ i ∈ range n, (1 - zeros i))) atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $f$ is holomorphic in the unit disc, bounded and not identically zero, and $z_{1}, z_{2}, \\ldots, z_{n}, \\ldots$ are its zeros $\\left(\\left|z_{k}\\right|<1\\right)$, then $\\sum_{n}\\left(1-\\left|z_{n}\\right|\\right)<\\infty$.\n\\begin{proof}\n Fix $\\mathrm{N}$ and let $D(0, R)$ contains the first $\\mathrm{N}$ zeroes of f. Let $S_N=\\sum_{k=1}^N\\left(1-\\left|z_k\\right|\\right)=$ $\\sum_{k=1}^N \\int_{\\left|z_k\\right|}^1 1 d r$. Let $\\eta_k$ be the characteristic function of the interval $\\left.\\| z_k \\mid, 1\\right]$. We have $S_N=\\sum_{k=1}^N \\int_0^1 \\eta(r) d r=\\int_0^1\\left(\\sum_{k=1}^N \\eta_k(r)\\right) d r \\leq \\int_0^1 n(r) d r$, where $n(r)$ is the number of zeroes of $f$ at the disk $D(0, r)$. For $r \\leq 1$ we have $n(r) \\leq \\frac{n(r)}{r}$. This means that $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}$. If $f(0)=0$ then we have $f(z)=z^m g(z)$ for some integer $\\mathrm{m}$ and some holomorphic $g$ with $g(0) \\neq 0$. The other zeroes of $\\mathrm{f}$ are precisely the zeroes of $g$. Thus we have reduced the problem to $f(0) \\neq 0$. By the Corollary of the Jensen's equality we get $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}=\\frac{1}{2 \\pi} \\int_0^{2 \\pi} \\log \\left|f\\left(R e^{i \\pi}\\right)\\right| d \\phi-\\log |f(0)|j$ (just reverse the roles of $i$ and $j$ otherwise). Then multiply both sides by $\\left(a^j\\right)^{-1}=a^{-j}$ to get\n$$\na^i * a^{-j}=a^{i-j}=e\n$$\nThus the $n=i-j$ is a positive integer such that $a^n=e$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 0$ such that $a^m = e$ for all $a \\in G$.\n\\begin{proof}\n Let $n_1, n_2, \\ldots, n_k$ be the orders of all $k$ elements of $G=$ $\\left\\{a_1, a_2, \\ldots, a_k\\right\\}$. Let $m=\\operatorname{lcm}\\left(n_1, n_2, \\ldots, n_k\\right)$. Then, for any $i=$ $1, \\ldots, k$, there exists an integer $c$ such that $m=n_i c$. Thus\n$$\na_i^m=a_i^{n_i c}=\\left(a_i^{n_i}\\right)^c=e^c=e\n$$\nHence $m$ is a positive integer such that $a^m=e$ for all $a \\in G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n ∀ a b : G, (a*b)^i = a^i * b^i}\n (hP1 : ∃ n : ℕ, P n ∧ P (n+1) ∧ P (n+2)) : CommGroup G := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group in which $(a b)^{i}=a^{i} b^{i}$ for three consecutive integers $i$, prove that $G$ is abelian.\n\\begin{proof}\n Let $G$ be a group, $a, b \\in G$ and $i$ be any integer. Then from given condition,\n$$\n\\begin{aligned}\n(a b)^i & =a^i b^i \\\\\n(a b)^{i+1} & =a^{i+1} b^{i+1} \\\\\n(a b)^{i+2} & =a^{i+2} b^{i+2}\n\\end{aligned}\n$$\nFrom first and second, we get\n$$\na^{i+1} b^{i+1}=(a b)^i(a b)=a^i b^i a b \\Longrightarrow b^i a=a b^i\n$$\nFrom first and third, we get\n$$\na^{i+2} b^{i+2}=(a b)^i(a b)^2=a^i b^i a b a b \\Longrightarrow a^2 b^{i+1}=b^i a b a\n$$\nThis gives\n$$\na^2 b^{i+1}=a\\left(a b^i\\right) b=a b^i a b=b^i a^2 b\n$$\nFinally, we get\n$$\nb^i a b a=b^i a^2 b \\Longrightarrow b a=a b\n$$\nThis shows that $G$ is Abelian.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1)\n (h : ∀ (a b : G), (a * b) ^ n = a ^ n * b ^ n) :\n ∀ (a b : G), (a * b * a⁻¹ * b⁻¹) ^ (n * (n - 1)) = 1 := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a group in which $(a b)^{n}=a^{n} b^{n}$ for some fixed integer $n>1$ for all $a, b \\in G$. For all $a, b \\in G$, prove that $\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e$. \n\\begin{proof}\n We start with the following two intermediate results.\n(1) $(a b)^{n-1}=b^{n-1} a^{n-1}$.\n(2) $a^n b^{n-1}=b^{n-1} a^n$.\nTo prove (1), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen,\n$(b a)^n=b^n a^n \\Longrightarrow b .(a b)(a b) \\ldots .(a b) . a=b\\left(b^{n-1} a^{n-1}\\right) a$, where $(a b)$ occurs $n-1$ times $\\Longrightarrow(a b)^{n-1}=b^{n-1} a^{n-1}$, by cancellation law.\nHence, for all $a, b \\in G$\n$$\n(a b)^{n-1}=b^{n-1} a^{n-1} .\n$$\nTo prove (2), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen we have\n$$\n\\begin{aligned}\n& (b a)^n=b^n a^n \\\\\n\\Longrightarrow & b \\cdot(a b)(a b) \\ldots(a b) \\cdot a=b\\left(b^{n-1} a^{n-1}\\right) a, \\text { where }(a b) \\text { occurs } n-1 \\text { times } \\\\\n\\Longrightarrow & (a b)^{n-1}=b^{n-1} a^{n-1}, \\text { by cancellation law } \\\\\n\\Longrightarrow & (a b)^{n-1}(a b)=\\left(b^{n-1} a^{n-1}\\right)(a b) \\\\\n\\Longrightarrow & (a b)^n=b^{n-1} a^n b \\\\\n\\Longrightarrow & a^n b^n=b^{n-1} a^n b, \\text { given condition } \\\\\n\\Longrightarrow & a^n b^{n-1}=b^{n-1} a^n, \\text { by cancellation law. }\n\\end{aligned}\n$$\nTherefore for all $a, b \\in G$ we have\n$$\na^n b^{n-1}=b^{n-1} a^n\n$$\nIn order to show that\n$$\n\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { for all } a, b \\in G\n$$\nit is enough to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nStep 3\nThis is because of\n$$\n\\begin{aligned}\n(a b)^{n(n-1)}=(b a)^{n(n-1)} & \\left.\\Longrightarrow(b a)^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(a^{-1} b^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}\\left((a b)^n\\right)(n-1)=e \\\\\n& \\Longrightarrow\\left((a b)^n\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}=e, \\text { by }(1) \\\\\n& \\Longrightarrow\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { ( given condition) }\n\\end{aligned}\n$$\nNow, it suffices to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nNow, we have\n$$\n\\begin{aligned}\n(a b)^{n(n-1)} & =\\left(a^n b^n\\right)^{n-1}, \\text { by the given condition } \\\\\n& =\\left(a^n b^{n-1} b\\right)^{n-1} \\\\\n& =\\left(b^{n-1} a^n b\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^n b\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =b^{n-1}\\left(a^n\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =\\left(b^{n-1}\\left(a^{n-1}\\right)^n\\right)\\left(b^{n-1}\\right)^{n-1} \\\\\n& =\\left(a^{n-1}\\right)^n b^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^{n-1}\\right)^n\\left(b^{n-1}\\right)^n \\\\\n& =\\left(a^{n-1} b^{n-1}\\right)^n, \\text { by }(1) \\\\\n& =(b a)^{n(n-1)}, \\text { by }(1) .\n\\end{aligned}\n$$\nThis completes our proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x⁻¹*g*x) '' (centralizer {a}) := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group and $a, x \\in G$, prove that $C\\left(x^{-1} a x\\right)=x^{-1} C(a) x$\n\\begin{proof}\n Note that\n$$\nC(a):=\\{x \\in G \\mid x a=a x\\} .\n$$\nLet us assume $p \\in C\\left(x^{-1} a x\\right)$. Then,\n$$\n\\begin{aligned}\n& p\\left(x^{-1} a x\\right)=\\left(x^{-1} a x\\right) p \\\\\n\\Longrightarrow & \\left(p x^{-1} a\\right) x=x^{-1}(a x p) \\\\\n\\Longrightarrow & x\\left(p x^{-1} a\\right)=(a x p) x^{-1} \\\\\n\\Longrightarrow & \\left(x p x^{-1}\\right) a=a\\left(x p x^{-1}\\right) \\\\\n\\Longrightarrow & x p x^{-1} \\in C(a) .\n\\end{aligned}\n$$\nTherefore,\n$$\np \\in C\\left(x^{-1} a x\\right) \\Longrightarrow x p x^{-1} \\in C(a) .\n$$\nThus,\n$$\nC\\left(x^{-1} a x\\right) \\subset x^{-1} C(a) x .\n$$\nLet us assume\n$$\nq \\in x^{-1} C(a) x .\n$$\nThen there exists an element $y$ in $C(a)$ such that\n$$\nq=x^{-1} y x\n$$\nNow,\n$$\ny \\in C(a) \\Longrightarrow y a=a y .\n$$\nAlso,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=x^{-1}(y a) x=x^{-1}(y a) x=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q .\n$$\nTherefore,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q\n$$\nSo,\n$$\nq \\in C\\left(x^{-1} a x\\right) .\n$$\nConsequently we have\n$$\nx^{-1} C(a) x \\subset C\\left(x^{-1} a x\\right) .\n$$\nIt follows from the aforesaid argument\n$$\nC\\left(x^{-1} a x\\right)=x^{-1} C(a) x .\n$$\nThis completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1) :\n n ∣ (a ^ n - 1).totient := sorry", "formal_proof": null, "informal_stmt": "If $a > 1$ is an integer, show that $n \\mid \\varphi(a^n - 1)$, where $\\phi$ is the Euler $\\varphi$-function.\n\\begin{proof}\n Proof: We have $a>1$. First we propose to prove that\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nIf possible, let us assume that\n$\\operatorname{Gcd}\\left(a, a^n-1\\right)=d$, where $d>1$.\nThen\n$d$ divides $a$ as well as $a^n-1$.\nNow,\n$d$ divides $a \\Longrightarrow d$ divides $a^n$.\nThis is an impossibility, since $d$ divides $a^n-1$ by our assumption. Consequently, $d$ divides 1 , which implies $d=1$. Hence we are contradict to the fact that $d>1$. Therefore\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nThen $a \\in U_{a^n-1}$, where $U_n$ is a group defined by\n$$\nU_n:=\\left\\{\\bar{a} \\in \\mathbb{Z}_n \\mid \\operatorname{Gcd}(a, n)=1\\right\\} .\n$$\nWe know that order of an element divides the order of the group. Here order of the group $U_{a^n-1}$ is $\\phi\\left(a^n-1\\right)$ and $a \\in U_{a^n-1}$. This follows that $\\mathrm{o}(a)$ divides $\\phi\\left(a^n-1\\right)$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $nn$. By lagrange's theorem then $p^{2 n-s}\\left|p^n m \\Longrightarrow p^{n-s}\\right| m \\Longrightarrow p \\mid m$-contradiction. So $\\phi(H)=H$, and $H$ is characteristic subgroup of $G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n\\frac{|G|}{2}$, where\n$$\nb^{-1} A=\\left\\{b^{-1} a \\mid a \\in A\\right\\}\n$$\nFirst notice that if we consider a map $f: A \\rightarrow b^{-1} A$ defined by $f(a)=b^{-1} a$, for all $a \\in A$, then $f$ is a 1-1 map and so $\\left|b^{-1} A\\right| \\geq|A|>\\frac{3}{4}|G|$. Now using inclusion-exclusion principle we have\n$$\n\\left|A \\cap\\left(b^{-1} A\\right)\\right|=|A|+\\left|b^{-1} A\\right|-\\left|A \\cup\\left(b^{-1} A\\right)\\right|>\\frac{3}{4}|G|+\\frac{3}{4}|G|-|G|=\\frac{1}{2}|G|\n$$\n2. Argue that $A \\cap\\left(b^{-1} A\\right) \\subseteq C(b)$, where $C(b)$ is the centralizer of $b$ in $G$.\n\nSuppose $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in A$ and $x \\in b^{-1} A$. Thus there exist an element $a \\in A$ such that $x=$ $b^{-1} a$, which gives us $x b=a \\in A$. Now notice that $x, b \\in A$ and $x b \\in A$, therefore we get\n$$\n\\phi(x b)=(x b)^{-1} \\Longrightarrow \\phi(x) \\phi(b)=(x b)^{-1} \\Longrightarrow x^{-1} b^{-1}=b^{-1} x^{-1} \\Longrightarrow x b=b x\n$$\nTherefore, we get $x b=b x$, for any $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in C(b)$.\n\n3. Argue that $C(b)=G$.\nWe know that centralizer of an element in a group $G$ is a subgroup (See Page 53). Therefore $C(b)$ is a subgroup of $G$. From statements $\\mathbf{1}$ and $\\mathbf{2}$, we have\n$$\n|C(b)| \\geq\\left|A \\cap\\left(b^{-1} A\\right)\\right|>\\frac{|G|}{2}\n$$\nWe need to use the following remark to argue $C(b)=G$ from the above step.\nRemark. Let $G$ be a finite group and $H$ be a subgroup with more then $|G| / 2$ elements then $H=G$.\n\nProof of Remark. Suppose $|H|=p$ Then by Lagrange Theorem, there exist an $n \\in \\mathbb{N}$, such that $|G|=n p$, as $|H|$ divide $|G|$. Now by hypothesis $p>\\frac{G]}{2}$ gives us,\n$$\np>\\frac{|G|}{2} \\Longrightarrow n p>\\frac{n|G|}{2} \\Longrightarrow n<2 \\Longrightarrow n=1\n$$\nTherefore we get $H=G$.\n\nNow notice that $C(b)$ is a subgroup of $G$ with $C(b)$ having more than $|G| / 2$ elements. Therefore, $C(b)=G$.\n\n4. Show that $A \\in Z(G)$.\n\nWe know that $x \\in Z(G)$ if and only if $C(a)=G$. Now notice that, for any $b \\in A$ we have $C(b)=G$. Therefore, every element of $A$ is in the center of $G$, that means, $A \\subseteq Z(G)$.\n\n5. 5how that $Z(G)=G$.\n\nAs it is given that $|A|>\\frac{3|G|}{4}$ and $A \\leq|Z(G)|$, therefore we get\n$$\n|Z(G)|>\\frac{3}{4}|G|>\\frac{1}{2}|G| .\n$$\nAs $Z(G)$ is a subgroup of $G$, so by the above Remark we have $Z(G)=G$. Hence $G$ is abelian.\n\n6. Finally show that $A=G$.\n\nFirst notice that $A$ is a subgroup of $G$. To show this let $p, q \\in A$. Then we have\n$$\n\\phi(p q)=\\phi(p) \\phi(q)=p^{-1} q^{-1}=(q p)^{-1}=(p q)^{-1}, \\quad \\text { As } G \\text { is abelian. }\n$$\nTherefore, $p q \\in A$ and so we have $A$ is a subgroup of $G$. Again by applying the above remark. we get $A=G$. Therefore we have\n$$\n\\phi(y)=y^{-1}, \\quad \\text { for all } y \\in G\n$$\n\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n q) (h1 : q ∣ p - 1) (hG : card G = p*q) (hH : card G = p*q) :\n G ≃* H := sorry", "formal_proof": null, "informal_stmt": "Prove that if $p > q$ are two primes such that $q \\mid p - 1$, then any two nonabelian groups of order $pq$ are isomorphic.\n\\begin{proof}\n For a nonabelian group of order $p q$, the structure of the group $G$ is set by determining the relation $a b a^{-1}=b^{k^{\\frac{p-1}{q}}}$ for some generator $k$ of the cyclic group. Here we are using the fact that $k^{\\frac{p-1}{q}}$ is a generator for the unique subgroup of order $q$ in $U_p$ (a cyclic group of order $m$ has a unique subgroup of order $d$ for each divisor $d$ of $m$ ). The other possible generators of this subgroup are $k^{\\frac{l(p-1)}{q}}$ for each $1 \\leq l \\leq q-1$, so these give potentially new group structures. Let $G^{\\prime}$ be a group with an element $c$ of order $q$, an element $d$ of order $p$ with structure defined by the relation $c d c^{-1}=d^{k^{\\frac{l(p-1)}{q}}}$. We may then define\n$$\n\\begin{aligned}\n\\phi: G^{\\prime} & \\rightarrow G \\\\\nc & \\mapsto a^l \\\\\nd & \\mapsto b\n\\end{aligned}\n$$\nsince $c$ and $a^l$ have the same order and $b$ and $d$ have the same order this is a well defined function.\nSince\n$$\n\\begin{aligned}\n\\phi(c) \\phi(d) \\phi(c)^{-1} & =a^l b a^{-l} \\\\\n& =b^{\\left(k^{\\frac{p-1}{q}}\\right)^l} \\\\\n& =b^{k^{\\frac{l(p-1)}{q}}} \\\\\n& =\\phi(d)^{k^{\\frac{l(p-1)}{q}}}\n\\end{aligned}\n$$\n$\\phi\\left(c^i d^j\\right)=a^{l i} b^j=e$ only if $i=j=0$, so $\\phi$ is 1-to-l. Therefore $G$ and $G^{\\prime}$ are isomorphic and so up to isomorphism there is only one nonabelian group of order $p q$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n1$. Let $g^k$ be an element of $G$ and $h^j$ be an element of $H$. Since the lowest common multiple of $n$ and $m$ is lower than the product $n . m$, that is, $\\operatorname{lcm}(n, m)1$, then $Z(G)$, the center of $G$, has more than one element; that is, if $|G|=p^k$ with $k\\geq 1$, then $|Z(G)|>1$.\n\n\\textit{Proof of the lemma:} Consider the class equation\n$$\n|G|=|Z(G)|+\\sum_{a \\notin Z(G)}[G: C(a)],\n$$\nwhere $C(a)$ denotes the centralizer of $a$ in $G$. If $G=Z(G)$, then the lemma is immediate. Suppose $Z(G)$ is a proper subset of $G$ and consider an element $a\\in G$ such that $a\\notin Z(G)$. Then $C(a)$ is a proper subgroup of $G$. Since $C(a)$ is a subgroup of a $p$-group, $[G:C(a)]$ is divisible by $p$ for all $a\\notin Z(G)$. This implies that $p$ divides $|G|=|Z(G)|+\\sum_{a\\notin Z(G)} [G:C(a)]$.\n\nSince $p$ also divides $|G|$, it follows that $p$ divides $|Z(G)|$. Hence, $|Z(G)|>1$. $\\Box$\n\nThis proves our \\textbf{lemma}.\n\nWe will prove the result by induction on $n$.\nIf $n=1$, the $G$ is a cyclic group of prime order and hence every subgroup of $G$ is normal in $G$. Thus, the result is true for $n=1$.\nSuppose the result is true for all groups of order $p^m$, where $1 \\leq mp^{n-1}$. Thus, $|N(H)|=p^n$ and $N(H)=G$.\nIn this case $H$ is normal in $G$.\nLet $H=N(H)$. Then $Z(G)$, the center of $G$, is a subset of $H$ and $Z(G) \\neq$ $\\{e\\}$.\nBy Cauchy's theorem and the above Claim, there exists $a \\in Z(G)$ such that $o(a)=p$.\nLet $K=\\langle a\\rangle$, a cyclic group generated by $a$.\nThen $K$ is a normal subgroup of $G$ of order $p$. Now, $|H / K|=p^{n-2}$ and $|G / K|=p^{n-1}$.\nThus, by induction hypothesis, $H / K$ is a normal subgroup of $G / K$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n3$.\nLet us take $p=3$. Then the sum\n$$\n\\frac{1}{1}+\\frac{1}{2}+\\ldots+\\frac{1}{(p-1)}\n$$\nbecomes\n$$\n1+\\frac{1}{3-1}=1+\\frac{1}{2}=\\frac{3}{2} .\n$$\nTherefore in this case $\\quad \\frac{a}{b}=\\frac{3}{2} \\quad$ implies $3 \\mid a$, i.e. $p \\mid a$.\nNow for odd prime $p>3$.\nLet us consider $f(x)=(x-1)(x-2) \\ldots(x-(p-1))$.\nNow, by Fermat, we know that the coefficients of $f(x)$ other than the $x^{p-1}$ and $x^0$ are divisible by $p$.\nSo if,\n$$\n\\begin{array}{r}\nf(x)=x^{p-1}+\\sum_{i=0}^{p-2} a_i x^i \\\\\n\\text { and } p>3 .\n\\end{array}\n$$\nThen $p \\mid a_2$, and\n$$\nf(p) \\equiv a_1 p+a_0 \\quad\\left(\\bmod p^3\\right)\n$$\nBut we see that\n$$\nf(x)=(-1)^{p-1} f(p-x) \\text { for any } x,\n$$\nso if $p$ is odd,\n$$\nf(p)=f(0)=a_0,\n$$\nSo it follows that:\n$$\n0=f(p)-a_0 \\equiv a_1 p \\quad\\left(\\bmod p^3\\right)\n$$\nTherefore,\n$$\n0 \\equiv a_1 \\quad\\left(\\bmod p^2\\right) .\n$$\nHence,\n$$\n0 \\equiv a_1 \\quad(\\bmod p) .\n$$\nNow our sum is just $\\frac{a_1}{(p-1) !}=\\frac{a}{b}$.\nIt follows that $p$ divides $a$. This completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x^5 + sqrt 2 * x^3 + sqrt 5 * x^2 + sqrt 7 * x + 11)\n (ha : p a = 0) :\n ∃ p : Polynomial ℂ , p.degree < 80 ∧ a ∈ p.roots ∧\n ∀ n : p.support, ∃ a b : ℤ, p.coeff n = a / b := sorry", "formal_proof": null, "informal_stmt": "If $a \\in C$ is such that $p(a) = 0$, where $p(x) = x^5 + \\sqrt{2}x^3 + \\sqrt{5}x^2 + \\sqrt{7}x + \\sqrt{11}$, show that $a$ is algebraic over $\\mathbb{Q}$ of degree at most 80.\n\\begin{proof}\n Given $a \\in \\mathbb{C}$ such that $p(a)=0$, where\n$$\np(x)=x^5+\\sqrt{2} x^3+\\sqrt{5} x^2+\\sqrt{7} x+\\sqrt{11}\n$$\nHere, we note that $p(x) \\in \\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$ and\n$$\n\\begin{aligned}\n {[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): \\mathbb{Q}] } & =[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7})] \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}): \\mathbb{Q}(\\sqrt{2}, \\sqrt{5})] \\\\\n& \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}): \\mathbb{Q}(\\sqrt{2})] \\cdot[\\mathbb{Q}(\\sqrt{2}): \\mathbb{Q}] \\\\\n& =2 \\cdot 2 \\cdot 2 \\cdot 2 \\\\\n& =16\n\\end{aligned}\n$$\nHere, we note that $p(x)$ is of degree 5 over $\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. If $a$ is root of $p(x)$, then\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}]=[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\cdot 15\n$$\nand $[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\leq 5$. We get equality if $p(x)$ is irreducible over $Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. This gives\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}] \\leq 16 \\cdot 5=80\n$$\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n p (f n)) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Let $(p_n)$ be a sequence and $f:\\mathbb{N}\\to\\mathbb{N}$. The sequence $(q_k)_{k\\in\\mathbb{N}}$ with $q_k=p_{f(k)}$ is called a rearrangement of $(p_n)$. Show that if $f$ is an injection, the limit of a sequence is unaffected by rearrangement.\n\\begin{proof}\n Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_26", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_26 {M : Type*} [TopologicalSpace M]\n (U : Set M) : IsOpen U ↔ ∀ x ∈ U, ¬ ClusterPt x (𝓟 Uᶜ) := sorry", "formal_proof": null, "informal_stmt": "Prove that a set $U \\subset M$ is open if and only if none of its points are limits of its complement.\n\\begin{proof}\n Assume that none of the points of $U$ are limits of its complement, and let us prove that $U$ is open. Assume by contradiction that $U$ is not open, so there exists $p \\in M$ so that $\\forall r>0$ there exists $q \\in M$ with $d(p, q)0$ such that $d(p, x)0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_29", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_29 (M : Type*) [MetricSpace M]\n (O C : Set (Set M))\n (hO : O = {s | IsOpen s})\n (hC : C = {s | IsClosed s}) :\n ∃ f : O → C, Bijective f := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}$ be the collection of open subsets of a metric space $\\mathrm{M}$, and $\\mathcal{K}$ the collection of closed subsets. Show that there is a bijection from $\\mathcal{T}$ onto $\\mathcal{K}$.\n\\begin{proof}\n The bijection given by $x\\mapsto X^C$ suffices. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_32a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_32a (A : Set ℕ) : IsClopen A := sorry", "formal_proof": null, "informal_stmt": "Show that every subset of $\\mathbb{N}$ is clopen.\n\\begin{proof}\n 32. The one-point set $\\{n\\} \\subset \\mathbb{N}$ is open, since it contains all $m \\in \\mathbb{N}$ that satisfy $d(m, n)<\\frac{1}{2}$. Every subset of $\\mathbb{N}$ is a union of one-point sets, hence is open. Then every set it closed, since its complement is necessarily open.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_41", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_41 (m : ℕ) {X : Type*} [NormedSpace ℝ ((Fin m) → ℝ)] :\n IsCompact (Metric.closedBall 0 1) := sorry", "formal_proof": null, "informal_stmt": "Let $\\|\\cdot\\|$ be any norm on $\\mathbb{R}^{m}$ and let $B=\\left\\{x \\in \\mathbb{R}^{m}:\\|x\\| \\leq 1\\right\\}$. Prove that $B$ is compact.\n\\begin{proof}\n Let us call $\\|\\cdot\\|_E$ the Euclidean norm in $\\mathbb{R}^m$. We start by claiming that there exist constants $C_1, C_2>0$ such that\n$$\nC_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E, \\forall x \\in \\mathbb{R}^m .\n$$\nAssuming (1) to be true, let us finish the problem. First let us show that $B$ is bounded w.r.t. $d_E$, which is how we call the Euclidean distance in $\\mathbb{R}^m$. Indeed, given $x \\in B,\\|x\\|_E \\leq \\frac{1}{C_1}\\|x\\| \\leq \\frac{1}{C_1}$. Hence $B \\subset\\left\\{x \\in \\mathbb{R}^m: d_E(x, 0)<\\frac{1}{C_1}+1\\right\\}$, which means $B$ is bounded w.r.t $d_E$.\nNow let us show that $B$ is closed w.r.t. $d_E$. Let $x_n \\rightarrow x$ w.r.t. $d_E$, where $x_n \\in B$. Notice that this implies that $x_n \\rightarrow x$ w.r.t. $d(x, y)=\\|x-y\\|$, the distance coming from $\\|\\cdot\\|$, since by (1) we have\n$$\nd\\left(x_n, x\\right)=\\left\\|x_n-x\\right\\| \\leq C_2\\left\\|x_n-x\\right\\|_E \\rightarrow 0 .\n$$\nAlso, notice that\n$$\n\\|x\\| \\leq\\left\\|x_n-x\\right\\|+\\left\\|x_n\\right\\| \\leq\\left\\|x_n-x\\right\\|+1,\n$$\nhence passing to the limit we obtain that $\\|x\\| \\leq 1$, therefore $x \\in B$ and so $B$ is closed w.r.t. $d_E$. Since $B$ is closed and bounded w.r.t. $d_E$, it must be compact. Now we claim that the identity function, $i d:\\left(\\mathbb{R}^m, d_E\\right) \\rightarrow\\left(\\mathbb{R}^m, d\\right)$ where $\\left(\\mathbb{R}^m, d_E\\right)$ means we are using the distance $d_E$ in $\\mathbb{R}^m$ and $\\left(\\mathbb{R}^m, d\\right)$ means we are using the distance $d$ in $\\mathbb{R}^m$, is a homeomorphism. This follows by (1), since $i d$ is always a bijection, and it is continuous and its inverse is continuous by (1) (if $x_n \\rightarrow x$ w.r.t. $d_E$, then $x_n \\rightarrow x$ w.r.t. $d$ and vice-versa, by (1)). By a result we saw in class, since $B$ is compact in $\\left(\\mathbb{R}^m, d_E\\right)$ and $i d$ is a homeomorphism, then $i d(B)=B$ is compact w.r.t. $d$.\n\nWe are left with proving (1). Notice that it suffices to prove that $C_1 \\leq\\|x\\| \\leq$ $C_2, \\forall x \\in \\mathbb{R}^m$ with $\\|x\\|_E=1$. Indeed, if this is true, given $x \\in \\mathbb{R}^m$, either $\\|x\\|_E=0$ (which implies $x=0$ and (1) holds in this case), or $x /\\|x\\|_E=y$ is such that $\\|y\\|_E=1$, so $C_1 \\leq\\|y\\| \\leq C_2$, which implies $C_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E$.\nWe want to show now that $\\|\\cdot\\|$ is continuous w.r.t. $d_E$, that is, given $\\varepsilon>0$ and $x \\in \\mathbb{R}^m$, there exists $\\delta>0$ such that if $d_E(x, y)<\\delta$, then $\\|\\mid x\\|-\\|y\\| \\|<\\varepsilon$.\n\nBy the triangle inequality, $\\|x\\|-\\|y\\| \\leq\\|x-y\\|$, and $\\|y\\|-\\|x\\| \\leq\\|x-y\\|$, therefore\n$$\n|\\|x||-\\| y|\\|\\leq\\| x-y \\| .\n$$\nWriting now $x=\\sum_{i=1}^m a_i e_i, y=\\sum_{i=1}^m b_i e_i$, where $e_i=(0, \\ldots, 1,0, \\ldots, 0)$ (with 1 in the i-th component), we obtain by the triangle inequality,\n$$\n\\begin{aligned}\n\\|x-y\\| & =\\left\\|\\sum_{i=1}^m\\left(a_i-b_i\\right) e_i\\right\\| \\leq \\sum_{i=1}^m\\left|a_i-b_i\\left\\|\\left|\\left\\|e_i\\right\\| \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| \\sum_{i=1}^m\\right| a_i-b_i \\mid\\right.\\right. \\\\\n& =\\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| d_{s u m}(x, y) \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_{\\max }(x, y) \\\\\n& \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_E(x, y) .\n\\end{aligned}\n$$\nLet $\\delta=\\frac{\\varepsilon}{m \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\|}$. Then if $d_E(x, y)<\\delta,\\|x\\|-\\|y\\|||<\\varepsilon$.\nSince $\\|\\cdot\\|$ is continuous w.r.t. $d_E$ and $K=\\left\\{x \\in \\mathbb{R}^m:\\|x\\|_E=1\\right\\}$ is compact w.r.t. $d_E$, then the function $\\|\\cdot\\|$ achieves a maximum and a minimum value on $K$. Call $C_1=\\min _{x \\in K}\\|x\\|, C_2=\\max _{x \\in K}\\|x\\|$. Then\n$$\nC_1 \\leq\\|x\\| \\leq C_2, \\forall x \\in \\mathbb{R}^m \\text { such that }\\|x\\|_E=1,\n$$\nwhich is what we needed.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_46", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_46 {M : Type*} [MetricSpace M]\n {A B : Set M} (hA : IsCompact A) (hB : IsCompact B)\n (hAB : Disjoint A B) (hA₀ : A ≠ ∅) (hB₀ : B ≠ ∅) :\n ∃ a₀ b₀, a₀ ∈ A ∧ b₀ ∈ B ∧ ∀ (a : M) (b : M),\n a ∈ A → b ∈ B → dist a₀ b₀ ≤ dist a b := sorry", "formal_proof": null, "informal_stmt": "Assume that $A, B$ are compact, disjoint, nonempty subsets of $M$. Prove that there are $a_0 \\in A$ and $b_0 \\in B$ such that for all $a \\in A$ and $b \\in B$ we have $d(a_0, b_0) \\leq d(a, b)$.\n\\begin{proof}\nLet $A$ and $B$ be compact, disjoint and non-empty subsets of $M$. We want to show that there exist $a_0 \\in A, b_0 \\in B$ such that for all $a \\in A, b \\in B$,\n$$\nd\\left(a_0, b_0\\right) \\leq d(a, b) .\n$$\nWe saw in class that the distance function $d: M \\times M \\rightarrow \\mathbb{R}$ is continuous. We also saw in class that any continuous, real-valued function assumes maximum and minimum values on a compact set. Since $A$ and $B$ are compact, $A \\times B$ is (non-empty) compact in $M \\times M$. Therefore there exists $\\left(a_0, b_0\\right) \\in A \\times B$ such that $d\\left(a_0, b_0\\right) \\leq d(a, b), \\forall(a, b) \\in A \\times B$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_57", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_57 {X : Type*} [TopologicalSpace X]\n : ∃ (S : Set X), IsConnected S ∧ ¬ IsConnected (interior S) := sorry", "formal_proof": null, "informal_stmt": "Show that if $S$ is connected, it is not true in general that its interior is connected.\n\\begin{proof}\n Consider $X=\\mathbb{R}^2$ and\n$$\nA=([-2,0] \\times[-2,0]) \\cup([0,2] \\times[0,2])\n$$\nwhich is connected, while $\\operatorname{int}(A)$ is not connected.\nTo see this consider the continuous function $f: \\mathbb{R}^2 \\rightarrow \\mathbb{R}$ is defined by $f(x, y)=x+y$. Let $U=f^{-1}(0,+\\infty)$ which is open in $\\mathbb{R}^2$ and so $U \\cap \\operatorname{int}(A)$ is open in $\\operatorname{int}(A)$. Also, since $(0,0) \\notin \\operatorname{int}(A)$, so for all $(x, y) \\in \\operatorname{int}(A), f(x, y) \\neq 0$ and $U \\cap \\operatorname{int}(A)=f^{-1}[0,+\\infty) \\cap \\operatorname{int}(A)$ is closed in $\\operatorname{int}(A)$. Furthermore, $(1,1)=f^{-1}(2) \\in U \\cap \\operatorname{int}(A)$ shows that $U \\cap \\operatorname{int}(A) \\neq \\emptyset$ while $(-1,-1) \\in \\operatorname{int}(A)$ and $(-1,-1) \\notin U$ shows that $U \\cap \\operatorname{int}(A) \\neq \\operatorname{int}(A)$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_92", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_92 {α : Type*} [TopologicalSpace α]\n {s : ℕ → Set α}\n (hs : ∀ i, IsCompact (s i))\n (hs : ∀ i, (s i).Nonempty)\n (hs : ∀ i, (s i) ⊃ (s (i + 1))) :\n (⋂ i, s i).Nonempty := sorry", "formal_proof": null, "informal_stmt": "Give a direct proof that the nested decreasing intersection of nonempty covering compact sets is nonempty.\n\\begin{proof}\n Let\n$$\nA_1 \\supset A_2 \\supset \\cdots \\supset A_n \\supset \\cdots\n$$\nbe a nested decreasing sequence of compacts. Suppose that $\\bigcap A_n=\\emptyset$. Take $U_n=A_n^c$, then\n$$\n\\bigcup U_n=\\bigcup A_n^c=\\left(\\bigcap A_n\\right)^c=A_1 .\n$$\nHere, I'm thinking of $A_1$ as the main metric space. Since $\\left\\{U_n\\right\\}$ is an open covering of $A_1$, we can extract a finite subcovering, that is,\n$$\nA_{\\alpha_1}^c \\cup A_{\\alpha_2}^c \\cup \\cdots \\cup A_{\\alpha_m}^c \\supset A_1\n$$\nor\n$$\n\\left(A_1 \\backslash A_{\\alpha_1}\\right) \\cup\\left(A_1 \\backslash A_{\\alpha_2}\\right) \\cup \\cdots \\cup\\left(A_1 \\backslash A_{\\alpha_m}\\right) \\supset A_1 .\n$$\nBut, this is true only if $A_{\\alpha_i}=\\emptyset$ for some $i$, a contradiction.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_126", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_126 {E : Set ℝ}\n (hE : ¬ Set.Countable E) : ∃ (p : ℝ), ClusterPt p (𝓟 E) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $E$ is an uncountable subset of $\\mathbb{R}$. Prove that there exists a point $p \\in \\mathbb{R}$ at which $E$ condenses.\n\\begin{proof}\n I think this is the proof by contrapositive that you were getting at.\nSuppose that $E$ has no limit points at all. Pick an arbitrary point $x \\in E$. Then $x$ cannot be a limit point, so there must be some $\\delta>0$ such that the ball of radius $\\delta$ around $x$ contains no other points of $E$ :\n$$\nB_\\delta(x) \\cap E=\\{x\\}\n$$\nCall this \"point 1 \". For the next point, take the closest element to $x$ and on its left; that is, choose the point\n$$\n\\max [E \\cap(-\\infty, x)]\n$$\nif it exists (that is important - if not, skip to the next step). Note that by the argument above, this supremum, should it exist, cannot equal $x$ and is therefore a new point in $E$.\n\nCall this \"point 2 \". Now take the first point to the right of $x$ for \"point 3 \". Take the first point to the left of point 2 for \"point 4 \". And so on, ad infinitum.\n\nThis gives a countable list of unique points; we must show that it exhausts the entire set $E$. Suppose not. Suppose there is some element $aa_1 \\in E$ such that $a_2$ is not in the list. Repeating, we generate an infinite monotone-increasing sequence $\\left\\{a_i\\right\\}$ of elements in $E$ and not in the list, which is clearly bounded above by $x$. By the Monotone\nConvergence Theorem this sequence has a limit. But that means the sequence $\\left\\{a_i\\right\\} \\subset E$ converges to a limit, and hence $E$ has a limit point, contradicting the assumption. Therefore our list exhausts $E$, and we have enumerated all its elements.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_1", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_1 {f : ℝ → ℝ}\n (hf : ∀ x y, |f x - f y| ≤ |x - y| ^ 2) :\n ∃ c, f = λ x => c := sorry", "formal_proof": null, "informal_stmt": "Assume that $f \\colon \\mathbb{R} \\rightarrow \\mathbb{R}$ satisfies $|f(t)-f(x)| \\leq|t-x|^{2}$ for all $t, x$. Prove that $f$ is constant.\n\\begin{proof}\n We have $|f(t)-f(x)| \\leq|t-x|^2, \\forall t, x \\in \\mathbb{R}$. Fix $x \\in \\mathbb{R}$ and let $t \\neq x$. Then\n$$\n\\left|\\frac{f(t)-f(x)}{t-x}\\right| \\leq|t-x| \\text {, hence } \\lim _{t \\rightarrow x}\\left|\\frac{f(t)-f(x)}{t-x}\\right|=0 \\text {, }\n$$\nso $f$ is differentiable in $\\mathbb{R}$ and $f^{\\prime}=0$. This implies that $f$ is constant, as seen in class.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_4", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_4 (n : ℕ) :\n Tendsto (λ n => (sqrt (n + 1) - sqrt n)) atTop (𝓝 0) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sqrt{n+1}-\\sqrt{n} \\rightarrow 0$ as $n \\rightarrow \\infty$.\n\\begin{proof}\n $$\n\\sqrt{n+1}-\\sqrt{n}=\\frac{(\\sqrt{n+1}-\\sqrt{n})(\\sqrt{n+1}+\\sqrt{n})}{\\sqrt{n+1}+\\sqrt{n}}=\\frac{1}{\\sqrt{n+1}+\\sqrt{n}}<\\frac{1}{2 \\sqrt{n}}\n$$\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_63a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63a (p : ℝ) (f : ℕ → ℝ) (hp : p > 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ converges when $p > 1$.\n\\begin{proof}\n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_63b", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63b (p : ℝ) (f : ℕ → ℝ) (hp : p ≤ 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ¬ ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ diverges when $p \\leq 1$.\n\\begin{proof} \n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_4_15a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_4_15a {α : Type*}\n (a b : ℝ) (F : Set (ℝ → ℝ)) :\n (∀ x : ℝ, ∀ ε > 0, ∃ U ∈ (𝓝 x),\n (∀ y z : U, ∀ f : ℝ → ℝ, f ∈ F → (dist (f y) (f z) < ε)))\n ↔\n ∃ (μ : ℝ → ℝ), ∀ (x : ℝ), (0 : ℝ) ≤ μ x ∧ Tendsto μ (𝓝 0) (𝓝 0) ∧\n (∀ (s t : ℝ) (f : ℝ → ℝ), f ∈ F → |(f s) - (f t)| ≤ μ (|s - t|)) := sorry", "formal_proof": null, "informal_stmt": "A continuous, strictly increasing function $\\mu \\colon (0, \\infty) \\rightarrow (0, \\infty)$ is a modulus of continuity if $\\mu(s) \\rightarrow 0$ as $s \\rightarrow 0$. A function $f \\colon [a, b] \\rightarrow \\mathbb{R}$ has modulus of continuity $\\mu$ if $|f(s) - f(t)| \\leq \\mu(|s - t|)$ for all $s, t \\in [a, b]$. Prove that a function is uniformly continuous if and only if it has a modulus of continuity.\n\\begin{proof}\n Suppose there exists a modulus of continuity $w$ for $f$, then fix $\\varepsilon>0$, since $\\lim _{s \\rightarrow 0} w(s)=0$, there exists $\\delta>0$ such that for any $|s|<\\delta$, we have $w(s)<\\varepsilon$, then we have for any $x, z \\in X$ such that $d_X(x, z)<\\delta$, we have $d_Y(f(x), f(z)) \\leq w\\left(d_X(x, z)\\right)<\\varepsilon$, which means $f$ is uniformly continuous.\n\nSuppose $f:\\left(X, d_X\\right) \\rightarrow\\left(Y, d_Y\\right)$ is uniformly continuous.\nLet $\\delta_1>0$ be such that $d_X(a, b)<\\delta_1$ implies $d_Y(f(a), f(b))<1$.\nDefine $w:[0, \\infty) \\rightarrow[0, \\infty]$ by\n$$\nw(s)= \\begin{cases}\\left.\\sup \\left\\{d_Y(f(a), f(b))\\right\\} \\mid d_X(a, b) \\leq s\\right\\} & \\text { if } s \\leq \\delta_1 \\\\ \\infty & \\text { if } s>\\delta_1\\end{cases}\n$$\nWe'll show that $w$ is a modulus of continuity for $f \\ldots$\nBy definition of $w$, it's immediate that $w(0)=0$ and it's clear that\n$$\nd_Y(f(a), f(b)) \\leq w\\left(d_X(a, b)\\right)\n$$\nfor all $a, b \\in X$.\nIt remains to show $\\lim _{s \\rightarrow 0^{+}} w(s)=0$.\nIt's easily seen that $w$ is nonnegative and non-decreasing, hence $\\lim _{s \\rightarrow 0^{+}}=L$ for some $L \\geq 0$, where $L=\\inf w((0, \\infty))$\nLet $\\epsilon>0$.\nBy uniform continuity of $f$, there exists $\\delta>0$ such that $d_X(a, b)<\\delta$ implies $d_Y(f(a), f(b))<\\epsilon$, hence by definition of $w$, we get $w(\\delta) \\leq \\epsilon$.\nThus $L \\leq \\epsilon$ for all $\\epsilon>0$, hence $L=0$.\nThis completes the proof.\n\\end{proof}\n\\end{document}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Axler_exercise_1_2", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_2 :\n (⟨-1/2, Real.sqrt 3 / 2⟩ : ℂ) ^ 3 = -1 := sorry", "formal_proof": null, "informal_stmt": "Show that $\\frac{-1 + \\sqrt{3}i}{2}$ is a cube root of 1 (meaning that its cube equals 1).\n\\begin{proof}\n$$\n\\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2},\n$$\nhence\n$$\n\\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1\n$$\nThis means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_3", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_3 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] {v : V} : -(-v) = v := sorry", "formal_proof": null, "informal_stmt": "Prove that $-(-v) = v$ for every $v \\in V$.\n\\begin{proof}\n By definition, we have\n$$\n(-v)+(-(-v))=0 \\quad \\text { and } \\quad v+(-v)=0 .\n$$\nThis implies both $v$ and $-(-v)$ are additive inverses of $-v$, by the uniqueness of additive inverse, it follows that $-(-v)=v$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_4", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_4 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] (v : V) (a : F): a • v = 0 ↔ a = 0 ∨ v = 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that if $a \\in \\mathbf{F}$, $v \\in V$, and $av = 0$, then $a = 0$ or $v = 0$.\n\\begin{proof}\n If $a=0$, then we immediately have our result. So suppose $a \\neq 0$. Then, because $a$ is some nonzero real or complex number, it has a multiplicative inverse $\\frac{1}{a}$. Now suppose that $v$ is some vector such that\n$$\na v=0\n$$\nMultiply by $\\frac{1}{a}$ on both sides of this equation to get\n$$\n\\begin{aligned}\n\\frac{1}{a}(a v) & =\\frac{1}{a} 0 & & \\\\\n\\frac{1}{a}(a v) & =0 & & \\\\\n\\left(\\frac{1}{a} \\cdot a\\right) v & =0 & & \\text { (associativity) } \\\\\n1 v & =0 & & \\text { (definition of } 1/a) \\\\\nv & =0 & & \\text { (multiplicative identity) }\n\\end{aligned}\n$$\nHence either $a=0$ or, if $a \\neq 0$, then $v=0$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_6", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_6 : ∃ U : Set (ℝ × ℝ),\n (U ≠ ∅) ∧\n (∀ (u v : ℝ × ℝ), u ∈ U ∧ v ∈ U → u + v ∈ U) ∧\n (∀ (u : ℝ × ℝ), u ∈ U → -u ∈ U) ∧\n (∀ U' : Submodule ℝ (ℝ × ℝ), U ≠ ↑U') := sorry", "formal_proof": null, "informal_stmt": "Give an example of a nonempty subset $U$ of $\\mathbf{R}^2$ such that $U$ is closed under addition and under taking additive inverses (meaning $-u \\in U$ whenever $u \\in U$), but $U$ is not a subspace of $\\mathbf{R}^2$.\n\\begin{proof}\n \\[U=\\mathbb{Z}^2=\\left\\{(x, y) \\in \\mathbf{R}^2: x, y \\text { are integers }\\right\\}\\]\n$U=\\mathbb{Z}^2$ satisfies the desired properties. To come up with this, note by assumption, $U$ must be closed under addition and subtraction, so in particular, it must contain 0 . We need to find a set which fails scalar multiplication. A discrete set like $\\mathbb{Z}^2$ does this.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_7", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_7 : ∃ U : Set (ℝ × ℝ),\n (U ≠ ∅) ∧\n (∀ (c : ℝ) (u : ℝ × ℝ), u ∈ U → c • u ∈ U) ∧\n (∀ U' : Submodule ℝ (ℝ × ℝ), U ≠ ↑U') := sorry", "formal_proof": null, "informal_stmt": "Give an example of a nonempty subset $U$ of $\\mathbf{R}^2$ such that $U$ is closed under scalar multiplication, but $U$ is not a subspace of $\\mathbf{R}^2$.\n\\begin{proof}\n$$\nU=\\left\\{(x, y) \\in \\mathbf{R}^2:|x|=|y|\\right\\}\n$$\nFor $(x, y) \\in U$ and $\\lambda \\in \\mathbb{R}$, it follows $\\lambda(x, y)=$ $(\\lambda x, \\lambda y)$, so $|\\lambda x|=|\\lambda||x|=|\\lambda||y|=|\\lambda y|$. Therefore, $\\lambda(x, y) \\in U$.\n\nOn the other hand, consider $a=(1,-1), b=$ $(1,1) \\in U$. Then, $a+b=(1,-1)+(1,1)=$ $(2,0) \\notin U$. So, $U$ is not a subspace of $\\mathbb{R}^2$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_8", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_8 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] {ι : Type*} (u : ι → Submodule F V) :\n ∃ U : Submodule F V, (⋂ (i : ι), (u i).carrier) = ↑U := sorry", "formal_proof": null, "informal_stmt": "Prove that the intersection of any collection of subspaces of $V$ is a subspace of $V$.\n\\begin{proof}\nLet $V_1, V_2, \\ldots, V_n$ be subspaces of the vector space $V$ over the field $F$. We must show that their intersection $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$ is also a subspace of $V$.\n\nTo begin, we observe that the additive identity $0$ of $V$ is in $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$. This is because $0$ is in each subspace $V_i$, as they are subspaces and hence contain the additive identity.\n\nNext, we show that the intersection of subspaces is closed under addition. Let $u$ and $v$ be vectors in $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$. By definition, $u$ and $v$ belong to each of the subspaces $V_i$. Since each $V_i$ is a subspace and therefore closed under addition, it follows that $u+v$ belongs to each $V_i$. Thus, $u+v$ belongs to the intersection $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$.\n\nFinally, we show that the intersection of subspaces is closed under scalar multiplication. Let $a$ be a scalar in $F$ and let $v$ be a vector in $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$. Since $v$ belongs to each $V_i$, we have $av$ belongs to each $V_i$ as well, as $V_i$ are subspaces and hence closed under scalar multiplication. Therefore, $av$ belongs to the intersection $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$.\n\nThus, we have shown that $V_1 \\cap V_2 \\cap \\ldots \\cap V_n$ is a subspace of $V$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_1_9", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_9 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] (U W : Submodule F V):\n ∃ U' : Submodule F V, (U'.carrier = ↑U ∩ ↑W ↔ (U ≤ W ∨ W ≤ U)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the union of two subspaces of $V$ is a subspace of $V$ if and only if one of the subspaces is contained in the other.\n\\begin{proof}\n To prove this one way, suppose for purposes of contradiction that for $U_1$ and $U_2$, which are subspaces of $V$, that $U_1 \\cup U_2$ is a subspace and neither is completely contained within the other. In other words, $U_1 \\nsubseteq U_2$ and $U_2 \\nsubseteq U_1$. We will show that you can pick a vector $v \\in U_1$ and a vector $u \\in U_2$ such that $v+u \\notin U_1 \\cup U_2$, proving that if $U_1 \\cup U_2$ is a subspace, one must be completely contained inside the other.\n\nIf $U_1 \\nsubseteq U_2$, we can pick a $v \\in U_1$ such that $v \\notin U_2$. Since $v$ is in the subspace $U_1$, then $(-v)$ must also be, by definition. Similarly, if $U_2 \\nsubseteq U_1$, then we can pick a $u \\in U_2$ such that $u \\notin U_1$. Since $u$ is in the subspace $U_2$, then $(-u)$ must also be, by definition.\n\nIf $v+u \\in U_1 \\cup U_2$, then $v+u$ must be in $U_1$ or $U_2$. But, $v+u \\in U_1 \\Rightarrow v+u+(-v) \\in U_1 \\Rightarrow u \\in U_1$\nSimilarly,\n$$\nv+u \\in U_2 \\Rightarrow v+u+(-u) \\in U_2 \\Rightarrow v \\in U_2\n$$\nThis is clearly a contradiction, as each element was defined to not be in these subspaces. Thus our initial assumption must have been wrong, and $U_1 \\subseteq U_2$ or $U_2 \\subseteq U_1$\nTo prove the other way, Let $U_1 \\subseteq U_2$ (WLOG). $U_1 \\subseteq U_2 \\Rightarrow U_1 \\cup U_2=U_2$. Since $U_2$ is a subspace, $U_1 \\cup U_2$ is as well. QED.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_3_1", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_3_1 {F V : Type*}\n [AddCommGroup V] [Field F] [Module F V] [FiniteDimensional F V]\n (T : V →ₗ[F] V) (hT : finrank F V = 1) :\n ∃ c : F, ∀ v : V, T v = c • v:= sorry", "formal_proof": null, "informal_stmt": "Show that every linear map from a one-dimensional vector space to itself is multiplication by some scalar. More precisely, prove that if $\\operatorname{dim} V=1$ and $T \\in \\mathcal{L}(V, V)$, then there exists $a \\in \\mathbf{F}$ such that $T v=a v$ for all $v \\in V$.\n\\begin{proof}\n If $\\operatorname{dim} V=1$, then in fact, $V=\\mathbf{F}$ and it is spanned by $1 \\in \\mathbf{F}$.\nLet $T$ be a linear map from $V$ to itself. Let $T(1)=\\lambda \\in V(=\\mathbf{F})$.\nStep 2\n2 of 3\nEvery $v \\in V$ is a scalar. Therefore,\n$$\n\\begin{aligned}\nT(v) & =T(v \\cdot 1) \\\\\n& =v T(1) \\ldots .(\\text { By the linearity of } T) \\\\\n& =v \\lambda\n\\end{aligned}\n$$\nHence, $T v=\\lambda v$ for every $v \\in V$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_3_8", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_3_8 {F V W : Type*} [AddCommGroup V]\n [AddCommGroup W] [Field F] [Module F V] [Module F W]\n (L : V →ₗ[F] W) :\n ∃ U : Submodule F V, U ⊓ (ker L) = ⊥ ∧\n (range L = range (domRestrict L U)):= sorry", "formal_proof": null, "informal_stmt": "Suppose that $V$ is finite dimensional and that $T \\in \\mathcal{L}(V, W)$. Prove that there exists a subspace $U$ of $V$ such that $U \\cap \\operatorname{null} T=\\{0\\}$ and range $T=\\{T u: u \\in U\\}$.\n\\begin{proof}\n The point here is to note that every subspace of a vector space has a complementary subspace.\nIn this example, $U$ will precisely turn out to be the complementary subspace of null $T$. That is, $V=U \\oplus \\operatorname{null} T$\nHow should we characterize $U$ ? This can be achieved by extending a basis $B_1=\\left\\{v_1, v_2, \\ldots, v_m\\right\\}$ of null $T$ to a basis of $V$. Let $B_2=\\left\\{u_1, u_2, \\ldots, u_n\\right\\}$ be such that $B=B_1 \\cup B_2$ is a basis of $V$.\n\nDefine $U=\\operatorname{span}\\left(B_2\\right)$. Now, since $B_1$ and $B_2$ are complementary subsets of the basis $B$ of $V$, their spans will turn out to be complementary subspaces of $V$. Let's prove that $V=U \\oplus$ null $T$.\n\nLet $v \\in V$. Then, $v$ can be expressed as a linear combination of the vectors in $B$.\nLet $v=a_1 u_1+\\cdots+a_n u_n+c_1 v_1+\\cdots+c_m v_m$. However, since $\\left\\{u_1, u_2, \\ldots, u_n\\right\\}$ is a basis of $U, a_1 u_1+$ $\\cdots+a_n u_n=u \\in U$ and since $\\left\\{v_1, v_2, \\ldots, v_m\\right\\}$ is a basis of null $T, c_1 v_1+\\cdots+c_m v_m=w \\in$ null $T$.\nHence, $v=u+w \\in U+\\operatorname{null} T$. This shows that\n$$\nV=U+\\operatorname{null} T\n$$\nNow, let $v \\in U \\cap \\operatorname{null} T$.\nSince $v \\in U, u$ can be expressed as a linear combination of basis vectors of $U$. Let\n$$\nv=a_1 u_1+\\cdots+a_n u_n\n$$\nSimilarly, since $v \\in \\operatorname{null} T$, it can also be expressed as a linear combination of the basis vectors of null $T$. Let\n$$\nv=c_1 v_1+\\cdots+c_m v_m\n$$\nThe left hand sides of the above two equations are equal. Therefore, we can equate the right hand sides.\n$$\n\\begin{aligned}\n& a_1 u_1+\\cdots+a_n u_n=v=c_1 v_1+\\cdots+c_m v_m \\\\\n& a_1 u_1+\\cdots+a_n u_n-c_1 v_1-\\cdots-c_m v_m=0\n\\end{aligned}\n$$\nWe have found a linear combination of $u_i^{\\prime}$ 's and $v_i$ 's which is equal to zero. However, they are basis vectors of $V$. Hence, all the multipliers $c_i$ 's and $a_i$ 's must be zero implying that $v=0$.\nTherefore, if $v \\in U \\cap$ null $T$, then $v=0$. this means that\n$$\nU \\cap \\operatorname{null} T=\\{0\\}\n$$\nThe above shows that $U$ satisfies the first of the required conditions.\nNow let $w \\in$ range $T$. Then, there exists $v \\in V$ such that $T v=w$. This allows us to write $v=u+w$ where $u \\in U$ and $w \\in$ null $T$. This implies\n$$\n\\begin{aligned}\nw & =T v \\\\\n& =T(u+w) \\\\\n& =T u+T w \\\\\n& =T u+0 \\quad \\quad(\\text { since } w \\in \\operatorname{null} T) \\\\\n& =T u\n\\end{aligned}\n$$\nThis shows that if $w \\in$ range $T$ then $w=T u$ for some $u \\in U$. Therefore, range $T \\subseteq\\{T u \\mid u \\in U\\}$.\nSince $U$ is a subspace of $V$, it follows that $T u \\in$ range $T$ for all $u \\in U$. Thus, $\\{T u \\mid u \\in U\\} \\subseteq$ range $T$.\nTherefore, range $T=\\{T u \\mid u \\in U\\}$.\nThis shows that $U$ satisfies the second required condition as well.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_4_4", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_4_4 (p : Polynomial ℂ) :\n p.degree = @card (rootSet p ℂ) (rootSetFintype p ℂ) ↔\n Disjoint\n (@card (rootSet (derivative p) ℂ) (rootSetFintype (derivative p) ℂ))\n (@card (rootSet p ℂ) (rootSetFintype p ℂ)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $p \\in \\mathcal{P}(\\mathbf{C})$ has degree $m$. Prove that $p$ has $m$ distinct roots if and only if $p$ and its derivative $p^{\\prime}$ have no roots in common.\n\\begin{proof}\n First, let $p$ have $m$ distinct roots. Since $p$ has the degree of $m$, then this could imply that $p$ can be actually written in the form of $p(z)=c\\left(z-\\lambda_1\\right) \\ldots\\left(z-\\lambda_m\\right)$, which you have $\\lambda_1, \\ldots, \\lambda_m$ being distinct.\nTo prove that both $p$ and $p^{\\prime}$ have no roots in commons, we must now show that $p^{\\prime}\\left(\\lambda_j\\right) \\neq 0$ for every $j$. So, to do so, just fix $j$. The previous expression for $p$ shows that we can now write $p$ in the form of $p(z)=\\left(z-\\lambda_j\\right) q(z)$, which $q$ is a polynomial such that $q\\left(\\lambda_j\\right) \\neq 0$.\n\nWhen you differentiate both sides of the previous equation, then you would then have $p^{\\prime}(z)=(z-$ $\\left.\\lambda_j\\right) q^{\\prime}(z)+q(z)$\n\nTherefore: $\\left.=p^{\\prime}\\left(\\lambda_j\\right)=q \\lambda_j\\right)$\nEquals: $p^{\\prime}\\left(\\lambda_j\\right) \\neq 0$\n\nNow, to prove the other direction, we would now prove the contrapositive, which means that we will be proving that if $p$ has actually less than $m$ distinct roots, then both $p$ and $p^{\\prime}$ have at least one root in common.\n\nNow, for some root of $\\lambda$ of $p$, we can write $p$ is in the form of $\\left.p(z)=(z-\\lambda)^n q(z)\\right)$, which is where both $n \\geq 2$ and $q$ is a polynomial. When differentiating both sides of the previous equations, we would then have $p^{\\prime}(z)=(z-\\lambda)^n q^{\\prime}(z)+n(z-\\lambda)^{n-1} q(z)$.\nTherefore, $p^{\\prime}(\\lambda)=0$, which would make $\\lambda$ is a common root of both $p$ and $p^{\\prime}$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_1", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_1 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] {L : V →ₗ[F] V} {n : ℕ} (U : Fin n → Submodule F V)\n (hU : ∀ i : Fin n, Submodule.map L (U i) = U i) :\n Submodule.map L (∑ i : Fin n, U i : Submodule F V) =\n (∑ i : Fin n, U i : Submodule F V) := sorry", "formal_proof": null, "informal_stmt": "Suppose $T \\in \\mathcal{L}(V)$. Prove that if $U_{1}, \\ldots, U_{m}$ are subspaces of $V$ invariant under $T$, then $U_{1}+\\cdots+U_{m}$ is invariant under $T$.\n\\begin{proof}\n First off, assume that $U_1, \\ldots, U_m$ are subspaces of $V$ invariant under $T$. Now, consider a vector $u \\in$ $U_1+\\ldots+U_m$. There does exist $u_1 \\in U_1, \\ldots, u_m \\in U_m$ such that $u=u_1+\\ldots+u_m$.\n\nOnce you apply $T$ towards both sides of the previous equation, we would then get $T u=T u_1+\\ldots+$ $T u_m$.\n\nSince each $U_j$ is invariant under $T$, then we would have $T u_1 \\in U_1+\\ldots+T u_m$. This would then make the equation shows that $T u \\in U_1+\\ldots+T u_m$, which does imply that $U_1+. .+U_m$ is invariant under $T$\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_4", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_4 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] (S T : V →ₗ[F] V) (hST : S ∘ T = T ∘ S) (c : F):\n Submodule.map S (ker (T - c • LinearMap.id)) = ker (T - c • LinearMap.id) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $S, T \\in \\mathcal{L}(V)$ are such that $S T=T S$. Prove that $\\operatorname{null} (T-\\lambda I)$ is invariant under $S$ for every $\\lambda \\in \\mathbf{F}$.\n\\begin{proof}\n First off, fix $\\lambda \\in F$. Secondly, let $v \\in \\operatorname{null}(T-\\lambda I)$. If so, then $(T-\\lambda I)(S v)=T S v-\\lambda S v=$ $S T v-\\lambda S v=S(T v-\\lambda v)=0$. Therefore, $S v \\in \\operatorname{null}(T-\\lambda I)$ since $n u l l(T-\\lambda I)$ is actually invariant under $S$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_11", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_11 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] (S T : End F V) :\n (S * T).Eigenvalues = (T * S).Eigenvalues := sorry", "formal_proof": null, "informal_stmt": "Suppose $S, T \\in \\mathcal{L}(V)$. Prove that $S T$ and $T S$ have the same eigenvalues.\n\\begin{proof}\n To start, let $\\lambda \\in F$ be an eigenvalue of $S T$. Now, we would want $\\lambda$ to be an eigenvalue of $T S$. Since $\\lambda$, by itself, is an eigenvalue of $S T$, then there has to be a nonzero vector $v \\in V$ such that $(S T) v=\\lambda v$.\nNow, With a given reference that $(S T) v=\\lambda v$, you will then have the following: $(T S)(T v)=$ $T(S T v)=T(\\lambda v)=\\lambda T v$\nIf $T v \\neq 0$, then the listed equation above shows that $\\lambda$ is an eigenvalue of $T S$.\nIf $T v=0$, then $\\lambda=0$, since $S(T v)=\\lambda T v$. This also means that $T$ isn't invertible, which would imply that $T S$ isn't invertible, which can also be implied that $\\lambda$, which equals 0 , is an eigenvalue of $T S$.\nStep 3\n3 of 3\nNow, regardless of whether $T v=0$ or not, we would have shown that $\\lambda$ is an eigenvalue of $T S$. Since $\\lambda$ (was) an arbitrary eigenvalue of $S T$, we have shown that every single eigenvalue of $S T$ is an eigenvalue of $T S$. When you do reverse the roles of both $S$ and $T$, then we can conclude that that every single eigenvalue of $T S$ is also an eigenvalue of $S T$. Therefore, both $S T$ and $T S$ have the exact same eigenvalues.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_12", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_12 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] {S : End F V}\n (hS : ∀ v : V, ∃ c : F, v ∈ eigenspace S c) :\n ∃ c : F, S = c • LinearMap.id := sorry", "formal_proof": null, "informal_stmt": "Suppose $T \\in \\mathcal{L}(V)$ is such that every vector in $V$ is an eigenvector of $T$. Prove that $T$ is a scalar multiple of the identity operator.\n\\begin{proof}\n For every single $v \\in V$, there does exist $a_v \\in F$ such that $T v=a_v v$. Since $T 0=0$, then we have to make $a_0$ be the any number in F. However, for every single $v \\in V\\{0\\}$, then the value of $a_V$ is uniquely determined by the previous equation of $T v=a_v v$.\n\nNow, to show that $T$ is a scalar multiple of the identity, then me must show that $a_v$ is independent of $v$ for $v \\in V\\{0\\}$. We would now want to show that $a_v=a_w$.\n\nFirst, just make the case of where $(v, w)$ is linearly dependent. Then, there does exist $b \\in F$ such that $w=b v$. Now, you would have the following: $a_W w=T w=T(b v)=b T v=b\\left(a_v v\\right)=a_v w$. This is showing that $a_v=a_w$.\nFinally, make the consideration to make $(v, w)$ be linearly independent. Now, we would have the following: $\\left.a_{(} v+w\\right)(v+w)=T(v+w)=T v+T w=a_v v+a_w w$.\n\nThat previous equation implies the following: $\\left.\\left.\\left(a_{(} v+w\\right)-a_v\\right) v+\\left(a_{(} v+w\\right)-a_w\\right) w=0$. Since $(v, w)$ is linearly independent, this would imply that both $\\left.a_{(} v+w\\right)=a_v$ and $\\left.a_{(} v+w\\right)=a_w$. Therefore, $a_v=a_w$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_13", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_13 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] [FiniteDimensional F V] {T : End F V}\n (hS : ∀ U : Submodule F V, finrank F U = finrank F V - 1 →\n Submodule.map T U = U) : ∃ c : F, T = c • LinearMap.id := sorry", "formal_proof": null, "informal_stmt": "Suppose $T \\in \\mathcal{L}(V)$ is such that every subspace of $V$ with dimension $\\operatorname{dim} V-1$ is invariant under $T$. Prove that $T$ is a scalar multiple of the identity operator.\n\\begin{proof}\n First off, let $T$ isn't a scalar multiple of the identity operator. So, there does exists that $v \\in V$ such that $u$ isn't an eigenvector of $T$. Therefore, $(u, T u)$ is linearly independent.\n\nNext, you should extend $(u, T u)$ to a basis of $\\left(u, T u, v_1, \\ldots, v_n\\right)$ of $V$. So, let $U=\\operatorname{span}\\left(u, v_1, \\ldots, v_n\\right)$. Then, $U$ is a subspace of $V$ and $\\operatorname{dim} U=\\operatorname{dim} V-1$. However, $U$ isn't invariant under $T$ since both $u \\in U$ and $T u \\in U$. This given contradiction to our hypothesis about $T$ actually shows us that our guess that $T$ is not a scalar multiple of the identity must have been false.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_20", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_20 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] [FiniteDimensional F V] {S T : End F V}\n (h1 : card (T.Eigenvalues) = finrank F V)\n (h2 : ∀ v : V, ∃ c : F, v ∈ eigenspace S c ↔ ∃ c : F, v ∈ eigenspace T c) :\n S * T = T * S := sorry", "formal_proof": null, "informal_stmt": "Suppose that $T \\in \\mathcal{L}(V)$ has $\\operatorname{dim} V$ distinct eigenvalues and that $S \\in \\mathcal{L}(V)$ has the same eigenvectors as $T$ (not necessarily with the same eigenvalues). Prove that $S T=T S$.\n\\begin{proof}\n First off, let $n=\\operatorname{dim} V$. so, there is a basis of $\\left(v_1, \\ldots, v_j\\right)$ of $V$ that consist of eigenvectors of $T$. Now, let $\\lambda_1, \\ldots, \\lambda_n$ be the corresponding eigenvalues, then we would have $T v_j=\\lambda_1 v_j$ for every single $j$.\n\nNow, for every $v_j$ is also an eigenvector of S, so $S v_j=a_j v_j$ for some $a_j \\in F$. For each $j$, we would then have $(S T) v_j=S\\left(T v_j\\right)=\\lambda_j S v_j=a_j \\lambda_j v_j$ and $(T S) v_j=T\\left(S v_j\\right)=a_j T v_j=a_j \\lambda_j v_j$. Since both operators, which are $S T$ and $T S$, agree on a basis, then both are equal.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_5_24", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_5_24 {V : Type*} [AddCommGroup V]\n [Module ℝ V] [FiniteDimensional ℝ V] {T : End ℝ V}\n (hT : ∀ c : ℝ, eigenspace T c = ⊥) {U : Submodule ℝ V}\n (hU : Submodule.map T U = U) : Even (finrank U) := sorry", "formal_proof": null, "informal_stmt": "Suppose $V$ is a real vector space and $T \\in \\mathcal{L}(V)$ has no eigenvalues. Prove that every subspace of $V$ invariant under $T$ has even dimension.\n\\begin{proof}\n First off, let us assume that $U$ is a subspace of $V$ that is invariant under $T$. Therefore, $\\left.T\\right|_U \\in \\mathcal{L}(U)$. If $\\operatorname{dim}$ $U$ were odd, then $\\left.T\\right|_U$ would have an eigenvalue $\\lambda \\in \\mathbb{R}$, so there would exist a nonzero vector $u \\in U$ such that\n$$\n\\left.T\\right|_U u=\\lambda u .\n$$\nSo, this would imply that $T_u=\\lambda u$, which would imply that $\\lambda$ is an eigenvalue of $T$. But $T$ has no eigenvalues, so $\\operatorname{dim} U$ must be even.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_6_2", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_6_2 {V : Type*} [NormedAddCommGroup V] [Module ℂ V]\n[InnerProductSpace ℂ V] (u v : V) :\n ⟪u, v⟫_ℂ = 0 ↔ ∀ (a : ℂ), ‖u‖ ≤ ‖u + a • v‖ := sorry", "formal_proof": null, "informal_stmt": "Suppose $u, v \\in V$. Prove that $\\langle u, v\\rangle=0$ if and only if $\\|u\\| \\leq\\|u+a v\\|$ for all $a \\in \\mathbf{F}$.\n\\begin{proof}\n First off, let us suppose that $(u, v)=0$.\nNow, let $a \\in \\mathbb{F}$. Next, $u, a v$ are orthogonal.\nThe Pythagorean theorem thus implies that\n$$\n\\begin{aligned}\n\\|u+a v\\|^2 & =\\|u\\|^2+\\|a v\\|^2 \\\\\n& \\geq\\|u\\|^2\n\\end{aligned}\n$$\nSo, by taking the square roots, this will now give us $\\|u\\| \\leq\\|u+a v\\|$.\nNow, to prove the implication in the other direction, we must now let $\\|u\\| \\leq$ $\\|u+a v\\|$ for all $a \\in \\mathbb{F}$. Squaring this inequality, we get both:\n$$\n\\begin{gathered}\n\\|u\\|^2 a n d \\leq\\|u+a v\\|^2 \\\\\n=(u+a v, u+a v) \\\\\n=(u, u)+(u, a v)+(a v, u)+(a v, a v) \\\\\n=\\|u\\|^2+\\bar{a}(u, v)+a \\overline{(u, v)}+|a|^2\\|v\\|^2 \\\\\n\\|u\\|^2+2 \\Re \\bar{a}(u, v)+|a|^2\\|v\\|^2\n\\end{gathered}\n$$\nfor all $a \\in \\mathbb{F}$.\nTherefore,\n$$\n-2 \\Re \\bar{a}(u, v) \\leq|a|^2\\|v\\|^2\n$$\nfor all $a \\in \\mathbb{F}$. In particular, we can let $a$ equal $-t(u, v)$ for $t>0$. Substituting this value for $a$ into the inequality above gives\n$$\n2 t|(u, v)|^2 \\leq t^2|(u, v)|^2\\|v\\|^2\n$$\nfor all $t>0$.\nStep 4\n4 of 4\nDivide both sides of the inequality above by $t$, getting\n$$\n2|(u, v)|^2 \\leq t \\mid(u, v)^2\\|v\\|^2\n$$\nfor all $t>0$. If $v=0$, then $(u, v)=0$, as desired. If $v \\neq 0$, set $t$ equal to $1 /\\|v\\|^2$ in the inequality above, getting\n$$\n2|(u, v)|^2 \\leq|(u, v)|^2,\n$$\nwhich implies that $(u, v)=0$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_6_3", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_6_3 {n : ℕ} (a b : Fin n → ℝ) :\n (∑ i, a i * b i) ^ 2 ≤ (∑ i : Fin n, i * a i ^ 2) * (∑ i, b i ^ 2 / i) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\left(\\sum_{j=1}^{n} a_{j} b_{j}\\right)^{2} \\leq\\left(\\sum_{j=1}^{n} j a_{j}{ }^{2}\\right)\\left(\\sum_{j=1}^{n} \\frac{b_{j}{ }^{2}}{j}\\right)$ for all real numbers $a_{1}, \\ldots, a_{n}$ and $b_{1}, \\ldots, b_{n}$.\n\\begin{proof}\n Let $a_1, a_2, \\ldots, a_n, b_1, b_2, \\ldots, b_n \\in R$.\nWe have that\n$$\n\\left(\\sum_{j=1}^n a_j b_j\\right)^2\n$$\nis equal to the\n$$\n\\left(\\sum_{j=1}^n a_j b_j \\frac{\\sqrt{j}}{\\sqrt{j}}\\right)^2=\\left(\\sum_{j=1}^n\\left(\\sqrt{j} a_j\\right)\\left(b_j \\frac{1}{\\sqrt{j}}\\right)\\right)^2\n$$\nThis can be observed as an inner product, and using the Cauchy-Schwarz Inequality, we get\n$$\n\\begin{aligned}\n&\\left(\\sum_{j=1}^n a_j b_j\\right)^2=\\left(\\sum_{j=1}^n\\left(\\sqrt{j} a_j\\right)\\left(b_j \\frac{1}{\\sqrt{j}}\\right)\\right)^2 \\\\\n&=\\left\\langle\\left(a, \\sqrt{2} a_2, \\ldots, \\sqrt{n} a_n\\right),\\left(b_1, \\frac{b_2}{\\sqrt{2}}, \\ldots, \\frac{b_n}{\\sqrt{n}}\\right)\\right\\rangle \\\\\n& \\leq\\left\\|\\left(a, \\sqrt{2} a_2, \\ldots, \\sqrt{n} a_n\\right)\\right\\|^2\\left\\|\\left(b_1, \\frac{b_2}{\\sqrt{2}}, \\ldots, \\frac{b_n}{\\sqrt{n}}\\right)\\right\\|^2 \\\\\n&=\\left(\\sum_{j=1}^n j a_j^2\\right)\\left(\\sum_{j=1}^n \\frac{b_j^2}{j}\\right) \\\\\n& \\text { Hence, }\\left(\\sum_{j=1}^n a_j b_j\\right)^2=\\left(\\sum_{j=1}^n j a_j^2\\right)\\left(\\sum_{j=1}^n \\frac{b_j^2}{j}\\right) .\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_6_7", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_6_7 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V] (u v : V) :\n ⟪u, v⟫_ℂ = (‖u + v‖^2 - ‖u - v‖^2 + I*‖u + I•v‖^2 - I*‖u-I•v‖^2) / 4 := sorry", "formal_proof": null, "informal_stmt": "Prove that if $V$ is a complex inner-product space, then $\\langle u, v\\rangle=\\frac{\\|u+v\\|^{2}-\\|u-v\\|^{2}+\\|u+i v\\|^{2} i-\\|u-i v\\|^{2} i}{4}$ for all $u, v \\in V$.\n\\begin{proof}\nLet $V$ be an inner-product space and $u, v\\in V$. Then \n$$\n\\begin{aligned}\n\\|u+v\\|^2 & =\\langle u+v, v+v\\rangle \\\\\n& =\\|u\\|^2+\\langle u, v\\rangle+\\langle v, u\\rangle+\\|v\\|^2 \\\\\n-\\|u-v\\|^2 & =-\\langle u-v, u-v\\rangle \\\\\n& =-\\|u\\|^2+\\langle u, v\\rangle+\\langle v, u\\rangle-\\|v\\|^2 \\\\\ni\\|u+i v\\|^2 & =i\\langle u+i v, u+i v\\rangle \\\\\n& =i\\|u\\|^2+\\langle u, v\\rangle-\\langle v, u\\rangle+i\\|v\\|^2 \\\\\n-i\\|u-i v\\|^2 & =-i\\langle u-i v, u-i v\\rangle \\\\\n& =-i\\|u\\|^2+\\langle u, v\\rangle-\\langle v, u\\rangle-i\\|v\\|^2 .\n\\end{aligned}\n$$\nThus $\\left(\\|u+v\\|^2\\right)-\\|u-v\\|^2+\\left(i\\|u+i v\\|^2\\right)-i\\|u-i v\\|^2=4\\langle u, v\\rangle.$\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_6_13", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_6_13 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V] {n : ℕ}\n {e : Fin n → V} (he : Orthonormal ℂ e) (v : V) :\n ‖v‖^2 = ∑ i : Fin n, ‖⟪v, e i⟫_ℂ‖^2 ↔ v ∈ Submodule.span ℂ (e '' Set.univ) := sorry", "formal_proof": null, "informal_stmt": "Suppose $\\left(e_{1}, \\ldots, e_{m}\\right)$ is an orthonormal list of vectors in $V$. Let $v \\in V$. Prove that $\\|v\\|^{2}=\\left|\\left\\langle v, e_{1}\\right\\rangle\\right|^{2}+\\cdots+\\left|\\left\\langle v, e_{m}\\right\\rangle\\right|^{2}$ if and only if $v \\in \\operatorname{span}\\left(e_{1}, \\ldots, e_{m}\\right)$.\n\\begin{proof}\nIf $v \\in \\operatorname{span}\\left(e_1, \\ldots, e_m\\right)$, it means that\n$$\nv=\\alpha_1 e_1+\\ldots+\\alpha_m e_m .\n$$\nfor some scalars $\\alpha_i$. We know that $\\alpha_k=\\left\\langle v, e_k\\right\\rangle, \\forall k \\in\\{1, \\ldots, m\\}$. Therefore,\n$$\n\\begin{aligned}\n\\|v\\|^2 & =\\langle v, v\\rangle \\\\\n& =\\left\\langle\\alpha_1 e_1+\\ldots+\\alpha_m e_m, \\alpha_1 e_1+\\ldots+\\alpha_m e_m\\right\\rangle \\\\\n& =\\left|\\alpha_1\\right|^2\\left\\langle e_1, e_1\\right\\rangle+\\ldots+\\left|\\alpha_m\\right|^2\\left\\langle e_m, e_m\\right\\rangle \\\\\n& =\\left|\\alpha_1\\right|^2+\\ldots+\\left|\\alpha_m\\right|^2 \\\\\n& =\\left|\\left\\langle v, e_1\\right\\rangle\\right|^2+\\ldots+\\left|\\left\\langle v, e_m\\right\\rangle\\right|^2 .\n\\end{aligned}\n$$\n$\\Rightarrow$ Assume that $v \\notin \\operatorname{span}\\left(e_1, \\ldots, e_m\\right)$. Then, we must have\n$$\nv=v_{m+1}+\\frac{\\left\\langle v, v_0\\right\\rangle}{\\left\\|v_0\\right\\|^2} v_0,\n$$\nwhere $v_0=\\alpha_1 e_1+\\ldots+\\alpha_m e_m, \\alpha_k=\\left\\langle v, e_k\\right\\rangle, \\forall k \\in\\{1, \\ldots, m\\}$, and $v_{m+1}=v-$ $\\frac{\\left\\langle v, v_0\\right\\rangle}{\\left\\|v_0\\right\\|^2} v_0 \\neq 0$.\n\nWe have $\\left\\langle v_0, v_{m+1}\\right\\rangle=0$ (from which we get $\\left\\langle v, v_0\\right\\rangle=\\left\\langle v_0, v_0\\right\\rangle$ and $\\left\\langle v, v_{m+1}\\right\\rangle=$ $\\left.\\left\\langle v_{m+1}, v_{m+1}\\right\\rangle\\right)$. Now,\n$$\n\\begin{aligned}\n\\|v\\|^2 & =\\langle v, v\\rangle \\\\\n& =\\left\\langle v, v_{m+1}+\\frac{\\left\\langle v, v_0\\right\\rangle}{\\left\\|v_0\\right\\|^2} v_0\\right\\rangle \\\\\n& =\\left\\langle v, v_{m+1}\\right\\rangle+\\left\\langle v, \\frac{\\left\\langle v, v_0\\right\\rangle}{\\left\\|v_0\\right\\|^2} v_0\\right\\rangle \\\\\n& =\\left\\langle v_{m+1}, v_{m+1}\\right\\rangle+\\frac{\\left\\langle v_0, v_0\\right\\rangle}{\\left\\|v_0\\right\\|^2}\\left\\langle v_0, v_0\\right\\rangle \\\\\n& =\\left\\|v_{m+1}\\right\\|^2+\\left\\|v_0\\right\\|^2 \\\\\n& >\\left\\|v_0\\right\\|^2 \\\\\n& =\\left|\\alpha_1\\right|^2+\\ldots+\\left|\\alpha_m\\right|^2 \\\\\n& =\\left|\\left\\langle v, e_1\\right\\rangle\\right|^2+\\ldots+\\left|\\left\\langle v, e_m\\right\\rangle\\right|^2 .\n\\end{aligned}\n$$\nBy contrapositive, if $\\left\\|v_1\\right\\|^2=\\left|\\left\\langle v, e_1\\right\\rangle\\right|^2+\\ldots+\\left|\\left\\langle v, e_m\\right\\rangle\\right|^2$, then $v \\in \\operatorname{span}\\left(e_1, \\ldots, e_m\\right)$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_6_16", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_6_16 {K V : Type*} [RCLike K] [NormedAddCommGroup V] [InnerProductSpace K V]\n {U : Submodule K V} :\n U.orthogonal = ⊥ ↔ U = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Suppose $U$ is a subspace of $V$. Prove that $U^{\\perp}=\\{0\\}$ if and only if $U=V$\n\\begin{proof}\n $V=U \\bigoplus U^{\\perp}$, therefore $U^\\perp = \\{0\\}$ iff $U=V$. \n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_5", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_5 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] (hV : finrank V ≥ 2) :\n ∀ U : Submodule ℂ (End ℂ V), U.carrier ≠\n {T | T * adjoint T = adjoint T * T} := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\operatorname{dim} V \\geq 2$, then the set of normal operators on $V$ is not a subspace of $\\mathcal{L}(V)$.\n\\begin{proof}\n First off, suppose that $\\operatorname{dim} V \\geq 2$. Next let $\\left(e_1, \\ldots, e_n\\right)$ be an orthonormal basis of $V$. Now, define $S, T \\in L(V)$ by both $S\\left(a_1 e_1+\\ldots+a_n e_n\\right)=a_2 e_1-a_1 e_2$ and $T\\left(a_1 e_1+\\ldots+\\right.$ $\\left.a_n e_n\\right)=a_2 e_1+a_1 e_2$. So, just by now doing a simple calculation verifies that $S^*\\left(a_1 e_1+\\right.$ $\\left.\\ldots+a_n e_n\\right)=-a_2 e_1+a_1 e_2$\n\nNow, based on this formula, another calculation would show that $S S^*=S^* S$. Another simple calculation would that that $T$ is self-adjoint. Therefore, both $S$ and $T$ are normal. However, $S+T$ is given by the formula of $(S+T)\\left(a_1 e_1+\\ldots+a_n e_n\\right)=2 a_2 e_1$. In this case, a simple calculator verifies that $(S+T)^*\\left(a_1 e_1+\\ldots+a_n e_n\\right)=2 a_1 e_2$.\n\nTherefore, there is a final simple calculation that shows that $(S+T)(S+T)^* \\neq(S+$ $T)^*(S+T)$. So, in other words, $S+T$ isn't normal. Therefore, the set of normal operators on $V$ isn't closed under addition and hence isn't a subspace of $L(V)$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_6", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_6 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] (T : End ℂ V)\n (hT : T * adjoint T = adjoint T * T) :\n range T = range (adjoint T) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $T \\in \\mathcal{L}(V)$ is normal, then $\\operatorname{range} T=\\operatorname{range} T^{*}.$\n\\begin{proof}\n Let $T \\in \\mathcal{L}(V)$ to be a normal operator.\nSuppose $u \\in \\operatorname{null} T$. Then, by $7.20$,\n$$\n0=\\|T u\\|=\\left\\|T^* u\\right\\|,\n$$\nwhich implies that $u \\in \\operatorname{null} T^*$.\nHence\n$$\n\\operatorname{null} T=\\operatorname{null} T^*\n$$\nbecause $\\left(T^*\\right)^*=T$ and the same argument can be repeated.\nNow we have\n$$\n\\begin{aligned}\n\\text { range } T & =\\left(\\text { null } T^*\\right)^{\\perp} \\\\\n& =(\\text { null } T)^{\\perp} \\\\\n& =\\operatorname{range} T^*,\n\\end{aligned}\n$$\nwhere the first and last equality follow from items (d) and (b) of 7.7.\nHence, range $T=$ range $T^*$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_9", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_9 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] (T : End ℂ V)\n (hT : T * adjoint T = adjoint T * T) :\n IsSelfAdjoint T ↔ ∀ e : T.Eigenvalues, (e : ℂ).im = 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that a normal operator on a complex inner-product space is self-adjoint if and only if all its eigenvalues are real.\n\\begin{proof}\n First off, suppose $V$ is a complex inner product space and $T \\in L(V)$ is normal. If $T$ is self-adjoint, then all its eigenvalues are real. So, conversely, let all of the eigenvalues of $T$ be real. By the complex spectral theorem, there's an orthonormal basis $\\left(e_1, \\ldots, e_n\\right)$ of $V$ consisting of eigenvectors of $T$. Thus, there exists real numbers $\\lambda_1, \\ldots, \\lambda_n$ such that $T e_j=\\lambda_j e_j$ for $j=$ $1, \\ldots, n$.\nThe matrix of $T$ with respect to the basis of $\\left(e_1, \\ldots, e_n\\right)$ is the diagonal matrix with $\\lambda_1, \\ldots, \\lambda_n$ on the diagonal. So, the matrix equals its conjugate transpose. Therefore, $T=T^*$. In other words, $T$ s self-adjoint.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_10", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_10 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] (T : End ℂ V)\n (hT : T * adjoint T = adjoint T * T) (hT1 : T^9 = T^8) :\n IsSelfAdjoint T ∧ T^2 = T := sorry", "formal_proof": null, "informal_stmt": "Suppose $V$ is a complex inner-product space and $T \\in \\mathcal{L}(V)$ is a normal operator such that $T^{9}=T^{8}$. Prove that $T$ is self-adjoint and $T^{2}=T$.\n\\begin{proof}\n Based on the complex spectral theorem, there is an orthonormal basis of $\\left(e_1, \\ldots, e_n\\right)$ of $V$ consisting of eigenvectors of $T$. Now, let $\\lambda_1, \\ldots, \\lambda_n$ be the corresponding eigenvalues. Therefore,\n$$\nT e_1=\\lambda_j e_j\n$$\nfor $j=1 \\ldots n$.\n\nNext, by applying $T$ repeatedly to both sides of the equation above, we get $T^9 e_j=\\left(\\lambda_j\\right)^9 e_j$ and rei =8ej. Thus $T^8 e_j=\\left(\\lambda_j\\right)^8 e_j$, which implies that $\\lambda_j$ equals 0 or 1 . In particular, all the eigenvalues of $T$ are real. This would then imply that $T$ is self-adjoint.\n\nNow, by applying $T$ to both sides of the equation above, we get\n$$\n\\begin{aligned}\nT^2 e_j & =\\left(\\lambda_j\\right)^2 e_j \\\\\n& =\\lambda_j e_j \\\\\n& =T e_j\n\\end{aligned}\n$$\nwhich is where the second equality holds because $\\lambda_j$ equals 0 or 1 . Because $T^2$ and $T$ agree on a basis, they must be equal.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_11", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_11 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] {T : End ℂ V} (hT : T*adjoint T = adjoint T*T) :\n ∃ (S : End ℂ V), S ^ 2 = T := sorry", "formal_proof": null, "informal_stmt": "Suppose $V$ is a complex inner-product space. Prove that every normal operator on $V$ has a square root. (An operator $S \\in \\mathcal{L}(V)$ is called a square root of $T \\in \\mathcal{L}(V)$ if $S^{2}=T$.)\n\\begin{proof}\n Let $V$ be a complex inner product space.\nIt is known that an operator $S \\in \\mathcal{L}(V)$ is called a square root of $T \\in \\mathcal{L}(V)$ if\n$$\nS^2=T\n$$\nNow, suppose that $T$ is a normal operator on $V$.\nBy the Complex Spectral Theorem, there is $e_1, \\ldots, e_n$ an orthonormal basis of $V$ consisting of eigenvalues of $T$ and let $\\lambda_1, \\ldots, \\lambda_n$ denote their corresponding eigenvalues.\nDefine $S$ by\n$$\nS e_j=\\sqrt{\\lambda_j} e_j,\n$$\nfor each $j=1, \\ldots, n$.\nObviously, $S^2 e_j=\\lambda_j e_j=T e_j$.\nHence, $S^2=T$ so there exist a square root of $T$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Axler_exercise_7_14", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_14 {𝕜 V : Type*} [RCLike 𝕜] [NormedAddCommGroup V]\n [InnerProductSpace 𝕜 V] [FiniteDimensional 𝕜 V]\n {T : End 𝕜 V} (hT : IsSelfAdjoint T)\n {l : 𝕜} {ε : ℝ} (he : ε > 0) : ∃ v : V, ‖v‖= 1 ∧ (‖T v - l • v‖ < ε →\n (∃ l' : T.Eigenvalues, ‖l - l'‖ < ε)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $T \\in \\mathcal{L}(V)$ is self-adjoint, $\\lambda \\in \\mathbf{F}$, and $\\epsilon>0$. Prove that if there exists $v \\in V$ such that $\\|v\\|=1$ and $\\|T v-\\lambda v\\|<\\epsilon,$ then $T$ has an eigenvalue $\\lambda^{\\prime}$ such that $\\left|\\lambda-\\lambda^{\\prime}\\right|<\\epsilon$.\n\\begin{proof}\n Let $T \\in \\mathcal{L}(V)$ be a self-adjoint, and let $\\lambda \\in \\mathbf{F}$ and $\\epsilon>0$.\nBy the Spectral Theorem, there is $e_1, \\ldots, e_n$ an orthonormal basis of $V$ consisting of eigenvectors of $T$ and let $\\lambda_1, \\ldots, \\lambda_n$ denote their corresponding eigenvalues.\nChoose an eigenvalue $\\lambda^{\\prime}$ of $T$ such that $\\left|\\lambda^{\\prime}-\\lambda\\right|^2$ is minimized.\nThere are $a_1, \\ldots, a_n \\in \\mathbb{F}$ such that\n$$\nv=a_1 e_1+\\cdots+a_n e_n .\n$$\nThus, we have\n$$\n\\begin{aligned}\n\\epsilon^2 & >|| T v-\\left.\\lambda v\\right|^2 \\\\\n& =\\left|\\left\\langle T v-\\lambda v, e_1\\right\\rangle\\right|^2+\\cdots+\\left|\\left\\langle T v-\\lambda v, e_n\\right\\rangle\\right|^2 \\\\\n& =\\left|\\lambda_1 a_1-\\lambda a_1\\right|^2+\\cdots+\\left|\\lambda_n a_n-\\lambda a_n\\right|^2 \\\\\n& =\\left|a_1\\right|^2\\left|\\lambda_1-\\lambda\\right|^2+\\cdots+\\left|a_n\\right|^2\\left|\\lambda_n-\\lambda\\right|^2 \\\\\n& \\geq\\left|a_1\\right|^2\\left|\\lambda^{\\prime}-\\lambda\\right|^2+\\cdots+\\left|a_n\\right|^2\\left|\\lambda^{\\prime}-\\lambda\\right|^2 \\\\\n& =\\left|\\lambda^{\\prime}-\\lambda\\right|^2\n\\end{aligned}\n$$\nwhere the second and fifth lines follow from $6.30$ (the fifth because $\\|v\\|=1$ ). Now, we taking the square root.\nHence, $T$ has an eigenvalue $\\lambda^{\\prime}$ such that $\\left|\\lambda^{\\prime}-\\lambda\\right|<\\epsilon$\n\\end{proof}\n\n\n\n\\end{document}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Dummit_Foote_exercise_1_1_2a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_2a : ∃ a b : ℤ, a - b ≠ b - a := sorry", "formal_proof": null, "informal_stmt": "Prove the the operation $\\star$ on $\\mathbb{Z}$ defined by $a\\star b=a-b$ is not commutative.\n\\begin{proof}\n Not commutative since\n$$\n1 \\star(-1)=1-(-1)=2\n$$\n$$\n(-1) \\star 1=-1-1=-2 .\n$$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_3", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_3 (n : ℤ) :\n ∀ (a b c : ℤ), (a+b)+c ≡ a+(b+c) [ZMOD n] := sorry", "formal_proof": null, "informal_stmt": "Prove that the addition of residue classes $\\mathbb{Z}/n\\mathbb{Z}$ is associative.\n\\begin{proof}\n We have\n$$\n\\begin{aligned}\n(\\bar{a}+\\bar{b})+\\bar{c} &=\\overline{a+b}+\\bar{c} \\\\\n&=\\overline{(a+b)+c} \\\\\n&=\\overline{a+(b+c)} \\\\\n&=\\bar{a}+\\overline{b+c} \\\\\n&=\\bar{a}+(\\bar{b}+\\bar{c})\n\\end{aligned}\n$$\nsince integer addition is associative.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_4", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_4 (n : ℕ) :\n ∀ (a b c : ℕ), (a * b) * c ≡ a * (b * c) [ZMOD n] := sorry", "formal_proof": null, "informal_stmt": "Prove that the multiplication of residue class $\\mathbb{Z}/n\\mathbb{Z}$ is associative.\n\\begin{proof}\n We have\n$$\n\\begin{aligned}\n(\\bar{a} \\cdot \\bar{b}) \\cdot \\bar{c} &=\\overline{a \\cdot b} \\cdot \\bar{c} \\\\\n&=\\overline{(a \\cdot b) \\cdot c} \\\\\n&=\\overline{a \\cdot(b \\cdot c)} \\\\\n&=\\bar{a} \\cdot \\overline{b \\cdot c} \\\\\n&=\\bar{a} \\cdot(\\bar{b} \\cdot \\bar{c})\n\\end{aligned}\n$$\nsince integer multiplication is associative.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_5", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_5 (n : ℕ) (hn : 1 < n) :\n IsEmpty (Group (ZMod n)) := sorry", "formal_proof": null, "informal_stmt": "Prove that for all $n>1$ that $\\mathbb{Z}/n\\mathbb{Z}$ is not a group under multiplication of residue classes.\n\\begin{proof}\n Note that since $n>1, \\overline{1} \\neq \\overline{0}$. Now suppose $\\mathbb{Z} /(n)$ contains a multiplicative identity element $\\bar{e}$. Then in particular,\n$$\n\\bar{e} \\cdot \\overline{1}=\\overline{1}\n$$\nso that $\\bar{e}=\\overline{1}$. Note, however, that\n$$\n\\overline{0} \\cdot \\bar{k}=\\overline{0}\n$$\nfor all k, so that $\\overline{0}$ does not have a multiplicative inverse. Hence $\\mathbb{Z} /(n)$ is not a group under multiplication.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_15", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_15 {G : Type*} [Group G] (as : List G) :\n as.prod⁻¹ = (as.reverse.map (λ x => x⁻¹)).prod := sorry", "formal_proof": null, "informal_stmt": "Prove that $(a_1a_2\\dots a_n)^{-1} = a_n^{-1}a_{n-1}^{-1}\\dots a_1^{-1}$ for all $a_1, a_2, \\dots, a_n\\in G$.\n\\begin{proof}\n For $n=1$, note that for all $a_1 \\in G$ we have $a_1^{-1}=a_1^{-1}$.\nNow for $n \\geq 2$ we proceed by induction on $n$. For the base case, note that for all $a_1, a_2 \\in G$ we have\n$$\n\\left(a_1 \\cdot a_2\\right)^{-1}=a_2^{-1} \\cdot a_1^{-1}\n$$\nsince\n$$\na_1 \\cdot a_2 \\cdot a_2^{-1} a_1^{-1}=1 .\n$$\nFor the inductive step, suppose that for some $n \\geq 2$, for all $a_i \\in G$ we have\n$$\n\\left(a_1 \\cdot \\ldots \\cdot a_n\\right)^{-1}=a_n^{-1} \\cdot \\ldots \\cdot a_1^{-1} .\n$$\nThen given some $a_{n+1} \\in G$, we have\n$$\n\\begin{aligned}\n\\left(a_1 \\cdot \\ldots \\cdot a_n \\cdot a_{n+1}\\right)^{-1} &=\\left(\\left(a_1 \\cdot \\ldots \\cdot a_n\\right) \\cdot a_{n+1}\\right)^{-1} \\\\\n&=a_{n+1}^{-1} \\cdot\\left(a_1 \\cdot \\ldots \\cdot a_n\\right)^{-1} \\\\\n&=a_{n+1}^{-1} \\cdot a_n^{-1} \\cdot \\ldots \\cdot a_1^{-1},\n\\end{aligned}\n$$\nusing associativity and the base case where necessary.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_16", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_16 {G : Type*} [Group G]\n (x : G) (hx : x ^ 2 = 1) :\n orderOf x = 1 ∨ orderOf x = 2 := sorry", "formal_proof": null, "informal_stmt": "Let $x$ be an element of $G$. Prove that $x^2=1$ if and only if $|x|$ is either $1$ or $2$.\n\\begin{proof}\n $(\\Rightarrow)$ Suppose $x^2=1$. Then we have $0<|x| \\leq 2$, i.e., $|x|$ is either 1 or 2 .\n( $\\Leftarrow$ ) If $|x|=1$, then we have $x=1$ so that $x^2=1$. If $|x|=2$ then $x^2=1$ by definition. So if $|x|$ is 1 or 2 , we have $x^2=1$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_17", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_17 {G : Type*} [Group G] {x : G} {n : ℕ}\n (hxn: orderOf x = n) :\n x⁻¹ = x ^ (n - 1 : ℤ) := sorry", "formal_proof": null, "informal_stmt": "Let $x$ be an element of $G$. Prove that if $|x|=n$ for some positive integer $n$ then $x^{-1}=x^{n-1}$.\n\\begin{proof}\n We have $x \\cdot x^{n-1}=x^n=1$, so by the uniqueness of inverses $x^{-1}=x^{n-1}$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_18", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_18 {G : Type*} [Group G]\n (x y : G) : (x * y = y * x ↔ y⁻¹ * x * y = x) ↔ (x⁻¹ * y⁻¹ * x * y = 1) := sorry", "formal_proof": null, "informal_stmt": "Let $x$ and $y$ be elements of $G$. Prove that $xy=yx$ if and only if $y^{-1}xy=x$ if and only if $x^{-1}y^{-1}xy=1$.\n\\begin{proof}\nIf $x y=y x$, then $y^{-1} x y=y^{-1} y x=1 x=x$. Multiplying by $x^{-1}$ then gives $x^{-1} y^{-1} x y=1$.\n\nOn the other hand, if $x^{-1} y^{-1} x y=1$, then we may multiply on the left by $x$ to get $y^{-1} x y=x$. Then multiplying on the left by $y$ gives $x y=y x$ as desired.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_20", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_20 {G : Type*} [Group G] {x : G} :\n orderOf x = orderOf x⁻¹ := sorry", "formal_proof": null, "informal_stmt": "For $x$ an element in $G$ show that $x$ and $x^{-1}$ have the same order.\n\\begin{proof}\n Recall that the order of a group element is either a positive integer or infinity.\nSuppose $|x|$ is infinite and that $\\left|x^{-1}\\right|=n$ for some $n$. Then\n$$\nx^n=x^{(-1) \\cdot n \\cdot(-1)}=\\left(\\left(x^{-1}\\right)^n\\right)^{-1}=1^{-1}=1,\n$$\na contradiction. So if $|x|$ is infinite, $\\left|x^{-1}\\right|$ must also be infinite. Likewise, if $\\left|x^{-1}\\right|$ is infinite, then $\\left|\\left(x^{-1}\\right)^{-1}\\right|=|x|$ is also infinite.\nSuppose now that $|x|=n$ and $\\left|x^{-1}\\right|=m$ are both finite. Then we have\n$$\n\\left(x^{-1}\\right)^n=\\left(x^n\\right)^{-1}=1^{-1}=1,\n$$\nso that $m \\leq n$. Likewise, $n \\leq m$. Hence $m=n$ and $x$ and $x^{-1}$ have the same order.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_22a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_22a {G : Type*} [Group G] (x g : G) :\n orderOf x = orderOf (g⁻¹ * x * g) := sorry", "formal_proof": null, "informal_stmt": "If $x$ and $g$ are elements of the group $G$, prove that $|x|=\\left|g^{-1} x g\\right|$.\n\\begin{proof}\n First we prove a technical lemma:\n\n {\\bf Lemma.} For all $a, b \\in G$ and $n \\in \\mathbb{Z},\\left(b^{-1} a b\\right)^n=b^{-1} a^n b$.\nThe statement is clear for $n=0$. We prove the case $n>0$ by induction; the base case $n=1$ is clear. Now suppose $\\left(b^{-1} a b\\right)^n=b^{-1} a^n b$ for some $n \\geq 1$; then\n$$\n\\left(b^{-1} a b\\right)^{n+1}=\\left(b^{-1} a b\\right)\\left(b^{-1} a b\\right)^n=b^{-1} a b b^{-1} a^n b=b^{-1} a^{n+1} b .\n$$\nBy induction the statement holds for all positive $n$.\nNow suppose $n<0$; we have\n$$\n\\left(b^{-1} a b\\right)^n=\\left(\\left(b^{-1} a b\\right)^{-n}\\right)^{-1}=\\left(b^{-1} a^{-n} b\\right)^{-1}=b^{-1} a^n b .\n$$\nHence, the statement holds for all integers $n$.\nNow to the main result. Suppose first that $|x|$ is infinity and that $\\left|g^{-1} x g\\right|=n$ for some positive integer $n$. Then we have\n$$\n\\left(g^{-1} x g\\right)^n=g^{-1} x^n g=1,\n$$\nand multiplying on the left by $g$ and on the right by $g^{-1}$ gives us that $x^n=1$, a contradiction. Thus if $|x|$ is infinity, so is $\\left|g^{-1} x g\\right|$. Similarly, if $\\left|g^{-1} x g\\right|$ is infinite and $|x|=n$, we have\n$$\n\\left(g^{-1} x g\\right)^n=g^{-1} x^n g=g^{-1} g=1,\n$$\na contradiction. Hence if $\\left|g^{-1} x g\\right|$ is infinite, so is $|x|$.\nSuppose now that $|x|=n$ and $\\left|g^{-1} x g\\right|=m$ for some positive integers $n$ and $m$. We have\n$$\n\\left(g^{-1} x g\\right)^n=g^{-1} x^n g=g^{-1} g=1,\n$$\nSo that $m \\leq n$, and\n$$\n\\left(g^{-1} x g\\right)^m=g^{-1} x^m g=1,\n$$\nso that $x^m=1$ and $n \\leq m$. Thus $n=m$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_22b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_22b {G: Type*} [Group G] (a b : G) :\n orderOf (a * b) = orderOf (b * a) := sorry", "formal_proof": null, "informal_stmt": "Deduce that $|a b|=|b a|$ for all $a, b \\in G$.\n\\begin{proof}\n Let $a$ and $b$ be arbitrary group elements. Letting $x=a b$ and $g=a$, we see that\n$$\n|a b|=\\left|a^{-1} a b a\\right|=|b a| .\n$$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_25", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_25 {G : Type*} [Group G]\n (h : ∀ x : G, x ^ 2 = 1) : ∀ a b : G, a*b = b*a := sorry", "formal_proof": null, "informal_stmt": "Prove that if $x^{2}=1$ for all $x \\in G$ then $G$ is abelian.\n\\begin{proof}\n Solution: Note that since $x^2=1$ for all $x \\in G$, we have $x^{-1}=x$. Now let $a, b \\in G$. We have\n$$\na b=(a b)^{-1}=b^{-1} a^{-1}=b a .\n$$\nThus $G$ is abelian.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_29", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_29 {A B : Type*} [Group A] [Group B] :\n ∀ x y : A × B, x*y = y*x ↔ (∀ x y : A, x*y = y*x) ∧\n (∀ x y : B, x*y = y*x) := sorry", "formal_proof": null, "informal_stmt": "Prove that $A \\times B$ is an abelian group if and only if both $A$ and $B$ are abelian.\n\\begin{proof}\n $(\\Rightarrow)$ Suppose $a_1, a_2 \\in A$ and $b_1, b_2 \\in B$. Then\n$$\n\\left(a_1 a_2, b_1 b_2\\right)=\\left(a_1, b_1\\right) \\cdot\\left(a_2, b_2\\right)=\\left(a_2, b_2\\right) \\cdot\\left(a_1, b_1\\right)=\\left(a_2 a_1, b_2 b_1\\right) .\n$$\nSince two pairs are equal precisely when their corresponding entries are equal, we have $a_1 a_2=a_2 a_1$ and $b_1 b_2=b_2 b_1$. Hence $A$ and $B$ are abelian.\n$(\\Leftarrow)$ Suppose $\\left(a_1, b_1\\right),\\left(a_2, b_2\\right) \\in A \\times B$. Then we have\n$$\n\\left(a_1, b_1\\right) \\cdot\\left(a_2, b_2\\right)=\\left(a_1 a_2, b_1 b_2\\right)=\\left(a_2 a_1, b_2 b_1\\right)=\\left(a_2, b_2\\right) \\cdot\\left(a_1, b_1\\right) .\n$$\nHence $A \\times B$ is abelian.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_1_34", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_34 {G : Type*} [Group G] {x : G}\n (hx_inf : orderOf x = 0) (n m : ℤ) :\n x ^ n ≠ x ^ m := sorry", "formal_proof": null, "informal_stmt": "If $x$ is an element of infinite order in $G$, prove that the elements $x^{n}, n \\in \\mathbb{Z}$ are all distinct.\n\\begin{proof}\n Solution: Suppose to the contrary that $x^a=x^b$ for some $0 \\leq a|x|>\\left|x^2\\right|>\\cdots,\n$$\nand in particular, $1>\\left|x^n\\right|$ for all $n$. So $x$ has infinite order in $\\mathbb{R}^{\\times}$.\nSimilarly, if $|x|>1$ (absolute value) then $x$ has infinite order in $\\mathbb{R}^{\\times}$. So $\\mathbb{R}^{\\times}$has 1 element of order 1,1 element of order 2 , and all other elements have infinite order.\nIn $\\mathbb{C}^{\\times}$, on the other hand, $i$ has order 4 . Thus $\\mathbb{R}^{\\times}$and $\\mathbb{C}^{\\times}$are not isomorphic.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_6_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Dummit_Foote_exercise_1_6_11 {A B : Type*} [Group A] [Group B] :\n A × B ≃* B × A := sorry", "formal_proof": null, "informal_stmt": "Let $A$ and $B$ be groups. Prove that $A \\times B \\cong B \\times A$.\n\\begin{proof}\n We know from set theory that the mapping $\\varphi: A \\times B \\rightarrow B \\times A$ given by $\\varphi((a, b))=(b, a)$ is a bijection with inverse $\\psi: B \\times A \\rightarrow A \\times B$ given by $\\psi((b, a))=(a, b)$. Also $\\varphi$ is a homomorphism, as we show below.\nLet $a_1, a_2 \\in A$ and $b_1, b_2 \\in B$. Then\n$$\n\\begin{aligned}\n\\varphi\\left(\\left(a_1, b_1\\right) \\cdot\\left(a_2, b_2\\right)\\right) &=\\varphi\\left(\\left(a_1 a_2, b_1 b_2\\right)\\right) \\\\\n&=\\left(b_1 b_2, a_1 a_2\\right) \\\\\n&=\\left(b_1, a_1\\right) \\cdot\\left(b_2, a_2\\right) \\\\\n&=\\varphi\\left(\\left(a_1, b_1\\right)\\right) \\cdot \\varphi\\left(\\left(a_2, b_2\\right)\\right)\n\\end{aligned}\n$$\nHence $A \\times B \\cong B \\times A$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_6_17", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_6_17 {G : Type*} [Group G] (f : G → G)\n (hf : f = λ g => g⁻¹) :\n ∀ x y : G, f x * f y = f (x*y) ↔ ∀ x y : G, x*y = y*x := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be any group. Prove that the map from $G$ to itself defined by $g \\mapsto g^{-1}$ is a homomorphism if and only if $G$ is abelian.\n\\begin{proof}\n $(\\Rightarrow)$ Suppose $G$ is abelian. Then\n$$\n\\varphi(a b)=(a b)^{-1}=b^{-1} a^{-1}=a^{-1} b^{-1}=\\varphi(a) \\varphi(b),\n$$\nso that $\\varphi$ is a homomorphism.\n$(\\Leftarrow)$ Suppose $\\varphi$ is a homomorphism, and let $a, b \\in G$. Then\n$$\na b=\\left(b^{-1} a^{-1}\\right)^{-1}=\\varphi\\left(b^{-1} a^{-1}\\right)=\\varphi\\left(b^{-1}\\right) \\varphi\\left(a^{-1}\\right)=\\left(b^{-1}\\right)^{-1}\\left(a^{-1}\\right)^{-1}=b a,\n$$\nso that $G$ is abelian.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_1_6_23", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_6_23 {G : Type*}\n [Group G] (σ : MulAut G) (hs : ∀ g : G, σ g = 1 → g = 1)\n (hs2 : ∀ g : G, σ (σ g) = g) :\n ∀ x y : G, x*y = y*x := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a finite group which possesses an automorphism $\\sigma$ such that $\\sigma(g)=g$ if and only if $g=1$. If $\\sigma^{2}$ is the identity map from $G$ to $G$, prove that $G$ is abelian.\n\\begin{proof}\n Solution: We define a mapping $f: G \\rightarrow G$ by $f(x)=x^{-1} \\sigma(x)$.\nClaim: $f$ is injective.\nProof of claim: Suppose $f(x)=f(y)$. Then $y^{-1} \\sigma(y)=x^{-1} \\sigma(x)$, so that $x y^{-1}=\\sigma(x) \\sigma\\left(y^{-1}\\right)$, and $x y^{-1}=\\sigma\\left(x y^{-1}\\right)$. Then we have $x y^{-1}=1$, hence $x=y$. So $f$ is injective.\n\nSince $G$ is finite and $f$ is injective, $f$ is also surjective. Then every $z \\in G$ is of the form $x^{-1} \\sigma(x)$ for some $x$. Now let $z \\in G$ with $z=x^{-1} \\sigma(x)$. We have\n$$\n\\sigma(z)=\\sigma\\left(x^{-1} \\sigma(x)\\right)=\\sigma(x)^{-1} x=\\left(x^{-1} \\sigma(x)\\right)^{-1}=z^{-1} .\n$$\nThus $\\sigma$ is in fact the inversion mapping, and we assumed that $\\sigma$ is a homomorphism. By a previous example, then, $G$ is abelian.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_2_1_5", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_2_1_5 {G : Type*} [Group G] [Fintype G]\n (hG : card G > 2) (H : Subgroup G) [Fintype H] :\n card H ≠ card G - 1 := sorry", "formal_proof": null, "informal_stmt": "Prove that $G$ cannot have a subgroup $H$ with $|H|=n-1$, where $n=|G|>2$.\n\\begin{proof}\n Solution: Under these conditions, there exists a nonidentity element $x \\in H$ and an element $y \\notin H$. Consider the product $x y$. If $x y \\in H$, then since $x^{-1} \\in H$ and $H$ is a subgroup, $y \\in H$, a contradiction. If $x y \\notin H$, then we have $x y=y$. Thus $x=1$, a contradiction. Thus no such subgroup exists.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_2_1_13", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_2_1_13 (H : AddSubgroup ℚ) {x : ℚ}\n (hH : x ∈ H → (1 / x) ∈ H):\n H = ⊥ ∨ H = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $H$ be a subgroup of the additive group of rational numbers with the property that $1 / x \\in H$ for every nonzero element $x$ of $H$. Prove that $H=0$ or $\\mathbb{Q}$.\n\\begin{proof}\n Solution: First, suppose there does not exist a nonzero element in $H$. Then $H=0$.\nNow suppose there does exist a nonzero element $a \\in H$; without loss of generality, say $a=p / q$ in lowest terms for some integers $p$ and $q$ - that is, $\\operatorname{gcd}(p, q)=1$. Now $q \\cdot \\frac{p}{q}=p \\in H$, and since $q / p \\in H$, we have $p \\cdot \\frac{q}{p} \\in H$. There exist integers $x, y$ such that $q x+p y=1$; note that $q x \\in H$ and $p y \\in H$, so that $1 \\in H$. Thus $n \\in H$ for all $n \\in \\mathbb{Z}$. Moreover, if $n \\neq 0,1 / n \\in H$. Then $m / n \\in H$ for all integers $m, n$ with $n \\neq 0$; hence $H=\\mathbb{Q}$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_2_4_4", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_2_4_4 {G : Type*} [Group G] (H : Subgroup G) :\n closure ((H : Set G) \\ {1}) = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ is a subgroup of $G$ then $H$ is generated by the set $H-\\{1\\}$.\n\\begin{proof}\n If $H=\\{1\\}$ then $H-\\{1\\}$ is the empty set which indeed generates the trivial subgroup $H$. So suppose $|H|>1$ and pick a nonidentity element $h \\in H$. Since $1=h h^{-1} \\in\\langle H-\\{1\\}\\rangle$ (Proposition 9), we see that $H \\leq\\langle H-\\{1\\}\\rangle$. By minimality of $\\langle H-\\{1\\}\\rangle$, the reverse inclusion also holds so that $\\langle H-\\{1\\}\\rangle=$ $H$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_2_4_16a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_2_4_16a {G : Type*} [Group G] {H : Subgroup G}\n (hH : H ≠ ⊤) :\n ∃ M : Subgroup G, M ≠ ⊤ ∧\n ∀ K : Subgroup G, M ≤ K → K = M ∨ K = ⊤ ∧\n H ≤ M := sorry", "formal_proof": null, "informal_stmt": "A subgroup $M$ of a group $G$ is called a maximal subgroup if $M \\neq G$ and the only subgroups of $G$ which contain $M$ are $M$ and $G$. Prove that if $H$ is a proper subgroup of the finite group $G$ then there is a maximal subgroup of $G$ containing $H$.\n\\begin{proof}\nIf $H$ is maximal, then we are done. If $H$ is not maximal, then there is a subgroup $K_1$ of $G$ such that $H1$ and let $H \\leq D_{2 n}$ consist of the rotations of $D_{2 n}$. That is, $H=\\langle r\\rangle$. Now, this subgroup is proper since it does not contain $s$. If $H$ is not maximal, then by the previous proof we know there is a maximal subset $K$ containing $H$. Then $K$ must contain a reflection $s r^k$ for $k \\in\\{0,1, \\ldots, n-1\\}$. Then since $s r^k \\in K$ and $r^{n-k} \\in K$, it follows by closure that\n$$\ns=\\left(s r^k\\right)\\left(r^{n-k}\\right) \\in K .\n$$\nBut $D_{2 n}=\\langle r, s\\rangle$, so this shows that $K=D_{2 n}$, which is a contradiction. Therefore $H$ must be maximal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_2_4_16c", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_2_4_16c {n : ℕ} (H : AddSubgroup (ZMod n)) :\n ∃ p : (ZMod n), Prime p ∧ H = AddSubgroup.closure {p} ↔\n (H ≠ ⊤ ∧ ∀ K : AddSubgroup (ZMod n), H ≤ K → K = H ∨ K = ⊤) := sorry", "formal_proof": null, "informal_stmt": "Show that if $G=\\langle x\\rangle$ is a cyclic group of order $n \\geq 1$ then a subgroup $H$ is maximal if and only $H=\\left\\langle x^{p}\\right\\rangle$ for some prime $p$ dividing $n$.\n\\begin{proof}\n Suppose $H$ is a maximal subgroup of $G$. Then $H$ is cyclic, and we may write $H=\\left\\langle x^k\\right\\rangle$ for some integer $k$, with $k>1$. Let $d=(n, k)$. Since $H$ is a proper subgroup, we know by Proposition 6 that $d>1$. Choose a prime factor $p$ of $d$. If $k=p=d$ then $k \\mid n$ as required.\n\nIf, however, $k$ is not prime, then consider the subgroup $K=\\left\\langle x^p\\right\\rangle$. Since $p$ is a proper divisor of $k$, it follows that $H1$, a contradiction. Therefore $k=p$ and the left-to-right implication holds.\nNow, for the converse, suppose $H=\\left\\langle x^p\\right\\rangle$ for $p$ a prime dividing $n$. If $H$ is not maximal then the first part of this exercise shows that there is a maximal subgroup $K$ containing $H$. Then $K=\\left\\langle x^q\\right\\rangle$. So $x^p \\in\\left\\langle x^q\\right\\rangle$, which implies $q \\mid p$. But the only divisors of $p$ are 1 and $p$. If $q=1$ then $K=G$ and $K$ cannot be a proper subgroup, and if $q=p$ then $H=K$ and $H$ cannot be a proper subgroup of $K$. This contradiction shows that $H$ is maximal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_1_3a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_1_3a {A : Type*} [CommGroup A] (B : Subgroup A) :\n ∀ a b : A ⧸ B, a*b = b*a := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be an abelian group and let $B$ be a subgroup of $A$. Prove that $A / B$ is abelian.\n\\begin{proof}\n Lemma: Let $G$ be a group. If $|G|=2$, then $G \\cong Z_2$.\nProof: Since $G=\\{e a\\}$ has an identity element, say $e$, we know that $e e=e, e a=a$, and $a e=a$. If $a^2=a$, we have $a=e$, a contradiction. Thus $a^2=e$. We can easily see that $G \\cong Z_2$.\n\nIf $A$ is abelian, every subgroup of $A$ is normal; in particular, $B$ is normal, so $A / B$ is a group. Now let $x B, y B \\in A / B$. Then\n$$\n(x B)(y B)=(x y) B=(y x) B=(y B)(x B) .\n$$\nHence $A / B$ is abelian.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_1_22a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_1_22a (G : Type*) [Group G] (H K : Subgroup G)\n [Normal H] [Normal K] :\n Normal (H ⊓ K) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ and $K$ are normal subgroups of a group $G$ then their intersection $H \\cap K$ is also a normal subgroup of $G$.\n\\begin{proof}\n Suppose $H$ and $K$ are normal subgroups of $G$. We already know that $H \\cap K$ is a subgroup of $G$, so we need to show that it is normal. Choose any $g \\in G$ and any $x \\in H \\cap K$. Since $x \\in H$ and $H \\unlhd G$, we know $g x g^{-1} \\in H$. Likewise, since $x \\in K$ and $K \\unlhd G$, we have $g x g^{-1} \\in K$. Therefore $g x g^{-1} \\in H \\cap K$. This shows that $g(H \\cap K) g^{-1} \\subseteq H \\cap K$, and this is true for all $g \\in G$. By Theorem 6 (5) (which we will prove in Exercise 3.1.25), this is enough to show that $H \\cap K \\unlhd G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_1_22b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_1_22b {G : Type*} [Group G] (I : Type*)\n (H : I → Subgroup G) (hH : ∀ i : I, Normal (H i)) :\n Normal (⨅ (i : I), H i):= sorry", "formal_proof": null, "informal_stmt": "Prove that the intersection of an arbitrary nonempty collection of normal subgroups of a group is a normal subgroup (do not assume the collection is countable).\n\\begin{proof}\nLet $\\left\\{H_i \\mid i \\in I\\right\\}$ be an arbitrary collection of normal subgroups of $G$ and consider the intersection\n$$\n\\bigcap_{i \\in I} H_i\n$$\nTake an element $a$ in the intersection and an arbitrary element $g \\in G$. Then $g a g^{-1} \\in H_i$ because $H_i$ is normal for any $i \\in H$\nBy the definition of the intersection, this shows that $g a g^{-1} \\in \\bigcap_{i \\in I} H_i$ and therefore it is a normal subgroup.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_2_8", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_2_8 {G : Type*} [Group G] (H K : Subgroup G)\n [Fintype H] [Fintype K]\n (hHK : Nat.Coprime (card H) (card K)) :\n H ⊓ K = ⊥ := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ and $K$ are finite subgroups of $G$ whose orders are relatively prime then $H \\cap K=1$.\n\\begin{proof}\n Solution: Let $|H|=p$ and $|K|=q$. We saw in a previous exercise that $H \\cap K$ is a subgroup of both $H$ and $K$; by Lagrange's Theorem, then, $|H \\cap K|$ divides $p$ and $q$. Since $\\operatorname{gcd}(p, q)=1$, then, $|H \\cap K|=1$. Thus $H \\cap K=1$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_2_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_2_11 {G : Type*} [Group G] {H K : Subgroup G}\n (hHK : H ≤ K) :\n H.index = K.index * H.relindex K := sorry", "formal_proof": null, "informal_stmt": "Let $H \\leq K \\leq G$. Prove that $|G: H|=|G: K| \\cdot|K: H|$ (do not assume $G$ is finite).\n\\begin{proof}\n Proof. Let $G$ be a group and let $I$ be a nonempty set of indices, not necessarily countable. Consider the collection of subgroups $\\left\\{N_\\alpha \\mid \\alpha \\in I\\right\\}$, where $N_\\alpha \\unlhd G$ for each $\\alpha \\in I$. Let\n$$\nN=\\bigcap_{\\alpha \\in I} N_\\alpha .\n$$\nWe know $N$ is a subgroup of $G$. \nFor any $g \\in G$ and any $n \\in N$, we must have $n \\in N_\\alpha$ for each $\\alpha$. And since $N_\\alpha \\unlhd G$, we have $g n g^{-1} \\in N_\\alpha$ for each $\\alpha$. Therefore $g n g^{-1} \\in N$, which shows that $g N g^{-1} \\subseteq N$ for each $g \\in G$. As before, this is enough to complete the proof.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_2_16", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_2_16 (p : ℕ) (hp : Nat.Prime p) (a : ℕ) :\n Nat.Coprime a p → a ^ p ≡ a [ZMOD p] := sorry", "formal_proof": null, "informal_stmt": "Use Lagrange's Theorem in the multiplicative group $(\\mathbb{Z} / p \\mathbb{Z})^{\\times}$to prove Fermat's Little Theorem: if $p$ is a prime then $a^{p} \\equiv a(\\bmod p)$ for all $a \\in \\mathbb{Z}$.\n\\begin{proof}\n Solution: If $p$ is prime, then $\\varphi(p)=p-1$ (where $\\varphi$ denotes the Euler totient). Thus\n$$\n\\mid\\left((\\mathbb{Z} /(p))^{\\times} \\mid=p-1 .\\right.\n$$\nSo for all $a \\in(\\mathbb{Z} /(p))^{\\times}$, we have $|a|$ divides $p-1$. Hence\n$$\na=1 \\cdot a=a^{p-1} a=a^p \\quad(\\bmod p) .\n$$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_2_21a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_2_21a (H : AddSubgroup ℚ) (hH : H ≠ ⊤) : H.index = 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\mathbb{Q}$ has no proper subgroups of finite index.\n\\begin{proof}\n Solution: We begin with a lemma.\nLemma: If $D$ is a divisible abelian group, then no proper subgroup of $D$ has finite index.\nProof: We saw previously that no finite group is divisible and that every proper quotient $D / A$ of a divisible group is divisible; thus no proper quotient of a divisible group is finite. Equivalently, $[D: A]$ is not finite.\nBecause $\\mathbb{Q}$ and $\\mathbb{Q} / \\mathbb{Z}$ are divisible, the conclusion follows.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_3_3", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_3_3 {p : Nat.Primes} {G : Type*} [Group G]\n {H : Subgroup G} [hH : H.Normal] (hH1 : H.index = p) :\n ∀ K : Subgroup G, K ≤ H ∨ H ⊔ K = ⊤ ∨ (K ⊓ H).relindex K = p := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ is a normal subgroup of $G$ of prime index $p$ then for all $K \\leq G$ either $K \\leq H$, or $G=H K$ and $|K: K \\cap H|=p$.\n\\begin{proof}\n Solution: Suppose $K \\backslash N \\neq \\emptyset$; say $k \\in K \\backslash N$. Now $G / N \\cong \\mathbb{Z} /(p)$ is cyclic, and moreover is generated by any nonidentity- in particular by $\\bar{k}$\n\nNow $K N \\leq G$ since $N$ is normal. Let $g \\in G$. We have $g N=k^a N$ for some integer a. In particular, $g=k^a n$ for some $n \\in N$, hence $g \\in K N$. We have $[K: K \\cap N]=p$ by the Second Isomorphism Theorem.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_4_1", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_1 (G : Type*) [CommGroup G] [IsSimpleGroup G] :\n IsCyclic G ∧ ∃ G_fin : Fintype G, Nat.Prime (@card G G_fin) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $G$ is an abelian simple group then $G \\cong Z_{p}$ for some prime $p$ (do not assume $G$ is a finite group).\n\\begin{proof}\n Solution: Let $G$ be an abelian simple group.\nSuppose $G$ is infinite. If $x \\in G$ is a nonidentity element of finite order, then $\\langle x\\rangle1$. First, if $n$ is prime then Cauchy's Theorem allows us to find an element $x \\in G$ having order $n$. Then $\\langle x\\rangle$ is the desired subgroup. On the other hand, if $n$ is not prime, then $n$ has a prime divisor $p$, so that $n=k p$ for some integer $k$. Cauchy's Theorem allows us to find an element $x$ having order $p$. Set $N=\\langle x\\rangle$. By Lagrange's Theorem,\n$$\n|G / N|=\\frac{|G|}{|N|}<|G| .\n$$\nNow, by the inductive hypothesis, the group $G / N$ must have a subgroup of order $k$. And by the Lattice Isomorphism Theorem, this subgroup has the form $H / N$ for some subgroup $H$ of $G$. Then $|H|=k|N|=k p=n$, so that $H$ has order $n$. This completes the inductive step.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_4_5a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_5a {G : Type*} [Group G]\n (H : Subgroup G) [IsSolvable G] : IsSolvable H := sorry", "formal_proof": null, "informal_stmt": "Prove that subgroups of a solvable group are solvable.\n\\begin{proof}\n Let $G$ be a solvable group and let $H \\leq G$. Since $G$ is solvable, we may find a chain of subgroups\n$$\n1=G_0 \\unlhd G_1 \\unlhd G_2 \\unlhd \\cdots \\unlhd G_n=G\n$$\nso that each quotient $G_{i+1} / G_i$ is abelian. For each $i$, define\n$$\nH_i=G_i \\cap H, \\quad 0 \\leq i \\leq n .\n$$\nThen $H_i \\leq H_{i+1}$ for each $i$. Moreover, if $g \\in H_{i+1}$ and $x \\in H_i$, then in particular $g \\in G_{i+1}$ and $x \\in G_i$, so that\n$$\ng x g^{-1} \\in G_i\n$$\nbecause $G_i \\unlhd G_{i+1}$. But $g$ and $x$ also belong to $H$, so\n$$\ng x g^{-1} \\in H_i,\n$$\nwhich shows that $H_i \\unlhd H_{i+1}$ for each $i$.\nNext, note that\n$$\nH_i=G_i \\cap H=\\left(G_i \\cap G_{i+1}\\right) \\cap H=G_i \\cap H_{i+1} .\n$$\nBy the Second Isomorphism Theorem, we then have\n$$\nH_{i+1} / H_i=H_{i+1} /\\left(H_{i+1} \\cap G_i\\right) \\cong H_{i+1} G_i / G_i \\leq G_{i+1} / G_i .\n$$\nSince $H_{i+1} / H_i$ is isomorphic to a subgroup of the abelian group $G_{i+1} / G_i$, it follows that $H_{i+1} / H_i$ is also abelian. This completes the proof that $H$ is solvable.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_4_5b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_5b {G : Type*} [Group G] [IsSolvable G]\n (H : Subgroup G) [Normal H] :\n IsSolvable (G ⧸ H) := sorry", "formal_proof": null, "informal_stmt": "Prove that quotient groups of a solvable group are solvable.\n\\begin{proof}\n Next, note that\n$$\nH_i=G_i \\cap H=\\left(G_i \\cap G_{i+1}\\right) \\cap H=G_i \\cap H_{i+1} .\n$$\nBy the Second Isomorphism Theorem, we then have\n$$\nH_{i+1} / H_i=H_{i+1} /\\left(H_{i+1} \\cap G_i\\right) \\cong H_{i+1} G_i / G_i \\leq G_{i+1} / G_i .\n$$\nSince $H_{i+1} / H_i$ is isomorphic to a subgroup of the abelian group $G_{i+1} / G_i$, it follows that $H_{i+1} / H_i$ is also abelian. This completes the proof that $H$ is solvable.\nNext, let $N \\unlhd G$. For each $i$, define\n$$\nN_i=G_i N, \\quad 0 \\leq i \\leq n .\n$$\nNow let $g \\in N_{i+1}$, where $g=g_0 n_0$ with $g_0 \\in G_{i+1}$ and $n_0 \\in N$. Also let $x \\in N_i$, where $x=g_1 n_1$ with $g_1 \\in G_i$ and $n_1 \\in N$. Then\n$$\ng x g^{-1}=g_0 n_0 g_1 n_1 n_0^{-1} g_0^{-1} .\n$$\nNow, since $N$ is normal in $G, N g=g N$, so $n_0 g_1=g_1 n_2$ for some $n_2 \\in N$. Then\n$$\ng x g^{-1}=g_0 g_1\\left(n_2 n_1 n_0^{-1}\\right) g_0^{-1}=g_0 g_1 n_3 g_0^{-1}\n$$\nfor some $n_3 \\in N$. Then $n_3 g_0^{-1}=g_0^{-1} n_4$ for some $n_4 \\in N$. And $g_0 g_1 g_0^{-1} \\in G_i$ since $G_i \\unlhd G_{i+1}$, so\n$$\ng x g^{-1}=g_0 g_1 g_0^{-1} n_4 \\in N_i .\n$$\nThis shows that $N_i \\unlhd N_{i+1}$. So by the Lattice Isomorphism Theorem, we have $N_{i+1} / N \\unlhd N_i / N$. This shows that\n$$\n1=N_0 / N \\unlhd N_1 / N \\unlhd N_2 / N \\unlhd \\cdots \\unlhd N_n / N=G / N .\n$$\nMoreover, the Third Isomorphism Theorem says that\n$$\n\\left(N_{i+1} / N\\right) /\\left(N_i / N\\right) \\cong N_{i+1} / N_i,\n$$\nso the proof will be complete if we can show that $N_{i+1} / N_i$ is abelian.\nLet $x, y \\in N_{i+1} / N_i$. Then\n$$\nx=\\left(g_0 n_0\\right) N_i \\quad \\text { and } \\quad y=\\left(g_1 n_1\\right) N_i\n$$\nfor some $g_0, g_1 \\in G_{i+1}$ and $n_0, n_1 \\in N$. We have\n$$\n\\begin{aligned}\nx y x^{-1} y^{-1} & =\\left(g_0 n_0\\right)\\left(g_1 n_1\\right)\\left(g_0 n_0\\right)^{-1}\\left(g_1 n_1\\right)^{-1} N_i \\\\\n& =g_0 n_0 g_1 n_1 n_0^{-1} g_0^{-1} n_1^{-1} g_1^{-1} N_i .\n\\end{aligned}\n$$\nSince $N \\unlhd G, g N=N g$ for any $g \\in G$, so we can find $n_2 \\in N$ such that\n$$\nx y x^{-1} y^{-1}=g_0 g_1 g_0^{-1} g^{-1} n_2 N_i .\n$$\nNow $N_i=G_i N=N G_i$ since $N \\unlhd G$ (see Proposition 14 and its corollary). Therefore\n$$\nn_2 N_i=n_2 N G_i=N G_i=G_i N\n$$\nand we get\n$$\nx y x^{-1} y^{-1}=g_0 g_1 g_0^{-1} g^{-1} G_i N=G_i N .\n$$\nSo $x y x^{-1} y^{-1}=1 N_i$ or $x y=y x$. This completes the proof that $G / N$ is solvable.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_3_4_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_11 {G : Type*} [Group G] [IsSolvable G]\n {H : Subgroup G} (hH : H ≠ ⊥) [H.Normal] :\n ∃ A ≤ H, A.Normal ∧ ∀ a b : A, a*b = b*a := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ is a nontrivial normal subgroup of the solvable group $G$ then there is a nontrivial subgroup $A$ of $H$ with $A \\unlhd G$ and $A$ abelian.\n\\begin{proof}\n Suppose $H$ is a nontrivial normal subgroup of the solvable group $G$.\nFirst, notice that $H$, being a subgroup of a solvable group, is itself solvable. By exercise $8, H$ has a chain of subgroups\n$$\n1 \\leq H_1 \\leq \\ldots \\leq H\n$$\nsuch that each $H_i$ is a normal subgroup of $H$ itself and $H_{i+1} / H_i$ is abelian. But then the first group in the series\n$$\nH_1 / 1 \\cong H\n$$\nis an abelian subgroup of $H$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_2_8", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_8 {G : Type*} [Group G] {H : Subgroup G}\n {n : ℕ} (hn : n > 0) (hH : H.index = n) :\n ∃ K ≤ H, K.Normal ∧ K.index ≤ n.factorial := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ has finite index $n$ then there is a normal subgroup $K$ of $G$ with $K \\leq H$ and $|G: K| \\leq n!$.\n\\begin{proof}\n Solution: $G$ acts on the cosets $G / H$ by left multiplication. Let $\\lambda: G \\rightarrow S_{G / H}$ be the permutation representation induced by this action, and let $K$ be the kernel of the representation.\nNow $K$ is normal in $G$, and $K \\leq \\operatorname{stab}_G(H)=H$. By the First Isomorphism Theorem, we have an injective group homomorphism $\\bar{\\lambda}: G / K \\rightarrow S_{G / H}$. Since $\\left|S_{G / H}\\right|=n !$, we have $[G: K] \\leq n !$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_3_26", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_3_26 {α : Type*} [Fintype α] (ha : card α > 1)\n (h_tran : ∀ a b: α, ∃ σ : Equiv.Perm α, σ a = b) :\n ∃ σ : Equiv.Perm α, ∀ a : α, σ a ≠ a := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a transitive permutation group on the finite set $A$ with $|A|>1$. Show that there is some $\\sigma \\in G$ such that $\\sigma(a) \\neq a$ for all $a \\in A$.\n\\begin{proof}\n Let $G$ be a transitive permutation group on the finite set $A,|A|>1$. We want to find an element $\\sigma$ which doesn't stabilize anything, that is, we want a $\\sigma$ such that\n$$\n\\sigma \\notin G_a\n$$\nfor all $a \\in A$.\nSince the group is transitive, there is always a $g \\in G$ such that $b=g \\cdot a$. Let us see in what relationship the stabilizers of $a$ and $b$ are. We find\n$$\n\\begin{aligned}\nG_b & =\\{h \\in G \\mid h \\cdot b=b\\} \\\\\n& =\\{h \\in G \\mid h g \\cdot a=g \\cdot a\\} \\\\\n& =\\left\\{h \\in G \\mid g^{-1} h g \\cdot a=a\\right\\}\n\\end{aligned}\n$$\nPutting $h^{\\prime}=g^{-1} h g$, we have $h=g h^{\\prime} g^{-1}$ and\n$$\n\\begin{aligned}\nG_b & =g\\left\\{h^{\\prime} \\in H \\mid h^{\\prime} \\cdot a=a\\right\\} g^{-1} \\\\\n& =g G_a g^{-1}\n\\end{aligned}\n$$\nBy the above, the stabilizer subgroup of any element is conjugate to some other stabilizer subgroup. Now, the stabilizer cannot be all of $G$ (else $\\{a\\}$ would be a orbit). Thus it is a proper subgroup of $G$. By the previous exercise, we have\n$$\n\\bigcup_{a \\in A} G_a=\\bigcup_{g \\in G} g G_a g^{-1} \\subset G\n$$\n(the union of conjugates of a proper subgroup can never be all of $G$ ). This shows there is an element $\\sigma$ which is not in any stabilizer of any element of $A$. Then $\\sigma(a) \\neq a$ for all $a \\in A$, as we wanted to show.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_2_9a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_9a {G : Type*} [Fintype G] [Group G] {p α : ℕ}\n (hp : p.Prime) (ha : α > 0) (hG : card G = p ^ α) :\n ∀ H : Subgroup G, H.index = p → H.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that if $p$ is a prime and $G$ is a group of order $p^{\\alpha}$ for some $\\alpha \\in \\mathbb{Z}^{+}$, then every subgroup of index $p$ is normal in $G$.\n\\begin{proof}\n Solution: Let $G$ be a group of order $p^k$ and $H \\leq G$ a subgroup with $[G: H]=p$. Now $G$ acts on the conjugates $g H g^{-1}$ by conjugation, since\n$$\ng_1 g_2 \\cdot H=\\left(g_1 g_2\\right) H\\left(g_1 g_2\\right)^{-1}=g_1\\left(g_2 H g_2^{-1}\\right) g_1^{-1}=g_1 \\cdot\\left(g_2 \\cdot H\\right)\n$$\nand $1 \\cdot H=1 H 1=H$. Moreover, under this action we have $H \\leq \\operatorname{stab}(H)$. By Exercise 3.2.11, we have\n$$\n[G: \\operatorname{stab}(H)][\\operatorname{stab}(H): H]=[G: H]=p,\n$$\na prime.\nIf $[G: \\operatorname{stab}(H)]=p$, then $[\\operatorname{stab}(H): H]=1$ and we have $H=\\operatorname{stab}(H)$; moreover, $H$ has exactly $p$ conjugates in $G$. Let $\\varphi: G \\rightarrow S_p$ be the permutation representation induced by the action of $G$ on the conjugates of $H$, and let $K$ be the kernel of this representation. Now $K \\leq \\operatorname{stab}(H)=H$. By the first isomorphism theorem, the induced map $\\bar{\\varphi}: G / K \\rightarrow S_p$ is injective, so that $|G / K|$ divides $p$ !. Note, however, that $|G / K|$ is a power of $p$ and that the only powers of $p$ that divide $p$ ! are 1 and $p$. So $[G: K]$ is 1 or $p$. If $[G: K]=1$, then $G=K$ so that $g H g^{-1}=H$ for all $g \\in G$; then $\\operatorname{stab}(H)=G$ and we have $[G: \\operatorname{stab}(H)]=1$, a contradiction. Now suppose $[G: K]=p$. Again by Exercise $3.2$.11 we have $[G: K]=[G: H][H: K]$, so that $[H: K]=1$, hence $H=K$. Again, this implies that $H$ is normal so that $g H g^{-1}=H$ for all $g \\in G$, and we have $[G: \\operatorname{stab}(H)]=1$, a contradiction. Thus $[G: \\operatorname{stab}(H)] \\neq p$\nIf $[G: \\operatorname{stab}(H)]=1$, then $G=\\operatorname{stab}(H)$. That is, $g H g^{-1}=H$ for all $g \\in G$; thus $H \\leq G$ is normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_2_14", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_14 {G : Type*} [Fintype G] [Group G]\n (hG : ¬ (card G).Prime) (hG1 : ∀ k : ℕ, k ∣ card G →\n ∃ (H : Subgroup G) (fH : Fintype H), @card H fH = k) :\n ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a finite group of composite order $n$ with the property that $G$ has a subgroup of order $k$ for each positive integer $k$ dividing $n$. Prove that $G$ is not simple.\n\\begin{proof}\n Solution: Let $p$ be the smallest prime dividing $n$, and write $n=p m$. Now $G$ has a subgroup $H$ of order $m$, and $H$ has index $p$. Then $H$ is normal in $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_4_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_2 {G : Type*} [Fintype G] [Group G]\n {p q : Nat.Primes} (hpq : p ≠ q) (hG : card G = p*q) :\n IsCyclic G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $G$ is an abelian group of order $p q$, where $p$ and $q$ are distinct primes, then $G$ is cyclic.\n\\begin{proof}\n Let $G$ be an abelian group of order $p q$. We need to prove that if $p$ and $q$ are distinct primes than $G$ is cyclic. By Cauchy's theorem there are $a, b \\in G$ with $a$ of order $p$ and $b$ of order $q$. Since $(|a|,|b|)=1$ and $a b=b a$ then $|a b|=|a| \\cdot|b|=p q$. Therefore $a b$ is an element of order $p q$, the order of $G$, which means $G$ is cyclic.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_4_6a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_6a {G : Type*} [Group G] (H : Subgroup G)\n [Characteristic H] : Normal H := sorry", "formal_proof": null, "informal_stmt": "Prove that characteristic subgroups are normal.\n\\begin{proof}\n Let $H$ be a characteristic subgroup of $G$. By definition $\\alpha(H) \\subset H$ for every $\\alpha \\in \\operatorname{Aut}(G)$. So, $H$ is in particular invariant under the inner automorphism. Let $\\phi_g$ denote the conjugation automorphism by $g$. Then $\\phi_g(H) \\subset H \\Longrightarrow$ $g H g^{-1} \\subset H$. So, $H$ is normal. \n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_4_6b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_6b :\n ∃ (G : Type*) (hG : Group G) (H : @Subgroup G hG), @Characteristic G hG H ∧ ¬ @Normal G hG H := sorry", "formal_proof": null, "informal_stmt": "Prove that there exists a normal subgroup that is not characteristic.\n\\begin{proof}\n We have to produce a group $G$ and a subgroup $H$ such that $H$ is normal in $G$, but not characteristic. Consider the Klein's four group $G=\\{ e, a, b, a b\\}$. This is an abelian group with each element having order 2. Consider $H=\\{ e, a\\}$. $H$ is normal in $G$. Define $\\sigma: G \\rightarrow G$ as $\\sigma(a)=b, \\sigma(b)=a, \\sigma(a b)=a b$. Clearly $\\sigma$ does not fix $H$. So, $H$ is not characteristic.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_4_7", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_7 {G : Type*} [Group G] {H : Subgroup G} [Fintype H]\n (hH : ∀ (K : Subgroup G) (fK : Fintype K), card H = @card K fK → H = K) :\n H.Characteristic := sorry", "formal_proof": null, "informal_stmt": "If $H$ is the unique subgroup of a given order in a group $G$ prove $H$ is characteristic in $G$.\n\\begin{proof}\n Let $G$ be group and $H$ be the unique subgroup of order $n$. Now, let $\\sigma \\in \\operatorname{Aut}(G)$. Now Clearly $|\\sigma(G)|=n$, because $\\sigma$ is a one-one onto map. But then as $H$ is the only subgroup of order $n$, and because of the fact that a automorphism maps subgroups to subgroups, we have $\\sigma(H)=$ $H$ for every $\\sigma \\in \\operatorname{Aut}(G)$. Hence, $H$ is a characteristic subgroup of $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_4_8a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_8a {G : Type*} [Group G] (H K : Subgroup G)\n (hHK : H ≤ K) [hHK1 : (H.subgroupOf K).Normal] [hK : K.Normal] :\n H.Normal := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a group with subgroups $H$ and $K$ with $H \\leq K$. Prove that if $H$ is characteristic in $K$ and $K$ is normal in $G$ then $H$ is normal in $G$.\n\\begin{proof}\nWe prove that $H$ is invariant under every inner automorphism of $G$. Consider a inner automorphism $\\phi_g$ of $G$. Now, $\\left.\\phi_g\\right|_K$ is a automorphism of $K$ because $K$ is normal in $G$. But $H$ is a characteristic subgroup of $K$, so $\\left.\\phi_g\\right|_K(H) \\subset H$, so in general $\\phi_g(H) \\subset H$. Hence $H$ is characteristic in $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_1a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_1a {p : ℕ} {G : Type*} [Group G]\n {P : Subgroup G} (hP : IsPGroup p P) (H : Subgroup G)\n (hH : P ≤ H) : IsPGroup p H := sorry", "formal_proof": null, "informal_stmt": "Prove that if $P \\in \\operatorname{Syl}_{p}(G)$ and $H$ is a subgroup of $G$ containing $P$ then $P \\in \\operatorname{Syl}_{p}(H)$.\n\\begin{proof}\nIf $P \\leq H \\leq G$ is a Sylow $p$-subgroup of $G$, then $p$ does not divide $[G: P]$. Now $[G: P]=[G: H][H: P]$, so that $p$ does not divide $[H: P]$; hence $P$ is a Sylow $p$-subgroup of $H$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_13", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_13 {G : Type*} [Group G] [Fintype G]\n (hG : card G = 56) :\n ∃ (p : ℕ) (P : Sylow p G), P.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of order 56 has a normal Sylow $p$-subgroup for some prime $p$ dividing its order.\n\\begin{proof} \nSince $|G|=56=2^{3}.7$, $G$ has $2-$Sylow subgroup of order $8$, as well as $7-$Sylow subgroup of order $7$. Now, we count the number of such subgroups. Let $n_{7}$ be the number of $7-$Sylow subgroup and $n_{2}$ be the number of $2-$Sylow subgroup. Now $n_{7}=1+7k$ where $1+7k|8$. The choices for $k$ are $0$ or $1$. If $k=0$, there is only one $7-$Sylow subgroup and hence normal. So, assume now, that there are $8$ $7-$Sylow subgroup(for $k=1$). Now we look at $2-$ Sylow subgroups. $n_{2}=1+2k| 7$. So choice for $k$ are $0$ and $3$. If $k=0$, there is only one $2-$Sylow subgroup and hence normal. So, assume now, that there are $7$ $2-$Sylow subgroup (for $k=3$). Now we claim that simultaneously, there cannot be $8$ $7-$Sylow subgroup and $7$ $2-$Sylow subgroup. So, either $7-$Sylow subgroup is normal being unique, or the $2-$Sylow subgroup is normal. Now, to prove the claim, we observe that there are 48 elements of order $7$. Let $H_{1}$ and $H_{2}$ be two distinct $2-$Sylow subgroup. Now $|H_{1}|=8$. So we already get $48+8=56$ distinct elements in the group. Now $H_{2}$ being distinct from $H_{1}$, has at least one element which is not in $H_{1}$. This adds one more element in the group, at the least. Now already we have number of elements in the group exceeding the number of element in $G$. This gives a contradiction and proves the claim.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_14", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_14 {G : Type*} [Group G] [Fintype G]\n (hG : card G = 312) :\n ∃ (p : ℕ) (P : Sylow p G), P.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of order 312 has a normal Sylow $p$-subgroup for some prime $p$ dividing its order.\n\\begin{proof}\nLet $n_{13}$ be the number of Sylow 13 -subgroup of $G$. Then by Sylow's Theorem, $n_{13} \\equiv 1(\\bmod 13)$ and $n_{13}$ divides $2^3 \\cdot 3=24$. This implies $n_{13}=1$, so that there is only one Sylow 13 -subgroup, which is consequently normal. The last assertion follows from the fact conjugation preserves the order of a subgroup. So if there is only one subgroup $H$ of order 13 , then for any $g \\in G$, we have $\\left|g H g^{-1}\\right|=|H|=13$, so $g H g^{-1}=H$, i.e. $H$ is normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_15", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_15 {G : Type*} [Group G] [Fintype G]\n (hG : card G = 351) :\n ∃ (p : ℕ) (P : Sylow p G), P.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of order 351 has a normal Sylow $p$-subgroup for some prime $p$ dividing its order.\n\\begin{proof}\n Since $|G|=351=3^{2}.13$, $G$ has $3-$Sylow subgroup of order $9$, as well as $13-$Sylow subgroup of order $13$. Now, we count the number of such subgroups. Let $n_{13}$ be the number of $13-$Sylow subgroup and $n_{3}$ be the number of $3-$Sylow subgroup. Now $n_{13}=1+13k$ where $1+13k|9$. The choices for $k$ is $0$. Hence, there is a unique $13-$Sylow subgroup and hence is normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_16", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_16 {p q r : ℕ} {G : Type*} [Group G]\n [Fintype G] (hpqr : p < q ∧ q < r)\n (hpqr1 : p.Prime ∧ q.Prime ∧ r.Prime)(hG : card G = p*q*r) :\n Nonempty (Sylow p G) ∨ Nonempty (Sylow q G) ∨ Nonempty (Sylow r G) := sorry", "formal_proof": null, "informal_stmt": "Let $|G|=p q r$, where $p, q$ and $r$ are primes with $p1, r(q-1)-r>$ 0 . So the number of elements exceeds $p q r$. So, it proves that at least $n_p$ or $n_q$ or $n_r$ is 1, which ultimately proves the result, because a unique Sylow-p subgroup is always normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_17", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_17 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 105) :\n Nonempty (Sylow 5 G) ∧ Nonempty (Sylow 7 G) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=105$ then $G$ has a normal Sylow 5 -subgroup and a normal Sylow 7-subgroup.\n\\begin{proof} \nSince $|G|=105=3.5.7$, $G$ has $3-$Sylow subgroup of order $3$, as well as $5-$Sylow subgroup of order $5$ and, $7-$Sylow subgroup of order 7. Now, we count the number of such subgroups. Let $n_{3}$ be the number of $3-$Sylow subgroup, $n_{5}$ be the number of $5-$Sylow subgroup, and $n_{7}$ be the number of $7-$Sylow subgroup. Now $n_{7}=1+7k$ where $1+7k|15$. The choices for $k$ are $0$ or $1$. If $k=0$, there is only one $7-$Sylow subgroup and hence normal. So, assume now, that there are $15$ $7-$Sylow subgroup(for $k=1$). Now we look at $5-$ Sylow subgroups. $n_{5}=1+5k| 21$. So choice for $k$ are $0$ and $4$. If $k=0$, there is only one $5-$Sylow subgroup and hence normal. So, assume now, that there are $24$ $5-$Sylow subgroup (for $k=4$). Now we claim that simultaneously, there cannot be $15$ $7-$Sylow subgroup and $24$ $5-$Sylow subgroup. So, either $7-$Sylow subgroup is normal being unique, or the $5-$Sylow subgroup is normal. Now, to prove the claim, we observe that there are 90 elements of order $7$. Also, see that there are $24\\times 4=96$ number of elements of order 5. So we get $90+94=184$ number of elements which exceeds the order of the group. This gives a contradiction and proves the claim. So, now we have proved that there is either a normal $5-$Sylow subgroup or a normal $7-$Sylow subgroup.\n Now we prove that indeed both $5-$ Sylow subgroup and 7 -Sylow subgroup are normal. Assume that 7 -Sylow subgroup is normal. So, there is a unique 7 -Sylow subgroup, say $H$. Now assume that there are 245 -Sylow subgroups. So, we get again $24 \\times 4=96$ elements of order 5 . From $H$ we get 7 elements which gives us total of $96+7=103$ elements. Now consider the number of 3 -Sylow subgroups. $n_3=1+3 k \\mid 35$. Then the possibilities for $k$ are 0 and 2 . But we can rule out $k=2$ because having 73 -Sylow subgroup, will mean we have 14 elements of order 3 . So we get $103+14=117$ elements in total which exceeds the order of the group. So we have now that there is a unique 3 -Sylow subgroup and hence normal. Call that subgroup $K$. Now take any one 5 -Sylow subgroup, call it $L$. Now observe $L K$ is a subgroup of $G$ with order 15 . We know that a group of order 15 is cyclic by an example in Page-143 of the book. So, there is an element of order 15. Actually we have $\\phi(15)=8$ number of elements of order 15. But then again we already had 103 elements and then we actually get at least $103+8=111$ elements which exceeds the order of the group. So, there can't be 24 5-Sylow subgroups, and hence there is a unique 5-Sylow subgroup, and hence normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_18", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_18 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 200) :\n ∃ N : Sylow 5 G, N.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of order 200 has a normal Sylow 5-subgroup.\n\\begin{proof}\n Let $G$ be a group of order $200=5^2 \\cdot 8$. Note that 5 is a prime not dividing 8 . Let $P \\in$ $S y l_5(G)$. [We know $P$ exists since $S y l_5(G) \\neq \\emptyset$ by Sylow's Theorem]\n\nThe number of Sylow 5-subgroups of $G$ is of the form $1+k \\cdot 5$, i.e., $n_5 \\equiv 1(\\bmod 5)$ and $n_5$ divides 8 . The only such number that divides 8 and equals $1 (\\bmod 5)$ is 1 so $n_5=1$. Hence $P$ is the unique Sylow 5-subgroup.\nSince $P$ is the unique Sylow 5-subgroup, this implies that $P$ is normal in $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_19", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_19 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 6545) : ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=6545$ then $G$ is not simple.\n\\begin{proof} \nSince $|G|=132=2^{2}.3.11$, $G$ has $2-$Sylow subgroup of order $4$, as well as $11-$Sylow subgroup of order $11$, and $3-$Sylow subgroup of order $3$. Now, we count the number of such subgroups. Let $n_{11}$ be the number of $11-$Sylow subgroup and $n_{3}$ be the number of $3-$Sylow subgroup. Now $n_{11}=1+11k$ where $1+11k|12$. The choices for $k$ are $0$ or $1$. If $k=0$, there is only one $11-$Sylow subgroup and hence normal. So, assume now, that there are $12$ $11-$Sylow subgroup(for $k=1$). Now we look at $3-$ Sylow subgroups. $n_{3}=1+3k| 44$. So choice for $k$ are $0$, $1$, and $7$. If $k=0$, there is only one $3-$Sylow subgroup and hence normal. So, assume now, that there are $4$ $2-$Sylow subgroup (for $k=3$). Now we claim that simultaneously, there cannot be $12$ $11-$Sylow subgroup and $4$ $3-$Sylow subgroups provided there is more than one $2-$Sylow subgroups. So, either $2-$Sylow subgroup is normal or if not, then, either $11-$Sylow subgroup is normal being unique, or the $3-$Sylow subgroup is normal(We don't consider the possibility of $22$ $3-$Sylow subgroup because of obvious reason). Now, to prove the claim, we observe that there are $120$ elements of order $11$. Also there are $8$ elements of order $3$. So we already get $120+8+1=129$ distinct elements in the group. Let us count the number of $2-$Sylow subgroups in $G$. $n_{2}=1+2k|33$. The possibilities for $k$ are $0$, $1$, $5$, $16$. Now, assume there is more than one $2-$Sylow subgroups. Let $H_{1}$ and $H_{2}$ be two distinct $2-$Sylow subgroup. Now $|H_{1}|=4$. So we already get $129+3=132$ distinct elements in the group. Now $H_{2}$ being distinct from $H_{1}$, has at least one element which is not in $H_{1}$. This adds one more element in the group, at the least. Now already we have number of elements in the group exceeding the number of element in $G$. This gives a contradiction and proves the claim.\nHence $G$ is not simple.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_20", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_20 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 1365) : ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=1365$ then $G$ is not simple.\n\\begin{proof} \nSince $|G|=1365=3.5.7.13$, $G$ has $13-$Sylow subgroup of order $13$. Now, we count the number of such subgroups. Let $n_{13}$ be the number of $13-$Sylow subgroup. Now $n_{13}=1+13k$ where $1+13k|3.5.7$. The choices for $k$ is $0$. Hence, there is a unique $13-$Sylow subgroup and hence is normal. so $G$ is not simple.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_21", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_21 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 2907) : ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=2907$ then $G$ is not simple.\n\\begin{proof} \nSince $|G|=2907=3^{2}.17.19$, $G$ has $19-$Sylow subgroup of order $19$. Now, we count the number of such subgroups. Let $n_{19}$ be the number of $19-$Sylow subgroup. Now $n_{19}=1+19k$ where $1+19k|3^{2}.17$. The choices for $k$ is $0$. Hence, there is a unique $19-$Sylow subgroup and hence is normal. so $G$ is not simple.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_22", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_22 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 132) : ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=132$ then $G$ is not simple.\n\\begin{proof} \nSince $|G|=132=2^{2}.3.11$, $G$ has $2-$Sylow subgroup of order $4$, as well as $11-$Sylow subgroup of order $11$, and $3-$Sylow subgroup of order $3$. Now, we count the number of such subgroups. Let $n_{11}$ be the number of $11-$Sylow subgroup and $n_{3}$ be the number of $3-$Sylow subgroup. Now $n_{11}=1+11k$ where $1+11k|12$. The choices for $k$ are $0$ or $1$. If $k=0$, there is only one $11-$Sylow subgroup and hence normal. So, assume now, that there are $12$ $11-$Sylow subgroup(for $k=1$). Now we look at $3-$ Sylow subgroups. $n_{3}=1+3k| 44$. So choice for $k$ are $0$, $1$, and $7$. If $k=0$, there is only one $3-$Sylow subgroup and hence normal. So, assume now, that there are $4$ $2-$Sylow subgroup (for $k=3$). Now we claim that simultaneously, there cannot be $12$ $11-$Sylow subgroup and $4$ $3-$Sylow subgroups provided there is more than one $2-$Sylow subgroups. So, either $2-$Sylow subgroup is normal or if not, then, either $11-$Sylow subgroup is normal being unique, or the $3-$Sylow subgroup is normal(We don't consider the possibility of $22$ $3-$Sylow subgroup because of obvious reason). Now, to prove the claim, we observe that there are $120$ elements of order $11$. Also there are $8$ elements of order $3$. So we already get $120+8+1=129$ distinct elements in the group. Let us count the number of $2-$Sylow subgroups in $G$. $n_{2}=1+2k|33$. The possibilities for $k$ are $0$, $1$, $5$, $16$. Now, assume there is more than one $2-$Sylow subgroups. Let $H_{1}$ and $H_{2}$ be two distinct $2-$Sylow subgroup. Now $|H_{1}|=4$. So we already get $129+3=132$ distinct elements in the group. Now $H_{2}$ being distinct from $H_{1}$, has at least one element which is not in $H_{1}$. This adds one more element in the group, at the least. Now already we have number of elements in the group exceeding the number of element in $G$. This gives a contradiction and proves the claim.\nHence $G$ is not simple.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_23", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_23 {G : Type*} [Fintype G] [Group G]\n (hG : card G = 462) : ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $|G|=462$ then $G$ is not simple.\n\\begin{proof}\n Let $G$ be a group of order $462=11 \\cdot 42$. Note that 11 is a prime not dividing 42 . Let $P \\in$ $S y l_{11}(G)$. [We know $P$ exists since $S y l_{11}(G) \\neq \\emptyset$]. Note that $|P|=11^1=11$ by definition. \n\nThe number of Sylow 11-subgroups of $G$ is of the form $1+k \\cdot 11$, i.e., $n_{11} \\equiv 1$ (mod 11) and $n_{11}$ divides 42 . The only such number that divides 42 and equals 1 (mod 11) is 1 so $n_{11}=1$. Hence $P$ is the unique Sylow 11-subgroup.\n\nSince $P$ is the unique Sylow Il-subgroup, this implies that $P$ is normal in $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_28", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Dummit_Foote_exercise_4_5_28 {G : Type*} [Group G] [Fintype G]\n (hG : card G = 105) {P : Sylow 3 G} (hP : P.Normal) :\n CommGroup G := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a group of order 105. Prove that if a Sylow 3-subgroup of $G$ is normal then $G$ is abelian.\n\\begin{proof}\n Given that $G$ is a group of order $1575=3^2 .5^2 .7$. Now, Let $n_p$ be the number of Sylow-p subgroups. It is given that Sylow-3 subgroup is normal and hence is unique, so $n_3=1$. First we prove that both Sylow-5 subgroup and Sylow 7-subgroup are normal. Let $P$ be the Sylow3 subgroup. Now, Consider $G / P$, which has order $5^2 .7$. Now, the number of Sylow $-5$ subgroup of $G / P$ is given by $1+5 k$, where $1+5 k \\mid 7$. Clearly $k=0$ is the only choice and hence there is a unique Sylow-5 subgroup of $G / P$, and hence normal. In the same way Sylow-7 subgroup of $G / P$ is also unique and hence normal. Consider now the canonical map $\\pi: G \\rightarrow G / P$. The inverse image of Sylow-5 subgroup of $G / P$ under $\\pi$, call it $H$, is a normal subgroup of $G$, and $|H|=3^2 .5^2$. Similarly, the inverse image of Sylow-7 subgroup of $G / P$ under $\\pi$ call it $K$ is also normal in $G$ and $|K|=3^2 .7$. Now, consider $H$. Observe first that the number of Sylow-5 subgroup in $H$ is $1+5 k$ such that $1+5 k \\mid 9$. Again $k=0$ and hence $H$ has a unique Sylow-5 subgroup, call it $P_1$. But, it is easy to see that $P_1$ is also a Sylow-5 subgroup of $G$, because $\\left|P_1\\right|=25$. But now any other Sylow 5 subgroup of $G$ is of the form $g P_1 g^{-1}$ for some $g \\in G$. But observe that since $P_1 \\subset H$ and $H$ is normal in $G$, so $g P_1 g^1 \\subset H$, and $g P_1 g^{-1}$ is also Sylow-5 subgroup of $H$. But, then as Sylow-5 subgroup of $H$ is unique we have $g P_1 g^{-1}=P_1$. This shows that Sylow-5 subgroup of $G$ is unique and hence normal in $G$.\n\nSimilarly, one can argue the same for $K$ and deduce that Sylow-7 subgroup of $G$ is unique and hence normal. So, the first part of the problem is done.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_5_33", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_5_33 {G : Type*} [Group G] [Fintype G] {p : ℕ}\n (P : Sylow p G) [hP : P.Normal] (H : Subgroup G) [Fintype H] :\n ∀ R : Sylow p H, R.toSubgroup = (H ⊓ P.toSubgroup).subgroupOf H ∧\n Nonempty (Sylow p H) := sorry", "formal_proof": null, "informal_stmt": "Let $P$ be a normal Sylow $p$-subgroup of $G$ and let $H$ be any subgroup of $G$. Prove that $P \\cap H$ is the unique Sylow $p$-subgroup of $H$.\n\\begin{proof}\n Let $G$ be a group and $P$ is a normal $p$-Sylow subgroup of $G .|G|=p^a . m$ where $p \\nmid m$. Then $|P|=p^a$. Let $H$ be a subgroup of $G$. Now if $|H|=k$ such that $p \\nmid k$. Then $P \\cap H=\\{e\\}$. There is nothing to prove in this case. Let $|H|=p^b . n$, where $b \\leq a$, and $p \\nmid n$. Now consider $P H$ which is a subgroup of $G$, as $P$ is normal. Now $|P H|=\\frac{|P||H|}{|P \\cap H|}=\\frac{p^{a+b} \\cdot n}{|P \\cap H|}$. Now since $P H \\leq G$, so $|P H|=p^a$.l, as $P \\leq P H$. This forces $|P \\cap H|=p^b$. So by order consideration we have $P \\cap H$ is a sylow $-p$ subgroup of $H$. Now we know $P$ is unique $p$ - Sylow subgroup. Suppose $H$ has a sylow-p subgroup distinct from $P \\cap H$, call it $H_1$. Now $H_1$ is a p-subgroup of $G$. So, $H_1$ is contained in some Sylow-p subgroup of $G$, call it $P_1$. Clearly $P_1$ is distinct from $P$, which is a contradiction. So $P \\cap H$ is the only $p$-Sylow subgroup of $H$, and hence normal in $H$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_5_4_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_5_4_2 {G : Type*} [Group G] (H : Subgroup G) :\n H.Normal ↔ ⁅(⊤ : Subgroup G), H⁆ ≤ H := sorry", "formal_proof": null, "informal_stmt": "Prove that a subgroup $H$ of $G$ is normal if and only if $[G, H] \\leq H$.\n\\begin{proof}\n $H \\unlhd G$ is equivalent to $g^{-1} h g \\in H, \\forall g \\in G, \\forall h \\in H$. We claim that holds if and only if $h^{-1} g^{-1} h g \\in H, \\forall g \\in G, \\forall h \\in H$, i.e., $\\left\\{h^{-1} g^{-1} h g: h \\in H, g \\in G\\right\\} \\subseteq H$. That holds by the following argument:\nIf $g^{-1} h g \\in H, \\forall g \\in G, \\forall h \\in H$, note that $h^{-1} \\in H$, so multiplying them, we also obtain an element of $H$.\nOn the other hand, if $h^{-1} g^{-1} h g \\in H, \\forall g \\in G, \\forall h \\in H$, then\n$$\nh h^{-1} g^{-1} h g=g^{-1} h g \\in H, \\forall g \\in G, \\forall h \\in H .\n$$\nSince $\\left\\{h^{-1} g^{-1} h g: h \\in H, g \\in G\\right\\} \\subseteq H \\Leftrightarrow\\left\\langle\\left\\{h^{-1} g^{-1} h g: h \\in H, g \\in G\\right\\}\\right\\rangle \\leq H$, we've solved the exercise by definition of $[H, G]$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_1_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_1_2 {R : Type*} [Ring R] {u : R}\n (hu : IsUnit u) : IsUnit (-u) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $u$ is a unit in $R$ then so is $-u$.\n\\begin{proof}\n Solution: Since $u$ is a unit, we have $u v=v u=1$ for some $v \\in R$. Thus, we have\n$$\n(-v)(-u)=v u=1\n$$\nand\n$$\n(-u)(-v)=u v=1 .\n$$\nThus $-u$ is a unit.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_1_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_1_11 {R : Type*} [Ring R] [IsDomain R]\n {x : R} (hx : x^2 = 1) : x = 1 ∨ x = -1 := sorry", "formal_proof": null, "informal_stmt": "Prove that if $R$ is an integral domain and $x^{2}=1$ for some $x \\in R$ then $x=\\pm 1$.\n\\begin{proof}\n Solution: If $x^2=1$, then $x^2-1=0$. Evidently, then,\n$$\n(x-1)(x+1)=0 .\n$$\nSince $R$ is an integral domain, we must have $x-1=0$ or $x+1=0$; thus $x=1$ or $x=-1$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_1_12", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_1_12 {F : Type*} [Field F] {K : Subring F}\n (hK : (1 : F) ∈ K) : IsDomain K := sorry", "formal_proof": null, "informal_stmt": "Prove that any subring of a field which contains the identity is an integral domain.\n\\begin{proof}\n Solution: Let $R \\subseteq F$ be a subring of a field. (We need not yet assume that $1 \\in R$ ). Suppose $x, y \\in R$ with $x y=0$. Since $x, y \\in F$ and the zero element in $R$ is the same as that in $F$, either $x=0$ or $y=0$. Thus $R$ has no zero divisors. If $R$ also contains 1 , then $R$ is an integral domain.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_1_15", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Dummit_Foote_exercise_7_1_15 {R : Type*} [Ring R] (hR : ∀ a : R, a^2 = a) :\n CommRing R := sorry", "formal_proof": null, "informal_stmt": "A ring $R$ is called a Boolean ring if $a^{2}=a$ for all $a \\in R$. Prove that every Boolean ring is commutative.\n\\begin{proof}\n Solution: Note first that for all $a \\in R$,\n$$\n-a=(-a)^2=(-1)^2 a^2=a^2=a .\n$$\nNow if $a, b \\in R$, we have\n$$\na+b=(a+b)^2=a^2+a b+b a+b^2=a+a b+b a+b .\n$$\nThus $a b+b a=0$, and we have $a b=-b a$. But then $a b=b a$. Thus $R$ is commutative.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_2_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_2_2 {R : Type*} [Ring R] (p : Polynomial R) :\n p ∣ 0 ↔ ∃ b : R, b ≠ 0 ∧ b • p = 0 := sorry", "formal_proof": null, "informal_stmt": "Let $p(x)=a_{n} x^{n}+a_{n-1} x^{n-1}+\\cdots+a_{1} x+a_{0}$ be an element of the polynomial ring $R[x]$. Prove that $p(x)$ is a zero divisor in $R[x]$ if and only if there is a nonzero $b \\in R$ such that $b p(x)=0$.\n\\begin{proof}\n Solution: If $b p(x)=0$ for some nonzero $b \\in R$, then it is clear that $p(x)$ is a zero divisor.\nNow suppose $p(x)$ is a zero divisor; that is, for some $q(x)=\\sum_{i=0}^m b_i x^i$, we have $p(x) q(x)=0$. We may choose $q(x)$ to have minimal degree among the nonzero polynomials with this property.\nWe will now show by induction that $a_i q(x)=0$ for all $0 \\leq i \\leq n$.\nFor the base case, note that\n$$\np(x) q(x)=\\sum_{k=0}^{n+m}\\left(\\sum_{i+j=k} a_i b_j\\right) x^k=0 .\n$$\nThe coefficient of $x^{n+m}$ in this product is $a_n b_m$ on one hand, and 0 on the other. Thus $a_n b_m=0$. Now $a_n q(x) p(x)=0$, and the coefficient of $x^m$ in $q$ is $a_n b_m=0$. Thus the degree of $a_n q(x)$ is strictly less than that of $q(x)$; since $q(x)$ has minimal degree among the nonzero polynomials which multiply $p(x)$ to 0 , in fact $a_n q(x)=0$. More specifically, $a_n b_i=0$ for all $0 \\leq i \\leq m$.\nFor the inductive step, suppose that for some $0 \\leq tm$, a contradiction. Thus we have $a_t b_m=0$. As in the base case,\n$$\na_t q(x) p(x)=0\n$$\nand $a_t q(x)$ has degree strictly less than that of $q(x)$, so that by minimality, $a_t q(x)=0$.\nBy induction, $a_i q(x)=0$ for all $0 \\leq i \\leq n$. In particular, $a_i b_m=0$. Thus $b_m p(x)=0$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_2_12", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_2_12 {R G : Type*} [Ring R] [Group G] [Fintype G] :\n ∑ g : G, MonoidAlgebra.of R G g ∈ center (MonoidAlgebra R G) := sorry", "formal_proof": null, "informal_stmt": "Let $G=\\left\\{g_{1}, \\ldots, g_{n}\\right\\}$ be a finite group. Prove that the element $N=g_{1}+g_{2}+\\ldots+g_{n}$ is in the center of the group ring $R G$.\n\\begin{proof}\n Let $M=\\sum_{i=1}^n r_i g_i$ be an element of $R[G]$. Note that for each $g_i \\in G$, the action of $g_i$ on $G$ by conjugation permutes the subscripts. Then we have the following.\n$$\n\\begin{aligned}\nN M &=\\left(\\sum_{i=1}^n g_i\\right)\\left(\\sum_{j=1}^n r_j g_j\\right) \\\\\n&=\\sum_{j=1}^n \\sum_{i=1}^n r_j g_i g_j \\\\\n&=\\sum_{j=1}^n \\sum_{i=1}^n r_j g_j g_j^{-1} g_i g_j \\\\\n&=\\sum_{j=1}^n r_j g_j\\left(\\sum_{i=1}^n g_j^{-1} g_i g_j\\right) \\\\\n&=\\sum_{j=1}^n r_j g_j\\left(\\sum_{i=1}^n g_i\\right) \\\\\n&=\\left(\\sum_{j=1}^n r_j g_j\\right)\\left(\\sum_{i=1}^n g_i\\right) \\\\\n&=M N .\n\\end{aligned}\n$$\nThus $N \\in Z(R[G])$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_3_16", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_3_16 {R S : Type*} [Ring R] [Ring S]\n {φ : R →+* S} (hf : Function.Surjective φ) :\n φ '' (center R) ⊂ center S := sorry", "formal_proof": null, "informal_stmt": "Let $\\varphi: R \\rightarrow S$ be a surjective homomorphism of rings. Prove that the image of the center of $R$ is contained in the center of $S$.\n\\begin{proof}\n Suppose $r \\in \\varphi[Z(R)]$. Then $r=\\varphi(z)$ for some $z \\in Z(R)$. Now let $x \\in S$. Since $\\varphi$ is surjective, we have $x=\\varphi y$ for some $y \\in R$. Now\n$$\nx r=\\varphi(y) \\varphi(z)=\\varphi(y z)=\\varphi(z y)=\\varphi(z) \\varphi(y)=r x .\n$$\nThus $r \\in Z(S)$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_3_37", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_3_37 {p m : ℕ} (hp : p.Prime) :\n IsNilpotent (span ({↑p} : Set $ ZMod $ p^m) : Ideal $ ZMod $ p^m) := sorry", "formal_proof": null, "informal_stmt": "An ideal $N$ is called nilpotent if $N^{n}$ is the zero ideal for some $n \\geq 1$. Prove that the ideal $p \\mathbb{Z} / p^{m} \\mathbb{Z}$ is a nilpotent ideal in the ring $\\mathbb{Z} / p^{m} \\mathbb{Z}$.\n\\begin{proof}\n First we prove a lemma.\nLemma: Let $R$ be a ring, and let $I_1, I_2, J \\subseteq R$ be ideals such that $J \\subseteq I_1, I_2$. Then $\\left(I_1 / J\\right)\\left(I_2 / J\\right)=I_1 I_2 / J$.\nProof: ( $\\subseteq$ ) Let\n$$\n\\alpha=\\sum\\left(x_i+J\\right)\\left(y_i+J\\right) \\in\\left(I_1 / J\\right)\\left(I_2 / J\\right) .\n$$\nThen\n$$\n\\alpha=\\sum\\left(x_i y_i+J\\right)=\\left(\\sum x_i y_i\\right)+J \\in\\left(I_1 I_2\\right) / J .\n$$\nNow let $\\alpha=\\left(\\sum x_i y_i\\right)+J \\in\\left(I_1 I_2\\right) / J$. Then\n$$\n\\alpha=\\sum\\left(x_i+J\\right)\\left(y_i+J\\right) \\in\\left(I_1 / J\\right)\\left(I_2 / J\\right) .\n$$\nFrom this lemma and the lemma to Exercise 7.3.36, it follows by an easy induction that\n$$\n\\left(p \\mathbb{Z} / p^m \\mathbb{Z}\\right)^m=(p \\mathbb{Z})^m / p^m \\mathbb{Z}=p^m \\mathbb{Z} / p^m \\mathbb{Z} \\cong 0 .\n$$\nThus $p \\mathbb{Z} / p^m \\mathbb{Z}$ is nilpotent in $\\mathbb{Z} / p^m \\mathbb{Z}$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_7_4_27", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_7_4_27 {R : Type*} [CommRing R] (hR : (0 : R) ≠ 1)\n {a : R} (ha : IsNilpotent a) (b : R) :\n IsUnit (1-a*b) := sorry", "formal_proof": null, "informal_stmt": "Let $R$ be a commutative ring with $1 \\neq 0$. Prove that if $a$ is a nilpotent element of $R$ then $1-a b$ is a unit for all $b \\in R$.\n\\begin{proof}\n $\\mathfrak{N}(R)$ is an ideal of $R$. Thus for all $b \\in R,-a b$ is nilpotent. Hence $1-a b$ is a unit in $R$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_1_12", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_1_12 {N : ℕ} (hN : N > 0) {M M': ℤ} {d : ℕ}\n (hMN : M.gcd N = 1) (hMd : d.gcd N.totient = 1)\n (hM' : M' ≡ M^d [ZMOD N]) :\n ∃ d' : ℕ, d' * d ≡ 1 [ZMOD N.totient] ∧\n M ≡ M'^d' [ZMOD N] := sorry", "formal_proof": null, "informal_stmt": "Let $N$ be a positive integer. Let $M$ be an integer relatively prime to $N$ and let $d$ be an integer relatively prime to $\\varphi(N)$, where $\\varphi$ denotes Euler's $\\varphi$-function. Prove that if $M_{1} \\equiv M^{d} \\pmod N$ then $M \\equiv M_{1}^{d^{\\prime}} \\pmod N$ where $d^{\\prime}$ is the inverse of $d \\bmod \\varphi(N)$: $d d^{\\prime} \\equiv 1 \\pmod {\\varphi(N)}$.\n\\begin{proof}\n Note that there is some $k \\in \\mathbb{Z}$ such that $M^{d d^{\\prime}} \\equiv M^{k \\varphi(N)+1} \\equiv\\left(M^{\\varphi(N)}\\right)^k \\cdot M \\bmod N$. By Euler's Theorem we have $M^{\\varphi(N)} \\equiv 1 \\bmod N$, so that $M_1^{d^{\\prime}} \\equiv M \\bmod N$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_2_4", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_2_4 {R : Type*} [Ring R][NoZeroDivisors R]\n [CancelCommMonoidWithZero R] [GCDMonoid R]\n (h1 : ∀ a b : R, a ≠ 0 → b ≠ 0 → ∃ r s : R, gcd a b = r*a + s*b)\n (h2 : ∀ a : ℕ → R, (∀ i j : ℕ, i < j → a i ∣ a j) →\n ∃ N : ℕ, ∀ n ≥ N, ∃ u : R, IsUnit u ∧ a n = u * a N) :\n IsPrincipalIdealRing R := sorry", "formal_proof": null, "informal_stmt": "Let $R$ be an integral domain. Prove that if the following two conditions hold then $R$ is a Principal Ideal Domain: (i) any two nonzero elements $a$ and $b$ in $R$ have a greatest common divisor which can be written in the form $r a+s b$ for some $r, s \\in R$, and (ii) if $a_{1}, a_{2}, a_{3}, \\ldots$ are nonzero elements of $R$ such that $a_{i+1} \\mid a_{i}$ for all $i$, then there is a positive integer $N$ such that $a_{n}$ is a unit times $a_{N}$ for all $n \\geq N$.\n\\begin{proof}\n Let $I \\leq R$ be a nonzero ideal and let $I / \\sim$ be the set of equivalence classes of elements of $I$ with regards to the relation of being associates. We can equip $I / \\sim$ with a partial order with $[x] \\leq[y]$ if $y \\mid x$. Condition (ii) implies all chains in $I / \\sim$ have an upper bound, so By Zorn's lemma $I / \\sim$ contains a maximal element, i.e. $I$ contains a class of associated elements which are minimal with respect to divisibility.\n\nNow let $a, b \\in I$ be two elements such that $[a]$ and $[b]$ are minimal with respect to divisibility. By condition (i) $a$ and $b$ have a greatest common divisor $d$ which can be expressed as $d=$ $a x+b y$ for some $x, y \\in R$. In particular, $d \\in I$. Since $a$ and $b$ are minimal with respect to divisibility, we have that $[a]=[b]=[d]$. Therefore $I$ has at least one element $a$ that is minimal with regard to divisibility and all such elements are associate, and we have $I=\\langle a\\rangle$ and so $I$ is principal. We conclude $R$ is a principal ideal domain.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_3_4", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_3_4 {R : Type*} {n : ℤ} {r s : ℚ}\n (h : r^2 + s^2 = n) :\n ∃ a b : ℤ, a^2 + b^2 = n := sorry", "formal_proof": null, "informal_stmt": "Prove that if an integer is the sum of two rational squares, then it is the sum of two integer squares.\n\\begin{proof}\n Let $n=\\frac{a^2}{b^2}+\\frac{c^2}{d^2}$, or, equivalently, $n(b d)^2=a^2 d^2+c^2 b^2$. From this, we see that $n(b d)^2$ can be written as a sum of two squared integers. Therefore, if $q \\equiv 3(\\bmod 4)$ and $q^i$ appears in the prime power factorization of $n, i$ must be even. Let $j \\in \\mathbb{N} \\cup\\{0\\}$ such that $q^j$ divides $b d$. Then $q^{i-2 j}$ divides $n$. But since $i$ is even, $i-2 j$ is even as well. Consequently, $n$ can be written as a sum of two squared integers.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_3_5a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_3_5a {n : ℤ} (hn0 : n > 3) (hn1 : Squarefree n) :\n Irreducible (2 : Zsqrtd $ -n) ∧\n Irreducible (⟨0, 1⟩ : Zsqrtd $ -n) ∧\n Irreducible (1 + ⟨0, 1⟩ : Zsqrtd $ -n) := sorry", "formal_proof": null, "informal_stmt": "Let $R=\\mathbb{Z}[\\sqrt{-n}]$ where $n$ is a squarefree integer greater than 3. Prove that $2, \\sqrt{-n}$ and $1+\\sqrt{-n}$ are irreducibles in $R$.\n\\begin{proof}\n Suppose $a=a_1+a_2 \\sqrt{-n}, b=b_1+b_2 \\sqrt{-n} \\in R$ are such that $2=a b$, then $N(a) N(b)=4$. Without loss of generality we can assume $N(a) \\leq N(b)$, so $N(a)=1$ or $N(a)=2$. Suppose $N(a)=2$, then $a_1^2+n a_2^2=2$ and since $n>3$ we have $a_2=0$, which implies $a_1^2=2$, a contradiction. So $N(a)=1$ and $a$ is a unit. Therefore 2 is irreducible in $R$.\n\nSuppose now $\\sqrt{-n}=a b$, then $N(a) N(b)=n$ and we can assume $N(a)<$ $N(b)$ since $n$ is square free. Suppose $N(a)>1$, then $a_1^2+n a_2^2>1$ and $a_1^2+n a_2^2 \\mid n$, so $a_2=0$, and therefore $a_1^2 \\mid n$. Since $n$ is squarefree, $a_1=\\pm 1$, a contradiction. Therefore $N(a)=1$ and so $a$ is a unit and $\\sqrt{-n}$ is irreducible.\n\nSuppose $1+\\sqrt{-n}=a b$, then $N(a) N(b)=n+1$ and we can assume $N(a) \\leq N(b)$. Suppose $N(a)>1$, then $a_1^2+n a_2^2>1$ and $a_1^2+n a_2^2 \\mid n+1$. If $\\left|a_2\\right| \\geq 2$, then since $n>3$ we have a contradiction since $N(a)$ is too large. If $\\left|a_2\\right|=1$, then $a_1^2+n$ divides $1+n$ and so $a_1=\\pm 1$, and in either case $N(a)=n+1$ which contradicts $N(a) \\leq N(b)$. If $a_2=0$ then $a_1^2\\left(b_1^2+n b_2^2\\right)=\\left(a_1 b_1\\right)^2+n\\left(a_1 b_2\\right)^2=n+1$. If $\\left|a_1 b_2\\right| \\geq 2$ we have a contradiction. If $\\left|a_1 b_2\\right|=1$ then $a_1=\\pm 1$ which contradicts $N(a)>1$. If $\\left|a_1 b_2\\right|=0$, then $b_2=0$ and so $a_1 b_1=\\sqrt{-n}$, a contradiction. Therefore $N(a)=1$ and so $a$ is a unit and $1+\\sqrt{-n}$ is irreducible.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_3_6a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_3_6a {R : Type} [Ring R]\n (hR : R = (GaussianInt ⧸ span ({⟨0, 1⟩} : Set GaussianInt))) :\n IsField R ∧ ∃ finR : Fintype R, @card R finR = 2 := sorry", "formal_proof": null, "informal_stmt": "Prove that the quotient ring $\\mathbb{Z}[i] /(1+i)$ is a field of order 2.\n\\begin{proof}\n Let $a+b i \\in \\mathbb{Z}[i]$. If $a \\equiv b \\bmod 2$, then $a+b$ and $b-a$ are even and $(1+i)\\left(\\frac{a+b}{2}+\\frac{b-a}{2} i\\right)=a+b i \\in\\langle 1+i\\rangle$. If $a \\not \\equiv b \\bmod 2$ then $a-1+b i \\in\\langle 1+i\\rangle$. Therefore every element of $\\mathbb{Z}[i]$ is in either $\\langle 1+i\\rangle$ or $1+\\langle 1+i\\rangle$, so $\\mathbb{Z}[i] /\\langle 1+i\\rangle$ is a finite ring of order 2 , which must be a field.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_8_3_6b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_8_3_6b {q : ℕ} (hq0 : q.Prime)\n (hq1 : q ≡ 3 [ZMOD 4]) {R : Type} [Ring R]\n (hR : R = (GaussianInt ⧸ span ({↑q} : Set GaussianInt))) :\n IsField R ∧ ∃ finR : Fintype R, @card R finR = q^2 := sorry", "formal_proof": null, "informal_stmt": "Let $q \\in \\mathbb{Z}$ be a prime with $q \\equiv 3 \\bmod 4$. Prove that the quotient ring $\\mathbb{Z}[i] /(q)$ is a field with $q^{2}$ elements.\n\\begin{proof}\n The division algorithm gives us that every element of $\\mathbb{Z}[i] /\\langle q\\rangle$ is represented by an element $a+b i$ such that $0 \\leq a, b MvPolynomial.X i * MvPolynomial.X (i+1)):\n Infinite (minimalPrimes (MvPolynomial ℕ ℤ ⧸ span (range f))) := sorry", "formal_proof": null, "informal_stmt": "Prove that the ring $\\mathbb{Z}\\left[x_{1}, x_{2}, x_{3}, \\ldots\\right] /\\left(x_{1} x_{2}, x_{3} x_{4}, x_{5} x_{6}, \\ldots\\right)$ contains infinitely many minimal prime ideals.\n\\begin{proof}\n Let $R=\\mathbb{Z}\\left[x_1, x_2, \\ldots, x_n\\right]$ and consider the ideal $K=\\left(x_{2 k+1} x_{2 k+2} \\mid k \\in \\mathbb{Z}_{+}\\right)$in $R$.\nConsider the family of subsets $X=\\left\\{\\left\\{x_{2 k+1}, x_{2 k+2}\\right\\} \\mid k \\in \\mathbb{Z}_{+}\\right\\}$, and $Y$ the set of choice function on $X$, ie the set of functions $\\lambda: \\mathbb{Z}_{+} \\rightarrow \\cup_{\\mathbb{Z}_{+}}\\left\\{x_{2 k+1}, x_{2 k+2}\\right\\}$ with $\\lambda(a) \\in$ $\\left\\{x_{2 a+1}, x_{2 a+2}\\right\\}$\nFor each $\\lambda \\in Y$ we have the ideal $I_\\lambda=(\\lambda(0), \\lambda(1), \\ldots)$.\nAll these ideals are distinct, ie for $\\lambda \\neq \\lambda^{\\prime}$ we have $I_\\lambda \\neq I_{\\lambda^{\\prime}}$.\nWe also have that by construction $K \\subset I_\\lambda$ for all $\\lambda \\in Y$.\nBy the Third Isomorphism Theorem\n$$\n(R / K) /\\left(I_\\lambda / K\\right) \\cong R / I_\\lambda\n$$\nNote also that $R / I_\\lambda$ is isomorphic to the polynomial ring over $R$ with indeterminates the $x_i$ not in the image of $\\lambda$, and since there is a countably infinite number of them we can conclude $R / I_\\lambda \\cong R$, an integral domain. Therefore $I_\\lambda / K$ is a prime ideal of $R / K$\n\nWe prove now that $I_\\lambda / K$ is a minimal prime ideal. Let $J / K \\subseteq I_\\lambda / K$ be a prime ideal. For each pair $\\left(x_{2 k+1}, x_{2 k+2}\\right)$ we have that $x_{2 k+1} x_{2 k+2} \\in K$ so $x_{2 k+1} x_{2 k+2} \\bmod K \\in J / K$ so $J$ must contain one of the elements in $\\left\\{x_{2 k+1}, x_{2 k+2}\\right\\}$. But since $J / K \\subseteq I_\\lambda / K$ it must be $\\lambda(k)$ for all $k \\in \\mathbb{Z}_{+}$. Therefore $J / K=I_\\lambda / K$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_9_3_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_3_2 {f g : Polynomial ℚ} (i j : ℕ)\n (hfg : ∀ n : ℕ, ∃ a : ℤ, (f*g).coeff = a) :\n ∃ a : ℤ, f.coeff i * g.coeff j = a := sorry", "formal_proof": null, "informal_stmt": "Prove that if $f(x)$ and $g(x)$ are polynomials with rational coefficients whose product $f(x) g(x)$ has integer coefficients, then the product of any coefficient of $g(x)$ with any coefficient of $f(x)$ is an integer.\n\\begin{proof}\n Let $f(x), g(x) \\in \\mathbb{Q}[x]$ be such that $f(x) g(x) \\in \\mathbb{Z}[x]$.\nBy Gauss' Lemma there exists $r, s \\in \\mathbb{Q}$ such that $r f(x), s g(x) \\in \\mathbb{Z}[x]$, and $(r f(x))(s g(x))=r s f(x) g(x)=f(x) g(x)$. From this last relation we can conclude that $s=r^{-1}$.\n\nTherefore for any coefficient $f_i$ of $f(x)$ and $g_j$ of $g(x)$ we have that $r f_i, r^{-1} g_j \\in$ $\\mathbb{Z}$ and by multiplicative closure and commutativity of $\\mathbb{Z}$ we have that $r f_i r^{-1} g_j=$ $f_i g_j \\in \\mathbb{Z}$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_9_4_2a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_2a : Irreducible (X^4 - 4*X^3 + 6 : Polynomial ℤ) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^4-4x^3+6$ is irreducible in $\\mathbb{Z}[x]$.\n\\begin{proof}\n$$\nx^4-4 x^3+6\n$$\nThe polynomial is irreducible by Eisenstein's Criterion since the prime $2$ doesn't divide the leading coefficient 2 divide coefficients of the low order term $-4,0,0$ but 6 is not divided by the square of 2.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_9_4_2b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_2b : Irreducible\n (X^6 + 30*X^5 - 15*X^3 + 6*X - 120 : Polynomial ℤ) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^6+30x^5-15x^3 + 6x-120$ is irreducible in $\\mathbb{Z}[x]$.\n\\begin{proof}\n $$\nx^6+30 x^5-15 x^3+6 x-120\n$$\nThe coefficients of the low order.: $30,-15,0,6,-120$\nThey are divisible by the prime 3 , but $3^2=9$ doesn't divide $-120$. So this polynomial is irreducible over $\\mathbb{Z}$. \n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_9_4_2c", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_2c : Irreducible\n (X^4 + 4*X^3 + 6*X^2 + 2*X + 1 : Polynomial ℤ) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^4+4x^3+6x^2+2x+1$ is irreducible in $\\mathbb{Z}[x]$.\n\\begin{proof}\n$$\np(x)=x^4+6 x^3+4 x^2+2 x+1\n$$\nWe calculate $p(x-1)$\n$$\n\\begin{aligned}\n(x-1)^4 & =x^4-4 x^3+6 x^2-4 x+1 \\\\\n6(x-1)^3 & =6 x^3-18 x^2+18 x-6 \\\\\n4(x-1)^2 & =4 x^2-8 x+4 \\\\\n2(x-1) & =2 x-2 \\\\\n1 & =1\n\\end{aligned}\n$$\n$$\n\\begin{aligned}\n& p(x-1)=(x-1)^4+6(x-1)^3+4(x-1)^2+2(x-1)+1=x^4+2 x^3-8 x^2+ \\\\\n& 8 x-2 \\\\\n& q(x)=x^4+2 x^3-8 x^2+8 x-2\n\\end{aligned}\n$$\n$q(x)$ is irreducible by Eisenstein's Criterion since the prime $\\$ 2 \\$$ divides the lower coefficient but $\\$ 2^{\\wedge} 2 \\$$ doesnt divide constant $-2$. Any factorization of $p(x)$ would provide a factor of $p(x)(x-1)$\nSince:\n$$\n\\begin{aligned}\n& p(x)=a(x) b(x) \\\\\n& q(x)=p(x)(x-1)=a(x-1) b(x-1)\n\\end{aligned}\n$$\nWe get a contradiction with the irreducibility of $p(x-1)$, so $p(x)$ is irreducible in $Z[x]$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_9_4_2d", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_2d {p : ℕ} (hp : p.Prime ∧ p > 2)\n {f : Polynomial ℤ} (hf : f = (X + 2)^p):\n Irreducible (∑ n ∈ (f.support \\ {0}), (f.coeff n : Polynomial ℤ) * X ^ (n-1) :\n Polynomial ℤ) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\frac{(x+2)^p-2^p}{x}$, where $p$ is an odd prime, is irreducible in $\\mathbb{Z}[x]$.\n\\begin{proof}\n$\\frac{(x+2)^p-2^p}{x} \\quad \\quad p$ is on add pprime $Z[x]$\n$$\n\\frac{(x+2)^p-2^p}{x} \\quad \\text { as a polynomial we expand }(x+2)^p\n$$\n$2^p$ cancels with $-2^p$, every remaining term has $x$ as $a$ factor\n$$\n\\begin{aligned}\n& x^{p-1}+2\\left(\\begin{array}{l}\np \\\\\n1\n\\end{array}\\right) x^{p-2}+2^2\\left(\\begin{array}{l}\np \\\\\n2\n\\end{array}\\right) x^{p-3}+\\ldots+2^{p-1}\\left(\\begin{array}{c}\np \\\\\np-1\n\\end{array}\\right) \\\\\n& 2^k\\left(\\begin{array}{l}\np \\\\\nk\n\\end{array}\\right) x^{p-k-1}=2^k \\cdot p \\cdot(p-1) \\ldots(p-k-1), \\quad 0 Irrational ( x + y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $r+x$ is irrational.\n\\begin{proof}\n If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_1b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_1b\n(x : ℝ)\n(y : ℚ)\n(h : y ≠ 0)\n: ( Irrational x ) -> Irrational ( x * y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $rx$ is irrational.\n\\begin{proof}\n If $r x$ were rational, then $x=\\frac{r x}{r}$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_2 : ¬ ∃ (x : ℚ), ( x ^ 2 = 12 ) := sorry", "formal_proof": null, "informal_stmt": "Prove that there is no rational number whose square is $12$.\n\\begin{proof}\n Suppose $m^2=12 n^2$, where $m$ and $n$ have no common factor. It follows that $m$ must be even, and therefore $n$ must be odd. Let $m=2 r$. Then we have $r^2=3 n^2$, so that $r$ is also odd. Let $r=2 s+1$ and $n=2 t+1$. Then\n$$\n4 s^2+4 s+1=3\\left(4 t^2+4 t+1\\right)=12 t^2+12 t+3,\n$$\nso that\n$$\n4\\left(s^2+s-3 t^2-3 t\\right)=2 .\n$$\nBut this is absurd, since 2 cannot be a multiple of 4 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_4\n(α : Type*) [PartialOrder α]\n(s : Set α)\n(x y : α)\n(h₀ : Set.Nonempty s)\n(h₁ : x ∈ lowerBounds s)\n(h₂ : y ∈ upperBounds s)\n: x ≤ y := sorry", "formal_proof": null, "informal_stmt": "Let $E$ be a nonempty subset of an ordered set; suppose $\\alpha$ is a lower bound of $E$ and $\\beta$ is an upper bound of $E$. Prove that $\\alpha \\leq \\beta$.\n\\begin{proof}\nSince $E$ is nonempty, there exists $x \\in E$. Then by definition of lower and upper bounds we have $\\alpha \\leq x \\leq \\beta$, and hence by property $i i$ in the definition of an ordering, we have $\\alpha<\\beta$ unless $\\alpha=x=\\beta$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_5 (A minus_A : Set ℝ) (hA : A.Nonempty)\n (hA_bdd_below : BddBelow A) (hminus_A : minus_A = {x | -x ∈ A}) :\n Min A = Max minus_A := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be a nonempty set of real numbers which is bounded below. Let $-A$ be the set of all numbers $-x$, where $x \\in A$. Prove that $\\inf A=-\\sup (-A)$.\n\\begin{proof}\n We need to prove that $-\\sup (-A)$ is the greatest lower bound of $A$. For brevity, let $\\alpha=-\\sup (-A)$. We need to show that $\\alpha \\leq x$ for all $x \\in A$ and $\\alpha \\geq \\beta$ if $\\beta$ is any lower bound of $A$.\n\nSuppose $x \\in A$. Then, $-x \\in-A$, and, hence $-x \\leq \\sup (-A)$. It follows that $x \\geq-\\sup (-A)$, i.e., $\\alpha \\leq x$. Thus $\\alpha$ is a lower bound of $A$.\n\nNow let $\\beta$ be any lower bound of $A$. This means $\\beta \\leq x$ for all $x$ in $A$. Hence $-x \\leq-\\beta$ for all $x \\in A$, which says $y \\leq-\\beta$ for all $y \\in-A$. This means $-\\beta$ is an upper bound of $-A$. Hence $-\\beta \\geq \\sup (-A)$ by definition of sup, i.e., $\\beta \\leq-\\sup (-A)$, and so $-\\sup (-A)$ is the greatest lower bound of $A$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_8", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_8 : ¬ ∃ (r : ℂ → ℂ → Prop), IsLinearOrder ℂ r := sorry", "formal_proof": null, "informal_stmt": "Prove that no order can be defined in the complex field that turns it into an ordered field.\n\\begin{proof}\n By Part (a) of Proposition $1.18$, either $i$ or $-i$ must be positive. Hence $-1=i^2=(-i)^2$ must be positive. But then $1=(-1)^2$, must also be positive, and this contradicts Part $(a)$ of Proposition 1.18, since 1 and $-1$ cannot both be positive.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_11a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_11a (z : ℂ) :\n ∃ (r : ℝ) (w : ℂ), norm w = 1 ∧ z = r * w := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number, prove that there exists an $r\\geq 0$ and a complex number $w$ with $| w | = 1$ such that $z = rw$.\n\\begin{proof}\n If $z=0$, we take $r=0, w=1$. (In this case $w$ is not unique.) Otherwise we take $r=|z|$ and $w=z /|z|$, and these choices are unique, since if $z=r w$, we must have $r=r|w|=|r w|=|z|, z / r$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_12 (n : ℕ) (f : ℕ → ℂ) :\n norm (∑ i ∈ range n, f i) ≤ ∑ i ∈ range n, norm (f i) := sorry", "formal_proof": null, "informal_stmt": "If $z_1, \\ldots, z_n$ are complex, prove that $|z_1 + z_2 + \\ldots + z_n| \\leq |z_1| + |z_2| + \\cdots + |z_n|$.\n\\begin{proof}\n We can apply the case $n=2$ and induction on $n$ to get\n$$\n\\begin{aligned}\n\\left|z_1+z_2+\\cdots z_n\\right| &=\\left|\\left(z_1+z_2+\\cdots+z_{n-1}\\right)+z_n\\right| \\\\\n& \\leq\\left|z_1+z_2+\\cdots+z_{n-1}\\right|+\\left|z_n\\right| \\\\\n& \\leq\\left|z_1\\right|+\\left|z_2\\right|+\\cdots+\\left|z_{n-1}\\right|+\\left|z_n\\right|\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_13 (x y : ℂ) :\n |(norm x) - (norm y)| ≤ norm (x - y) := sorry", "formal_proof": null, "informal_stmt": "If $x, y$ are complex, prove that $||x|-|y|| \\leq |x-y|$.\n\\begin{proof}\n Since $x=x-y+y$, the triangle inequality gives\n$$\n|x| \\leq|x-y|+|y|\n$$\nso that $|x|-|y| \\leq|x-y|$. Similarly $|y|-|x| \\leq|x-y|$. Since $|x|-|y|$ is a real number we have either ||$x|-| y||=|x|-|y|$ or ||$x|-| y||=|y|-|x|$. In either case, we have shown that ||$x|-| y|| \\leq|x-y|$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_14", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_14\n (z : ℂ) (h : norm z = 1)\n : (norm (1 + z)) ^ 2 + (norm (1 - z)) ^ 2 = 4 := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number such that $|z|=1$, that is, such that $z \\bar{z}=1$, compute $|1+z|^{2}+|1-z|^{2}$.\n\\begin{proof}\n $|1+z|^2=(1+z)(1+\\bar{z})=1+\\bar{z}+z+z \\bar{z}=2+z+\\bar{z}$. Similarly $|1-z|^2=(1-z)(1-\\bar{z})=1-z-\\bar{z}+z \\bar{z}=2-z-\\bar{z}$. Hence\n$$\n|1+z|^2+|1-z|^2=4 \\text {. }\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_16a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_16a\n (n : ℕ)\n (d r : ℝ)\n (x y z : EuclideanSpace ℝ (Fin n)) -- R^n\n (h₁ : n ≥ 3)\n (h₂ : ‖x - y‖ = d)\n (h₃ : d > 0)\n (h₄ : r > 0)\n (h₅ : 2 * r > d)\n : Set.Infinite {z : EuclideanSpace ℝ (Fin n) | ‖z - x‖ = r ∧ ‖z - y‖ = r} := sorry", "formal_proof": null, "informal_stmt": "Suppose $k \\geq 3, x, y \\in \\mathbb{R}^k, |x - y| = d > 0$, and $r > 0$. Prove that if $2r > d$, there are infinitely many $z \\in \\mathbb{R}^k$ such that $|z-x|=|z-y|=r$.\n\\begin{proof}\n (a) Let w be any vector satisfying the following two equations:\n$$\n\\begin{aligned}\n\\mathbf{w} \\cdot(\\mathbf{x}-\\mathbf{y}) &=0, \\\\\n|\\mathbf{w}|^2 &=r^2-\\frac{d^2}{4} .\n\\end{aligned}\n$$\nFrom linear algebra it is known that all but one of the components of a solution $\\mathbf{w}$ of the first equation can be arbitrary. The remaining component is then uniquely determined. Also, if $w$ is any non-zero solution of the first equation, there is a unique positive number $t$ such that $t$ w satisfies both equations. (For example, if $x_1 \\neq y_1$, the first equation is satisfied whenever\n$$\nz_1=\\frac{z_2\\left(x_2-y_2\\right)+\\cdots+z_k\\left(x_k-y_k\\right)}{y_1-x_1} .\n$$\nIf $\\left(z_1, z_2, \\ldots, z_k\\right)$ satisfies this equation, so does $\\left(t z_1, t z_2, \\ldots, t z_k\\right)$ for any real number $t$.) Since at least two of these components can vary independently, we can find a solution with these components having any prescribed ratio. This ratio does not change when we multiply by the positive number $t$ to obtain a solution of both equations. Since there are infinitely many ratios, there are infinitely many distinct solutions. For each such solution $\\mathbf{w}$ the vector $\\mathbf{z}=$ $\\frac{1}{2} \\mathrm{x}+\\frac{1}{2} \\mathrm{y}+\\mathrm{w}$ is a solution of the required equation. For\n$$\n\\begin{aligned}\n|\\mathrm{z}-\\mathbf{x}|^2 &=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}+\\mathbf{w}\\right|^2 \\\\\n&=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}\\right|^2+2 \\mathbf{w} \\cdot \\frac{\\mathbf{x}-\\mathbf{y}}{2}+|\\mathbf{w}|^2 \\\\\n&=\\frac{d^2}{4}+0+r^2-\\frac{d^2}{4} \\\\\n&=r^2\n\\end{aligned}\n$$\nand a similar relation holds for $|z-y|^2$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_17\n (n : ℕ)\n (x y : EuclideanSpace ℝ (Fin n)) -- R^n\n : ‖x + y‖^2 + ‖x - y‖^2 = 2*‖x‖^2 + 2*‖y‖^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that $|\\mathbf{x}+\\mathbf{y}|^{2}+|\\mathbf{x}-\\mathbf{y}|^{2}=2|\\mathbf{x}|^{2}+2|\\mathbf{y}|^{2}$ if $\\mathbf{x} \\in R^{k}$ and $\\mathbf{y} \\in R^{k}$.\n\\begin{proof}\n The proof is a routine computation, using the relation\n$$\n|x \\pm y|^2=(x \\pm y) \\cdot(x \\pm y)=|x|^2 \\pm 2 x \\cdot y+|y|^2 .\n$$\nIf $\\mathrm{x}$ and $\\mathrm{y}$ are the sides of a parallelogram, then $\\mathrm{x}+\\mathrm{y}$ and $\\mathbf{x}-\\mathrm{y}$ are its diagonals. Hence this result says that the sum of the squares on the diagonals of a parallelogram equals the sum of the squares on the sides.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_18a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18a\n (n : ℕ)\n (h : n > 1)\n (x : EuclideanSpace ℝ (Fin n)) -- R^n\n : ∃ (y : EuclideanSpace ℝ (Fin n)), y ≠ 0 ∧ (inner ℝ x y) = (0 : ℝ) := sorry", "formal_proof": null, "informal_stmt": "If $k \\geq 2$ and $\\mathbf{x} \\in R^{k}$, prove that there exists $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n If $\\mathbf{x}$ has any components equal to 0 , then $\\mathbf{y}$ can be taken to have the corresponding components equal to 1 and all others equal to 0 . If all the components of $\\mathbf{x}$ are nonzero, $\\mathbf{y}$ can be taken as $\\left(-x_2, x_1, 0, \\ldots, 0\\right)$. This is, of course, not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_18b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18b\n : ¬ ∀ (x : ℝ), ∃ (y : ℝ), y ≠ 0 ∧ x * y = 0 := sorry", "formal_proof": null, "informal_stmt": "If $k = 1$ and $\\mathbf{x} \\in R^{k}$, prove that there does not exist $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n Not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_19", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_19\n (n : ℕ)\n (a b c x : EuclideanSpace ℝ (Fin n))\n (r : ℝ)\n (h₁ : r > 0)\n (h₂ : 3 • c = 4 • b - a)\n (h₃ : 3 * r = 2 * ‖x - b‖)\n : ‖x - a‖ = 2 * ‖x - b‖ ↔ ‖x - c‖ = r := sorry", "formal_proof": null, "informal_stmt": "Suppose $a, b \\in R^k$. Find $c \\in R^k$ and $r > 0$ such that $|x-a|=2|x-b|$ if and only if $| x - c | = r$. Prove that $3c = 4b - a$ and $3r = 2 |b - a|$.\n\\begin{proof}\n Since the solution is given to us, all we have to do is verify it, i.e., we need to show that the equation\n$$\n|\\mathrm{x}-\\mathrm{a}|=2|\\mathrm{x}-\\mathrm{b}|\n$$\nis equivalent to $|\\mathrm{x}-\\mathbf{c}|=r$, which says\n$$\n\\left|\\mathbf{x}-\\frac{4}{3} \\mathbf{b}+\\frac{1}{3} \\mathbf{a}\\right|=\\frac{2}{3}|\\mathbf{b}-\\mathbf{a}| .\n$$\nIf we square both sides of both equations, we an equivalent pair of equations, the first of which reduces to\n$$\n3|\\mathbf{x}|^2+2 \\mathbf{a} \\cdot \\mathbf{x}-8 \\mathbf{b} \\cdot \\mathbf{x}-|\\mathbf{a}|^2+4|\\mathbf{b}|^2=0,\n$$\nand the second of which reduces to this equation divided by 3 . Hence these equations are indeed equivalent.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_19a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_19a {X : Type*} [MetricSpace X]\n (A B : Set X) (hA : IsClosed A) (hB : IsClosed B) (hAB : Disjoint A B) :\n SeparatedNhds A B := sorry", "formal_proof": null, "informal_stmt": "If $A$ and $B$ are disjoint closed sets in some metric space $X$, prove that they are separated.\n\\begin{proof}\n We are given that $A \\cap B=\\varnothing$. Since $A$ and $B$ are closed, this means $A \\cap \\bar{B}=\\varnothing=\\bar{A} \\cap B$, which says that $A$ and $B$ are separated.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_24 {X : Type*} [MetricSpace X]\n (hX : ∀ (A : Set X), Infinite A → ∃ (x : X), x ∈ closure A) :\n SeparableSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a metric space in which every infinite subset has a limit point. Prove that $X$ is separable.\n\\begin{proof}\n We observe that if the process of constructing $x_j$ did not terminate, the result would be an infinite set of points $x_j, j=1,2, \\ldots$, such that $d\\left(x_i, x_j\\right) \\geq \\delta$ for $i \\neq j$. It would then follow that for any $x \\in X$, the open ball $B_{\\frac{\\delta}{2}}(x)$ contains at most one point of the infinite set, hence that no point could be a limit point of this set, contrary to hypothesis. Hence $X$ is totally bounded, i.e., for each $\\delta>0$ there is a finite set $x_1, \\ldots, x_{N\\delta}$such that $X=\\bigcup_{j / 1}^{N\\delta} B_\\delta\\left(x_j\\right)$\n\nLet $x_{n_1}, \\ldots, x_{n N_n}$ be such that $X=\\bigcup_{j / 1}^{N_n} B_{\\frac{1}{n}}\\left(x_{n j}\\right), n=1,2, \\ldots$ We claim that $\\left\\{x_{n j}: 1 \\leq j \\leq N_n ; n=1,2, \\ldots\\right\\}$ is a countable dense subset of $X$. Indeed\n25\nif $x \\in X$ and $\\delta>0$, then $x \\in B_{\\frac{1}{n}}\\left(x_{n j}\\right)$ for some $x_{n j}$ for some $n>\\frac{1}{\\delta}$, and hence $d\\left(x, x_{n j}\\right)<\\delta$. By definition, this means that $\\left\\{x_{n j}\\right\\}$ is dense in $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_25", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_25 {K : Type*} [MetricSpace K] [CompactSpace K] :\n ∃ (B : Set (Set K)), Set.Countable B ∧ IsTopologicalBasis B := sorry", "formal_proof": null, "informal_stmt": "Prove that every compact metric space $K$ has a countable base.\n\\begin{proof}\n $K$ can be covered by a finite union of neighborhoods of radius $1 / n$, and this shows that this implies that $K$ is separable.\n\nIt is not entirely obvious that a metric space with a countable base is separable. To prove this, let $\\left\\{V_n\\right\\}_{n=1}^{\\infty}$ be a countable base, and let $x_n \\in V_n$. The points $V_n$ must be dense in $X$. For if $G$ is any non-empty open set, then $G$ contains $V_n$ for some $n$, and hence $x_n \\in G$. (Thus for a metric space, having a countable base and being separable are equivalent.)\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_27a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27a (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, ¬ Set.Countable (P ∩ E)}) :\n IsClosed P ∧ P = {x | ClusterPt x (𝓟 P)} := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that $P$ is perfect.\n\\begin{proof}\n We see that $E \\cap W$ is at most countable, being a countable union of at-most-countable sets. It remains to show that $P=W^c$, and that $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_27b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27b (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, (P ∩ E).Nonempty ∧ ¬ Set.Countable (P ∩ E)}) :\n Set.Countable (E \\ P) := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that at most countably many points of $E$ are not in $P$.\n\\begin{proof}\n If $x \\in W^c$, and $O$ is any neighborhood of $x$, then $x \\in V_n \\subseteq O$ for some n. Since $x \\notin W, V_n \\cap E$ is uncountable. Hence $O$ contains uncountably many points of $E$, and so $x$ is a condensation point of $E$. Thus $x \\in P$, i.e., $W^c \\subseteq P$.\nConversely if $x \\in W$, then $x \\in V_n$ for some $V_n$ such that $V_n \\cap E$ is countable. Hence $x$ has a neighborhood (any neighborhood contained in $V_n$ ) containing at most a countable set of points of $E$, and so $x \\notin P$, i.e., $W \\subseteq P^c$. Hence $P=W^c$.\nIt is clear that $P$ is closed (since its complement $W$ is open), so that we need only show that $P \\subseteq P^{\\prime}$. Hence suppose $x \\in P$, and $O$ is any neighborhood of $x$. (By definition of $P$ this means $O \\cap E$ is uncountable.) We need to show that there is a point $y \\in P \\cap(O \\backslash\\{x\\})$. If this is not the case, i.e., if every point $y$ in $O \\backslash\\{x\\}$ is in $P^c$, then for each such point $y$ there is a set $V_n$ containing $y$ such that $V_n \\cap E$ is at most countable. That would mean that $y \\in W$, i.e., that $O \\backslash\\{x\\}$ is contained in $W$. It would follow that $O \\cap E \\subseteq\\{x\\} \\cup(W \\cap E)$, and so $O \\cap E$ contains at most a countable set of points, contrary to the hypothesis that $x \\in P$. Hence $O$ contains a point of $P$ different from $x$, and so $P \\subseteq P^{\\prime}$. Thus $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_28", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_28 (X : Type*) [MetricSpace X] [SeparableSpace X]\n (A : Set X) (hA : IsClosed A) :\n ∃ P₁ P₂ : Set X, A = P₁ ∪ P₂ ∧\n IsClosed P₁ ∧ P₁ = {x | ClusterPt x (𝓟 P₁)} ∧\n Set.Countable P₂ := sorry", "formal_proof": null, "informal_stmt": "Prove that every closed set in a separable metric space is the union of a (possibly empty) perfect set and a set which is at most countable.\n\\begin{proof}\n If $E$ is closed, it contains all its limit points, and hence certainly all its condensation points. Thus $E=P \\cup(E \\backslash P)$, where $P$ is perfect (the set of all condensation points of $E$ ), and $E \\backslash P$ is at most countable.\n\nSince a perfect set in a separable metric space has the same cardinality as the real numbers, the set $P$ must be empty if $E$ is countable. The at-most countable set $E \\backslash P$ cannot be perfect, hence must have isolated points if it is nonempty.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_29", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_29 (U : Set ℝ) (hU : IsOpen U) :\n ∃ (f : ℕ → Set ℝ), (∀ n, ∃ a b : ℝ, f n = {x | a < x ∧ x < b}) ∧ (∀ n, f n ⊆ U) ∧\n (∀ n m, n ≠ m → f n ∩ f m = ∅) ∧\n U = ⋃ n, f n := sorry", "formal_proof": null, "informal_stmt": "Prove that every open set in $\\mathbb{R}$ is the union of an at most countable collection of disjoint segments.\n\\begin{proof}\n Let $O$ be open. For each pair of points $x \\in O, y \\in O$, we define an equivalence relation $x \\sim y$ by saying $x \\sim y$ if and only if $[\\min (x, y), \\max (x, y)] \\subset$ 0 . This is an equivalence relation, since $x \\sim x([x, x] \\subset O$ if $x \\in O)$; if $x \\sim y$, then $y \\sim x$ (since $\\min (x, y)=\\min (y, x)$ and $\\max (x, y)=\\max (y, x))$; and if $x \\sim y$ and $y \\sim z$, then $x \\sim z([\\min (x, z), \\max (x, z)] \\subseteq[\\min (x, y), \\max (x, y)] \\cup$ $[\\min (y, z), \\max (y, z)] \\subseteq O)$. In fact it is easy to prove that\n$$\n\\min (x, z) \\geq \\min (\\min (x, y), \\min (y, z))\n$$\nand\n$$\n\\max (x, z) \\leq \\max (\\max (x, y), \\max (y, z))\n$$\nIt follows that $O$ can be written as a disjoint union of pairwise disjoint equivalence classes. We claim that each equivalence class is an open interval.\n\nTo show this, for each $x \\in O$; let $A=\\{z:[z, x] \\subseteq O\\}$ and $B=\\{z:[x, z] \\subseteq$ $O\\}$, and let $a=\\inf A, b=\\sup B$. We claim that $(a, b) \\subset O$. Indeed if $az$. Then $z \\in[c, x] \\cup[x, d] \\subseteq O$. We now claim that $(a, b)$ is the equivalence class containing $x$. It is clear that each element of $(a, b)$ is equivalent to $x$ by the way in which $a$ and $b$ were chosen. We need to show that if $z \\notin(a, b)$, then $z$ is not equivalent to $x$. Suppose that $zb$ and $z \\sim x$, then $b$ could not be an upper bound for $B$.\n\nWe have now established that $O$ is a union of pairwise disjoint open intervals. Such a union must be at most countable, since each open interval contains a rational number not in any other interval.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_1a\n (f : ℕ → ℝ)\n (h : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => f n) atTop (𝓝 a))\n : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => |f n|) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Prove that convergence of $\\left\\{s_{n}\\right\\}$ implies convergence of $\\left\\{\\left|s_{n}\\right|\\right\\}$.\n\\begin{proof}\n Let $\\varepsilon>0$. Since the sequence $\\left\\{s_n\\right\\}$ is a Cauchy sequence, there exists $N$ such that $\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. We then have $\\left| |s_m| - |s_n| \\right| \\leq\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. Hence the sequence $\\left\\{\\left|s_n\\right|\\right\\}$ is also a Cauchy sequence, and therefore must converge.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_2a\n : Tendsto (λ (n : ℝ) => (sqrt (n^2 + n) - n)) atTop (𝓝 (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty}\\sqrt{n^2 + n} -n = 1/2$.\n\\begin{proof}\n Multiplying and dividing by $\\sqrt{n^2+n}+n$ yields\n$$\n\\sqrt{n^2+n}-n=\\frac{n}{\\sqrt{n^2+n}+n}=\\frac{1}{\\sqrt{1+\\frac{1}{n}}+1} .\n$$\nIt follows that the limit is $\\frac{1}{2}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_3\n : ∃ (x : ℝ), Tendsto f atTop (𝓝 x) ∧ ∀ n, f n < 2 := sorry", "formal_proof": null, "informal_stmt": "If $s_{1}=\\sqrt{2}$, and $s_{n+1}=\\sqrt{2+\\sqrt{s_{n}}} \\quad(n=1,2,3, \\ldots),$ prove that $\\left\\{s_{n}\\right\\}$ converges, and that $s_{n}<2$ for $n=1,2,3, \\ldots$.\n\\begin{proof}\n Since $\\sqrt{2}<2$, it is manifest that if $s_n<2$, then $s_{n+1}<\\sqrt{2+2}=2$. Hence it follows by induction that $\\sqrt{2}1$, i.e., $s_n>s_n^2-2=s_{n-1}$. Hence the sequence is an increasing sequence that is bounded above (by 2 ) and so converges. Since the limit $s$ satisfies $s^2-s-2=0$, it follows that the limit is 2.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_5\n (a b : ℕ → ℝ)\n (h : limsup a + limsup b ≠ 0) :\n limsup (λ n => a n + b n) ≤ limsup a + limsup b := sorry", "formal_proof": null, "informal_stmt": "For any two real sequences $\\left\\{a_{n}\\right\\},\\left\\{b_{n}\\right\\}$, prove that $\\limsup _{n \\rightarrow \\infty}\\left(a_{n}+b_{n}\\right) \\leq \\limsup _{n \\rightarrow \\infty} a_{n}+\\limsup _{n \\rightarrow \\infty} b_{n},$ provided the sum on the right is not of the form $\\infty-\\infty$.\n\\begin{proof}\n Since the case when $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$ and $\\limsup _{n \\rightarrow \\infty} b_n=-\\infty$ has been excluded from consideration, we note that the inequality is obvious if $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$. Hence we shall assume that $\\left\\{a_n\\right\\}$ is bounded above.\n\nLet $\\left\\{n_k\\right\\}$ be a subsequence of the positive integers such that $\\lim _{k \\rightarrow \\infty}\\left(a_{n_k}+\\right.$ $\\left.b_{n_k}\\right)=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Then choose a subsequence of the positive integers $\\left\\{k_m\\right\\}$ such that\n$$\n\\lim _{m \\rightarrow \\infty} a_{n_{k_m}}=\\limsup _{k \\rightarrow \\infty} a_{n_k} .\n$$\nThe subsequence $a_{n_{k_m}}+b_{n_{k_m}}$ still converges to the same limit as $a_{n_k}+b_{n_k}$, i.e., to $\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Hence, since $a_{n_k}$ is bounded above (so that $\\limsup _{k \\rightarrow \\infty} a_{n_k}$ is finite), it follows that $b_{n_{k_m}}$ converges to the difference\n$$\n\\lim _{m \\rightarrow \\infty} b_{n_{k_m}}=\\lim _{m \\rightarrow \\infty}\\left(a_{n_{k_m}}+b_{n_{k_m}}\\right)-\\lim _{m \\rightarrow \\infty} a_{n_{k_m}} .\n$$\nThus we have proved that there exist subsequences $\\left\\{a_{n_{k_m}}\\right\\}$ and $\\left\\{b_{n_{k_m}}\\right\\}$ which converge to limits $a$ and $b$ respectively such that $a+b=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n^*\\right)$. Since $a$ is the limit of a subsequence of $\\left\\{a_n\\right\\}$ and $b$ is the limit of a subsequence of $\\left\\{b_n\\right\\}$, it follows that $a \\leq \\limsup _{n \\rightarrow \\infty} a_n$ and $b \\leq \\limsup _{n \\rightarrow \\infty} b_n$, from which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_6a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_6a\n: Tendsto (λ (n : ℕ) => (∑ i ∈ range n, g i)) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty} \\sum_{i (∑ i ∈ (range n), a i)) atTop (𝓝 y))) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), sqrt (a i) / n)) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the convergence of $\\Sigma a_{n}$ implies the convergence of $\\sum \\frac{\\sqrt{a_{n}}}{n}$ if $a_n\\geq 0$.\n\\begin{proof}\n Since $\\left(\\sqrt{a_n}-\\frac{1}{n}\\right)^2 \\geq 0$, it follows that\n$$\n\\frac{\\sqrt{a_n}}{n} \\leq \\frac{1}{2}\\left(a_n^2+\\frac{1}{n^2}\\right) .\n$$\nNow $\\Sigma a_n^2$ converges by comparison with $\\Sigma a_n$ (since $\\Sigma a_n$ converges, we have $a_n<1$ for large $n$, and hence $\\left.a_n^2 (∑ i ∈ (range n), a i)) atTop (𝓝 y)))\n (h2 : Monotone b)\n (h3 : Bornology.IsBounded (Set.range b)) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), (a i) * (b i))) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "If $\\Sigma a_{n}$ converges, and if $\\left\\{b_{n}\\right\\}$ is monotonic and bounded, prove that $\\Sigma a_{n} b_{n}$ converges.\n\\begin{proof}\n We shall show that the partial sums of this series form a Cauchy sequence, i.e., given $\\varepsilon>0$ there exists $N$ such that $\\left|\\sum_{k=m+1}^n a_k b_k\\right|\\langle\\varepsilon$ if $n\\rangle$ $m \\geq N$. To do this, let $S_n=\\sum_{k=1}^n a_k\\left(S_0=0\\right)$, so that $a_k=S_k-S_{k-1}$ for $k=1,2, \\ldots$ Let $M$ be an upper bound for both $\\left|b_n\\right|$ and $\\left|S_n\\right|$, and let $S=\\sum a_n$ and $b=\\lim b_n$. Choose $N$ so large that the following three inequalities hold for all $m>N$ and $n>N$ :\n$$\n\\left|b_n S_n-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m S_m-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M} .\n$$\nThen if $n>m>N$, we have, from the formula for summation by parts,\n$$\n\\sum_{k=m+1}^n a_n b_n=b_n S_n-b_m S_m+\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\n$$\nOur assumptions yield immediately that $\\left|b_n S_n-b_m S_m\\right|<\\frac{2 \\varepsilon}{3}$, and\n$$\n\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\\right| \\leq M \\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right| .\n$$\nSince the sequence $\\left\\{b_n\\right\\}$ is monotonic, we have\n$$\n\\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right|=\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right)\\right|=\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M},\n$$\nfrom which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_13\n (a b : ℕ → ℝ)\n (ha : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |a i|)) atTop (𝓝 y)))\n (hb : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |b i|)) atTop (𝓝 y))) :\n ∃ y, (Tendsto (λ n => (∑ i ∈ (range n),\n λ i => (∑ j ∈ range (i + 1), a j * b (i - j)))) atTop (𝓝 y)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the Cauchy product of two absolutely convergent series converges absolutely.\n\\begin{proof}\n Since both the hypothesis and conclusion refer to absolute convergence, we may assume both series consist of nonnegative terms. We let $S_n=\\sum_{k=0}^n a_n, T_n=\\sum_{k=0}^n b_n$, and $U_n=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l}$. We need to show that $U_n$ remains bounded, given that $S_n$ and $T_n$ are bounded. To do this we make the convention that $a_{-1}=T_{-1}=0$, in order to save ourselves from having to separate off the first and last terms when we sum by parts. We then have\n$$\n\\begin{aligned}\nU_n &=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l} \\\\\n&=\\sum_{k=0}^n \\sum_{l=0}^k a_l\\left(T_{k-l}-T_{k-l-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k a_{k-j}\\left(T_j-T_{j-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k\\left(a_{k-j}-a_{k-j-1}\\right) T_j \\\\\n&=\\sum_{j=0}^n \\sum_{k=j}^n\\left(a_{k-j}-a_{k-j-1}\\right) T_j\n&=\\sum_{j=0}^n a_{n-j} T_j \\\\\n&\\leq T \\sum_{m=0}^n a_m \\\\\n&=T S_n \\\\\n&\\leq S T .\n\\end{aligned}\n$$\nThus $U_n$ is bounded, and hence approaches a finite limit.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_20", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_20 {X : Type*} [MetricSpace X]\n (p : ℕ → X) (l : ℕ) (r : X)\n (hp : CauchySeq p)\n (hpl : Tendsto (λ n => p (l * n)) atTop (𝓝 r)) :\n Tendsto p atTop (𝓝 r) := sorry", "formal_proof": null, "informal_stmt": "Suppose $\\left\\{p_{n}\\right\\}$ is a Cauchy sequence in a metric space $X$, and some sequence $\\left\\{p_{n l}\\right\\}$ converges to a point $p \\in X$. Prove that the full sequence $\\left\\{p_{n}\\right\\}$ converges to $p$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $N_1$ so large that $d\\left(p_m, p_n\\right)<\\frac{\\varepsilon}{2}$ if $m>N_1$ and $n>N_1$. Then choose $N \\geq N_1$ so large that $d\\left(p_{n_k}, p\\right)<\\frac{\\varepsilon}{2}$ if $k>N$. Then if $n>N$, we have\n$$\nd\\left(p_n, p\\right) \\leq d\\left(p_n, p_{n_{N+1}}\\right)+d\\left(p_{n_{N+1}}, p\\right)<\\varepsilon\n$$\nFor the first term on the right is less than $\\frac{\\varepsilon}{2}$ since $n>N_1$ and $n_{N+1}>N+1>$ $N_1$. The second term is less than $\\frac{\\varepsilon}{2}$ by the choice of $N$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_21", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_21\n {X : Type*} [MetricSpace X] [CompleteSpace X]\n (E : ℕ → Set X)\n (hE : ∀ n, E n ⊃ E (n + 1))\n (hE' : Tendsto (λ n => Metric.diam (E n)) atTop (𝓝 0)) :\n ∃ a, Set.iInter E = {a} := sorry", "formal_proof": null, "informal_stmt": "If $\\left\\{E_{n}\\right\\}$ is a sequence of closed nonempty and bounded sets in a complete metric space $X$, if $E_{n} \\supset E_{n+1}$, and if $\\lim _{n \\rightarrow \\infty} \\operatorname{diam} E_{n}=0,$ then $\\bigcap_{1}^{\\infty} E_{n}$ consists of exactly one point.\n\\begin{proof}\n Choose $x_n \\in E_n$. (We use the axiom of choice here.) The sequence $\\left\\{x_n\\right\\}$ is a Cauchy sequence, since the diameter of $E_n$ tends to zero as $n$ tends to infinity and $E_n$ contains $E_{n+1}$. Since the metric space $X$ is complete, the sequence $x_n$ converges to a point $x$, which must belong to $E_n$ for all $n$, since $E_n$ is closed and contains $x_m$ for all $m \\geq n$. There cannot be a second point $y$ in all of the $E_n$, since for any point $y \\neq x$ the diameter of $E_n$ is less $\\operatorname{than} d(x, y)$ for large $n$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_22", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_22 (X : Type*) [MetricSpace X] [CompleteSpace X]\n (G : ℕ → Set X) (hG : ∀ n, IsOpen (G n) ∧ Dense (G n)) :\n ∃ x, ∀ n, x ∈ G n := sorry", "formal_proof": null, "informal_stmt": "Suppose $X$ is a nonempty complete metric space, and $\\left\\{G_{n}\\right\\}$ is a sequence of dense open sets of $X$. Prove Baire's theorem, namely, that $\\bigcap_{1}^{\\infty} G_{n}$ is not empty.\n\\begin{proof}\n Let $F_n$ be the complement of $G_n$, so that $F_n$ is closed and contains no open sets. We shall prove that any nonempty open set $U$ contains a point not in any $F_n$, hence in all $G_n$. To this end, we note that $U$ is not contained in $F_1$, so that there is a point $x_1 \\in U \\backslash F_1$. Since $U \\backslash F_1$ is open, there exists $r_1>0$ such that $B_1$, defined as the open ball of radius $r_1$ about $x_1$, is contained in $U \\backslash F_1$. Let $E_1$ be the open ball of radius $\\frac{r_1}{2}$ about $x_1$, so that the closure of $E_1$ is contained in $B_1$. Now $F_2$ does not contain $E_1$, and so we can find a point $x_2 \\in E_1 \\backslash F_2$. Since $E_1 \\backslash F_2$ is an open set, there exists a positive number $r_2$ such that $B_2$, the open ball of radius $R_2$ about $x_2$, is contained in $E_1 \\backslash F_2$, which in turn is contained in $U \\backslash\\left(F_1 \\cup F_2\\right)$. We let $E_2$ be the open ball of radius $\\frac{r_2}{2}$ about $x_2$, so that $\\bar{E}_2 \\subseteq B_2$. Proceeding in this way, we construct a sequence of open balls $E_j$, such that $E_j \\supseteq \\bar{E}_{j+1}$, and the diameter of $E_j$ tends to zero. By the previous exercise, there is a point $x$ belonging to all the sets $\\bar{E}_j$, hence to all the sets $U \\backslash\\left(F_1 \\cup F_2 \\cup \\cdots \\cup F_n\\right)$. Thus the point $x$ belongs to $U \\cap\\left(\\cap_1^{\\infty} G_n\\right)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_1a\n : ∃ (f : ℝ → ℝ), (∀ (x : ℝ), Tendsto (λ y => f (x + y) - f (x - y)) (𝓝 0) (𝓝 0)) ∧ ¬ Continuous f := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real function defined on $\\mathbb{R}$ which satisfies $\\lim_{h \\rightarrow 0} f(x + h) - f(x - h) = 0$ for every $x \\in \\mathbb{R}$. Show that $f$ does not need to be continuous.\n\\begin{proof}\n $$\nf(x)= \\begin{cases}1 & \\text { if } x \\text { is an integer } \\\\ 0 & \\text { if } x \\text { is not an integer. }\\end{cases}\n$$\n(If $x$ is an integer, then $f(x+h)-f(x-h) \\equiv 0$ for all $h$; while if $x$ is not an integer, $f(x+h)-f(x-h)=0$ for $|h|<\\min (x-[x], 1+[x]-x)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_2a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (h₁ : Continuous f)\n : ∀ (x : Set α), f '' (closure x) ⊆ closure (f '' x) := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a continuous mapping of a metric space $X$ into a metric space $Y$, prove that $f(\\overline{E}) \\subset \\overline{f(E)}$ for every set $E \\subset X$. ($\\overline{E}$ denotes the closure of $E$).\n\\begin{proof}\n Let $x \\in \\bar{E}$. We need to show that $f(x) \\in \\overline{f(E)}$. To this end, let $O$ be any neighborhood of $f(x)$. Since $f$ is continuous, $f^{-1}(O)$ contains (is) a neighborhood of $x$. Since $x \\in \\bar{E}$, there is a point $u$ of $E$ in $f^{-1}(O)$. Hence $\\frac{f(u)}{f(E)} \\in O \\cap f(E)$. Since $O$ was any neighborhood of $f(x)$, it follows that $f(x) \\in \\overline{f(E)}$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_3\n {α : Type} [MetricSpace α]\n (f : α → ℝ) (h : Continuous f) (z : Set α) (g : z = f⁻¹' {0})\n : IsClosed z := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a continuous real function on a metric space $X$. Let $Z(f)$ (the zero set of $f$ ) be the set of all $p \\in X$ at which $f(p)=0$. Prove that $Z(f)$ is closed.\n\\begin{proof}\n $Z(f)=f^{-1}(\\{0\\})$, which is the inverse image of a closed set. Hence $Z(f)$ is closed.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_4a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Dense s)\n : f '' Set.univ ⊆ closure (f '' s) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that $f(E)$ is dense in $f(X)$.\n\\begin{proof}\n To prove that $f(E)$ is dense in $f(X)$, simply use that $f(X)=f(\\bar{E}) \\subseteq \\overline{f(E)}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_4b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4b\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f g : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Continuous g)\n (h₃ : Dense s)\n (h₄ : ∀ x ∈ s, f x = g x)\n : f = g := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that if $g(p) = f(p)$ for all $p \\in P$ then $g(p) = f(p)$ for all $p \\in X$.\n\\begin{proof}\n The function $\\varphi: X \\rightarrow R^1$ given by\n$$\n\\varphi(p)=d_Y(f(p), g(p))\n$$\nis continuous, since\n$$\n\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right| \\leq d_Y(f(p), f(q))+d_Y(g(p), g(q))\n$$\n(This inequality follows from the triangle inequality, since\n$$\nd_Y(f(p), g(p)) \\leq d_Y(f(p), f(q))+d_Y(f(q), g(q))+d_Y(g(q), g(p)),\n$$\nand the same inequality holds with $p$ and $q$ interchanged. The absolute value $\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right|$ must be either $d_Y(f(p), g(p))-d_Y(f(q), g(q))$ or $d_Y(f(q), g(q))-d_Y(f(p), g(p))$, and the triangle inequality shows that both of these numbers are at most $d_Y(f(p), f(q))+d_Y(g(p), g(q))$.)\nBy the previous problem, the zero set of $\\varphi$ is closed. But by definition\n$$\nZ(\\varphi)=\\{p: f(p)=g(p)\\} .\n$$\nHence the set of $p$ for which $f(p)=g(p)$ is closed. Since by hypothesis it is dense, it must be $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_5a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_5a\n (f : ℝ → ℝ)\n (E : Set ℝ)\n (h₁ : IsClosed E)\n (h₂ : ContinuousOn f E)\n : ∃ (g : ℝ → ℝ), Continuous g ∧ ∀ x ∈ E, f x = g x := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a real continuous function defined on a closed set $E \\subset \\mathbb{R}$, prove that there exist continuous real functions $g$ on $\\mathbb{R}$ such that $g(x)=f(x)$ for all $x \\in E$.\n\\begin{proof}\nFollowing the hint, let the complement of $E$ consist of a countable collection of finite open intervals $\\left(a_k, b_k\\right)$ together with possibly one or both of the the semi-infinite intervals $(b,+\\infty)$ and $(-\\infty, a)$. The function $f(x)$ is already defined at $a_k$ and $b_k$, as well as at $a$ and $b$ (if these last two points exist). Define $g(x)$ to be $f(b)$ for $x>b$ and $f(a)$ for $x0$. To choose $\\delta>0$ such that $|x-u|<\\delta$ implies $|g(x)-g(u)|<\\varepsilon$, we consider three cases.\ni. If $x>b$, let $\\delta=x-b$. Then if $|x-u|<\\delta$, it follows that $u>b$ also, so that $g(u)=f(b)=g(x)$, and $|g(u)-g(x)|=0<\\varepsilon$. Similarly if $xa_k+\\delta_1$. Let us consider the second of these cases and show how to get $|f(u)-f(x)|<\\varepsilon$ for $xx$ we have $a_k0$ be given. Choose $\\eta>0$ so that $d_Y(f(x), f(u))<\\frac{\\varepsilon}{2}$ if $d_E(x, y)<\\eta$. Then let $\\delta=\\min \\left(\\eta, \\frac{\\varepsilon}{2}\\right)$. It is easy to see that $\\rho(\\varphi(x), \\varphi(u))<\\varepsilon$ if $d_E(x, u)<\\delta$. Conversely if $\\varphi$ is continuous, it is obvious from the inequality $\\rho(\\varphi(x), \\varphi(u)) \\geq d_Y(f(x), f(u))$ that $f$ is continuous.\n\nFrom these facts we deduce immediately that the graph of a continuous function $f$ on a compact set $E$ is compact, being the image of $E$ under the continuous mapping $\\varphi$. Conversely, if $f$ is not continuous at some point $x$, there is a sequence of points $x_n$ converging to $x$ such that $f\\left(x_n\\right)$ does not converge to $f(x)$. If no subsequence of $f\\left(x_n\\right)$ converges, then the sequence $\\left\\{\\left(x_n, f\\left(x_n\\right)\\right\\}_{n=1}^{\\infty}\\right.$ has no convergent subsequence, and so the graph is not compact. If some subsequence of $f\\left(x_n\\right)$ converges, say $f\\left(x_{n_k}\\right) \\rightarrow z$, but $z \\neq f(x)$, then the graph of $f$ fails to contain the limit point $(x, z)$, and hence is not closed. A fortiori it is not compact.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_8a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_8a\n (E : Set ℝ) (f : ℝ → ℝ) (hf : UniformContinuousOn f E)\n (hE : Bornology.IsBounded E) : Bornology.IsBounded (Set.image f E) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real uniformly continuous function on the bounded set $E$ in $R^{1}$. Prove that $f$ is bounded on $E$.\n\\begin{proof}\n Let $a=\\inf E$ and $b=\\sup E$, and let $\\delta>0$ be such that $|f(x)-f(y)|<1$ if $x, y \\in E$ and $|x-y|<\\delta$. Now choose a positive integer $N$ larger than $(b-a) / \\delta$, and consider the $N$ intervals $I_k=\\left[a+\\frac{k-1}{b-a}, a+\\frac{k}{b-a}\\right], k=1,2, \\ldots, N$. For each $k$ such that $I_k \\cap E \\neq \\varnothing$ let $x_k \\in E \\cap I_k$. Then let $M=1+\\max \\left\\{\\left|f\\left(x_k\\right)\\right|\\right\\}$. If $x \\in E$, we have $\\left|x-x_k\\right|<\\delta$ for some $k$, and hence $|f(x)| f (x n)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a uniformly continuous mapping of a metric space $X$ into a metric space $Y$ and prove that $\\left\\{f\\left(x_{n}\\right)\\right\\}$ is a Cauchy sequence in $Y$ for every Cauchy sequence $\\{x_n\\}$ in $X$.\n\\begin{proof}\n Suppose $\\left\\{x_n\\right\\}$ is a Cauchy sequence in $X$. Let $\\varepsilon>0$ be given. Let $\\delta>0$ be such that $d_Y(f(x), f(u))<\\varepsilon$ if $d_X(x, u)<\\delta$. Then choose $N$ so that $d_X\\left(x_n, x_m\\right)<\\delta$ if $n, m>N$. Obviously $d_Y\\left(f\\left(x_n\\right), f\\left(x_m\\right)\\right)<\\varepsilon$ if $m, n>N$, showing that $\\left\\{f\\left(x_n\\right)\\right\\}$ is a Cauchy sequence.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_12\n {α β γ : Type*} [UniformSpace α] [UniformSpace β] [UniformSpace γ]\n {f : α → β} {g : β → γ}\n (hf : UniformContinuous f) (hg : UniformContinuous g) :\n UniformContinuous (g ∘ f) := sorry", "formal_proof": null, "informal_stmt": "A uniformly continuous function of a uniformly continuous function is uniformly continuous.\n\\begin{proof}\n Let $f: X \\rightarrow Y$ and $g: Y \\rightarrow Z$ be uniformly continuous. Then $g \\circ f: X \\rightarrow Z$ is uniformly continuous, where $g \\circ f(x)=g(f(x))$ for all $x \\in X$.\nTo prove this fact, let $\\varepsilon>0$ be given. Then, since $g$ is uniformly continuous, there exists $\\eta>0$ such that $d_Z(g(u), g(v))<\\varepsilon$ if $d_Y(u, v)<\\eta$. Since $f$ is uniformly continuous, there exists $\\delta>0$ such that $d_Y(f(x), f(y))<\\eta$ if $d_X(x, y)<\\delta$\n\nIt is then obvious that $d_Z(g(f(x)), g(f(y)))<\\varepsilon$ if $d_X(x, y)<\\delta$, so that $g \\circ f$ is uniformly continuous.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_15 {f : ℝ → ℝ}\n (hf : Continuous f) (hof : IsOpenMap f) :\n Monotone f := sorry", "formal_proof": null, "informal_stmt": "Prove that every continuous open mapping of $R^{1}$ into $R^{1}$ is monotonic.\n\\begin{proof}\n Suppose $f$ is continuous and not monotonic, say there exist points $a 0 ∧ ∀ (p q : X), p ∈ K → q ∈ F → dist p q ≥ δ := sorry", "formal_proof": null, "informal_stmt": "Suppose $K$ and $F$ are disjoint sets in a metric space $X, K$ is compact, $F$ is closed. Prove that there exists $\\delta>0$ such that $d(p, q)>\\delta$ if $p \\in K, q \\in F$.\n\\begin{proof}\nFollowing the hint, we observe that $\\rho_F(x)$ must attain its minimum value on $K$, i.e., there is some point $r \\in K$ such that\n$$\n\\rho_F(r)=\\min _{q \\in K} \\rho_F(q) .\n$$\nSince $F$ is closed and $r \\notin F$, it follows from Exercise $4.20$ that $\\rho_F(r)>0$. Let $\\delta$ be any positive number smaller than $\\rho_F(r)$. Then for any $p \\in F, q \\in K$, we have\n$$\nd(p, q) \\geq \\rho_F(q) \\geq \\rho_F(r)>\\delta .\n$$\nThis proves the positive assertion.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_24 {f : ℝ → ℝ}\n (hf : Continuous f) (a b : ℝ) (hab : a < b)\n (h : ∀ x y : ℝ, a < x → x < b → a < y → y < b → f ((x + y) / 2) ≤ (f x + f y) / 2) :\n ConvexOn ℝ (Set.Ioo a b) f := sorry", "formal_proof": null, "informal_stmt": "Assume that $f$ is a continuous real function defined in $(a, b)$ such that $f\\left(\\frac{x+y}{2}\\right) \\leq \\frac{f(x)+f(y)}{2}$ for all $x, y \\in(a, b)$. Prove that $f$ is convex.\n\\begin{proof}\n We shall prove that\n$$\nf(\\lambda x+(1-\\lambda) y) \\leq \\lambda f(x)+(1-\\lambda) f(y)\n$$\nfor all \"dyadic rational\" numbers, i.e., all numbers of the form $\\lambda=\\frac{k}{2^n}$, where $k$ is a nonnegative integer not larger than $2^n$. We do this by induction on $n$. The case $n=0$ is trivial (since $\\lambda=0$ or $\\lambda=1$ ). In the case $n=1$ we have $\\lambda=0$ or $\\lambda=1$ or $\\lambda=\\frac{1}{2}$. The first two cases are again trivial, and the third is precisely the hypothesis of the theorem. Suppose the result is proved for $n \\leq r$, and consider $\\lambda=\\frac{k}{2^{r+1}}$. If $k$ is even, say $k=2 l$, then $\\frac{k}{2^{r+1}}=\\frac{l}{2^r}$, and we can appeal to the induction hypothesis. Now suppose $k$ is odd. Then $1 \\leq k \\leq 2^{r+1}-1$, and so the numbers $l=\\frac{k-1}{2}$ and $m=\\frac{k+1}{2}$ are integers with $0 \\leq l c := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be defined for all real $x$, and suppose that $|f(x)-f(y)| \\leq (x-y)^{2}$ for all real $x$ and $y$. Prove that $f$ is constant.\n\\begin{proof}\n Dividing by $x-y$, and letting $x \\rightarrow y$, we find that $f^{\\prime}(y)=0$ for all $y$. Hence $f$ is constant.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_2 {a b : ℝ}\n {f g : ℝ → ℝ} (hf : ∀ x ∈ Set.Ioo a b, deriv f x > 0)\n (hg : g = f⁻¹)\n (hg_diff : DifferentiableOn ℝ g (Set.Ioo a b)) :\n DifferentiableOn ℝ g (Set.Ioo a b) ∧\n ∀ x ∈ Set.Ioo a b, deriv g x = 1 / deriv f x := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x)>0$ in $(a, b)$. Prove that $f$ is strictly increasing in $(a, b)$, and let $g$ be its inverse function. Prove that $g$ is differentiable, and that $g^{\\prime}(f(x))=\\frac{1}{f^{\\prime}(x)} \\quad(a0$. Hence $f(c)0$ there exists $\\eta>0$ such that\n$$\n\\left|\\frac{1}{\\frac{f(x+h)-f(x)}{h}}-\\frac{1}{f^{\\prime}(x)}\\right|<\\varepsilon\n$$\nif $0<|h|<\\eta$. Since $h=g(y+k)-g(y)$, there exists $\\delta>0$ such that $0<|h|<\\eta$ if $0<|k|<\\delta$. The proof is now complete. \n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_3 {g : ℝ → ℝ} (hg : Continuous g)\n (hg' : ∃ M : ℝ, ∀ x : ℝ, |deriv g x| ≤ M) :\n ∃ N, ∀ ε > 0, ε < N → Function.Injective (λ x : ℝ => x + ε * g x) := sorry", "formal_proof": null, "informal_stmt": "Suppose $g$ is a real function on $R^{1}$, with bounded derivative (say $\\left|g^{\\prime}\\right| \\leq M$ ). Fix $\\varepsilon>0$, and define $f(x)=x+\\varepsilon g(x)$. Prove that $f$ is one-to-one if $\\varepsilon$ is small enough.\n\\begin{proof}\n If $0<\\varepsilon<\\frac{1}{M}$, we certainly have\n$$\nf^{\\prime}(x) \\geq 1-\\varepsilon M>0,\n$$\nand this implies that $f(x)$ is one-to-one, by the preceding problem.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_4 {n : ℕ}\n (C : ℕ → ℝ)\n (hC : ∑ i ∈ (range (n + 1)), (C i) / (i + 1) = 0) :\n ∃ x, x ∈ (Set.Icc (0 : ℝ) 1) ∧ ∑ i ∈ range (n + 1), (C i) * (x^i) = 0 := sorry", "formal_proof": null, "informal_stmt": "If $C_{0}+\\frac{C_{1}}{2}+\\cdots+\\frac{C_{n-1}}{n}+\\frac{C_{n}}{n+1}=0,$ where $C_{0}, \\ldots, C_{n}$ are real constants, prove that the equation $C_{0}+C_{1} x+\\cdots+C_{n-1} x^{n-1}+C_{n} x^{n}=0$ has at least one real root between 0 and 1.\n\\begin{proof}\n Consider the polynomial\n$$\np(x)=C_0 x+\\frac{C_1}{2} x^2+\\cdots+\\frac{C_{n-1}}{n} x^n+\\frac{C_n}{n+1} x^{n+1},\n$$\nwhose derivative is\n$$\np^{\\prime}(x)=C_0+C_1 x+\\cdots+C_{n-1} x^{n-1}+C_n x^n .\n$$\nIt is obvious that $p(0)=0$, and the hypothesis of the problem is that $p(1)=0$. Hence Rolle's theorem implies that $p^{\\prime}(x)=0$ for some $x$ between 0 and 1 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_5\n {f : ℝ → ℝ}\n (hfd : Differentiable ℝ f)\n (hf : Tendsto (deriv f) atTop (𝓝 0)) :\n Tendsto (λ x => f (x + 1) - f x) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is defined and differentiable for every $x>0$, and $f^{\\prime}(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$. Put $g(x)=f(x+1)-f(x)$. Prove that $g(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $x_0$ such that $\\left|f^{\\prime}(x)\\right|<\\varepsilon$ if $x>x_0$. Then for any $x \\geq x_0$ there exists $x_1 \\in(x, x+1)$ such that\n$$\nf(x+1)-f(x)=f^{\\prime}\\left(x_1\\right) .\n$$\nSince $\\left|f^{\\prime}\\left(x_1\\right)\\right|<\\varepsilon$, it follows that $|f(x+1)-f(x)|<\\varepsilon$, as required.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_6", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_6\n {f : ℝ → ℝ}\n (hf1 : Continuous f)\n (hf2 : ∀ x, DifferentiableAt ℝ f x)\n (hf3 : f 0 = 0)\n (hf4 : Monotone (deriv f)) :\n MonotoneOn (λ x => f x / x) (Set.Ioi 0) := sorry", "formal_proof": null, "informal_stmt": "Suppose (a) $f$ is continuous for $x \\geq 0$, (b) $f^{\\prime}(x)$ exists for $x>0$, (c) $f(0)=0$, (d) $f^{\\prime}$ is monotonically increasing. Put $g(x)=\\frac{f(x)}{x} \\quad(x>0)$ and prove that $g$ is monotonically increasing.\n\\begin{proof}\n Put\n$$\ng(x)=\\frac{f(x)}{x} \\quad(x>0)\n$$\nand prove that $g$ is monotonically increasing.\nBy the mean-value theorem\n$$\nf(x)=f(x)-f(0)=f^{\\prime}(c) x\n$$\nfor some $c \\in(0, x)$. Since $f^{\\prime}$ is monotonically increasing, this result implies that $f(x)0,\n$$\nso that $g$ is also monotonically increasing.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_7", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_7\n {f g : ℝ → ℝ} {x : ℝ}\n (hf' : DifferentiableAt ℝ f 0)\n (hg' : DifferentiableAt ℝ g 0)\n (hg'_ne_0 : deriv g 0 ≠ 0)\n (f0 : f 0 = 0) (g0 : g 0 = 0) :\n Tendsto (λ x => f x / g x) (𝓝 x) (𝓝 (deriv f x / deriv g x)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x), g^{\\prime}(x)$ exist, $g^{\\prime}(x) \\neq 0$, and $f(x)=g(x)=0$. Prove that $\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)}=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}.$\n\\begin{proof}\n Since $f(x)=g(x)=0$, we have\n$$\n\\begin{aligned}\n\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)} &=\\lim _{t \\rightarrow x} \\frac{\\frac{f(t)-f(x)}{t-x}}{\\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{\\lim _{t \\rightarrow x} \\frac{f(t)-f(x)}{t-x}}{\\lim _{t \\rightarrow x} \\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_15 {f : ℝ → ℝ} (a M0 M1 M2 : ℝ)\n (hf' : DifferentiableOn ℝ f (Set.Ici a))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Ici a))\n (hM0 : M0 = sSup {(|f x|) | x ∈ (Set.Ici a)})\n (hM1 : M1 = sSup {(|deriv f x|) | x ∈ (Set.Ici a)})\n (hM2 : M2 = sSup {(|deriv (deriv f) x|) | x ∈ (Set.Ici a)}) :\n (M1 ^ 2) ≤ 4 * M0 * M2 := sorry", "formal_proof": null, "informal_stmt": "Suppose $a \\in R^{1}, f$ is a twice-differentiable real function on $(a, \\infty)$, and $M_{0}, M_{1}, M_{2}$ are the least upper bounds of $|f(x)|,\\left|f^{\\prime}(x)\\right|,\\left|f^{\\prime \\prime}(x)\\right|$, respectively, on $(a, \\infty)$. Prove that $M_{1}^{2} \\leq 4 M_{0} M_{2} .$\n\\begin{proof}\n The inequality is obvious if $M_0=+\\infty$ or $M_2=+\\infty$, so we shall assume that $M_0$ and $M_2$ are both finite. We need to show that\n$$\n\\left|f^{\\prime}(x)\\right| \\leq 2 \\sqrt{M_0 M_2}\n$$\nfor all $x>a$. We note that this is obvious if $M_2=0$, since in that case $f^{\\prime}(x)$ is constant, $f(x)$ is a linear function, and the only bounded linear function is a constant, whose derivative is zero. Hence we shall assume from now on that $0-1$. Now $f^{\\prime}(x)=\\frac{4 x}{\\left(x^2+1\\right)^2}$ for $x>0$ and $f^{\\prime}(x)=4 x$ for $x<0$. It thus follows from Exercise 9 above that $f^{\\prime}(0)=0$, and that $f^{\\prime}(x)$ is continuous. Likewise $f^{\\prime \\prime}(x)=4$ for $x<0$ and $f^{\\prime \\prime}(x)=\\frac{4-4 x^2}{\\left(x^2+1\\right)^3}=-4 \\frac{x^2-1}{\\left(x^2+1\\right)^3}$. This shows that $\\left|f^{\\prime \\prime}(x)\\right|<4$ for $x>0$ and also that $\\lim _{x \\rightarrow 0} f^{\\prime \\prime}(x)=4$. Hence Exercise 9 again implies that $f^{\\prime \\prime}(x)$ is continuous and $f^{\\prime \\prime}(0)=4$.\n\nOn $n$-dimensional space let $\\mathbf{f}(x)=\\left(f_1(x), \\ldots, f_n(x)\\right), M_0=\\sup |\\mathbf{f}(x)|$, $M_1=\\sup \\left|\\mathbf{f}^{\\prime}(x)\\right|$, and $M_2=\\sup \\left|\\mathbf{f}^{\\prime \\prime}(x)\\right|$. Just as in the numerical case, there is nothing to prove if $M_2=0$ or $M_0=+\\infty$ or $M_2=+\\infty$, and so we assume $0a$, and let $\\mathbf{u}=\\frac{1}{\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|} \\mathbf{f}^{\\prime}\\left(x_0\\right)$. Consider the real-valued function $\\varphi(x)=\\mathrm{u} \\cdot \\mathrm{f}(x)$. Let $N_0, N_1$, and $N_2$ be the suprema of $|\\varphi(x)|,\\left|\\varphi^{\\prime}(x)\\right|$, and $\\left|\\varphi^{\\prime \\prime}(x)\\right|$ respectively. By the Schwarz inequality we have (since $|\\mathbf{u}|=1) N_0 \\leq M_0$ and $N_2 \\leq M_2$, while $N_1 \\geq \\varphi\\left(x_0\\right)=\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|>a$. We therefore have $a^2<4 N_0 N_2 \\leq 4 M_0 M_2$. Since $a$ was any positive number less than $M_1$, we have $M_1^2 \\leq 4 M_0 M_2$, i.e., the result holds also for vector-valued functions.\n\nEquality can hold on any $R^n$, as we see by taking $\\mathbf{f}(x)=(f(x), 0, \\ldots, 0)$ or $\\mathbf{f}(x)=(f(x), f(x), \\ldots, f(x))$, where $f(x)$ is a real-valued function for which equality holds.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_17\n {f : ℝ → ℝ}\n (hf' : DifferentiableOn ℝ f (Set.Icc (-1) 1))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Icc 1 1))\n (hf''' : DifferentiableOn ℝ (deriv (deriv f)) (Set.Icc 1 1))\n (hf0 : f (-1) = 0)\n (hf1 : f 0 = 0)\n (hf2 : f 1 = 1)\n (hf3 : deriv f 0 = 0) :\n ∃ x, x ∈ Set.Ioo (-1 : ℝ) 1 ∧ deriv (deriv (deriv f)) x ≥ 3 := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real, three times differentiable function on $[-1,1]$, such that $f(-1)=0, \\quad f(0)=0, \\quad f(1)=1, \\quad f^{\\prime}(0)=0 .$ Prove that $f^{(3)}(x) \\geq 3$ for some $x \\in(-1,1)$.\n\\begin{proof}\n Following the hint, we observe that Theorem $5.15$ (Taylor's formula with remainder) implies that\n$$\n\\begin{aligned}\nf(1) &=f(0)+f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)+\\frac{1}{6} f^{(3)}(s) \\\\\nf(-1) &=f(0)-f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)-\\frac{1}{6} f^{(3)}(t)\n\\end{aligned}\n$$\nfor some $s \\in(0,1), t \\in(-1,0)$. By subtracting the second equation from the first and using the given values of $f(1), f(-1)$, and $f^{\\prime}(0)$, we obtain\n$$\n1=\\frac{1}{6}\\left(f^{(3)}(s)+f^{(3)}(t)\\right),\n$$\nwhich is the desired result. Note that we made no use of the hypothesis $f(0)=0$.\n\\end{proof}\n\n\n\n\\end{document}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Putnam_exercise_2020_b5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2020_b5 (z : Fin 4 → ℂ) (hz0 : ∀ n, ‖z n‖ < 1)\n (hz1 : ∀ n : Fin 4, z n ≠ 1) :\n 3 - z 0 - z 1 - z 2 - z 3 + (z 0) * (z 1) * (z 2) * (z 3) ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "For $j \\in\\{1,2,3,4\\}$, let $z_{j}$ be a complex number with $\\left|z_{j}\\right|=1$ and $z_{j} \\neq 1$. Prove that $3-z_{1}-z_{2}-z_{3}-z_{4}+z_{1} z_{2} z_{3} z_{4} \\neq 0 .$\n\\begin{proof}\n It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1.\n\nTo this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \n\\[\nf(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2.\n\\]\n A routine calculation shows that \n\\begin{align*}\nf(\\alpha, \\beta, \\gamma)&=\n10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\\n&\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\\n&\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha).\n\\end{align*}\nSince the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \n\\begin{align*}\n\\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &=\n6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\\n&=\n24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right)\n\\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right).\n\\end{align*}\nHence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \n\\[\nf = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2;\n\\]\nsince $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$. \n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_a5 (f : ℝ → ℝ) (hf : ContDiff ℝ ⊤ f)\n (hf0 : f 0 = 0) (hf1 : f 1 = 1) (hf2 : ∀ x, f x ≥ 0) :\n ∃ (n : ℕ) (x : ℝ), iteratedDeriv n f x = 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f: \\mathbb{R} \\rightarrow \\mathbb{R}$ be an infinitely differentiable function satisfying $f(0)=0, f(1)=1$, and $f(x) \\geq 0$ for all $x \\in$ $\\mathbb{R}$. Show that there exist a positive integer $n$ and a real number $x$ such that $f^{(n)}(x)<0$.\n\\begin{proof}\n Call a function $f\\colon \\mathbb{R} \\to \\mathbb{R}$ \\textit{ultraconvex} if $f$ is infinitely differentiable and $f^{(n)}(x) \\geq 0$ for all $n \\geq 0$ and all $x \\in \\mathbb{R}$, where $f^{(0)}(x) = f(x)$;\nnote that if $f$ is ultraconvex, then so is $f'$.\nDefine the set\n\\[\nS = \\{ f :\\thinspace \\mathbb{R} \\to \\mathbb{R} \\,|\\,f \\text{ ultraconvex and } f(0)=0\\}.\n\\]\nFor $f \\in S$, we must have $f(x) = 0$ for all $x < 0$: if $f(x_0) > 0$ for some $x_0 < 0$, then\nby the mean value theorem there exists $x \\in (0,x_0)$ for which $f'(x) = \\frac{f(x_0)}{x_0} < 0$.\nIn particular, $f'(0) = 0$, so $f' \\in S$ also.\n\nWe show by induction that for all $n \\geq 0$,\n\\[\nf(x) \\leq \\frac{f^{(n)}(1)}{n!} x^n \\qquad (f \\in S, x \\in [0,1]).\n\\]\nWe induct with base case $n=0$, which holds because any $f \\in S$ is nondecreasing. Given the claim for $n=m$,\nwe apply the induction hypothesis to $f' \\in S$ to see that\n\\[\nf'(t) \\leq \\frac{f^{(n+1)}(1)}{n!} t^n \\qquad (t \\in [0,1]),\n\\]\nthen integrate both sides from $0$ to $x$ to conclude.\n\nNow for $f \\in S$, we have $0 \\leq f(1) \\leq \\frac{f^{(n)}(1)}{n!}$ for all $n \\geq 0$. \nOn the other hand, by Taylor's theorem with remainder,\n\\[\nf(x) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}(x-1)^k \\qquad (x \\geq 1).\n\\]\nApplying this with $x=2$, we obtain $f(2) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}$ for all $n$;\nthis implies that $\\lim_{n\\to\\infty} \\frac{f^{(n)}(1)}{n!} = 0$.\nSince $f(1) \\leq \\frac{f^{(n)}(1)}{n!}$, we must have $f(1) = 0$.\n\nFor $f \\in S$, we proved earlier that $f(x) = 0$ for all $x\\leq 0$, as well as for $x=1$. Since\nthe function $g(x) = f(cx)$ is also ultraconvex for $c>0$, we also have $f(x) = 0$ for all $x>0$;\nhence $f$ is identically zero.\n\nTo sum up, if $f\\colon \\mathbb{R} \\to \\mathbb{R}$ is infinitely differentiable, $f(0)=0$, and $f(1) = 1$,\nthen $f$ cannot be ultraconvex. This implies the desired result.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_b2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b2 (n : ℕ) (hn : n > 0) (f : ℕ → ℂ → ℂ)\n (hf : ∀ n : ℕ, f n = λ (z : ℂ) => (∑ i : Fin n, (n-i)* z^(i : ℕ))) :\n ¬ (∃ z : ℂ, ‖z‖ ≤ 1 ∧ f n z = 0) := sorry", "formal_proof": null, "informal_stmt": "Let $n$ be a positive integer, and let $f_{n}(z)=n+(n-1) z+$ $(n-2) z^{2}+\\cdots+z^{n-1}$. Prove that $f_{n}$ has no roots in the closed unit disk $\\{z \\in \\mathbb{C}:|z| \\leq 1\\}$.\n\\begin{proof}\n Note first that $f_n(1) > 0$, so $1$ is not a root of $f_n$.\nNext, note that\n\\[\n(z-1)f_n(z) = z^n + \\cdots + z - n;\n\\]\nhowever, for $\\left| z \\right| \\leq 1$, we have \n$\\left| z^n + \\cdots + z \\right| \\leq n$ by the triangle inequality;\nequality can only occur if $z,\\dots,z^n$ have norm 1 and the same argument, which only happens for $z=1$.\nThus there can be no root of $f_n$ with $|z| \\leq 1$.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b4 (a : ℝ) (x : ℕ → ℝ) (hx0 : x 0 = a)\n (hx1 : x 1 = a)\n (hxn : ∀ n : ℕ, n ≥ 2 → x (n+1) = 2*(x n)*(x (n-1)) - x (n-2))\n (h : ∃ n, x n = 0) :\n ∃ c, Function.Periodic x c := sorry", "formal_proof": null, "informal_stmt": "Given a real number $a$, we define a sequence by $x_{0}=1$, $x_{1}=x_{2}=a$, and $x_{n+1}=2 x_{n} x_{n-1}-x_{n-2}$ for $n \\geq 2$. Prove that if $x_{n}=0$ for some $n$, then the sequence is periodic.\n\\begin{proof}\n We first rule out the case $|a|>1$. In this case, we prove that $|x_{n+1}| \\geq |x_n|$ for all $n$, meaning that we cannot have $x_n = 0$. We proceed by induction; the claim is true for $n=0,1$ by hypothesis. To prove the claim for $n \\geq 2$, write\n\\begin{align*}\n|x_{n+1}| &= |2x_nx_{n-1}-x_{n-2}| \\\\\n&\\geq 2|x_n||x_{n-1}|-|x_{n-2}| \\\\\n&\\geq |x_n|(2|x_{n-1}|-1) \\geq |x_n|,\n\\end{align*} \nwhere the last step follows from $|x_{n-1}| \\geq |x_{n-2}| \\geq \\cdots \\geq |x_0| = 1$.\n\nWe may thus assume hereafter that $|a|\\leq 1$. We can then write $a = \\cos b$ for some $b \\in [0,\\pi]$. \nLet $\\{F_n\\}$ be the Fibonacci sequence, defined as usual by $F_1=F_2=1$ and $F_{n+1}=F_n+F_{n-1}$. We show by induction that\n\\[\nx_n = \\cos(F_n b) \\qquad (n \\geq 0).\n\\]\nIndeed, this is true for $n=0,1,2$; given that it is true for $n \\leq m$, then\n\\begin{align*}\n2x_mx_{m-1}&=2\\cos(F_mb)\\cos(F_{m-1}b) \\\\\n&= \\cos((F_m-F_{m-1})b)+\\cos((F_m+F_{m-1})b) \\\\\n&= \\cos(F_{m-2}b)+\\cos(F_{m+1}b)\n\\end{align*}\nand so \n$x_{m+1} = 2x_mx_{m-1}-x_{m-2} = \\cos(F_{m+1}b)$. This completes the induction.\n\n\nSince $x_n = \\cos(F_n b)$, if $x_n=0$ for some $n$ then $F_n b = \\frac{k}{2} \\pi$ for some odd integer $k$. In particular, we can write $b = \\frac{c}{d}(2\\pi)$ where $c = k$ and $d = 4F_n$ are integers.\n\n\nLet $x_n$ denote the pair $(F_n,F_{n+1})$, where each entry in this pair is viewed as an element of $\\mathbb{Z}/d\\mathbb{Z}$. Since there are only finitely many possibilities for $x_n$, there must be some $n_2>n_1$ such that $x_{n_1}=x_{n_2}$. Now $x_n$ uniquely determines both $x_{n+1}$ and $x_{n-1}$, and it follows that the sequence $\\{x_n\\}$ is periodic: for $\\ell = n_2-n_1$, $x_{n+\\ell} = x_n$ for all $n \\geq 0$. In particular, $F_{n+\\ell} \\equiv F_n \\pmod{d}$ for all $n$. But then $\\frac{F_{n+\\ell}c}{d}-\\frac{F_n c}{d}$ is an integer, and so\n\\begin{align*}\nx_{n+\\ell} &= \\cos\\left(\\frac{F_{n+\\ell}c}{d}(2\\pi)\\right)\\\\\n& = \\cos\\left(\\frac{F_n c}{d}(2\\pi)\\right) = x_n\n\\end{align*}\nfor all $n$. Thus the sequence $\\{x_n\\}$ is periodic, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2017_b3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2017_b3 (f : ℝ → ℝ) (c : ℕ → ℝ)\n (hf : f = λ x => (∑' (i : ℕ), (c i) * x^i))\n (hc : ∀ n, c n = 0 ∨ c n = 1)\n (hf1 : f (2/3) = 3/2) :\n Irrational (f (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f(x)=\\sum_{i=0}^{\\infty} c_{i} x^{i}$ is a power series for which each coefficient $c_{i}$ is 0 or 1 . Show that if $f(2 / 3)=3 / 2$, then $f(1 / 2)$ must be irrational.\n\\begin{proof}\n Suppose by way of contradiction that $f(1/2)$ is rational. Then $\\sum_{i=0}^{\\infty} c_i 2^{-i}$ is the binary expansion of a rational number, and hence must be eventually periodic; that is, there exist some integers $m,n$ such that\n$c_i = c_{m+i}$ for all $i \\geq n$. We may then write\n\\[\nf(x) = \\sum_{i=0}^{n-1} c_i x^i + \\frac{x^n}{1-x^m} \\sum_{i=0}^{m-1} c_{n+i} x^i.\n\\]\nEvaluating at $x = 2/3$, we may equate $f(2/3) = 3/2$ with \n\\[\n\\frac{1}{3^{n-1}} \\sum_{i=0}^{n-1} c_i 2^i 3^{n-i-1} + \\frac{2^n 3^m}{3^{n+m-1}(3^m-2^m)} \\sum_{i=0}^{m-1} c_{n+i} 2^i 3^{m-1-i};\n\\]\nsince all terms on the right-hand side have odd denominator, the same must be true of the sum, a contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2014_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2014_a5 (P : ℕ → Polynomial ℤ)\n (hP : ∀ n, P n = ∑ i : Fin n, (n+1) * Polynomial.X ^ n) :\n ∀ (j k : ℕ), j ≠ k → IsCoprime (P j) (P k) := sorry", "formal_proof": null, "informal_stmt": "Let\n$P_n(x)=1+2 x+3 x^2+\\cdots+n x^{n-1} .$ Prove that the polynomials $P_j(x)$ and $P_k(x)$ are relatively prime for all positive integers $j$ and $k$ with $j \\neq k$.\n\\begin{proof}\n Suppose to the contrary that there exist positive integers $i \\neq j$ and a complex number $z$ such that $P_i(z) = P_j(z) = 0$. Note that $z$ cannot be a nonnegative real number or else $P_i(z), P_j(z) > 0$; we may put $w = z^{-1} \\neq 0,1$. For $n \\in \\{i+1,j+1\\}$ we compute that\n\\[\nw^n = n w - n + 1,\n\\qquad \\overline{w}^n = n \\overline{w} - n + 1;\n\\]\nnote crucially that these equations also hold for $n \\in \\{0,1\\}$.\nTherefore, the function $f: [0, +\\infty) \\to \\mathbb{R}$ given by\n\\[\nf(t) = \\left| w \\right|^{2t} - t^2 \\left| w \\right|^2 + 2t(t-1)\\mathrm{Re}(w) - (t-1)^2\n\\]\nsatisfies $f(t) = 0$ for $t \\in \\{0,1,i+1,j+1\\}$. On the other hand, for all $t \\geq 0$ we have\n\\[\nf'''(t) = (2 \\log \\left| w \\right|)^3 \\left| w \\right|^{2t} > 0,\n\\]\nso by Rolle's theorem, the equation $f^{(3-k)}(t) = 0$ has at most $k$ distinct solutions for $k=0,1,2,3$. This yields the desired contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2010_a4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2010_a4 (n : ℕ) :\n ¬ Nat.Prime (10^10^10^n + 10^10^n + 10^n - 1) := sorry", "formal_proof": null, "informal_stmt": "Prove that for each positive integer $n$, the number $10^{10^{10^n}}+10^{10^n}+10^n-1$ is not prime.\n\\begin{proof}\n Put\n\\[\nN = 10^{10^{10^n}} + 10^{10^n} + 10^n - 1.\n\\]\nWrite $n = 2^m k$ with $m$ a nonnegative integer and $k$ a positive odd integer.\nFor any nonnegative integer $j$,\n\\[\n10^{2^m j} \\equiv (-1)^j \\pmod{10^{2^m} + 1}.\n\\]\nSince $10^n \\geq n \\geq 2^m \\geq m+1$, $10^n$ is divisible by $2^n$ and hence by $2^{m+1}$,\nand similarly $10^{10^n}$ is divisible by $2^{10^n}$ and hence by $2^{m+1}$. It follows that\n\\[\nN \\equiv 1 + 1 + (-1) + (-1) \\equiv 0 \\pmod{10^{2^m} + 1}.\n\\]\nSince $N \\geq 10^{10^n} > 10^n + 1 \\geq 10^{2^m} + 1$, it follows that $N$ is composite.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2001_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2001_a5 :\n ∃! a : ℕ × ℕ, a.1 > 0 ∧ a.2 > 0 ∧ a.1^(a.2+1) - (a.1+1)^a.2 = 2001 := sorry", "formal_proof": null, "informal_stmt": "Prove that there are unique positive integers $a, n$ such that $a^{n+1}-(a+1)^n=2001$.\n\\begin{proof}\n Suppose $a^{n+1} - (a+1)^n = 2001$.\nNotice that $a^{n+1} + [(a+1)^n - 1]$ is a multiple of $a$; thus\n$a$ divides $2002 = 2 \\times 7 \\times 11 \\times 13$.\n\nSince $2001$ is divisible by 3, we must have $a \\equiv 1 \\pmod{3}$,\notherwise one of $a^{n+1}$ and $(a+1)^n$ is a multiple of 3 and the\nother is not, so their difference cannot be divisible by 3. Now\n$a^{n+1} \\equiv 1 \\pmod{3}$, so we must have $(a+1)^n \\equiv 1\n\\pmod{3}$, which forces $n$ to be even, and in particular at least 2.\n\nIf $a$ is even, then $a^{n+1} - (a+1)^n \\equiv -(a+1)^n \\pmod{4}$.\nSince $n$ is even, $-(a+1)^n \\equiv -1 \\pmod{4}$. Since $2001 \\equiv 1\n\\pmod{4}$, this is impossible. Thus $a$ is odd, and so must divide\n$1001 = 7 \\times 11 \\times 13$. Moreover, $a^{n+1} - (a+1)^n \\equiv a\n\\pmod{4}$, so $a \\equiv 1 \\pmod{4}$.\n\nOf the divisors of $7 \\times 11 \\times 13$, those congruent to 1 mod 3\nare precisely those not divisible by 11 (since 7 and 13 are both\ncongruent to 1 mod 3). Thus $a$ divides $7 \\times 13$. Now\n$a \\equiv 1 \\pmod{4}$ is only possible if $a$ divides $13$.\n\nWe cannot have $a=1$, since $1 - 2^n \\neq 2001$ for any $n$. Thus\nthe only possibility is $a = 13$. One easily checks that $a=13, n=2$ is a\nsolution; all that remains is to check that no other $n$ works. In fact,\nif $n > 2$, then $13^{n+1} \\equiv 2001 \\equiv 1 \\pmod{8}$.\nBut $13^{n+1} \\equiv 13 \\pmod{8}$ since $n$ is even, contradiction.\nThus $a=13, n=2$ is the unique solution.\n\nNote: once one has that $n$ is even, one can use that $2002\n=a^{n+1} + 1 - (a+1)^n$ is divisible by $a+1$ to rule out cases.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2000_a2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2000_a2 :\n ∀ N : ℕ, ∃ n : ℕ, n > N ∧ ∃ i : Fin 6 → ℕ, n = (i 0)^2 + (i 1)^2 ∧\n n + 1 = (i 2)^2 + (i 3)^2 ∧ n + 2 = (i 4)^2 + (i 5)^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that there exist infinitely many integers $n$ such that $n, n+1, n+2$ are each the sum of the squares of two integers. \n\\begin{proof}\n It is well-known that the equation $x^2-2y^2=1$ has infinitely\nmany solutions (the so-called ``Pell'' equation). Thus setting\n$n=2y^2$ (so that $n=y^2+y^2$, $n+1=x^2+0^2$, $n+2=x^2+1^2$)\nyields infinitely many $n$ with the desired property.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_1999_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1999_b4 (f : ℝ → ℝ) (hf: ContDiff ℝ 3 f)\n (hf1 : ∀ n ≤ 3, ∀ x : ℝ, iteratedDeriv n f x > 0)\n (hf2 : ∀ x : ℝ, iteratedDeriv 3 f x ≤ f x) :\n ∀ x : ℝ, deriv f x < 2 * f x := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function with a continuous third derivative such that $f(x), f^{\\prime}(x), f^{\\prime \\prime}(x), f^{\\prime \\prime \\prime}(x)$ are positive for all $x$. Suppose that $f^{\\prime \\prime \\prime}(x) \\leq f(x)$ for all $x$. Show that $f^{\\prime}(x)<2 f(x)$ for all $x$.\n\\begin{proof} \n\\setcounter{equation}{0}\nWe make repeated use of the following fact: if $f$ is a differentiable function on all of\n$\\mathbb{R}$, $\\lim_{x \\to -\\infty} f(x) \\geq 0$, and $f'(x) > 0$ for all $x \\in \\mathbb{R}$, then\n$f(x) > 0$ for all $x \\in \\mathbb{R}$. (Proof: if $f(y) < 0$ for some $x$, then $f(x)< f(y)$ for all\n$x0$, but then $\\lim_{x \\to -\\infty} f(x) \\leq f(y) < 0$.)\n\nFrom the inequality $f'''(x) \\leq f(x)$ we obtain\n\\[\nf'' f'''(x) \\leq f''(x) f(x) < f''(x) f(x) + f'(x)^2\n\\]\nsince $f'(x)$ is positive. Applying the fact to the difference between the right and left sides,\nwe get\n\\begin{equation}\n\\frac{1}{2} (f''(x))^2 < f(x) f'(x).\n\\end{equation}\n\nOn the other hand, since $f(x)$ and $f'''(x)$ are both positive for all $x$,\nwe have\n\\[\n2f'(x) f''(x) < 2f'(x)f''(x) + 2f(x) f'''(x).\n\\]\nApplying the fact to the difference between the sides yields\n\\begin{equation}\nf'(x)^2 \\leq 2f(x) f''(x).\n\\end{equation}\nCombining (1) and (2), we obtain\n\\begin{align*}\n\\frac{1}{2} \\left( \\frac{f'(x)^2}{2f(x)} \\right)^2\n&< \\frac{1}{2} (f''(x))^2 \\\\\n&< f(x) f'(x),\n\\end{align*}\nor $(f'(x))^3 < 8 f(x)^3$. We conclude $f'(x) < 2f(x)$, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_1998_a3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_a3 (f : ℝ → ℝ) (hf : ContDiff ℝ 3 f) :\n ∃ a : ℝ, (f a) * (deriv f a) * (iteratedDeriv 2 f a) * (iteratedDeriv 3 f a) ≥ 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function on the real line with continuous third derivative. Prove that there exists a point $a$ such that\n$f(a) \\cdot f^{\\prime}(a) \\cdot f^{\\prime \\prime}(a) \\cdot f^{\\prime \\prime \\prime}(a) \\geq 0$. \n\\begin{proof}\n If at least one of $f(a)$, $f'(a)$, $f''(a)$, or $f'''(a)$ vanishes\nat some point $a$, then we are done. Hence we may assume each of\n$f(x)$, $f'(x)$, $f''(x)$, and $f'''(x)$ is either strictly positive\nor strictly negative on the real line. By replacing $f(x)$ by $-f(x)$\nif necessary, we may assume $f''(x)>0$; by replacing $f(x)$\nby $f(-x)$ if necessary, we may assume $f'''(x)>0$. (Notice that these\nsubstitutions do not change the sign of $f(x) f'(x) f''(x) f'''(x)$.)\nNow $f''(x)>0$ implies that $f'(x)$ is increasing, and $f'''(x)>0$\nimplies that $f'(x)$ is convex, so that $f'(x+a)>f'(x)+a f''(x)$\nfor all $x$ and $a$. By\nletting $a$ increase in the latter inequality, we see that $f'(x+a)$\nmust be positive for sufficiently large $a$; it follows that\n$f'(x)>0$\nfor all $x$. Similarly, $f'(x)>0$ and $f''(x)>0$ imply\nthat $f(x)>0$ for all $x$. Therefore $f(x) f'(x) f''(x) f'''(x)>0$ for\nall $x$, and we are done.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_1998_b6", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_b6 (a b c : ℤ) :\n ∃ n : ℤ, n > 0 ∧ ¬ ∃ m : ℤ, Real.sqrt (n^3 + a*n^2 + b*n + c) = m := sorry", "formal_proof": null, "informal_stmt": "Prove that, for any integers $a, b, c$, there exists a positive integer $n$ such that $\\sqrt{n^3+a n^2+b n+c}$ is not an integer.\n\\begin{proof}\n We prove more generally that for any polynomial $P(z)$ with integer\ncoefficients which is not a perfect square, there exists a positive\ninteger $n$ such that $P(n)$ is not a perfect square. Of course it\nsuffices to assume $P(z)$ has no repeated factors, which is to say $P(z)$\nand its derivative $P'(z)$ are relatively prime.\n\nIn particular, if we carry out the Euclidean algorithm on $P(z)$ and $P'(z)$\nwithout dividing, we get an integer $D$ (the discriminant of $P$) such that\nthe greatest common divisor of $P(n)$ and $P'(n)$ divides $D$ for any $n$.\nNow there exist infinitely many primes $p$ such that $p$ divides $P(n)$ for\nsome $n$: if there were only finitely many, say, $p_1, \\dots, p_k$, then\nfor any $n$ divisible by $m = P(0) p_1 p_2 \\cdots p_k$, we have $P(n)\n\\equiv P(0) \\pmod{m}$, that is, $P(n)/P(0)$ is not divisible by $p_1,\n\\dots, p_k$, so must be $\\pm 1$, but then $P$ takes some value infinitely\nmany times, contradiction. In particular, we can choose some such $p$ not\ndividing $D$, and choose $n$ such that $p$ divides $P(n)$. Then $P(n+kp)\n\\equiv P(n) + kp P'(n) (\\mathrm{mod}\\,p)$\n(write out the Taylor series of the left side);\nin particular, since $p$ does not divide $P'(n)$, we can find some $k$\nsuch that $P(n+kp)$ is divisible by $p$ but not by $p^2$, and so\nis not a perfect square.\n\\end{proof}\n\n\n\n\n\\end{document}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Artin_exercise_2_2_9", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_2_9 {G : Type*} [Group G] {a b : G}\n (h : a * b = b * a) :\n ∀ x y : closure {x | x = a ∨ x = b}, x*y = y*x := sorry", "formal_proof": null, "informal_stmt": "Let $H$ be the subgroup generated by two elements $a, b$ of a group $G$. Prove that if $a b=b a$, then $H$ is an abelian group.\n\\begin{proof}\n Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_3_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_3_2 {G : Type*} [Group G] (a b : G) :\n ∃ g : G, b* a = g * a * b * g⁻¹ := sorry", "formal_proof": null, "informal_stmt": "Prove that the products $a b$ and $b a$ are conjugate elements in a group.\n\\begin{proof}\n We have that $(a^{-1})ab(a^{-1})^{-1} = ba$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_4_19", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_4_19 {G : Type*} [Group G] {x : G}\n (hx : orderOf x = 2) (hx1 : ∀ y, orderOf y = 2 → y = x) :\n x ∈ center G := sorry", "formal_proof": null, "informal_stmt": "Prove that if a group contains exactly one element of order 2 , then that element is in the center of the group.\n\\begin{proof}\n Let $x$ be the element of order two. Consider the element $z=y^{-1} x y$, we have: $z^2=\\left(y^{-1} x y\\right)^2=\\left(y^{-1} x y\\right)\\left(y^{-1} x y\\right)=e$. So: $z=x$, and $y^{-1} x y=x$. So: $x y=y x$. So: $x$ is in the center of $G$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_8_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Artin_exercise_2_8_6 {G H : Type*} [Group G] [Group H] :\n center (G × H) ≃* (center G) × (center H) := sorry", "formal_proof": null, "informal_stmt": "Prove that the center of the product of two groups is the product of their centers.\n\\begin{proof}\n We have that $(g_1, g_2)\\cdot (h_1, h_2) = (h_1, h_2)\\cdot (g_1, g_2)$ if and only if $g_1h_1 = h_1g_1$ and $g_2h_2 = h_2g_2$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_11_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_11_3 {G : Type*} [Group G] [Fintype G]\n (hG : Even (card G)) : ∃ x : G, orderOf x = 2 := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of even order contains an element of order $2 .$\n\\begin{proof}\n Pair up if possible each element of $G$ with its inverse, and observe that\n$$\ng^2 \\neq e \\Longleftrightarrow g \\neq g^{-1} \\Longleftrightarrow \\text { there exists the pair }\\left(g, g^{-1}\\right)\n$$\nNow, there is one element that has no pairing: the unit $e$ (since indeed $e=e^{-1} \\Longleftrightarrow e^2=e$ ), so since the number of elements of $G$ is even there must be at least one element more, say $e \\neq a \\in G$, without a pairing, and thus $a=a^{-1} \\Longleftrightarrow a^2=e$\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_2_7", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_2_7 {F : Type*} [Field F] {G : Type*} [Field G]\n (φ : F →+* G) : Injective φ := sorry", "formal_proof": null, "informal_stmt": "Prove that every homomorphism of fields is injective.\n\\begin{proof}\n Suppose $f(a)=f(b)$, then $f(a-b)=0=f(0)$. If $u=(a-b) \\neq 0$, then $f(u) f\\left(u^{-1}\\right)=f(1)=1$, but that means that $0 f\\left(u^{-1}\\right)=1$, which is impossible. Hence $a-b=0$ and $a=b$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_5_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_5_6 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {S : Set V} (hS : Set.Countable S)\n (hS1 : span K S = ⊤) {ι : Type*} (R : ι → V)\n (hR : LinearIndependent K R) : Countable ι := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space which is spanned by a countably infinite set. Prove that every linearly independent subset of $V$ is finite or countably infinite.\n\\begin{proof}\n Let $A$ be the countable generating set, and let $U$ be an uncountable linearly independent set. It can be extended to a basis $B$ of the whole space. Now consider the subset $C$ of elements of $B$ that appear in the $B$-decompositions of elements of $A$.\nSince only finitely many elements are involved in the decomposition of each element of $A$, the set $C$ is countable. But $C$ also clearly generates the vector space $V$. This contradicts the fact that it is a proper subset of the basis $B$ (since $B$ is uncountable).\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_7_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_7_2 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {ι : Type*} [Fintype ι] (γ : ι → Submodule K V)\n (h : ∀ i : ι, γ i ≠ ⊤) :\n (⋂ (i : ι), (γ i : Set V)) ≠ ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space over an infinite field $F$. Prove that $V$ is not the union of finitely many proper subspaces.\n\\begin{proof}\n If $V$ is the set-theoretic union of $n$ proper subspaces $W_i$ ( $1 \\leq i \\leq n$ ), then $|F| \\leq n-1$.\nProof. We may suppose no $W_i$ is contained in the union of the other subspaces. Let $u \\in W_i, \\quad u \\notin \\bigcup_{j \\neq i} W_j$ and $v \\notin W_i$.\nThen $(v+F u) \\cap W_i=\\varnothing$ and $(v+F u) \\cap W_j(j \\neq i)$ contains at most one vector since otherwise $W_j$ would contain $u$. Hence\n$$\n|v+F u|=|F| \\leq n-1 .\n$$\nCorollary: Avoidance lemma for vector spaces.\nLet $E$ be a vector space over an infinite field. If a subspace is contained in a finite union of subspaces, it is contained in one of them.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_1_14", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_1_14 (G : Type*) [Group G]\n (hG : IsCyclic $ G ⧸ (center G)) :\n center G = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $Z$ be the center of a group $G$. Prove that if $G / Z$ is a cyclic group, then $G$ is abelian and hence $G=Z$.\n\\begin{proof}\n We have that $G / Z(G)$ is cyclic, and so there is an element $x \\in G$ such that $G / Z(G)=\\langle x Z(G)\\rangle$, where $x Z(G)$ is the coset with representative $x$. Now let $g \\in G$\nWe know that $g Z(G)=(x Z(G))^m$ for some $m$, and by definition $(x Z(G))^m=x^m Z(G)$.\nNow, in general, if $H \\leq G$, we have by definition too that $a H=b H$ if and only if $b^{-1} a \\in H$.\nIn our case, we have that $g Z(G)=x^m Z(G)$, and this happens if and only if $\\left(x^m\\right)^{-1} g \\in Z(G)$.\nThen, there's a $z \\in Z(G)$ such that $\\left(x^m\\right)^{-1} g=z$, and so $g=x^m z$.\n\n$g, h \\in G$ implies that $g=x^{a_1} z_1$ and $h=x^{a_2} z_2$, so\n$$\n\\begin{aligned}\ng h & =\\left(x^{a_1} z_1\\right)\\left(x^{a_2} z_2\\right) \\\\\n& =x^{a_1} x^{a_2} z_1 z_2 \\\\\n& =x^{a_1+a_2} z_2 z_1 \\\\\n& =\\ldots=\\left(x^{a_2} z_2\\right)\\left(x^{a_1} z_1\\right)=h g .\n\\end{aligned}\n$$\nTherefore, $G$ is abelian.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_4_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_2 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p*q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n If $|G|=n=p q$ then the only two Sylow subgroups are of order $p$ and $q$.\nFrom Sylow's third theorem we know that $n_p \\mid q$ which means that $n_p=1$ or $n_p=q$.\nIf $n_p=1$ then we are done (by a corollary of Sylow's theorem)\nIf $n_p=q$ then we have accounted for $q(p-1)=p q-q$ elements of $G$ and so there is only one group of order $q$ and again we are done.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_4_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_3 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p^2 *q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p^2 q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n We may as well assume $p0$ and $b^2>0$, so $-a^2-b^2<0$. Furthermore, it is an integer. Thus, we have found a nonzero integer in $I$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_10_4_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_4_6 {R : Type*} [CommRing R]\n [NoZeroDivisors R] (I J : Ideal R) (x : ↑(I ⊓ J)) :\n IsNilpotent ((Ideal.Quotient.mk (I*J)) x) := sorry", "formal_proof": null, "informal_stmt": "Let $I, J$ be ideals in a ring $R$. Prove that the residue of any element of $I \\cap J$ in $R / I J$ is nilpotent.\n\\begin{proof}\n If $x$ is in $I \\cap J, x \\in I$ and $x \\in J . R / I J=\\{r+a b: a \\in I, b \\in J, r \\in R\\}$. Then $x \\in I \\cap J \\Rightarrow x \\in I$ and $x \\in J$, and so $x^2 \\in I J$. Thus\n$$\n[x]^2=\\left[x^2\\right]=[0] \\text { in } R / I J\n$$\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_10_4_7a", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_4_7a {R : Type*} [CommRing R] [NoZeroDivisors R]\n (I J : Ideal R) (hIJ : I + J = ⊤) : I * J = I ⊓ J := sorry", "formal_proof": null, "informal_stmt": "Let $I, J$ be ideals of a ring $R$ such that $I+J=R$. Prove that $I J=I \\cap J$.\n\\begin{proof}\n We have seen that $IJ \\subset I \\cap J$, so it remains to show that $I \\cap J \\subset IJ$. Since $I+J = (1)$, there are elements $i \\in I$ and $j \\in J$ such that $i+j = 1$. Let $k \\in I \\cap J$, and multiply $i+j=1$ through by $k$ to get $ki+kj = k$. Write this more suggestively as\n\\[ k = ik+kj. \\]\nThe first term is in $IJ$ because $k \\in J$, and the second term is in $IJ$ because $k \\in I$, so $k \\in IJ$ as desired.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_10_7_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_7_10 {R : Type*} [Ring R]\n (M : Ideal R) (hM : ∀ (x : R), x ∉ M → IsUnit x)\n (hProper : ∃ x : R, x ∉ M) :\n IsMaximal M ∧ ∀ (N : Ideal R), IsMaximal N → N = M := sorry", "formal_proof": null, "informal_stmt": "Let $R$ be a ring, with $M$ an ideal of $R$. Suppose that every element of $R$ which is not in $M$ is a unit of $R$. Prove that $M$ is a maximal ideal and that moreover it is the only maximal ideal of $R$.\n\\begin{proof}\nSuppose there is an ideal $M\\subset I\\subset R$. If $I\\neq M$, then $I$ contains a unit, thus $I=R$. Therefore $M$ is a maximal ideal. \n\nSuppose we have an arbitrary maximal ideal $M^\\prime$ of $R$. The ideal $M^\\prime$ cannot contain a unit, otherwise $M^\\prime =R$. Therefore $M^\\prime \\subset M$. But we cannot have $M^\\prime \\subsetneq M \\subsetneq R$, therefore $M=M^\\prime$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_2_13", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_2_13 (a b : ℤ) :\n (ofInt a : GaussianInt) ∣ ofInt b → a ∣ b := sorry", "formal_proof": null, "informal_stmt": "If $a, b$ are integers and if $a$ divides $b$ in the ring of Gauss integers, then $a$ divides $b$ in $\\mathbb{Z}$.\n\\begin{proof}\n Suppose $a|b$ in $\\mathbb{Z}[i]$ and $a,b\\in\\mathbb{Z}$. Then $a(x+yi)=b$ for $x,y\\in\\mathbb{Z}$. Expanding this we get $ax+ayi=b$, and equating imaginary parts gives us $ay=0$, implying $y=0$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_1b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_1b {F : Type*} [Field F] [Fintype F] (hF : card F = 2) :\n Irreducible (12 + 6 * X + X ^ 3 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 + 6x + 12$ is irreducible in $\\mathbb{Q}$.\n\\begin{proof}\n Apply Eisenstein's criterion with $p=3$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6a", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6a {F : Type*} [Field F] [Fintype F] (hF : card F = 7) :\n Irreducible (X ^ 2 + 1 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+x+1$ is irreducible in the field $\\mathbb{F}_2$.\n\\begin{proof}\n If $x^2+x+1$ were reducible in $\\mathbb{F}_2$, its factors must be linear. But we neither have that $0^2+0+1=$ nor $1^2+1+1=0$, therefore $x^2+x+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6b {F : Type*} [Field F] [Fintype F] (hF : card F = 31) :\n Irreducible (X ^ 3 - 9 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+1$ is irreducible in $\\mathbb{F}_7$\n\\begin{proof}\n If $p(x)=x^2+1$ were reducible, its factors must be linear. But no $p(a)$ for $a\\in\\mathbb{F}_7$ evaluates to 0, therefore $x^2+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6c", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6c : Irreducible (X^3 - 9 : Polynomial (ZMod 31)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 - 9$ is irreducible in $\\mathbb{F}_{31}$.\n\\begin{proof}\n If $p(x) = x^3-9$ were reducible, it would have a linear factor, since it either has a linear factor and a quadratic factor or three linear factors. We can then verify by brute force that $p(x)\\neq 0$ for $x \\in \\mathbb{F}_31$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_8", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_8 (p : ℕ) (hp : Prime p) (n : ℕ) :\n -- p ∈ ℕ can be written as p ∈ ℚ[X]\n Irreducible (X ^ n - (p : Polynomial ℚ) : Polynomial ℚ) := sorry", "formal_proof": null, "informal_stmt": "Let $p$ be a prime integer. Prove that the polynomial $x^n-p$ is irreducible in $\\mathbb{Q}[x]$.\n\\begin{proof}\n Straightforward application of Eisenstein's criterion with $p$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_13_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_13_3 (N : ℕ):\n ∃ p ≥ N, Nat.Prime p ∧ p + 1 ≡ 0 [MOD 4] := sorry", "formal_proof": null, "informal_stmt": "Prove that there are infinitely many primes congruent to $-1$ (modulo $4$).\n\\begin{proof}\n First we show a lemma: if $a \\equiv 3(\\bmod 4)$ then there exists a prime $p$ such that $p \\mid a$ and $p \\equiv 3(\\bmod 4)$.\n\n Clearly, all primes dividing $a$ are odd. Suppose all of them would be $\\equiv 1(\\bmod 4)$. Then their product would also be $a \\equiv 1(\\bmod 4)$, which is a contradiction.\n\nTo prove the main claim, suppose that $p_1, \\ldots, p_n$ would be all such primes. (In particular, we have $p_1=3$.) Consider $a=4 p_2 \\cdots p_n+3$. (Or you can take $a=4 p_2 \\cdots p_n-1$.) Show that $p_i \\nmid a$ for $i=1, \\ldots, n$. (The case $3 \\nmid a$ is solved differently than the other primes - this is the reason for omitting $p_1$ in the definition of $a$.) Then use the above lemma to get a contradiction.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_13_4_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_4_10\n {p : ℕ} {hp : Nat.Prime p} (h : ∃ r : ℕ, p = 2 ^ r + 1) :\n ∃ (k : ℕ), p = 2 ^ (2 ^ k) + 1 := sorry", "formal_proof": null, "informal_stmt": "Prove that if a prime integer $p$ has the form $2^r+1$, then it actually has the form $2^{2^k}+1$.\n\\begin{proof}\n In particular, we have\n$$\n\\frac{x^a+1}{x+1}=\\frac{(-x)^a-1}{(-x)-1}=1-x+x^2-\\cdots+(-x)^{a-1}\n$$\nby the geometric sum formula. In this case, specialize to $x=2^{2^m}$ and we have a nontrivial divisor.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_13_6_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_6_10 {K : Type*} [Field K] [Fintype Kˣ] :\n (∏ x : Kˣ, x) = -1 := sorry", "formal_proof": null, "informal_stmt": "Let $K$ be a finite field. Prove that the product of the nonzero elements of $K$ is $-1$.\n\\begin{proof}\n Since we are working with a finite field with $q$ elements, anyone of them is a root of the following polynomial\n$$\nx^q-x=0 .\n$$\nIn particular if we rule out the 0 element, any $a_i \\neq 0$ is a root of\n$$\nx^{q-1}-1=0 .\n$$\nThis polynomial splits completely in $\\mathbb{F}_q$ so we find\n$$\n\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)=0\n$$\nin particular\n$$\nx^{q-1}-1=\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)\n$$\nThus $a_1 \\cdots a_{q-1}=-1$.\n\\end{proof}\n\\end{document}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Ireland_Rosen_exercise_1_27", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_1_27 {n : ℕ} (hn : Odd n) : 8 ∣ (n^2 - 1) := sorry", "formal_proof": null, "informal_stmt": "For all odd $n$ show that $8 \\mid n^{2}-1$.\n\\begin{proof}\n We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 .\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_1_30", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_1_30 {n : ℕ} :\n ¬ ∃ a : ℤ, ∑ i : Fin n, (1 : ℚ) / (n+2) = a := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\frac{1}{2}+\\frac{1}{3}+\\cdots+\\frac{1}{n}$ is not an integer.\n\\begin{proof}\nLet $2^s$ be the largest power of 2 occurring as a denominator in $H_n$, say $2^s=k \\leqslant n$. Write $H_n=$ $\\frac{1}{2^s}+\\left(1+1 / 2+\\ldots+1 /(k-1)+1 /(k+1)+\\ldots+1 / n\\right.$. The sum in parentheses can be written as $1 / 2^{s-1}$ times sum of fractions with odd denominators, so the denominator of the sum in parentheses will not be divisible by $2^s$, but it must equal $2^s$ by Ex $1.29$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_1_31", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_1_31 : (⟨1, 1⟩ : GaussianInt) ^ 2 ∣ 2 := sorry", "formal_proof": null, "informal_stmt": "Show that 2 is divisible by $(1+i)^{2}$ in $\\mathbb{Z}[i]$.\n\\begin{proof}\nWe have $(1+i)^2=1+2 i-1=2 i$, so $2=-i(1+i)^2$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_2_4", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_2_4 {a : ℤ} (ha : a ≠ 0)\n (f_a := sorry", "formal_proof": null, "informal_stmt": "If $a$ is a nonzero integer, then for $n>m$ show that $\\left(a^{2^{n}}+1, a^{2^{m}}+1\\right)=1$ or 2 depending on whether $a$ is odd or even.\n\\begin{proof} \n\\begin{align*}\n\\operatorname{ord}_p\\, n! &= \\sum_{k\\geq 1} \\left \\lfloor \\frac{n}{p^{k}}\\right \\rfloor \\leq \\sum_{k\\geq 1} \\frac{n}{p^{k}} = \\frac{n}{p} \\frac{1}{1 - \\frac{1}{p}} = \\frac{n}{p-1}\n\\end{align*}\n\nThe decomposition of $n!$ in prime factors is\n\n$n! = p_1^{\\alpha_1}p_2^{\\alpha_2}\\cdots p_k^{\\alpha_k}$ \nwhere $\\alpha_i = \\operatorname{ord}_{p_i}\\, n! \\leq \\frac{n}{p_i-1}$, and $p_i \\leq n, \\ i=1,2,\\cdots,k$.\n\nThen\n\\begin{align*}\nn! &\\leq p_1^{\\frac{n}{p_1-1}}p_2^{\\frac{n}{p_2-1}}\\cdots p_k^{\\frac{n}{p_n-1}}\\\\\n\\sqrt[n]{n!} &\\leq p_1^{\\frac{1}{p_1-1}}p_2^{\\frac{1}{p_2-1}}\\cdots p_k^{\\frac{1}{p_n-1}}\\\\\n&\\leq \\prod_{p\\leq n} p^{\\frac{1}{p-1}}\n\\end{align*}\n(the values of $p$ in this product describe all prime numbers $p\\leq n$.)\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_2_21", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_2_21 {l : ℕ → ℝ}\n (hl : ∀ p n : ℕ, p.Prime → l (p^n) = log p )\n (hl1 : ∀ m : ℕ, ¬ IsPrimePow m → l m = 0) :\n l = λ n => ∑ d : Nat.divisors n, ArithmeticFunction.moebius (n/d) * log d := sorry", "formal_proof": null, "informal_stmt": "Define $\\wedge(n)=\\log p$ if $n$ is a power of $p$ and zero otherwise. Prove that $\\sum_{A \\mid n} \\mu(n / d) \\log d$ $=\\wedge(n)$.\n\\begin{proof} \n$$\n\\left\\{\n\\begin{array}{cccl}\n \\land(n)& = & \\log p & \\mathrm{if}\\ n =p^\\alpha,\\ \\alpha \\in \\mathbb{N}^* \\\\\n & = & 0 & \\mathrm{otherwise }.\n\\end{array}\n\\right.\n$$\nLet $n = p_1^{\\alpha_1}\\cdots p_t^{\\alpha_t}$ the decomposition of $n$ in prime factors. As $\\land(d) = 0$ for all divisors of $n$, except for $d = p_j^i, i>0, j=1,\\ldots t$,\n\\begin{align*}\n\\sum_{d \\mid n} \\land(d)&= \\sum_{i=1}^{\\alpha_1} \\land(p_1^{i}) + \\cdots+ \\sum_{i=1}^{\\alpha_t} \\land(p_t^{i})\\\\ \n&= \\alpha_1 \\log p_1+\\cdots + \\alpha_t \\log p_t\\\\\n&= \\log n\n\\end{align*}\nBy Mobius Inversion Theorem,\n$$\\land(n) = \\sum_{d \\mid n} \\mu\\left (\\frac{n}{d}\\right ) \\log d.$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_2_27a", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_2_27a :\n ¬ Summable (λ i : {p : ℤ // Squarefree p} => (1 : ℚ) / i) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\sum^{\\prime} 1 / n$, the sum being over square free integers, diverges.\n\\begin{proof}\n \nLet $S \\subset \\mathbb{N}^*$ the set of square free integers.\n\nLet $N \\in \\mathbb{N}^*$. Every integer $n, \\, 1\\leq n \\leq N$ can be written as $n = a b^2$, where $a,b$ are integers and $a$ is square free. Then $1\\leq a \\leq N$, and $1\\leq b \\leq \\sqrt{N}$, so\n$$\\sum_{n\\leq N} \\frac{1}{n} \\leq \\sum_{a \\in S, a\\leq N}\\ \\sum_{1\\leq b \\leq \\sqrt{N}} \\frac{1}{ab^2} \\leq \\sum_{a \\in S, a\\leq N}\\ \\frac{1}{a} \\, \\sum_{b=1}^\\infty \\frac{1}{b^2} = \\frac{\\pi^2}{6} \\sum_{a \\in S, a\\leq N}\\ \\frac{1}{a}.$$\nSo $$\\sum_{a \\in S, a\\leq N} \\frac{1}{a} \\geq \\frac{6}{\\pi^2} \\sum_{n\\leq N} \\frac{1}{n}.$$\nAs $\\sum_{n=1}^\\infty \\frac{1}{n}$ diverges, $\\lim\\limits_{N \\to \\infty} \\sum\\limits_{a \\in S, a\\leq N} \\frac{1}{a} = +\\infty$, so the family $\\left(\\frac{1}{a}\\right)_{a\\in S}$ of the inverse of square free integers is not summable.\n\nLet $S_N = \\prod_{p0$, so\n$$\\log S_N = \\sum_{k=1}^{l(N)} \\log\\left(1+\\frac{1}{p_k}\\right) \\leq \\sum_{k=1}^{l(N)} \\frac{1}{p_k}.$$\n$\\lim\\limits_{N\\to \\infty} \\log S_N = +\\infty$ and $\\lim\\limits_{N\\to \\infty} l(N) = +\\infty$, so\n$$\\lim_{N\\to \\infty} \\sum_{p1$. \n\nThen $N \\equiv -1 \\pmod 6$. As $6k +2, 6k +3, 6k +4$ are composite for all integers $k$, every prime factor of $N$ is congruent to $1$ or $-1$ modulo $6$. If every prime factor of $N$ was congruent to 1, then $N \\equiv 1 \\pmod 6$ : this is a contradiction because $-1 \\not \\equiv 1 \\pmod 6$. So there exists a prime factor $p$ of $N$ such that $p\\equiv -1 \\pmod 6$.\n\nIf $p\\leq n$, then $p \\mid n!$, and $p \\mid N = n!-1$, so $p \\mid 1$. As $p$ is prime, this is a contradiction, so $p>n$. \n\nConclusion :\n\n for any integer $n$, there exists a prime $p >n$ such that $p \\equiv -1 \\pmod 6$ : there are infinitely many primes congruent to $-1$ modulo $6$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_3_4", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_3_4 : ¬ ∃ x y : ℤ, 3*x^2 + 2 = y^2 := sorry", "formal_proof": null, "informal_stmt": "Show that the equation $3 x^{2}+2=y^{2}$ has no solution in integers.\n\\begin{proof} \nIf $3x^2+2 = y^2$, then $\\overline{y}^2 = \\overline{2}$ in $\\mathbb{Z}/3\\mathbb{Z}$.\n\n\nAs $\\{-1,0,1\\}$ is a complete set of residues modulo $3$, the squares in $\\mathbb{Z}/3\\mathbb{Z}$ are $\\overline{0} = \\overline{0}^2$ and $\\overline{1} = \\overline{1}^2 = (\\overline{-1})^2$, so $\\overline{2}$ is not a square in $\\mathbb{Z}/3\\mathbb{Z}$ : $\\overline{y}^2 = \\overline{2}$ is impossible in $\\mathbb{Z}/3\\mathbb{Z}$.\n\nThus $3x^2+2 = y^2$ has no solution in integers.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_3_5", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_3_5 : ¬ ∃ x y : ℤ, 7*x^3 + 2 = y^3 := sorry", "formal_proof": null, "informal_stmt": "Show that the equation $7 x^{3}+2=y^{3}$ has no solution in integers.\n\\begin{proof}\n If $7x^2 + 2 = y^3,\\ x,y \\in \\mathbb{Z}$, then $y^3 \\equiv 2 \\pmod 7$ (so $y \\not \\equiv 0 \\pmod 7$)\n\nFrom Fermat's Little Theorem, $y^6 \\equiv 1 \\pmod 7$, so $2^2 \\equiv y^6 \\equiv 1 \\pmod 7$, which implies $7 \\mid 2^2-1 = 3$ : this is a contradiction. Thus the equation $7x^2 + 2 = y^3$ has no solution in integers.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_3_10", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_3_10 {n : ℕ} (hn0 : ¬ n.Prime) (hn1 : n ≠ 4) :\n Nat.factorial (n-1) ≡ 0 [MOD n] := sorry", "formal_proof": null, "informal_stmt": "If $n$ is not a prime, show that $(n-1) ! \\equiv 0(n)$, except when $n=4$.\n\\begin{proof} \nSuppose that $n >1$ is not a prime. Then $n = uv$, where $2 \\leq u \\leq v \\leq n-1$.\n\n$\\bullet$ If $u \\neq v$, then $n = uv \\mid (n-1)! = 1\\times 2 \\times\\cdots \\times u \\times\\cdots \\times v \\times \\cdots \\times (n-1)$ (even if $u\\wedge v \\neq 1$ !).\n\n$\\bullet$ If $u=v$, $n = u^2$ is a square.\n\nIf $u$ is not prime, $u =st,\\ 2\\leq s \\leq t \\leq u-1 \\leq n-1$, and $n = u' v'$, where $u' =s,v' =st^2$ verify $2 \\leq u' < v' \\leq n-1$. As in the first case, $n = u'v' \\mid (n-1)!$. \n\nIf $u = p$ is a prime, then $n =p^2$.\n\nIn the case $p = 2$, $n = 4$ and $n=4 \\nmid (n-1)! = 6$. In the other case $p >2$, and $(n-1)! = (p^2 - 1)!$ contains the factors $p < 2p < p^2$, so $p^2 \\mid (p^2-1)!, n \\mid (n-1)!$.\n\nConclusion : if $n$ is not a prime, $(n - 1)! \\equiv 0 \\pmod n$, except when $n=4$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_3_14", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_3_14 {p q n : ℕ} (hp0 : p.Prime ∧ p > 2)\n (hq0 : q.Prime ∧ q > 2) (hpq0 : p ≠ q) (hpq1 : p - 1 ∣ q - 1)\n (hn : n.gcd (p*q) = 1) :\n n^(q-1) ≡ 1 [MOD p*q] := sorry", "formal_proof": null, "informal_stmt": "Let $p$ and $q$ be distinct odd primes such that $p-1$ divides $q-1$. If $(n, p q)=1$, show that $n^{q-1} \\equiv 1(p q)$.\n\\begin{proof} \nAs $n \\wedge pq = 1, n\\wedge p=1, n \\wedge q = 1$, so from Fermat's Little Theorem\n$$n^{q-1} \\equiv 1 \\pmod q,\\qquad n^{p-1} \\equiv 1 \\pmod p.$$\n$p-1 \\mid q-1$, so there exists $k \\in \\mathbb{Z}$ such that $q-1 = k(p-1)$.\nThus\n$$n^{q-1} = (n^{p-1})^k \\equiv 1 \\pmod p.$$\n$p \\mid n^{q-1} - 1, q \\mid n^{q-1} - 1$, and $p\\wedge q = 1$, so $pq \\mid n^{q-1} - 1$ :\n$$n^{q-1} \\equiv 1 \\pmod{pq}.$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_4_4", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_4_4 {p t: ℕ} (hp0 : p.Prime) (hp1 : p = 4*t + 1)\n (a : ZMod p) :\n IsPrimitiveRoot a p ↔ IsPrimitiveRoot (-a) p := sorry", "formal_proof": null, "informal_stmt": "Consider a prime $p$ of the form $4 t+1$. Show that $a$ is a primitive root modulo $p$ iff $-a$ is a primitive root modulo $p$.\n\\begin{proof}\n Suppose that $a$ is a primitive root modulo $p$. As $p-1$ is even, $(-a)^{p-1}=a^{p-1} \\equiv 1$ $(\\bmod p)$\nIf $(-a)^n \\equiv 1(\\bmod p)$, with $n \\in \\mathbb{N}$, then $a^n \\equiv(-1)^n(\\bmod p)$.\nTherefore $a^{2 n} \\equiv 1(\\bmod p)$. As $a$ is a primitive root modulo $p, p-1|2 n, 2 t| n$, so $n$ is even.\n\nHence $a^n \\equiv 1(\\bmod p)$, and $p-1 \\mid n$. So the least $n \\in \\mathbb{N}^*$ such that $(-a)^n \\equiv 1$ $(\\bmod p)$ is $p-1:$ the order of $-a$ modulo $p$ is $p-1,-a$ is a primitive root modulo $p$. Conversely, if $-a$ is a primitive root modulo $p$, we apply the previous result at $-a$ to to obtain that $-(-a)=a$ is a primitive root.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_4_5", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_4_5 {p t : ℕ} (hp0 : p.Prime) (hp1 : p = 4*t + 3)\n (a : ZMod p) :\n IsPrimitiveRoot a p ↔ ((-a) ^ ((p-1)/2) = 1 ∧ ∀ (k : ℕ), k < (p-1)/2 → (-a)^k ≠ 1) := sorry", "formal_proof": null, "informal_stmt": "Consider a prime $p$ of the form $4 t+3$. Show that $a$ is a primitive root modulo $p$ iff $-a$ has order $(p-1) / 2$.\n\\begin{proof}\n Let $a$ a primitive root modulo $p$.\nAs $a^{p-1} \\equiv 1(\\bmod p), p \\mid\\left(a^{(p-1) / 2}-1\\right)\\left(a^{(p-1) / 2}+1\\right)$, so $p \\mid a^{(p-1) / 2}-1$ or $p \\mid$ $a^{(p-1) / 2}+1$. As $a$ is a primitive root modulo $p, a^{(p-1) / 2} \\not \\equiv 1(\\bmod p)$, so\n$$\na^{(p-1) / 2} \\equiv-1 \\quad(\\bmod p) .\n$$\nHence $(-a)^{(p-1) / 2}=(-1)^{2 t+1} a^{(p-1) / 2} \\equiv(-1) \\times(-1)=1(\\bmod p)$.\nSuppose that $(-a)^n \\equiv 1(\\bmod p)$, with $n \\in \\mathbb{N}$.\nThen $a^{2 n}=(-a)^{2 n} \\equiv 1(\\bmod p)$, so $p-1\\left|2 n, \\frac{p-1}{2}\\right| n$.\nSo $-a$ has order $(p-1) / 2$ modulo $p$.\nConversely, suppose that $-a$ has order $(p-1) / 2=2 t+1$ modulo $p$. Let $2, p_1, \\ldots p_k$ the prime factors of $p-1$, where $p_i$ are odd.\n$a^{(p-1) / 2}=a^{2 t+1}=-(-a)^{2 t+1}=-(-a)^{(p-1) / 2} \\equiv-1$, so $a^{(p-1) / 2} \\not \\equiv 1(\\bmod 2)$.\nAs $p-1$ is even, $(p-1) / p_i$ is even, so $a^{(p-1) / p_i}=(-a)^{(p-1) / p_i} \\not \\equiv 1(\\bmod p)($ since $-a$ has order $p-1)$.\nSo the order of $a$ is $p-1$ (see Ex. 4.8) : $a$ is a primitive root modulo $p$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_4_6", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_4_6 {p n : ℕ} (hp : p.Prime) (hpn : p = 2^n + 1) :\n IsPrimitiveRoot 3 p := sorry", "formal_proof": null, "informal_stmt": "If $p=2^{n}+1$ is a Fermat prime, show that 3 is a primitive root modulo $p$.\n\\begin{proof}\n \\newcommand{\\legendre}[2]{\\genfrac{(}{)}{}{}{#1}{#2}}\nWrite $p = 2^k + 1$, with $k = 2^n$.\n\nWe suppose that $n>0$, so $k\\geq 2, p \\geq 5$. As $p$ is prime, $3^{p-1} \\equiv 1 \\pmod p$. \n\nIn other words, $3^{2^k} \\equiv 1 \\pmod p$ : the order of $3$ is a divisor of $2^k$, a power of $2$.\n\n$3$ has order $2^k$ modulo $p$ iff $3^{2^{k-1}} \\not \\equiv 1 \\pmod p$. As $\\left (3^{2^{k-1}} \\right)^2 \\equiv 1 \\pmod p$, where $p$ is prime, this is equivalent to $3^{2^{k-1}} \\equiv -1 \\pmod p$, which remains to prove.\n\n$3^{2^{k-1}} = 3^{(p-1)/2} \\equiv \\legendre{3}{p} \\pmod p$.\n\nAs the result is true for $p=5$, we can suppose $n\\geq 2$.\nFrom the law of quadratic reciprocity :\n$$\\legendre{3}{p} \\legendre{p}{3} = (-1)^{(p-1)/2} = (-1)^{2^{k-1}} = 1.$$\nSo $\\legendre{3}{p} = \\legendre{p}{3}$\n \n\\begin{align*}\np = 2^{2^n}+1 &\\equiv (-1)^{2^n} + 1 \\pmod 3\\\\\n&\\equiv 2 \\equiv -1 \\pmod 3,\n\\end{align*}\nso $\\legendre{3}{p} = \\legendre {p}{3} = -1$, that is to say\n$$3^{2^{k-1}} \\equiv -1 \\pmod p.$$\nThe order of $3$ modulo $p = 2^{2^n} + 1$ is $p-1 = 2^{2^n}$ : $3$ is a primitive root modulo $p$.\n\n(On the other hand, if $3$ is of order $p-1$ modulo $p$, then $p$ is prime, so\n$$ F_n = 2^{2^n} + 1 \\ \\mathrm{is}\\ \\mathrm{prime}\\ \\iff 3^{(F_n-1)/2} = 3^{2^{2^n - 1}} \\equiv -1 \\pmod {F_n}.)$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_4_8", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_4_8 {p a : ℕ} (hp : Odd p) :\n IsPrimitiveRoot a p ↔ (∀ q : ℕ, q ∣ (p-1) → q.Prime → ¬ a^(p-1) ≡ 1 [MOD p]) := sorry", "formal_proof": null, "informal_stmt": "Let $p$ be an odd prime. Show that $a$ is a primitive root modulo $p$ iff $a^{(p-1) / q} \\not \\equiv 1(p)$ for all prime divisors $q$ of $p-1$.\n\\begin{proof} \n$\\bullet$ If $a$ is a primitive root, then $a^k \\not \\equiv 1$ for all $k, 1\\leq k < p-1$, so $a^{(p-1)/q} \\not \\equiv 1 \\pmod p$ for all prime divisors $q$ of $p - 1$.\n\n$\\bullet$ In the other direction, suppose $a^{(p-1)/q} \\not \\equiv 1 \\pmod p$ for all prime divisors $q$ of $p - 1$.\n\nLet $\\delta$ the order of $a$, and $p-1 = q_1^{a_1}q_2^{a_2}\\cdots q_k^{a_k}$ the decomposition of $p-1$ in prime factors. As $\\delta \\mid p-1, \\delta = q_1^{b_1}p_2^{b_2}\\cdots q_k^{b_k}$, with $b_i \\leq a_i, i=1,2,\\ldots,k$. If $b_i < a_i$ for some index $i$, then $\\delta \\mid (p-1)/q_i$, so $a^{(p-1)/q_i} \\equiv 1 \\pmod p$, which is in contradiction with the hypothesis. Thus $b_i = a_i$ for all $i$, and $\\delta = q-1$ : $a$ is a primitive root modulo $p$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_4_11", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_4_11 {p : ℕ} (hp : p.Prime) (k s: ℕ)\n (s := sorry", "formal_proof": null, "informal_stmt": "Prove that $1^{k}+2^{k}+\\cdots+(p-1)^{k} \\equiv 0(p)$ if $p-1 \\nmid k$ and $-1(p)$ if $p-1 \\mid k$.\n\\begin{proof} \nLet $S_k = 1^k+2^k+\\cdots+(p-1)^k$.\n\nLet $g$ a primitive root modulo $p$ : $\\overline{g}$ a generator of $\\mathbb{F}_p^*$.\n\nAs $(\\overline{1},\\overline{g},\\overline{g}^{2}, \\ldots, \\overline{g}^{p-2}) $ is a permutation of $ (\\overline{1},\\overline{2}, \\ldots,\\overline{p-1})$,\n\\begin{align*}\n\\overline{S_k} &= \\overline{1}^k + \\overline{2}^k+\\cdots+ \\overline{p-1}^k\\\\\n&= \\sum_{i=0}^{p-2} \\overline{g}^{ki} =\n\\left\\{\n\\begin{array}{ccc}\n\\overline{ p-1} = -\\overline{1} & \\mathrm{if} & p-1 \\mid k \\\\\n \\frac{ \\overline{g}^{(p-1)k} -1}{ \\overline{g}^k -1} = \\overline{0}& \\mathrm{if} & p-1 \\nmid k\n\\end{array}\n\\right.\n\\end{align*}\nsince $p-1 \\mid k \\iff \\overline{g}^k = \\overline{1}$.\n\nConclusion :\n\\begin{align*}\n1^k+2^k+\\cdots+(p-1)^k&\\equiv 0 \\pmod p\\ \\mathrm{if} \\ p-1 \\nmid k\\\\\n1^k+2^k+\\cdots+(p-1)^k&\\equiv -1 \\pmod p\\ \\mathrm{if} \\ p-1 \\mid k\\\\\n\\end{align*}\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_5_13", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_5_13 {p x: ℤ} (hp : Prime p)\n (hpx : p ∣ (x^4 - x^2 + 1)) : p ≡ 1 [ZMOD 12] := sorry", "formal_proof": null, "informal_stmt": "Show that any prime divisor of $x^{4}-x^{2}+1$ is congruent to 1 modulo 12 .\n\\begin{proof} \n\\newcommand{\\legendre}[2]{\\genfrac{(}{)}{}{}{#1}{#2}}\n$\\bullet$ As $a^6 +1 = (a^2+1)(a^4-a^2+1)$, $p\\mid a^4 - a^2+1$ implies $p \\mid a^6 + 1$, so $\\legendre{-1}{p} = 1$ and $p\\equiv 1 \\pmod 4$.\n\n$\\bullet$ $p \\mid 4a^4 - 4 a^2 +4 = (2a-1)^2 + 3$, so $\\legendre{-3}{p} = 1$.\n\nAs $-3 \\equiv 1 \\pmod 4$, $\\legendre{-3}{p} = \\legendre{p}{3}$, so $\\legendre{p}{3} = 1$, thus $p \\equiv 1 \\pmod 3$.\n\n$4 \\mid p-1$ and $3 \\mid p-1$, thus $12 \\mid p-1$ : $$p \\equiv 1 \\pmod {12}.$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_5_28", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_5_28 {p : ℕ} (hp : p.Prime) (hp1 : p ≡ 1 [MOD 4]):\n ∃ x, x^4 ≡ 2 [MOD p] ↔ ∃ A B, p = A^2 + 64*B^2 := sorry", "formal_proof": null, "informal_stmt": "Show that $x^{4} \\equiv 2(p)$ has a solution for $p \\equiv 1(4)$ iff $p$ is of the form $A^{2}+64 B^{2}$.\n\\begin{proof} \nIf $p\\equiv 1\\ [4]$ and if there exists $x \\in \\mathbb{Z}$ such that $x^4 \\equiv 2\\ [p]$, then\n$$2^{\\frac{p-1}{4} }\\equiv x^{p-1} \\equiv 1 \\ [p].$$ \n\nFrom Ex. 5.27, where $p = a^2 +b^2, a$ odd, we know that $$f^{\\frac{ab}{2}} \\equiv 2^{\\frac{p-1}{4} } \\equiv 1 \\ [p].$$\n\nSince $f^2 \\equiv -1\\ [p]$, the order of $f$ modulo $p$ is 4, thus $4 \\mid \\frac{ab}{2}$, so $8\\mid ab$.\n\nAs $a$ is odd, $8 | b$, then $p = A^2 + 64 B^2$ (with $A = a, B = b/8$).\n\n\\bigskip\n\nConversely, if $p=A^2+64 B^2$, then $p\\equiv A^2 \\equiv 1 \\ [4]$.\n\nLet $a=A,b=8B$. Then $$2^{\\frac{p-1}{4} } \\equiv f^{\\frac{ab}{2}} \\equiv f^{4AB} \\equiv (-1)^{2AB} \\equiv 1 \\ [p].$$\n\nAs $2^{\\frac{p-1}{4} } \\equiv 1 \\ [p]$, $x^4 \\equiv 2 \\ [p]$ has a solution in $\\mathbb{Z}$ (Prop. 4.2.1) : $2$ is a biquadratic residue modulo $p$.\n\nConclusion : \n\n$$\\exists A \\in \\mathbb{Z}, \\exists B \\in \\mathbb{Z}\\,, p = A^2+64 B^2 \\iff( p\\equiv 1 \\ [4] \\ \\mathrm{and} \\ \\exists x \\in \\mathbb{Z}, \\, x^4 \\equiv 2 \\ [p]).$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_5_37", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_5_37 {p q : ℕ} [Fact (p.Prime)] [Fact (q.Prime)] {a : ℤ}\n (ha : a < 0) (h0 : p ≡ q [ZMOD 4*a]) (h1 : ¬ ((p : ℤ) ∣ a)) :\n legendreSym p a = legendreSym q a := sorry", "formal_proof": null, "informal_stmt": "Show that if $a$ is negative then $p \\equiv q(4 a) together with p\\not | a$ imply $(a / p)=(a / q)$.\n\\begin{proof} \n\\newcommand{\\legendre}[2]{\\genfrac{(}{)}{}{}{#1}{#2}}\nWrite $a = -A, A>0$. As $p \\equiv q \\pmod {4a}$, we know from Prop. 5.3.3. (b) that $(A/p) = (A/q)$.\n\nMoreover,\n\\begin{align*}\n\\legendre{a}{p}&= \\legendre{-A}{p} = (-1)^{(p-1)/2} \\legendre{A}{p}\\\\\n\\legendre{a}{q}&= \\legendre{-A}{q} = (-1^{(q-1)/2} \\legendre{A}{q}\n\\end{align*}\nAs $p \\equiv q \\pmod {4a}$, $ p = q + 4ak, k\\in \\mathbb{Z}$, so\n$$(-1)^{(p-1)/2} = (-1)^{(q+4ak-1)/2} = (-1)^{(q-1)/2},$$\nso $(a/p) = (a/q)$.\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_12_12", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_12_12 : IsAlgebraic ℚ (sin (pi/12)) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\sin (\\pi / 12)$ is an algebraic number.\n\\begin{proof}\n$$\n\\begin{aligned}\n \\sin \\pi/12=\\sin \\left(\\pi/4-\\pi/6\\right) & =\\sin \\pi/4 \\cos \\pi/6-\\cos \\pi/4 \\sin \\pi/6 \\\\\n& =\\frac{\\sqrt{3}}{2 \\sqrt{2}}-\\frac{1}{2 \\sqrt{2}} \\\\\n& =\\frac{\\sqrt{3}-1}{2 \\sqrt{2}}\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Ireland_Rosen_exercise_18_4", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_18_4 {n : ℕ} (hn : ∃ x y z w : ℤ,\n x^3 + y^3 = n ∧ z^3 + w^3 = n ∧ x ≠ z ∧ x ≠ w ∧ y ≠ z ∧ y ≠ w) :\n n ≥ 1729 := sorry", "formal_proof": null, "informal_stmt": "Show that 1729 is the smallest positive integer expressible as the sum of two different integral cubes in two ways.\n\\begin{proof}\n Let $n=a^3+b^3$, and suppose that $\\operatorname{gcd}(a, b)=1$. If a prime $p \\mid a^3+b^3$, then\n$$\n\\left(a b^{-1}\\right)^3 \\equiv_p-1\n$$\nThus $3 \\mid \\frac{p-1}{2}$, that is, $p \\equiv_6 1$.\nIf we have $n=a^3+b^3=c^3+d^3$, then we can factor $n$ as\n$$\n\\begin{aligned}\n& n=(a+b)\\left(a^2-a b+b^2\\right) \\\\\n& n=(c+d)\\left(c^2-c d+d^2\\right)\n\\end{aligned}\n$$\nThus we need $n$ to have at least 3 distinct prime factors, and so the smallest taxicab number is on the form\n$$\nn=(6 k+1)(12 k+1)(18 k+1)\n$$\n\\end{proof}\n\\end{document}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} +{"name": "Munkres_exercise_13_1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_1 (X : Type*) [TopologicalSpace X] (A : Set X)\n (h1 : ∀ x ∈ A, ∃ U : Set X, x ∈ U ∧ IsOpen U ∧ U ⊆ A) :\n IsOpen A := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a topological space; let $A$ be a subset of $X$. Suppose that for each $x \\in A$ there is an open set $U$ containing $x$ such that $U \\subset A$. Show that $A$ is open in $X$.\n\\begin{proof}\n Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that\n$$\nA=\\bigcup_{x \\in A} U_x\n$$\nObserve that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_3b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_3b : ¬ ∀ X : Type, ∀s : Set (Set X),\n (∀ t : Set X, t ∈ s → (Set.Infinite tᶜ ∨ t = ∅ ∨ t = ⊤)) →\n (Set.Infinite (⋃₀ s)ᶜ ∨ (⋃₀ s) = ∅ ∨ (⋃₀ s) = ⊤) := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $$\\mathcal{T}_\\infty = \\{U | X - U \\text{ is infinite or empty or all of X}\\}$$ does not need to be a topology on the set $X$.\n\\begin{proof}\n Let $X=\\mathbb{R}, U_1=(-\\infty, 0)$ and $U_2=(0, \\infty)$. Then $U_1$ and $U_2$ are in $\\mathcal{T}_{\\infty}$ but $U_1 \\cup U_2=\\mathbb{R} \\backslash\\{0\\}$ is not.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4a1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4a1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcap \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\begin{proof}\n Since $\\emptyset$ and $X$ belong to $\\mathcal{T}_\\alpha$ for each $\\alpha$, they belong to $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. Let $\\left\\{V_\\beta\\right\\}_\\beta$ be a collection of open sets in $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. For any fixed $\\alpha$ we have $\\cup_\\beta V_\\beta \\in \\mathcal{T}_\\alpha$ since $\\mathcal{T}_\\alpha$ is a topology on $X$, so $\\bigcup_\\beta V_\\beta \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. Similarly, if $U_1, \\ldots, U_n$ are elements of $\\bigcap_\\alpha \\mathcal{T}_\\alpha$, then for each $\\alpha$ we have $\\bigcup_{i=1}^n U_i \\in \\mathcal{T}_\\alpha$ and therefore $\\bigcup_{i=1}^n U_i \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. It follows that $\\bigcap_\\alpha \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4a2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4a2 :\n ∃ (X I : Type*) (T : I → Set (Set X)),\n (∀ i, is_topology X (T i)) ∧ ¬ is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcup \\mathcal{T}_\\alpha$ does not need to be a topology on $X$.\n\\begin{proof}\n On the other hand, the union $\\bigcup_\\alpha \\mathcal{T}_\\alpha$ is in general not a topology on $X$. For instance, let $X=\\{a, b, c\\}$. Then $\\mathcal{T}_1=\\{\\emptyset, X,\\{a\\}\\}$ and $\\mathcal{T}_2=\\{\\emptyset, X,\\{b\\}\\}$ are topologies on $X$ but $\\mathcal{T}_1 \\cup \\mathcal{T}_2=$ $\\{\\emptyset, X,\\{a\\},\\{b\\}\\}$ is not.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4b1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4b1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T i ⊆ T') ∧\n ∀ T'', is_topology X T'' → (∀ i, T i ⊆ T'') → T'' ⊆ T' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n (b) First we prove that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. For each $\\alpha$ let $\\mathcal{B}_\\alpha$ be a basis for $\\mathcal{T}_\\alpha$. Let $\\mathcal{T}$ be the topology generated by the subbasis $\\mathcal{S}=\\bigcup_\\alpha \\mathcal{B}_\\alpha$. Then the collection $\\mathcal{B}$ of all finite intersections of elements of $\\mathcal{S}$ is a basis for $\\mathcal{T}$. Clearly $\\mathcal{T}_\\alpha \\subset \\mathcal{T}$ for all $\\alpha$. We now prove that if $\\mathcal{O}$ is a topology on $X$ such that $\\mathcal{T}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, then $\\mathcal{T} \\subset \\mathcal{O}$. Given such $\\mathcal{O}$, we have $\\mathcal{B}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, so $\\mathcal{S} \\subset \\mathcal{O}$. Since $\\mathcal{O}$ is a topology, it must contain all finite intersections of elements of $\\mathcal{S}$, so $\\mathcal{B} \\subset \\mathcal{O}$ and hence $\\mathcal{T} \\subset \\mathcal{O}$. We conclude that the topology $\\mathcal{T}$ generated by the subbasis $\\mathcal{S}=\\cup_\\alpha \\mathcal{B}_\\alpha$ is the unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4b2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4b2 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T' ⊆ T i) ∧\n ∀ T'', is_topology X T'' → (∀ i, T'' ⊆ T i) → T' ⊆ T'' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique largest topology on $X$ contained in all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n Now we prove that there exists a unique largest topology contained in all $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. Consider $\\mathcal{T}=\\bigcap_\\alpha \\mathcal{T}_\\alpha$. We already know that $\\mathcal{T}$ is a topology by, and clearly $\\mathcal{T} \\subset \\mathcal{T}_\\alpha$ for all $\\alpha$. If $\\mathcal{O}$ is another topology contained in all $\\mathcal{T}_\\alpha$, it must be contained in their intersection, so $\\mathcal{O} \\subset \\mathcal{T}$. I follows that $\\mathcal{T}$ is the unique largest topology contained in all $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_5a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_5a {X : Type*}\n [TopologicalSpace X] (A : Set (Set X)) (hA : IsTopologicalBasis A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a basis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n Let $\\mathcal{T}$ be the topology generated by $\\mathcal{A}$ and let $\\mathcal{O}$ be the intersection of all topologies on $X$ that contains $\\mathcal{A}$. Clearly $\\mathcal{O} \\subset \\mathcal{T}$ since $\\mathcal{T}$ is a topology on $X$ that contain $\\mathcal{A}$. Conversely, let $U \\in \\mathcal{T}$, so that $U$ is a union of elements of $\\mathcal{A}$. Since each of this elements is also an element of $\\mathcal{O}$, their union $U$ belongs to $\\mathcal{O}$. Thus $\\mathcal{T} \\subset \\mathcal{O}$ and the equality holds.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_5b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_5b {X : Type*}\n [t : TopologicalSpace X] (A : Set (Set X)) (hA : t = generateFrom A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a subbasis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n If we now considered $\\mathcal{A}$ as a subbasis, then the elements of $\\mathcal{T}$ are union of finite intersections of elements of $\\mathcal{A}$. The inclusion $\\mathcal{O} \\subset \\mathcal{T}$ is again clear and $\\mathcal{T} \\subset \\mathcal{O}$ holds since every union of finite intersections of elements of $\\mathcal{A}$ belongs to $\\mathcal{O}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_6 :\n ¬ (∀ U, Rl.IsOpen U → K_topology.IsOpen U) ∧ ¬ (∀ U, K_topology.IsOpen U → Rl.IsOpen U) := sorry", "formal_proof": null, "informal_stmt": "Show that the lower limit topology $\\mathbb{R}_l$ and $K$-topology $\\mathbb{R}_K$ are not comparable.\n\\begin{proof}\n Let $\\mathcal{T}_{\\ell}$ and $\\mathcal{T}_K$ denote the topologies of $\\mathbb{R}_{\\ell}$ and $\\mathbb{R}_K$ respectively. Given the basis element $[0,1)$ for $\\mathcal{T}_{\\ell}$, there is no basis element for $\\mathcal{T}_K$ containing 0 and contained in $[0,1)$, so $\\mathcal{T}_{\\ell} \\not \\subset \\mathcal{T}_K$. Similarly, given the basis element $(-1,1) \\backslash K$ for $\\mathcal{T}_K$, there is no basis element for $\\mathcal{T}_{\\ell}$ containing 0 contained in $(-1,1) \\backslash K$, so $\\mathcal{T}_K \\not \\subset \\mathcal{T}_{\\ell}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_8a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_8a :\n IsTopologicalBasis {S : Set ℝ | ∃ a b : ℚ, a < b ∧ S = Ioo ↑a ↑b} := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $\\{(a,b) \\mid a < b, a \\text{ and } b \\text{ rational}\\}$ is a basis that generates the standard topology on $\\mathbb{R}$.\n\\begin{proof}\n Exercise 13.8. (a) First note that $\\mathcal{B}$ is a basis for a topology on $\\mathbb{R}$. This follows from the fact that the union of its elements is all of $\\mathbb{R}$ and the intersection of two elements of $\\mathcal{B}$ is either empty or another element of $\\mathcal{B}$. Let $\\mathcal{T}$ be the standard topology on $\\mathbb{R}$. Clearly the topology generated by $\\mathcal{B}$ is coarser than $\\mathcal{T}$. Let $U \\in \\mathcal{T}$ and $x \\in U$. Then $U$ contains an open interval with centre $x$. Since the rationals are dense in $\\mathbb{R}$ with the standard topology, there exists $q \\in \\mathbb{Q}$ such that $x \\in(x-q, x+q) \\subset U$. This proves that $\\mathcal{T}$ is coarser than the topology generated by $\\mathcal{B}$. We conclude that $\\mathcal{B}$ generates the standard topology on $\\mathbb{R}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_8b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_8b :\n (generateFrom {S : Set ℝ | ∃ a b : ℚ, a < b ∧ S = Ico ↑a ↑b}).IsOpen ≠\n (lower_limit_topology ℝ).IsOpen := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $\\{(a,b) \\mid a < b, a \\text{ and } b \\text{ rational}\\}$ is a basis that generates a topology different from the lower limit topology on $\\mathbb{R}$.\n\\begin{proof}\n (b) $\\mathcal{C}$ is a basis for a topology on $\\mathbb{R}$ since the union of its elements is $\\mathbb{R}$ and the intersection of two elements of $\\mathcal{C}$ is either empty or another element of $\\mathcal{C}$. Now consider $[r, s)$ where $r$ is any irrational number and $s$ is any real number greater than $r$. Then $[r, s)$ is a basis element for the topology of $\\mathbb{R}_{\\ell}$, but $[r, s)$ is not a union of elements of $\\mathcal{C}$. Indeed, suppose that $[r, s)=\\cup_\\alpha\\left[a_\\alpha, b_\\alpha\\right)$ for rationals $a_\\alpha, b_\\alpha$. Then $r \\in\\left[a_\\alpha, b_\\alpha\\right)$ for some $\\alpha$. Since $r$ is irrational we must have $a_\\alpha min (f x) (g x)) := sorry", "formal_proof": null, "informal_stmt": "Let $Y$ be an ordered set in the order topology. Let $f, g: X \\rightarrow Y$ be continuous. Let $h: X \\rightarrow Y$ be the function $h(x)=\\min \\{f(x), g(x)\\}.$ Show that $h$ is continuous.\n\\begin{proof}\n Let $A=\\{x \\mid f(x) \\leq g(x)\\}$ and $B=\\{x \\mid g(x) \\leq f(x)\\}$. Then $A$ and $B$ are closed in $X$ by (a), $A \\cap B=\\{x \\mid f(x)=g(x)\\}$, and $X=A \\cup B$. Since $f$ and $g$ are continuous, their restrictions $f^{\\prime}: A \\rightarrow Y$ and $g^{\\prime}: B \\rightarrow Y$ are continuous. It follows from the pasting lemma that\n$$\nh: X \\rightarrow Y, \\quad h(x)=\\min \\{f(x), g(x)\\}= \\begin{cases}f^{\\prime}(x) & \\text { if } x \\in A \\\\ g^{\\prime}(x) & \\text { if } x \\in B\\end{cases}\n$$\nis continuous\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_18_13", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_18_13\n {X : Type*} [TopologicalSpace X] {Y : Type*} [TopologicalSpace Y]\n [T2Space Y] {A : Set X} {f : A → Y} (hf : Continuous f)\n (g : closure A → Y)\n (g_con : Continuous g) :\n ∀ (g' : closure A → Y), Continuous g' → (∀ (x : closure A), g x = g' x) := sorry", "formal_proof": null, "informal_stmt": "Let $A \\subset X$; let $f: A \\rightarrow Y$ be continuous; let $Y$ be Hausdorff. Show that if $f$ may be extended to a continuous function $g: \\bar{A} \\rightarrow Y$, then $g$ is uniquely determined by $f$.\n\\begin{proof}\n Let $h, g: \\bar{A} \\rightarrow Y$ be continuous extensions of $f$. Suppose that there is a point $x \\in \\bar{A}$ such that $h(x) \\neq g(x)$. Since $h=g$ on $A$, we must have $x \\in A^{\\prime}$. Since $Y$ is Hausdorff, there is a neighbourhood $U$ of $h(x)$ and a neighbourhood $V$ of $g(x)$ such that $U \\cap V=\\emptyset$. Since $h$ and $g$ are continuous, $h^{-1}(U) \\cap g^{-1}(V)$ is a neighbourhood of $x$. Since $x \\in A^{\\prime}$, there is a point $y \\in h^{-1}(U) \\cap g^{-1}(V) \\cap A$ different from $x$. But $h=g$ on $A$, so $g^{-1}(V) \\cap A=h^{-1}(V) \\cap A$ and hence $y \\in h^{-1}(U) \\cap h^{-1}(V)=h^{-1}(U \\cap V)=\\emptyset$, a contradiction. It follows that $h=g$ on $\\bar{A}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_19_6a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_19_6a\n {n : ℕ}\n {f : Fin n → Type*} {x : ℕ → Πa, f a}\n (y : Πi, f i)\n [Πa, TopologicalSpace (f a)] :\n Tendsto x atTop (𝓝 y) ↔ ∀ i, Tendsto (λ j => (x j) i) atTop (𝓝 (y i)) := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathbf{x}_1, \\mathbf{x}_2, \\ldots$ be a sequence of the points of the product space $\\prod X_\\alpha$. Show that this sequence converges to the point $\\mathbf{x}$ if and only if the sequence $\\pi_\\alpha(\\mathbf{x}_i)$ converges to $\\pi_\\alpha(\\mathbf{x})$ for each $\\alpha$.\n\\begin{proof}\n For each $n \\in \\mathbb{Z}_{+}$, we write $\\mathbf{x}_n=\\left(x_n^\\alpha\\right)_\\alpha$, so that $\\pi_\\alpha\\left(\\mathbf{x}_n\\right)=x_n^\\alpha$ for each $\\alpha$.\nFirst assume that the sequence $\\mathbf{x}_1, \\mathbf{x}_2, \\ldots$ converges to $\\mathbf{x}=\\left(x_\\alpha\\right)_\\alpha$ in the product space $\\prod_\\alpha X_\\alpha$. Fix an index $\\beta$ and let $U$ be a neighbourhood of $\\pi_\\beta(\\mathbf{x})=x_\\beta$. Let $V=\\prod_\\alpha U_\\alpha$, where $U_\\alpha=X_\\alpha$ for each $\\alpha \\neq \\beta$ and $U_\\beta=U$. Then $V$ is a neighbourhood of $\\mathbf{x}$, so there exists $N \\in \\mathbb{Z}_{+}$such that $\\mathbf{x}_n \\in V$ for all $n \\geq N$. Therefore $\\pi_\\beta\\left(\\mathbf{x}_n\\right)=x_n^\\beta \\in U$ for all $n \\geq N$. Since $U$ was arbitrary, it follows that $\\pi_\\beta\\left(\\mathbf{x}_1\\right), \\pi_\\beta\\left(\\mathbf{x}_2\\right), \\ldots$ converges to $\\pi_\\beta(\\mathbf{x})$. Since $\\beta$ was arbitrary, this holds for all indices $\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_20_2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_20_2\n [TopologicalSpace (ℝ ×ₗ ℝ)] [OrderTopology (ℝ ×ₗ ℝ)]\n : MetrizableSpace (ℝ ×ₗ ℝ) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\mathbb{R} \\times \\mathbb{R}$ in the dictionary order topology is metrizable.\n\\begin{proof}\n The dictionary order topology on $\\mathbb{R} \\times \\mathbb{R}$ is the same as the product topology $\\mathbb{R}_d \\times \\mathbb{R}$, where $\\mathbb{R}_d$ denotes $\\mathbb{R}$ with the discrete topology. We know that $\\mathbb{R}_d$ and $\\mathbb{R}$ are metrisable. Thus, it suffices to show that the product of two metrisable spaces is metrisable.\nSo let $X$ and $Y$ be metrisable spaces, with metrics $d$ and $d^{\\prime}$ respectively. On $X \\times Y$, define\n$$\n\\rho(x \\times y, w \\times z)=\\max \\left\\{d(x, w), d^{\\prime}(y, z)\\right\\} .\n$$\nThen $\\rho$ is a metric on $X \\times Y$; it remains to prove that it induces the product topology on $X \\times Y$. If $B_d\\left(x, r_1\\right) \\times B_d\\left(y, r_2\\right)$ is a basis element for the product space $X \\times Y$, and $r=\\min \\left\\{r_1, r_2\\right\\}$, then $x \\times y \\in B_\\rho(x \\times y, r) \\subset B_d\\left(x, r_1\\right) \\times B_d\\left(y, r_2\\right)$, so the product topology is coarser than the $\\rho$-topology. Conversely, if $B_\\rho(x \\times y, \\delta)$ is a basis element for the $\\rho$-topology, then $x \\times y \\in B_d(x, \\delta) \\times B_{d^{\\prime}}(y, \\delta) \\subset$ $B_\\rho(x \\times y, \\delta)$, so the product topology is finer than the $\\rho$-topology. It follows that both topologies are equal, so the product space $X \\times Y$ is metrisable.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_21_6a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_21_6a\n (f : ℕ → I → ℝ )\n (h : ∀ x n, f n x = x ^ n) :\n ∀ x, ∃ y, Tendsto (λ n => f n x) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Define $f_{n}:[0,1] \\rightarrow \\mathbb{R}$ by the equation $f_{n}(x)=x^{n}$. Show that the sequence $\\left(f_{n}(x)\\right)$ converges for each $x \\in[0,1]$.\n\\begin{proof}\nIf $0 \\leq x<1$ is fixed, then $f_n(x) \\rightarrow 0$ as $n \\rightarrow \\infty$. As $f_n(1)=1$ for all $n, f_n(1) \\rightarrow 1$. Thus $\\left(f_n\\right)_n$ converges to $f:[0,1] \\rightarrow \\mathbb{R}$ given by $f(x)=0$ if $x=0$ and $f(1)=1$. The sequence\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_21_6b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_21_6b\n (f : ℕ → I → ℝ )\n (h : ∀ x n, f n x = x ^ n) :\n ¬ ∃ f₀, TendstoUniformly f f₀ atTop := sorry", "formal_proof": null, "informal_stmt": "Define $f_{n}:[0,1] \\rightarrow \\mathbb{R}$ by the equation $f_{n}(x)=x^{n}$. Show that the sequence $\\left(f_{n}\\right)$ does not converge uniformly.\n\\begin{proof}\n The sequence $\\left(f_n\\right)_n$ does not converge uniformly, since given $0<\\varepsilon<1$ and $N \\in \\mathbb{Z}_{+}$, for $x=\\varepsilon^{1 / N}$ we have $d\\left(f_N(x), f(x)\\right)=\\varepsilon$. We can also apply Theorem 21.6: the convergence is not uniform since $f$ is not continuous.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_21_8", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_21_8\n {X : Type*} [TopologicalSpace X] {Y : Type*} [MetricSpace Y]\n {f : ℕ → X → Y} {x : ℕ → X}\n (hf : ∀ n, Continuous (f n))\n (x₀ : X)\n (hx : Tendsto x atTop (𝓝 x₀))\n (f₀ : X → Y)\n (hh : TendstoUniformly f f₀ atTop) :\n Tendsto (λ n => f n (x n)) atTop (𝓝 (f₀ x₀)) := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a topological space and let $Y$ be a metric space. Let $f_{n}: X \\rightarrow Y$ be a sequence of continuous functions. Let $x_{n}$ be a sequence of points of $X$ converging to $x$. Show that if the sequence $\\left(f_{n}\\right)$ converges uniformly to $f$, then $\\left(f_{n}\\left(x_{n}\\right)\\right)$ converges to $f(x)$.\n\\begin{proof}\n Let $d$ be the metric on $Y$. Let $V$ be a neighbourhood of $f(x)$, and let $\\varepsilon>0$ be such that $f(x) \\in B_d(f(x), \\varepsilon) \\subset V$. Since $\\left(f_n\\right)_n$ converges uniformly to $f$, there exists $N_1 \\in \\mathbb{Z}_{+}$such that $d\\left(f_n(x), f(x)\\right)<\\varepsilon / 2$ for all $x \\in X$ and all $n \\geq N_1$, so that $d\\left(f_n\\left(x_n\\right), f\\left(x_n\\right)\\right)<\\varepsilon / 2$ for all $n \\geq N_1$. Moreover, $f$ is continuous, so there exists $N_2 \\in \\mathbb{Z}_{+}$such that $d\\left(f\\left(x_n\\right), f(x)\\right)<\\varepsilon / 2$ for all $n \\geq N_2$. Thus, if $N>\\max \\left\\{N_1, N_2\\right\\}$, then\n$$\nd\\left(f_n\\left(x_n\\right), f(x)\\right) \\leq d\\left(f_n\\left(x_n\\right), f\\left(x_n\\right)\\right)+d\\left(f\\left(x_n\\right), f(x)\\right)<\\frac{\\varepsilon}{2}+\\frac{\\varepsilon}{2}=\\varepsilon\n$$\nfor all $n \\geq N$, so $f_n\\left(x_n\\right) \\in V$ for all $n \\geq N$. It follows that $\\left(f_n\\left(x_n\\right)\\right)_n$ converges to $f(x)$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_22_2a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_22_2a {X Y : Type*} [TopologicalSpace X]\n [TopologicalSpace Y] (p : X → Y) (h : Continuous p) :\n IsQuotientMap p ↔ ∃ (f : Y → X), Continuous f ∧ p ∘ f = id := sorry", "formal_proof": null, "informal_stmt": "Let $p: X \\rightarrow Y$ be a continuous map. Show that if there is a continuous map $f: Y \\rightarrow X$ such that $p \\circ f$ equals the identity map of $Y$, then $p$ is a quotient map.\n\\begin{proof}\nLet $1_Y: Y \\rightarrow Y$ be the identity map in $Y$. If $U$ is a subset of $Y$ and $p^{-1}(U)$ is open in $X$, then $f^{-1}\\left(p^{-1}(U)\\right)=1_Y^{-1}(U)=U$ is open in $Y$ by continuity of $f$. Thus $p$ is a quotient map.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_22_2b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_22_2b {X : Type*} [TopologicalSpace X]\n {A : Set X} (r : X → A) (hr : Continuous r) (h : ∀ x : A, r x = x) :\n IsQuotientMap r := sorry", "formal_proof": null, "informal_stmt": "If $A \\subset X$, a retraction of $X$ onto $A$ is a continuous map $r: X \\rightarrow A$ such that $r(a)=a$ for each $a \\in A$. Show that a retraction is a quotient map.\n\\begin{proof}\nThe inclusion map $i: A \\rightarrow X$ is continuous and $r \\circ i=1_A$ is the identity. Thus $r$ is a quotient map by (a).\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_22_5", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_22_5 {X Y : Type*} [TopologicalSpace X]\n [TopologicalSpace Y] (p : X → Y) (hp : IsOpenMap p)\n (A : Set X) (hA : IsOpen A) : IsOpenMap (p ∘ Subtype.val : A → Y) := sorry", "formal_proof": null, "informal_stmt": "Let $p \\colon X \\rightarrow Y$ be an open map. Show that if $A$ is open in $X$, then the map $q \\colon A \\rightarrow p(A)$ obtained by restricting $p$ is an open map.\n\\begin{proof}\nLet $U$ be open in $A$. Since $A$ is open in $X, U$ is open in $X$ as well, so $p(U)$ is open in $Y$. Since $q(U)=p(U)=p(U) \\cap p(A)$, the set $q(U)$ is open in $p(A)$. Thus $q$ is an open map.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_2 {X : Type*}\n [TopologicalSpace X] {A : ℕ → Set X} (hA : ∀ n, IsConnected (A n))\n (hAn : ∀ n, A n ∩ A (n + 1) ≠ ∅) :\n IsConnected (⋃ n, A n) := sorry", "formal_proof": null, "informal_stmt": "Let $\\left\\{A_{n}\\right\\}$ be a sequence of connected subspaces of $X$, such that $A_{n} \\cap A_{n+1} \\neq \\varnothing$ for all $n$. Show that $\\bigcup A_{n}$ is connected.\n\\begin{proof}\n Suppose that $\\bigcup_n A_n=B \\cup C$, where $B$ and $C$ are disjoint open subsets of $\\bigcup_n A_n$. Since $A_1$ is connected and a subset of $B \\cup C$, by Lemma $23.2$ it lies entirely within either $B$ or $C$. Without any loss of generality, we may assume $A_1 \\subset B$. Note that given $n$, if $A_n \\subset B$ then $A_{n+1} \\subset B$, for if $A_{n+1} \\subset C$ then $A_n \\cap A_{n+1} \\subset B \\cap C=\\emptyset$, in contradiction with the assumption. By induction, $A_n \\subset B$ for all $n \\in \\mathbb{Z}_{+}$, so that $\\bigcup_n A_n \\subset B$. It follows that $\\bigcup_n A_n$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_3", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_3 {X : Type*} [TopologicalSpace X]\n [TopologicalSpace X] {A : ℕ → Set X}\n (hAn : ∀ n, IsConnected (A n))\n (A₀ : Set X)\n (hA : IsConnected A₀)\n (h : ∀ n, A₀ ∩ A n ≠ ∅) :\n IsConnected (A₀ ∪ (⋃ n, A n)) := sorry", "formal_proof": null, "informal_stmt": "Let $\\left\\{A_{\\alpha}\\right\\}$ be a collection of connected subspaces of $X$; let $A$ be a connected subset of $X$. Show that if $A \\cap A_{\\alpha} \\neq \\varnothing$ for all $\\alpha$, then $A \\cup\\left(\\bigcup A_{\\alpha}\\right)$ is connected.\n\\begin{proof}\n For each $\\alpha$ we have $A \\cap A_\\alpha \\neq \\emptyset$, so each $A \\cup A_\\alpha$ is connected by Theorem 23.3. In turn $\\left\\{A \\cup A_\\alpha\\right\\}_\\alpha$ is a collection of connected spaces that have a point in common (namely any point in $A)$, so $\\bigcup_\\alpha\\left(A \\cup A_\\alpha\\right)=A \\cup\\left(\\bigcup_\\alpha A_\\alpha\\right)$ is connected. \n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_4", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_4 {X : Type*} [TopologicalSpace X] [CofiniteTopology X]\n (s : Set X) : Infinite s → IsConnected s := sorry", "formal_proof": null, "informal_stmt": "Show that if $X$ is an infinite set, it is connected in the finite complement topology.\n\\begin{proof}\n Suppose that $A$ is a non-empty subset of $X$ that is both open and closed, i.e., $A$ and $X \\backslash A$ are finite or all of $X$. Since $A$ is non-empty, $X \\backslash A$ is finite. Thus $A$ cannot be finite as $X \\backslash A$ is infinite, so $A$ is all of $X$. Therefore $X$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_6 {X : Type*}\n [TopologicalSpace X] {A C : Set X} (hc : IsConnected C)\n (hCA : C ∩ A ≠ ∅) (hCXA : C ∩ Aᶜ ≠ ∅) :\n C ∩ (frontier A) ≠ ∅ := sorry", "formal_proof": null, "informal_stmt": "Let $A \\subset X$. Show that if $C$ is a connected subspace of $X$ that intersects both $A$ and $X-A$, then $C$ intersects $\\operatorname{Bd} A$.\n\\begin{proof}\n Suppose that $C \\cap B d A=C \\cap \\bar{A} \\cap \\overline{X-A}=\\emptyset$. Then $C \\cap A$ and $C \\cap(X \\backslash A)$ are a pair of disjoint non-empty sets whose union is all of $C$, neither of which contains a limit point of the other. Indeed, if $C \\cap(X-A)$ contains a limit point $x$ of $C \\cap A$, then $x \\in C \\cap(X-A) \\cap A^{\\prime} \\subset C \\cap \\bar{A} \\cap \\overline{X-A}=\\emptyset$, a contradiction, and similarly $C \\cap A$ does not contain a limit point of $C \\cap(X-A)$. Then $C \\cap A$ and $C \\cap(X-A)$ constitute a separation of $C$, contradicting the fact that $C$ is connected (Lemma 23.1).\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_9", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_9 {X Y : Type*}\n [TopologicalSpace X] [TopologicalSpace Y]\n (A₁ A₂ : Set X)\n (B₁ B₂ : Set Y)\n (hA : A₁ ⊂ A₂)\n (hB : B₁ ⊂ B₂)\n (hA : IsConnected A₂)\n (hB : IsConnected B₂) :\n IsConnected ({x | ∃ a b, x = (a, b) ∧ a ∈ A₂ ∧ b ∈ B₂} \\\n {x | ∃ a b, x = (a, b) ∧ a ∈ A₁ ∧ b ∈ B₁}) := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be a proper subset of $X$, and let $B$ be a proper subset of $Y$. If $X$ and $Y$ are connected, show that $(X \\times Y)-(A \\times B)$ is connected.\n\\begin{proof}\nThis is similar to the proof of Theorem 23.6. Take $c \\times d \\in(X \\backslash A) \\times(Y \\backslash B)$. For each $x \\in X \\backslash A$, the set\n$$\nU_x=(X \\times\\{d\\}) \\cup(\\{x\\} \\times Y)\n$$\nis connected since $X \\times\\{d\\}$ and $\\{x\\} \\times Y$ are connected and have the common point $x \\times d$. Then $U=\\bigcup_{x \\in X \\backslash A} U_x$ is connected because it is the union of the connected spaces $U_x$ which have the point $c \\times d$ in common. Similarly, for each $y \\in Y \\backslash B$ the set\n$$\nV_y=(X \\times\\{y\\}) \\cup(\\{c\\} \\times Y)\n$$\nis connected, so $V=\\bigcup_{y \\in Y \\backslash B} V_y$ is connected. Thus $(X \\times Y) \\backslash(A \\times B)=U \\cup V$ is connected since $c \\times d$ is a common point of $U$ and $V$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_11", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_11 {X Y : Type*} [TopologicalSpace X] [TopologicalSpace Y]\n (p : X → Y) (hq : QuotientMap p)\n (hY : ConnectedSpace Y) (hX : ∀ y : Y, IsConnected (p ⁻¹' {y})) :\n ConnectedSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $p: X \\rightarrow Y$ be a quotient map. Show that if each set $p^{-1}(\\{y\\})$ is connected, and if $Y$ is connected, then $X$ is connected.\n\\begin{proof}\n Suppose that $U$ and $V$ constitute a separation of $X$. If $y \\in p(U)$, then $y=p(x)$ for some $x \\in U$, so that $x \\in p^{-1}(\\{y\\})$. Since $p^{-1}(\\{y\\})$ is connected and $x \\in U \\cap p^{-1}(\\{y\\})$, we have $p^{-1}(\\{y\\}) \\subset U$. Thus $p^{-1}(\\{y\\}) \\subset U$ for all $y \\in p(U)$, so that $p^{-1}(p(U)) \\subset U$. The inclusion $U \\subset p^{-1}(p(U))$ if true for any subset and function, so we have the equality $U=p^{-1}(p(U))$ and therefore $U$ is saturated. Similarly, $V$ is saturated. Since $p$ is a quotient map, $p(U)$ and $p(V)$ are disjoint non-empty open sets in $Y$. But $p(U) \\cup p(V)=Y$ as $p$ is surjective, so $p(U)$ and $p(V)$ constitute a separation of $Y$, contradicting the fact that $Y$ is connected. We conclude that $X$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_24_2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_24_2 {f : (Metric.sphere 0 1 : Set ℝ) → ℝ}\n (hf : Continuous f) : ∃ x, f x = f (-x) := sorry", "formal_proof": null, "informal_stmt": "Let $f: S^{1} \\rightarrow \\mathbb{R}$ be a continuous map. Show there exists a point $x$ of $S^{1}$ such that $f(x)=f(-x)$.\n\\begin{proof}\n Let $f: S^1 \\rightarrow \\mathbb{R}$ be continuous. Let $x \\in S^1$. If $f(x)=f(-x)$ we are done, so assume $f(x) \\neq f(-x)$. Define $g: S^1 \\rightarrow \\mathbb{R}$ by setting $g(x)=f(x)-f(-x)$. Then $g$ is continuous. Suppose $f(x)>f(-x)$, so that $g(x)>0$. Then $-x \\in S^1$ and $g(-x)<0$. By the intermediate value theorem, since $S^1$ is connected and $g(-x)<00$ and $f(1)<1$. Let $g:[0,1] \\rightarrow[0,1]$ be given by $g(x)=f(x)-x$. Then $g$ is continuous, $g(0)>0$ and $g(1)<0$. Since $[0,1]$ is connected and $g(1)<00$. Therefore $X$ must be uncountable.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_28_4", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_4 {X : Type*}\n [TopologicalSpace X] (hT1 : T1Space X) :\n countably_compact X ↔ limit_point_compact X := sorry", "formal_proof": null, "informal_stmt": "A space $X$ is said to be countably compact if every countable open covering of $X$ contains a finite subcollection that covers $X$. Show that for a $T_1$ space $X$, countable compactness is equivalent to limit point compactness.\n\\begin{proof}\n First let $X$ be a countable compact space. Note that if $Y$ is a closed subset of $X$, then $Y$ is countable compact as well, for if $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $Y$, then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}} \\cup(X \\backslash Y)$ is a countable open covering of $X$; there is a finite subcovering of $X$, hence a finite subcovering of $Y$. Now let $A$ be an infinite subset. We show that $A$ has a limit point. Let $B$ be a countable infinite subset of $A$. Suppose that $B$ has no limit point, so that $B$ is closed in $X$. Then $B$ is countable compact. Since $B$ has no limit point, for each $b \\in B$ there is a neighbourhood $U_b$ of $b$ that intersects $B$ in the point $b$ alone. Then $\\left\\{U_b\\right\\}_{b \\in B}$ is an open covering of $B$ with no finite subcovering, contradicting the fact that $B$ is countable compact. Hence $B$ has a limit point, so that $A$ has a limit point as well. Since $A$ was arbitrary, we deduce that $X$ is limit point compact. (Note that the $T_1$ property is not necessary in this direction.)\n\nNow assume that $X$ is a limit point compact $T_1$ space. We show that $X$ is countable compact. Suppose, on the contrary, that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $X$ with no finite subcovering. For each $n$, take a point $x_n$ in $X$ not in $U_1 \\cup \\cdots \\cup U_n$. By assumption, the infinite set $A=\\left\\{x_n \\mid n \\in \\mathbb{Z}_{+}\\right\\}$has a limit point $y \\in X$. Since $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$, there exists $N \\in \\mathbb{Z}_{+}$such that $y \\in U_1 \\cup \\cdots \\cup U_N$. Now $X$ is $T_1$, so for each $i=1, \\ldots, N$ there exists a neighbourhood $V_i$ of $y$ that does not contain $x_i$. Then\n$$\nV=\\left(V_1 \\cap \\cdots \\cap V_N\\right) \\cap\\left(U_1 \\cup \\cdots \\cup U_N\\right)\n$$\nis a neighbourhood of $y$ that does not contain any of the points $x_i$, contradicting the fact that $y$ is a limit point of $A$. It follows that every countable open covering of $X$ must have a finite subcovering, so $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_28_5", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_5\n (X : Type*) [TopologicalSpace X] :\n countably_compact X ↔ ∀ (C : ℕ → Set X), (∀ n, IsClosed (C n)) ∧\n (∀ n, C n ≠ ∅) ∧ (∀ n, C n ⊆ C (n + 1)) → ∃ x, ∀ n, x ∈ C n := sorry", "formal_proof": null, "informal_stmt": "Show that X is countably compact if and only if every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed nonempty sets of X has a nonempty intersection.\n\\begin{proof}\nWe could imitate the proof of Theorem 26.9, but we prove directly each direction. First let $X$ be countable compact and let $C_1 \\supset C_2 \\supset \\cdots$ be a nested sequence of closed nonempty sets of $X$. For each $n \\in \\mathbb{Z}_{+}, U_n=X \\backslash C_n$ is open in $X$. Then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable collection of open sets with no finite subcollection covering $X$, for if $U_{i_1} \\cup \\cdots \\cup U_{1_n}$ covers $X$, then $C_{i_1} \\cap \\cdots \\cap C_{i_n}$ is empty, contrary to the assumption. Hence $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$does not cover $X$, so there exist $x \\in X \\backslash \\bigcup_{n \\in \\mathbb{Z}_{+}} U_n=\\bigcap_{n \\in Z_{+}}\\left(X \\backslash U_n\\right)=\\bigcap_{n \\in Z_{+}} C_n$.\n\nConversely, assume that every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed non-empty sets of $X$ has a non-empty intersection and let $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$be a countable open covering of $X$. For each $n$, let $V_n=U_1 \\cup \\cdots \\cup U_n$ and $C_n=X \\backslash V_n$. Suppose that no finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. Then each $C_n$ is non-empty, so $C_1 \\supset C_2 \\supset \\cdots$ is a nested sequence of non-empty closed sets and $\\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$ is non-empty by assumption. Then there exists $x \\in \\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$, so that $x \\notin V_n$ for all $n$, contradicting the fact that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. It follows that there exists $N \\in \\mathbb{Z}_{+}$such that $C_N=\\emptyset$, so that $X=V_N$ and hence some finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. We deduce that $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_28_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_6 {X : Type*} [MetricSpace X]\n [CompactSpace X] {f : X → X} (hf : Isometry f) :\n Function.Bijective f := sorry", "formal_proof": null, "informal_stmt": "Let $(X, d)$ be a metric space. If $f: X \\rightarrow X$ satisfies the condition $d(f(x), f(y))=d(x, y)$ for all $x, y \\in X$, then $f$ is called an isometry of $X$. Show that if $f$ is an isometry and $X$ is compact, then $f$ is bijective and hence a homeomorphism.\n\\begin{proof}\n Note that $f$ is an imbedding. It remains to prove that $f$ is surjective. Suppose it is not, and let $a \\in f(X)$. Since $X$ is compact, $f(X)$ is compact and hence closed (every metric space is Hausdorff). Thus, there exists $\\varepsilon>0$ such that the $\\varepsilon^{-}$ neighbourhood of $a$ is contained in $X \\backslash f(X)$. Set $x_1=a$, and inductively $x_{n+1}=f\\left(x_n\\right)$ for $n \\in \\mathbb{Z}_{+}$. We show that $d\\left(x_n, x_m\\right) \\geq \\varepsilon$ for $n \\neq m$. Indeed, we may assume $n0$ there exists $\\delta>0$ such that\n$$\nd_Y(f(x), f(y))<\\epsilon \\text { whenever } d_X(x, y)<\\delta \\text { and } x, y \\in A\n$$\nSo for this $\\delta>0$ there exists $N \\in \\mathbb{N}$ such that\n$$\nd_X\\left(x_n, x\\right)<\\frac{\\delta}{2} \\text { and } d_X\\left(y_n, x\\right)<\\frac{\\delta}{2}, \\text { foe all } n \\geq N .\n$$\nTherefore, we have that for all $n \\geq N$,\n$$\nd_X\\left(x_n, y_n\\right)<\\delta\n$$\nThus the equation (1) yields us that\n$$\nd_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)<\\epsilon \\text { for all } n \\geq N .\n$$\nNow since $\\lim _{n \\rightarrow \\infty} f\\left(x_n\\right)=a$ and $b=\\lim _{n \\rightarrow \\infty} f\\left(y_n\\right)$, so for the above $\\epsilon>0$ we have a natural number $K \\geq N$ such that\n$$\n\\begin{gathered}\nd_Y\\left(f\\left(x_n\\right), a\\right)<\\epsilon \\text { for all } n \\geq K \\text { and } \\\\\nd_Y\\left(f\\left(y_n\\right), b\\right)<\\epsilon \\text { for all } n \\geq K .\n\\end{gathered}\n$$\nMoreover, since $K \\geq N$, from $(2)$ we get\n$$\nd_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)<\\epsilon \\text { for all } n \\geq K .\n$$\nNow we calculate the following, for $n \\geq K$,\n$$\n\\begin{array}{rlr}\nd_Y(a, b) & \\leq & d_Y\\left(a, f\\left(x_n\\right)\\right)+d_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)+d\\left(f\\left(y_n\\right), b\\right) \\\\\n& < & \\epsilon+\\epsilon+\\epsilon \\text { by }(3),(4) \\text { and }(5) \\\\\n& = & 3 \\epsilon\n\\end{array}\n$$\nwhere the first inequality holds because of triangular inequality. Since $\\epsilon>0$ is arbitrary the above calculation shows that $d_Y(a, b)=0$. Thus, the above definition is independent of the choice of the sequence $\\left\\{x_n\\right\\}$ and hence the map $g$ is well defined. Moreover, from the construction it follows that $g$ is continuous on $\\bar{A}$.\nMoreover, we observe that $g$ is unique extension of $f$ by the construction.\nSo it remains to show that $g$ is uniformly continuous. In order to that we take a Cauchy sequence $\\left\\{a_n\\right\\} \\subset \\bar{A}$. Then since $\\bar{A}$ is a closed set so the sequence $\\left\\{a_n\\right\\}$ is convergent and hence $\\left\\{g\\left(a_n\\right)\\right\\}$ is also a convergent sequence as $g$ is continuous on $\\bar{A}$. So $\\left\\{g\\left(a_n\\right)\\right\\}$ is a Cauchy sequence in $Y$. Since a function is uniformly continuous if and only if it sends Cauchy sequences to Cauchy sequences, we conclude that $g$ is uniformly continuous.\n\\end{proof}\n\\end{document}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_1E_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_1E_a : ∀ N : ℕ, ∃ n ≥ N, (3*n+1).Prime ∧ (3*n+1) ≥ N := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} +{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_2D_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_2D_a : Irrational (2^((1:ℝ)/3) + 3^((1:ℝ)/3)) := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} +{"name": "Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i (U : Set ℂ) (hU : IsOpen U)\n (hU1 : Nonempty U) (hU2 : IsConnected U) (f : ℕ → ℂ → ℂ) (f' : ℂ → ℂ)\n (hf : ∀ n : ℕ, DifferentiableOn ℂ (f n) U)\n (hf1 : ∀ X ⊂ U, CompactSpace X →\n (TendstoUniformly (λ n => restrict X (f n)) (restrict X f') atTop)) :\n DifferentiableOn ℂ f' U := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} diff --git a/script/build_proofnet_jsonl.py b/script/build_proofnet_jsonl.py new file mode 100644 index 0000000..2847fca --- /dev/null +++ b/script/build_proofnet_jsonl.py @@ -0,0 +1,141 @@ +#!/usr/bin/env python3 +""" +build_proofnet_jsonl.py + +Construct a JSONL dataset from formal Lean files and informal TeX files. +Each entry contains: + - name: combined source filename and theorem/instance name + - source: Lean file name + - header: Lean file header before first theorem/instance + - formal_statement: theorem content with trailing 'sorry' + - formal_proof: proof text or None if contains 'sorry' + - informal_stmt: text after \\paragraph{...} + - informal_proof: text inside \\begin{proof}...\\end{proof} + +Missing informal entries are logged. +""" +import os +import re +import json + + +def parse_formal_file(file_path): + """Parse a Lean file into header and a list of theorem blocks.""" + lines = open(file_path, 'r', encoding='utf-8').read().splitlines() + # extract header before first theorem or instance + idx = 0 + while idx < len(lines) and not re.match(r"^\s*(theorem|instance) ", lines[idx]): + idx += 1 + header = "\n".join(lines[:idx]) + + entries = [] + n = len(lines) + i = idx + # file prefix for name + base = os.path.basename(file_path) + file_prefix = os.path.splitext(base)[0].replace('-', '_') + + while i < n: + line = lines[i] + m_name = re.match(r"\s*(theorem|instance)\s+(\w+)", line) + if m_name: + orig_name = m_name.group(2) + # collect block until blank line + block = [] + while i < n and lines[i].strip() != '': + block.append(lines[i]) + i += 1 + full_text = "\n".join(block) + # split at first ':=' + if ':=' in full_text: + head, sep, tail = full_text.partition(':=') + content = f"{head}{sep} sorry" + proof = tail.strip() or None + else: + raise ValueError(f"Invalid theorem format in {file_path} at line {i + 1}") + # new name + new_name = f"{file_prefix}_{orig_name}" + # update content and proof names + content = content.replace(orig_name, new_name) + if proof: + proof = proof.replace(orig_name, new_name) + entries.append({ + 'orig_name': orig_name, + 'name': new_name, + 'formal_statement': content, + 'formal_proof': None if (proof and 'sorry' in proof) else proof + }) + else: + i += 1 + return header, os.path.basename(file_path), entries + + +def parse_informal_tex(tex_text, orig_name): + """Extract informal statement and proof from TeX text for given original name.""" + # build title: capitalize first part, join numbers with dots + parts = orig_name.split('_') + title = parts[0].capitalize() + ' ' + '.'.join(parts[1:]) + # extract paragraph + pat_stmt = re.compile(rf"\\paragraph\{{\s*{re.escape(title)}\s*\}}(.*?)(?=(\\paragraph|$))", re.DOTALL) + m_stmt = pat_stmt.search(tex_text) + informal_stmt = m_stmt.group(1).strip() if m_stmt else None + # extract proof environment + pat_proof = re.compile(r"\\begin\{proof\}(.*?)\\end\{proof\}", re.DOTALL) + m_proof = pat_proof.search(tex_text) + informal_proof = m_proof.group(1).strip().replace('\n', ' ').strip() if m_proof else None + return informal_stmt, informal_proof + + +def main(): + base = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) + formal_dir = os.path.join(base, 'formal') + informal_dir = os.path.join(base, 'informal') + output_file = os.path.join(base, 'proofnet_lean4.jsonl') + log_missing = [] + + # load all informal texts + informal_texts = {} + for fname in os.listdir(informal_dir): + if fname.endswith('.tex'): + key = os.path.splitext(fname)[0] + path = os.path.join(informal_dir, fname) + informal_texts[key] = open(path, 'r', encoding='utf-8').read() + + # build entries and write jsonl + with open(output_file, 'w', encoding='utf-8') as outp: + for f_name in os.listdir(formal_dir): + if not f_name.endswith('.lean'): continue + fpath = os.path.join(formal_dir, f_name) + # determine the key for informal tex lookup by file name without extension + file_key = os.path.splitext(f_name)[0] + header, source, entries = parse_formal_file(fpath) + for e in entries: + orig = e['orig_name'] + # lookup informal tex by the formal file base name + tex_text = informal_texts.get(file_key) + if tex_text: + inf_stmt, inf_proof = parse_informal_tex(tex_text, orig) + else: + inf_stmt = inf_proof = None + log_missing.append(e['name']) + record = { + 'name': e['name'], + 'source': source, + 'header': header, + 'formal_statement': e['formal_statement'], + 'formal_proof': e['formal_proof'], + 'informal_stmt': inf_stmt, + 'informal_proof': inf_proof + } + json.dump(record, outp, ensure_ascii=False) + outp.write('\n') + + # log missing informal + log_file = os.path.join(base, 'script', 'missing_informal.log') + with open(log_file, 'w', encoding='utf-8') as lf: + for nm in sorted(set(log_missing)): + lf.write(f"{nm}\n") + print(f"Generated {output_file}, logged {len(set(log_missing))} missing informal entries to {log_file}") + +if __name__ == '__main__': + main() From a91661dfd4aa1344b056db6f4a7bf9e3fffcf201 Mon Sep 17 00:00:00 2001 From: subfishzhou Date: Tue, 10 Jun 2025 19:28:51 +0200 Subject: [PATCH 2/3] fix definition dependency --- formal/Munkres.lean | 2 +- proofnet_lean4.jsonl | 28 ++--- script/build_proofnet_jsonl.py | 207 ++++++++++++++++++++++++++++----- 3 files changed, 195 insertions(+), 42 deletions(-) diff --git a/formal/Munkres.lean b/formal/Munkres.lean index 45ae0b8..55c25c8 100644 --- a/formal/Munkres.lean +++ b/formal/Munkres.lean @@ -212,7 +212,7 @@ theorem exercise_23_9 {X Y : Type*} sorry theorem exercise_23_11 {X Y : Type*} [TopologicalSpace X] [TopologicalSpace Y] - (p : X → Y) (hq : QuotientMap p) + (p : X → Y) (hq : IsQuotientMap p) (hY : ConnectedSpace Y) (hX : ∀ y : Y, IsConnected (p ⁻¹' {y})) : ConnectedSpace X := sorry diff --git a/proofnet_lean4.jsonl b/proofnet_lean4.jsonl index 6c15b08..e054f79 100644 --- a/proofnet_lean4.jsonl +++ b/proofnet_lean4.jsonl @@ -214,9 +214,9 @@ {"name": "Rudin_exercise_2_29", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_29 (U : Set ℝ) (hU : IsOpen U) :\n ∃ (f : ℕ → Set ℝ), (∀ n, ∃ a b : ℝ, f n = {x | a < x ∧ x < b}) ∧ (∀ n, f n ⊆ U) ∧\n (∀ n m, n ≠ m → f n ∩ f m = ∅) ∧\n U = ⋃ n, f n := sorry", "formal_proof": null, "informal_stmt": "Prove that every open set in $\\mathbb{R}$ is the union of an at most countable collection of disjoint segments.\n\\begin{proof}\n Let $O$ be open. For each pair of points $x \\in O, y \\in O$, we define an equivalence relation $x \\sim y$ by saying $x \\sim y$ if and only if $[\\min (x, y), \\max (x, y)] \\subset$ 0 . This is an equivalence relation, since $x \\sim x([x, x] \\subset O$ if $x \\in O)$; if $x \\sim y$, then $y \\sim x$ (since $\\min (x, y)=\\min (y, x)$ and $\\max (x, y)=\\max (y, x))$; and if $x \\sim y$ and $y \\sim z$, then $x \\sim z([\\min (x, z), \\max (x, z)] \\subseteq[\\min (x, y), \\max (x, y)] \\cup$ $[\\min (y, z), \\max (y, z)] \\subseteq O)$. In fact it is easy to prove that\n$$\n\\min (x, z) \\geq \\min (\\min (x, y), \\min (y, z))\n$$\nand\n$$\n\\max (x, z) \\leq \\max (\\max (x, y), \\max (y, z))\n$$\nIt follows that $O$ can be written as a disjoint union of pairwise disjoint equivalence classes. We claim that each equivalence class is an open interval.\n\nTo show this, for each $x \\in O$; let $A=\\{z:[z, x] \\subseteq O\\}$ and $B=\\{z:[x, z] \\subseteq$ $O\\}$, and let $a=\\inf A, b=\\sup B$. We claim that $(a, b) \\subset O$. Indeed if $az$. Then $z \\in[c, x] \\cup[x, d] \\subseteq O$. We now claim that $(a, b)$ is the equivalence class containing $x$. It is clear that each element of $(a, b)$ is equivalent to $x$ by the way in which $a$ and $b$ were chosen. We need to show that if $z \\notin(a, b)$, then $z$ is not equivalent to $x$. Suppose that $zb$ and $z \\sim x$, then $b$ could not be an upper bound for $B$.\n\nWe have now established that $O$ is a union of pairwise disjoint open intervals. Such a union must be at most countable, since each open interval contains a rational number not in any other interval.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} {"name": "Rudin_exercise_3_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_1a\n (f : ℕ → ℝ)\n (h : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => f n) atTop (𝓝 a))\n : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => |f n|) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Prove that convergence of $\\left\\{s_{n}\\right\\}$ implies convergence of $\\left\\{\\left|s_{n}\\right|\\right\\}$.\n\\begin{proof}\n Let $\\varepsilon>0$. Since the sequence $\\left\\{s_n\\right\\}$ is a Cauchy sequence, there exists $N$ such that $\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. We then have $\\left| |s_m| - |s_n| \\right| \\leq\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. Hence the sequence $\\left\\{\\left|s_n\\right|\\right\\}$ is also a Cauchy sequence, and therefore must converge.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} {"name": "Rudin_exercise_3_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_2a\n : Tendsto (λ (n : ℝ) => (sqrt (n^2 + n) - n)) atTop (𝓝 (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty}\\sqrt{n^2 + n} -n = 1/2$.\n\\begin{proof}\n Multiplying and dividing by $\\sqrt{n^2+n}+n$ yields\n$$\n\\sqrt{n^2+n}-n=\\frac{n}{\\sqrt{n^2+n}+n}=\\frac{1}{\\sqrt{1+\\frac{1}{n}}+1} .\n$$\nIt follows that the limit is $\\frac{1}{2}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_3\n : ∃ (x : ℝ), Tendsto f atTop (𝓝 x) ∧ ∀ n, f n < 2 := sorry", "formal_proof": null, "informal_stmt": "If $s_{1}=\\sqrt{2}$, and $s_{n+1}=\\sqrt{2+\\sqrt{s_{n}}} \\quad(n=1,2,3, \\ldots),$ prove that $\\left\\{s_{n}\\right\\}$ converges, and that $s_{n}<2$ for $n=1,2,3, \\ldots$.\n\\begin{proof}\n Since $\\sqrt{2}<2$, it is manifest that if $s_n<2$, then $s_{n+1}<\\sqrt{2+2}=2$. Hence it follows by induction that $\\sqrt{2}1$, i.e., $s_n>s_n^2-2=s_{n-1}$. Hence the sequence is an increasing sequence that is bounded above (by 2 ) and so converges. Since the limit $s$ satisfies $s^2-s-2=0$, it follows that the limit is 2.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "noncomputable def f : ℕ → ℝ\n| 0 => sqrt 2\n| (n + 1) => sqrt (2 + sqrt (f n))\n\ntheorem Rudin_exercise_3_3\n : ∃ (x : ℝ), Tendsto f atTop (𝓝 x) ∧ ∀ n, f n < 2 := sorry", "formal_proof": null, "informal_stmt": "If $s_{1}=\\sqrt{2}$, and $s_{n+1}=\\sqrt{2+\\sqrt{s_{n}}} \\quad(n=1,2,3, \\ldots),$ prove that $\\left\\{s_{n}\\right\\}$ converges, and that $s_{n}<2$ for $n=1,2,3, \\ldots$.\n\\begin{proof}\n Since $\\sqrt{2}<2$, it is manifest that if $s_n<2$, then $s_{n+1}<\\sqrt{2+2}=2$. Hence it follows by induction that $\\sqrt{2}1$, i.e., $s_n>s_n^2-2=s_{n-1}$. Hence the sequence is an increasing sequence that is bounded above (by 2 ) and so converges. Since the limit $s$ satisfies $s^2-s-2=0$, it follows that the limit is 2.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} {"name": "Rudin_exercise_3_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_5\n (a b : ℕ → ℝ)\n (h : limsup a + limsup b ≠ 0) :\n limsup (λ n => a n + b n) ≤ limsup a + limsup b := sorry", "formal_proof": null, "informal_stmt": "For any two real sequences $\\left\\{a_{n}\\right\\},\\left\\{b_{n}\\right\\}$, prove that $\\limsup _{n \\rightarrow \\infty}\\left(a_{n}+b_{n}\\right) \\leq \\limsup _{n \\rightarrow \\infty} a_{n}+\\limsup _{n \\rightarrow \\infty} b_{n},$ provided the sum on the right is not of the form $\\infty-\\infty$.\n\\begin{proof}\n Since the case when $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$ and $\\limsup _{n \\rightarrow \\infty} b_n=-\\infty$ has been excluded from consideration, we note that the inequality is obvious if $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$. Hence we shall assume that $\\left\\{a_n\\right\\}$ is bounded above.\n\nLet $\\left\\{n_k\\right\\}$ be a subsequence of the positive integers such that $\\lim _{k \\rightarrow \\infty}\\left(a_{n_k}+\\right.$ $\\left.b_{n_k}\\right)=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Then choose a subsequence of the positive integers $\\left\\{k_m\\right\\}$ such that\n$$\n\\lim _{m \\rightarrow \\infty} a_{n_{k_m}}=\\limsup _{k \\rightarrow \\infty} a_{n_k} .\n$$\nThe subsequence $a_{n_{k_m}}+b_{n_{k_m}}$ still converges to the same limit as $a_{n_k}+b_{n_k}$, i.e., to $\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Hence, since $a_{n_k}$ is bounded above (so that $\\limsup _{k \\rightarrow \\infty} a_{n_k}$ is finite), it follows that $b_{n_{k_m}}$ converges to the difference\n$$\n\\lim _{m \\rightarrow \\infty} b_{n_{k_m}}=\\lim _{m \\rightarrow \\infty}\\left(a_{n_{k_m}}+b_{n_{k_m}}\\right)-\\lim _{m \\rightarrow \\infty} a_{n_{k_m}} .\n$$\nThus we have proved that there exist subsequences $\\left\\{a_{n_{k_m}}\\right\\}$ and $\\left\\{b_{n_{k_m}}\\right\\}$ which converge to limits $a$ and $b$ respectively such that $a+b=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n^*\\right)$. Since $a$ is the limit of a subsequence of $\\left\\{a_n\\right\\}$ and $b$ is the limit of a subsequence of $\\left\\{b_n\\right\\}$, it follows that $a \\leq \\limsup _{n \\rightarrow \\infty} a_n$ and $b \\leq \\limsup _{n \\rightarrow \\infty} b_n$, from which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_6a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_6a\n: Tendsto (λ (n : ℕ) => (∑ i ∈ range n, g i)) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty} \\sum_{i (∑ i ∈ range n, g i)) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty} \\sum_{i (∑ i ∈ (range n), a i)) atTop (𝓝 y))) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), sqrt (a i) / n)) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the convergence of $\\Sigma a_{n}$ implies the convergence of $\\sum \\frac{\\sqrt{a_{n}}}{n}$ if $a_n\\geq 0$.\n\\begin{proof}\n Since $\\left(\\sqrt{a_n}-\\frac{1}{n}\\right)^2 \\geq 0$, it follows that\n$$\n\\frac{\\sqrt{a_n}}{n} \\leq \\frac{1}{2}\\left(a_n^2+\\frac{1}{n^2}\\right) .\n$$\nNow $\\Sigma a_n^2$ converges by comparison with $\\Sigma a_n$ (since $\\Sigma a_n$ converges, we have $a_n<1$ for large $n$, and hence $\\left.a_n^2 (∑ i ∈ (range n), a i)) atTop (𝓝 y)))\n (h2 : Monotone b)\n (h3 : Bornology.IsBounded (Set.range b)) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), (a i) * (b i))) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "If $\\Sigma a_{n}$ converges, and if $\\left\\{b_{n}\\right\\}$ is monotonic and bounded, prove that $\\Sigma a_{n} b_{n}$ converges.\n\\begin{proof}\n We shall show that the partial sums of this series form a Cauchy sequence, i.e., given $\\varepsilon>0$ there exists $N$ such that $\\left|\\sum_{k=m+1}^n a_k b_k\\right|\\langle\\varepsilon$ if $n\\rangle$ $m \\geq N$. To do this, let $S_n=\\sum_{k=1}^n a_k\\left(S_0=0\\right)$, so that $a_k=S_k-S_{k-1}$ for $k=1,2, \\ldots$ Let $M$ be an upper bound for both $\\left|b_n\\right|$ and $\\left|S_n\\right|$, and let $S=\\sum a_n$ and $b=\\lim b_n$. Choose $N$ so large that the following three inequalities hold for all $m>N$ and $n>N$ :\n$$\n\\left|b_n S_n-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m S_m-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M} .\n$$\nThen if $n>m>N$, we have, from the formula for summation by parts,\n$$\n\\sum_{k=m+1}^n a_n b_n=b_n S_n-b_m S_m+\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\n$$\nOur assumptions yield immediately that $\\left|b_n S_n-b_m S_m\\right|<\\frac{2 \\varepsilon}{3}$, and\n$$\n\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\\right| \\leq M \\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right| .\n$$\nSince the sequence $\\left\\{b_n\\right\\}$ is monotonic, we have\n$$\n\\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right|=\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right)\\right|=\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M},\n$$\nfrom which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} {"name": "Rudin_exercise_3_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_13\n (a b : ℕ → ℝ)\n (ha : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |a i|)) atTop (𝓝 y)))\n (hb : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |b i|)) atTop (𝓝 y))) :\n ∃ y, (Tendsto (λ n => (∑ i ∈ (range n),\n λ i => (∑ j ∈ range (i + 1), a j * b (i - j)))) atTop (𝓝 y)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the Cauchy product of two absolutely convergent series converges absolutely.\n\\begin{proof}\n Since both the hypothesis and conclusion refer to absolute convergence, we may assume both series consist of nonnegative terms. We let $S_n=\\sum_{k=0}^n a_n, T_n=\\sum_{k=0}^n b_n$, and $U_n=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l}$. We need to show that $U_n$ remains bounded, given that $S_n$ and $T_n$ are bounded. To do this we make the convention that $a_{-1}=T_{-1}=0$, in order to save ourselves from having to separate off the first and last terms when we sum by parts. We then have\n$$\n\\begin{aligned}\nU_n &=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l} \\\\\n&=\\sum_{k=0}^n \\sum_{l=0}^k a_l\\left(T_{k-l}-T_{k-l-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k a_{k-j}\\left(T_j-T_{j-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k\\left(a_{k-j}-a_{k-j-1}\\right) T_j \\\\\n&=\\sum_{j=0}^n \\sum_{k=j}^n\\left(a_{k-j}-a_{k-j-1}\\right) T_j\n&=\\sum_{j=0}^n a_{n-j} T_j \\\\\n&\\leq T \\sum_{m=0}^n a_m \\\\\n&=T S_n \\\\\n&\\leq S T .\n\\end{aligned}\n$$\nThus $U_n$ is bounded, and hence approaches a finite limit.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} @@ -311,18 +311,18 @@ {"name": "Ireland_Rosen_exercise_18_4", "source": "Ireland-Rosen.lean", "header": "import Mathlib\n\nopen Real\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Ireland_Rosen_exercise_18_4 {n : ℕ} (hn : ∃ x y z w : ℤ,\n x^3 + y^3 = n ∧ z^3 + w^3 = n ∧ x ≠ z ∧ x ≠ w ∧ y ≠ z ∧ y ≠ w) :\n n ≥ 1729 := sorry", "formal_proof": null, "informal_stmt": "Show that 1729 is the smallest positive integer expressible as the sum of two different integral cubes in two ways.\n\\begin{proof}\n Let $n=a^3+b^3$, and suppose that $\\operatorname{gcd}(a, b)=1$. If a prime $p \\mid a^3+b^3$, then\n$$\n\\left(a b^{-1}\\right)^3 \\equiv_p-1\n$$\nThus $3 \\mid \\frac{p-1}{2}$, that is, $p \\equiv_6 1$.\nIf we have $n=a^3+b^3=c^3+d^3$, then we can factor $n$ as\n$$\n\\begin{aligned}\n& n=(a+b)\\left(a^2-a b+b^2\\right) \\\\\n& n=(c+d)\\left(c^2-c d+d^2\\right)\n\\end{aligned}\n$$\nThus we need $n$ to have at least 3 distinct prime factors, and so the smallest taxicab number is on the form\n$$\nn=(6 k+1)(12 k+1)(18 k+1)\n$$\n\\end{proof}\n\\end{document}", "informal_proof": "We have $n^2-1=(n+1)(n-1)$. Since $n$ is odd, both $n+1, n-1$ are even, and moreso, one of these must be divisible by 4 , as one of the two consecutive odd numbers is divisible by 4 . Thus, their product is divisible by 8 . Similarly, if 3 does not divide $n$, it must divide one of $n-1, n+1$, otherwise it wouldn't divide three consecutive integers, which is impossible. As $n$ is odd, $n+1$ is even, so $(n+1)(n-1)$ is divisible by both 2 and 3 , so it is divisible by 6 ."} {"name": "Munkres_exercise_13_1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_1 (X : Type*) [TopologicalSpace X] (A : Set X)\n (h1 : ∀ x ∈ A, ∃ U : Set X, x ∈ U ∧ IsOpen U ∧ U ⊆ A) :\n IsOpen A := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a topological space; let $A$ be a subset of $X$. Suppose that for each $x \\in A$ there is an open set $U$ containing $x$ such that $U \\subset A$. Show that $A$ is open in $X$.\n\\begin{proof}\n Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that\n$$\nA=\\bigcup_{x \\in A} U_x\n$$\nObserve that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_13_3b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_3b : ¬ ∀ X : Type, ∀s : Set (Set X),\n (∀ t : Set X, t ∈ s → (Set.Infinite tᶜ ∨ t = ∅ ∨ t = ⊤)) →\n (Set.Infinite (⋃₀ s)ᶜ ∨ (⋃₀ s) = ∅ ∨ (⋃₀ s) = ⊤) := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $$\\mathcal{T}_\\infty = \\{U | X - U \\text{ is infinite or empty or all of X}\\}$$ does not need to be a topology on the set $X$.\n\\begin{proof}\n Let $X=\\mathbb{R}, U_1=(-\\infty, 0)$ and $U_2=(0, \\infty)$. Then $U_1$ and $U_2$ are in $\\mathcal{T}_{\\infty}$ but $U_1 \\cup U_2=\\mathbb{R} \\backslash\\{0\\}$ is not.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_4a1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4a1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcap \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\begin{proof}\n Since $\\emptyset$ and $X$ belong to $\\mathcal{T}_\\alpha$ for each $\\alpha$, they belong to $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. Let $\\left\\{V_\\beta\\right\\}_\\beta$ be a collection of open sets in $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. For any fixed $\\alpha$ we have $\\cup_\\beta V_\\beta \\in \\mathcal{T}_\\alpha$ since $\\mathcal{T}_\\alpha$ is a topology on $X$, so $\\bigcup_\\beta V_\\beta \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. Similarly, if $U_1, \\ldots, U_n$ are elements of $\\bigcap_\\alpha \\mathcal{T}_\\alpha$, then for each $\\alpha$ we have $\\bigcup_{i=1}^n U_i \\in \\mathcal{T}_\\alpha$ and therefore $\\bigcup_{i=1}^n U_i \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. It follows that $\\bigcap_\\alpha \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_4a2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4a2 :\n ∃ (X I : Type*) (T : I → Set (Set X)),\n (∀ i, is_topology X (T i)) ∧ ¬ is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcup \\mathcal{T}_\\alpha$ does not need to be a topology on $X$.\n\\begin{proof}\n On the other hand, the union $\\bigcup_\\alpha \\mathcal{T}_\\alpha$ is in general not a topology on $X$. For instance, let $X=\\{a, b, c\\}$. Then $\\mathcal{T}_1=\\{\\emptyset, X,\\{a\\}\\}$ and $\\mathcal{T}_2=\\{\\emptyset, X,\\{b\\}\\}$ are topologies on $X$ but $\\mathcal{T}_1 \\cup \\mathcal{T}_2=$ $\\{\\emptyset, X,\\{a\\},\\{b\\}\\}$ is not.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_4b1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4b1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T i ⊆ T') ∧\n ∀ T'', is_topology X T'' → (∀ i, T i ⊆ T'') → T'' ⊆ T' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n (b) First we prove that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. For each $\\alpha$ let $\\mathcal{B}_\\alpha$ be a basis for $\\mathcal{T}_\\alpha$. Let $\\mathcal{T}$ be the topology generated by the subbasis $\\mathcal{S}=\\bigcup_\\alpha \\mathcal{B}_\\alpha$. Then the collection $\\mathcal{B}$ of all finite intersections of elements of $\\mathcal{S}$ is a basis for $\\mathcal{T}$. Clearly $\\mathcal{T}_\\alpha \\subset \\mathcal{T}$ for all $\\alpha$. We now prove that if $\\mathcal{O}$ is a topology on $X$ such that $\\mathcal{T}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, then $\\mathcal{T} \\subset \\mathcal{O}$. Given such $\\mathcal{O}$, we have $\\mathcal{B}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, so $\\mathcal{S} \\subset \\mathcal{O}$. Since $\\mathcal{O}$ is a topology, it must contain all finite intersections of elements of $\\mathcal{S}$, so $\\mathcal{B} \\subset \\mathcal{O}$ and hence $\\mathcal{T} \\subset \\mathcal{O}$. We conclude that the topology $\\mathcal{T}$ generated by the subbasis $\\mathcal{S}=\\cup_\\alpha \\mathcal{B}_\\alpha$ is the unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_4b2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_4b2 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T' ⊆ T i) ∧\n ∀ T'', is_topology X T'' → (∀ i, T'' ⊆ T i) → T' ⊆ T'' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique largest topology on $X$ contained in all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n Now we prove that there exists a unique largest topology contained in all $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. Consider $\\mathcal{T}=\\bigcap_\\alpha \\mathcal{T}_\\alpha$. We already know that $\\mathcal{T}$ is a topology by, and clearly $\\mathcal{T} \\subset \\mathcal{T}_\\alpha$ for all $\\alpha$. If $\\mathcal{O}$ is another topology contained in all $\\mathcal{T}_\\alpha$, it must be contained in their intersection, so $\\mathcal{O} \\subset \\mathcal{T}$. I follows that $\\mathcal{T}$ is the unique largest topology contained in all $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_5a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_5a {X : Type*}\n [TopologicalSpace X] (A : Set (Set X)) (hA : IsTopologicalBasis A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a basis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n Let $\\mathcal{T}$ be the topology generated by $\\mathcal{A}$ and let $\\mathcal{O}$ be the intersection of all topologies on $X$ that contains $\\mathcal{A}$. Clearly $\\mathcal{O} \\subset \\mathcal{T}$ since $\\mathcal{T}$ is a topology on $X$ that contain $\\mathcal{A}$. Conversely, let $U \\in \\mathcal{T}$, so that $U$ is a union of elements of $\\mathcal{A}$. Since each of this elements is also an element of $\\mathcal{O}$, their union $U$ belongs to $\\mathcal{O}$. Thus $\\mathcal{T} \\subset \\mathcal{O}$ and the equality holds.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_5b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_5b {X : Type*}\n [t : TopologicalSpace X] (A : Set (Set X)) (hA : t = generateFrom A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a subbasis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n If we now considered $\\mathcal{A}$ as a subbasis, then the elements of $\\mathcal{T}$ are union of finite intersections of elements of $\\mathcal{A}$. The inclusion $\\mathcal{O} \\subset \\mathcal{T}$ is again clear and $\\mathcal{T} \\subset \\mathcal{O}$ holds since every union of finite intersections of elements of $\\mathcal{A}$ belongs to $\\mathcal{O}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_6 :\n ¬ (∀ U, Rl.IsOpen U → K_topology.IsOpen U) ∧ ¬ (∀ U, K_topology.IsOpen U → Rl.IsOpen U) := sorry", "formal_proof": null, "informal_stmt": "Show that the lower limit topology $\\mathbb{R}_l$ and $K$-topology $\\mathbb{R}_K$ are not comparable.\n\\begin{proof}\n Let $\\mathcal{T}_{\\ell}$ and $\\mathcal{T}_K$ denote the topologies of $\\mathbb{R}_{\\ell}$ and $\\mathbb{R}_K$ respectively. Given the basis element $[0,1)$ for $\\mathcal{T}_{\\ell}$, there is no basis element for $\\mathcal{T}_K$ containing 0 and contained in $[0,1)$, so $\\mathcal{T}_{\\ell} \\not \\subset \\mathcal{T}_K$. Similarly, given the basis element $(-1,1) \\backslash K$ for $\\mathcal{T}_K$, there is no basis element for $\\mathcal{T}_{\\ell}$ containing 0 contained in $(-1,1) \\backslash K$, so $\\mathcal{T}_K \\not \\subset \\mathcal{T}_{\\ell}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4a1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_4a1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcap \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\begin{proof}\n Since $\\emptyset$ and $X$ belong to $\\mathcal{T}_\\alpha$ for each $\\alpha$, they belong to $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. Let $\\left\\{V_\\beta\\right\\}_\\beta$ be a collection of open sets in $\\bigcap_\\alpha \\mathcal{T}_\\alpha$. For any fixed $\\alpha$ we have $\\cup_\\beta V_\\beta \\in \\mathcal{T}_\\alpha$ since $\\mathcal{T}_\\alpha$ is a topology on $X$, so $\\bigcup_\\beta V_\\beta \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. Similarly, if $U_1, \\ldots, U_n$ are elements of $\\bigcap_\\alpha \\mathcal{T}_\\alpha$, then for each $\\alpha$ we have $\\bigcup_{i=1}^n U_i \\in \\mathcal{T}_\\alpha$ and therefore $\\bigcup_{i=1}^n U_i \\in \\bigcap_\\alpha \\mathcal{T}_\\alpha$. It follows that $\\bigcap_\\alpha \\mathcal{T}_\\alpha$ is a topology on $X$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4a2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_4a2 :\n ∃ (X I : Type*) (T : I → Set (Set X)),\n (∀ i, is_topology X (T i)) ∧ ¬ is_topology X (⋂ i : I, T i) := sorry", "formal_proof": null, "informal_stmt": "If $\\mathcal{T}_\\alpha$ is a family of topologies on $X$, show that $\\bigcup \\mathcal{T}_\\alpha$ does not need to be a topology on $X$.\n\\begin{proof}\n On the other hand, the union $\\bigcup_\\alpha \\mathcal{T}_\\alpha$ is in general not a topology on $X$. For instance, let $X=\\{a, b, c\\}$. Then $\\mathcal{T}_1=\\{\\emptyset, X,\\{a\\}\\}$ and $\\mathcal{T}_2=\\{\\emptyset, X,\\{b\\}\\}$ are topologies on $X$ but $\\mathcal{T}_1 \\cup \\mathcal{T}_2=$ $\\{\\emptyset, X,\\{a\\},\\{b\\}\\}$ is not.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4b1", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_4b1 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T i ⊆ T') ∧\n ∀ T'', is_topology X T'' → (∀ i, T i ⊆ T'') → T'' ⊆ T' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n (b) First we prove that there is a unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. For each $\\alpha$ let $\\mathcal{B}_\\alpha$ be a basis for $\\mathcal{T}_\\alpha$. Let $\\mathcal{T}$ be the topology generated by the subbasis $\\mathcal{S}=\\bigcup_\\alpha \\mathcal{B}_\\alpha$. Then the collection $\\mathcal{B}$ of all finite intersections of elements of $\\mathcal{S}$ is a basis for $\\mathcal{T}$. Clearly $\\mathcal{T}_\\alpha \\subset \\mathcal{T}$ for all $\\alpha$. We now prove that if $\\mathcal{O}$ is a topology on $X$ such that $\\mathcal{T}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, then $\\mathcal{T} \\subset \\mathcal{O}$. Given such $\\mathcal{O}$, we have $\\mathcal{B}_\\alpha \\subset \\mathcal{O}$ for all $\\alpha$, so $\\mathcal{S} \\subset \\mathcal{O}$. Since $\\mathcal{O}$ is a topology, it must contain all finite intersections of elements of $\\mathcal{S}$, so $\\mathcal{B} \\subset \\mathcal{O}$ and hence $\\mathcal{T} \\subset \\mathcal{O}$. We conclude that the topology $\\mathcal{T}$ generated by the subbasis $\\mathcal{S}=\\cup_\\alpha \\mathcal{B}_\\alpha$ is the unique smallest topology on $X$ containing all the collections $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_4b2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_4b2 (X I : Type*) (T : I → Set (Set X)) (h : ∀ i, is_topology X (T i)) :\n ∃! T', is_topology X T' ∧ (∀ i, T' ⊆ T i) ∧\n ∀ T'', is_topology X T'' → (∀ i, T'' ⊆ T i) → T' ⊆ T'' := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}_\\alpha$ be a family of topologies on $X$. Show that there is a unique largest topology on $X$ contained in all the collections $\\mathcal{T}_\\alpha$.\n\\begin{proof}\n Now we prove that there exists a unique largest topology contained in all $\\mathcal{T}_\\alpha$. Uniqueness of such topology is clear. Consider $\\mathcal{T}=\\bigcap_\\alpha \\mathcal{T}_\\alpha$. We already know that $\\mathcal{T}$ is a topology by, and clearly $\\mathcal{T} \\subset \\mathcal{T}_\\alpha$ for all $\\alpha$. If $\\mathcal{O}$ is another topology contained in all $\\mathcal{T}_\\alpha$, it must be contained in their intersection, so $\\mathcal{O} \\subset \\mathcal{T}$. I follows that $\\mathcal{T}$ is the unique largest topology contained in all $\\mathcal{T}_\\alpha$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_5a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_5a {X : Type*}\n [TopologicalSpace X] (A : Set (Set X)) (hA : IsTopologicalBasis A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a basis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n Let $\\mathcal{T}$ be the topology generated by $\\mathcal{A}$ and let $\\mathcal{O}$ be the intersection of all topologies on $X$ that contains $\\mathcal{A}$. Clearly $\\mathcal{O} \\subset \\mathcal{T}$ since $\\mathcal{T}$ is a topology on $X$ that contain $\\mathcal{A}$. Conversely, let $U \\in \\mathcal{T}$, so that $U$ is a union of elements of $\\mathcal{A}$. Since each of this elements is also an element of $\\mathcal{O}$, their union $U$ belongs to $\\mathcal{O}$. Thus $\\mathcal{T} \\subset \\mathcal{O}$ and the equality holds.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_5b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def is_topology (X : Type*) (T : Set (Set X)) :=\n univ ∈ T ∧\n (∀ s t, s ∈ T → t ∈ T → s ∩ t ∈ T) ∧\n (∀s, (∀t ∈ s, t ∈ T) → sUnion s ∈ T)\n\ntheorem Munkres_exercise_13_5b {X : Type*}\n [t : TopologicalSpace X] (A : Set (Set X)) (hA : t = generateFrom A) :\n generateFrom A = generateFrom (sInter {T | is_topology X T ∧ A ⊆ T}) := sorry", "formal_proof": null, "informal_stmt": "Show that if $\\mathcal{A}$ is a subbasis for a topology on $X$, then the topology generated by $\\mathcal{A}$ equals the intersection of all topologies on $X$ that contain $\\mathcal{A}$.\n\\begin{proof}\n If we now considered $\\mathcal{A}$ as a subbasis, then the elements of $\\mathcal{T}$ are union of finite intersections of elements of $\\mathcal{A}$. The inclusion $\\mathcal{O} \\subset \\mathcal{T}$ is again clear and $\\mathcal{T} \\subset \\mathcal{O}$ holds since every union of finite intersections of elements of $\\mathcal{A}$ belongs to $\\mathcal{O}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_13_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def lower_limit_topology (X : Type) [Preorder X] :=\n generateFrom {S : Set X | ∃ a b, a < b ∧ S = Ico a b}\n\ndef Rl := lower_limit_topology ℝ\n\ndef K : Set ℝ := {r | ∃ n : ℕ, r = 1 / n}\n\ndef K_topology := generateFrom\n ({S : Set ℝ | ∃ a b, a < b ∧ S = Ioo a b} ∪ {S : Set ℝ | ∃ a b, a < b ∧ S = Ioo a b \\ K})\n\ntheorem Munkres_exercise_13_6 :\n ¬ (∀ U, Rl.IsOpen U → K_topology.IsOpen U) ∧ ¬ (∀ U, K_topology.IsOpen U → Rl.IsOpen U) := sorry", "formal_proof": null, "informal_stmt": "Show that the lower limit topology $\\mathbb{R}_l$ and $K$-topology $\\mathbb{R}_K$ are not comparable.\n\\begin{proof}\n Let $\\mathcal{T}_{\\ell}$ and $\\mathcal{T}_K$ denote the topologies of $\\mathbb{R}_{\\ell}$ and $\\mathbb{R}_K$ respectively. Given the basis element $[0,1)$ for $\\mathcal{T}_{\\ell}$, there is no basis element for $\\mathcal{T}_K$ containing 0 and contained in $[0,1)$, so $\\mathcal{T}_{\\ell} \\not \\subset \\mathcal{T}_K$. Similarly, given the basis element $(-1,1) \\backslash K$ for $\\mathcal{T}_K$, there is no basis element for $\\mathcal{T}_{\\ell}$ containing 0 contained in $(-1,1) \\backslash K$, so $\\mathcal{T}_K \\not \\subset \\mathcal{T}_{\\ell}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_13_8a", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_8a :\n IsTopologicalBasis {S : Set ℝ | ∃ a b : ℚ, a < b ∧ S = Ioo ↑a ↑b} := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $\\{(a,b) \\mid a < b, a \\text{ and } b \\text{ rational}\\}$ is a basis that generates the standard topology on $\\mathbb{R}$.\n\\begin{proof}\n Exercise 13.8. (a) First note that $\\mathcal{B}$ is a basis for a topology on $\\mathbb{R}$. This follows from the fact that the union of its elements is all of $\\mathbb{R}$ and the intersection of two elements of $\\mathcal{B}$ is either empty or another element of $\\mathcal{B}$. Let $\\mathcal{T}$ be the standard topology on $\\mathbb{R}$. Clearly the topology generated by $\\mathcal{B}$ is coarser than $\\mathcal{T}$. Let $U \\in \\mathcal{T}$ and $x \\in U$. Then $U$ contains an open interval with centre $x$. Since the rationals are dense in $\\mathbb{R}$ with the standard topology, there exists $q \\in \\mathbb{Q}$ such that $x \\in(x-q, x+q) \\subset U$. This proves that $\\mathcal{T}$ is coarser than the topology generated by $\\mathcal{B}$. We conclude that $\\mathcal{B}$ generates the standard topology on $\\mathbb{R}$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_13_8b", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_13_8b :\n (generateFrom {S : Set ℝ | ∃ a b : ℚ, a < b ∧ S = Ico ↑a ↑b}).IsOpen ≠\n (lower_limit_topology ℝ).IsOpen := sorry", "formal_proof": null, "informal_stmt": "Show that the collection $\\{(a,b) \\mid a < b, a \\text{ and } b \\text{ rational}\\}$ is a basis that generates a topology different from the lower limit topology on $\\mathbb{R}$.\n\\begin{proof}\n (b) $\\mathcal{C}$ is a basis for a topology on $\\mathbb{R}$ since the union of its elements is $\\mathbb{R}$ and the intersection of two elements of $\\mathcal{C}$ is either empty or another element of $\\mathcal{C}$. Now consider $[r, s)$ where $r$ is any irrational number and $s$ is any real number greater than $r$. Then $[r, s)$ is a basis element for the topology of $\\mathbb{R}_{\\ell}$, but $[r, s)$ is not a union of elements of $\\mathcal{C}$. Indeed, suppose that $[r, s)=\\cup_\\alpha\\left[a_\\alpha, b_\\alpha\\right)$ for rationals $a_\\alpha, b_\\alpha$. Then $r \\in\\left[a_\\alpha, b_\\alpha\\right)$ for some $\\alpha$. Since $r$ is irrational we must have $a_\\alpha min (f x) (g x)) := sorry", "formal_proof": null, "informal_stmt": "Let $Y$ be an ordered set in the order topology. Let $f, g: X \\rightarrow Y$ be continuous. Let $h: X \\rightarrow Y$ be the function $h(x)=\\min \\{f(x), g(x)\\}.$ Show that $h$ is continuous.\n\\begin{proof}\n Let $A=\\{x \\mid f(x) \\leq g(x)\\}$ and $B=\\{x \\mid g(x) \\leq f(x)\\}$. Then $A$ and $B$ are closed in $X$ by (a), $A \\cap B=\\{x \\mid f(x)=g(x)\\}$, and $X=A \\cup B$. Since $f$ and $g$ are continuous, their restrictions $f^{\\prime}: A \\rightarrow Y$ and $g^{\\prime}: B \\rightarrow Y$ are continuous. It follows from the pasting lemma that\n$$\nh: X \\rightarrow Y, \\quad h(x)=\\min \\{f(x), g(x)\\}= \\begin{cases}f^{\\prime}(x) & \\text { if } x \\in A \\\\ g^{\\prime}(x) & \\text { if } x \\in B\\end{cases}\n$$\nis continuous\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} @@ -340,7 +340,7 @@ {"name": "Munkres_exercise_23_4", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_4 {X : Type*} [TopologicalSpace X] [CofiniteTopology X]\n (s : Set X) : Infinite s → IsConnected s := sorry", "formal_proof": null, "informal_stmt": "Show that if $X$ is an infinite set, it is connected in the finite complement topology.\n\\begin{proof}\n Suppose that $A$ is a non-empty subset of $X$ that is both open and closed, i.e., $A$ and $X \\backslash A$ are finite or all of $X$. Since $A$ is non-empty, $X \\backslash A$ is finite. Thus $A$ cannot be finite as $X \\backslash A$ is infinite, so $A$ is all of $X$. Therefore $X$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_23_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_6 {X : Type*}\n [TopologicalSpace X] {A C : Set X} (hc : IsConnected C)\n (hCA : C ∩ A ≠ ∅) (hCXA : C ∩ Aᶜ ≠ ∅) :\n C ∩ (frontier A) ≠ ∅ := sorry", "formal_proof": null, "informal_stmt": "Let $A \\subset X$. Show that if $C$ is a connected subspace of $X$ that intersects both $A$ and $X-A$, then $C$ intersects $\\operatorname{Bd} A$.\n\\begin{proof}\n Suppose that $C \\cap B d A=C \\cap \\bar{A} \\cap \\overline{X-A}=\\emptyset$. Then $C \\cap A$ and $C \\cap(X \\backslash A)$ are a pair of disjoint non-empty sets whose union is all of $C$, neither of which contains a limit point of the other. Indeed, if $C \\cap(X-A)$ contains a limit point $x$ of $C \\cap A$, then $x \\in C \\cap(X-A) \\cap A^{\\prime} \\subset C \\cap \\bar{A} \\cap \\overline{X-A}=\\emptyset$, a contradiction, and similarly $C \\cap A$ does not contain a limit point of $C \\cap(X-A)$. Then $C \\cap A$ and $C \\cap(X-A)$ constitute a separation of $C$, contradicting the fact that $C$ is connected (Lemma 23.1).\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_23_9", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_9 {X Y : Type*}\n [TopologicalSpace X] [TopologicalSpace Y]\n (A₁ A₂ : Set X)\n (B₁ B₂ : Set Y)\n (hA : A₁ ⊂ A₂)\n (hB : B₁ ⊂ B₂)\n (hA : IsConnected A₂)\n (hB : IsConnected B₂) :\n IsConnected ({x | ∃ a b, x = (a, b) ∧ a ∈ A₂ ∧ b ∈ B₂} \\\n {x | ∃ a b, x = (a, b) ∧ a ∈ A₁ ∧ b ∈ B₁}) := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be a proper subset of $X$, and let $B$ be a proper subset of $Y$. If $X$ and $Y$ are connected, show that $(X \\times Y)-(A \\times B)$ is connected.\n\\begin{proof}\nThis is similar to the proof of Theorem 23.6. Take $c \\times d \\in(X \\backslash A) \\times(Y \\backslash B)$. For each $x \\in X \\backslash A$, the set\n$$\nU_x=(X \\times\\{d\\}) \\cup(\\{x\\} \\times Y)\n$$\nis connected since $X \\times\\{d\\}$ and $\\{x\\} \\times Y$ are connected and have the common point $x \\times d$. Then $U=\\bigcup_{x \\in X \\backslash A} U_x$ is connected because it is the union of the connected spaces $U_x$ which have the point $c \\times d$ in common. Similarly, for each $y \\in Y \\backslash B$ the set\n$$\nV_y=(X \\times\\{y\\}) \\cup(\\{c\\} \\times Y)\n$$\nis connected, so $V=\\bigcup_{y \\in Y \\backslash B} V_y$ is connected. Thus $(X \\times Y) \\backslash(A \\times B)=U \\cup V$ is connected since $c \\times d$ is a common point of $U$ and $V$.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_23_11", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_11 {X Y : Type*} [TopologicalSpace X] [TopologicalSpace Y]\n (p : X → Y) (hq : QuotientMap p)\n (hY : ConnectedSpace Y) (hX : ∀ y : Y, IsConnected (p ⁻¹' {y})) :\n ConnectedSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $p: X \\rightarrow Y$ be a quotient map. Show that if each set $p^{-1}(\\{y\\})$ is connected, and if $Y$ is connected, then $X$ is connected.\n\\begin{proof}\n Suppose that $U$ and $V$ constitute a separation of $X$. If $y \\in p(U)$, then $y=p(x)$ for some $x \\in U$, so that $x \\in p^{-1}(\\{y\\})$. Since $p^{-1}(\\{y\\})$ is connected and $x \\in U \\cap p^{-1}(\\{y\\})$, we have $p^{-1}(\\{y\\}) \\subset U$. Thus $p^{-1}(\\{y\\}) \\subset U$ for all $y \\in p(U)$, so that $p^{-1}(p(U)) \\subset U$. The inclusion $U \\subset p^{-1}(p(U))$ if true for any subset and function, so we have the equality $U=p^{-1}(p(U))$ and therefore $U$ is saturated. Similarly, $V$ is saturated. Since $p$ is a quotient map, $p(U)$ and $p(V)$ are disjoint non-empty open sets in $Y$. But $p(U) \\cup p(V)=Y$ as $p$ is surjective, so $p(U)$ and $p(V)$ constitute a separation of $Y$, contradicting the fact that $Y$ is connected. We conclude that $X$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_23_11", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_23_11 {X Y : Type*} [TopologicalSpace X] [TopologicalSpace Y]\n (p : X → Y) (hq : IsQuotientMap p)\n (hY : ConnectedSpace Y) (hX : ∀ y : Y, IsConnected (p ⁻¹' {y})) :\n ConnectedSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $p: X \\rightarrow Y$ be a quotient map. Show that if each set $p^{-1}(\\{y\\})$ is connected, and if $Y$ is connected, then $X$ is connected.\n\\begin{proof}\n Suppose that $U$ and $V$ constitute a separation of $X$. If $y \\in p(U)$, then $y=p(x)$ for some $x \\in U$, so that $x \\in p^{-1}(\\{y\\})$. Since $p^{-1}(\\{y\\})$ is connected and $x \\in U \\cap p^{-1}(\\{y\\})$, we have $p^{-1}(\\{y\\}) \\subset U$. Thus $p^{-1}(\\{y\\}) \\subset U$ for all $y \\in p(U)$, so that $p^{-1}(p(U)) \\subset U$. The inclusion $U \\subset p^{-1}(p(U))$ if true for any subset and function, so we have the equality $U=p^{-1}(p(U))$ and therefore $U$ is saturated. Similarly, $V$ is saturated. Since $p$ is a quotient map, $p(U)$ and $p(V)$ are disjoint non-empty open sets in $Y$. But $p(U) \\cup p(V)=Y$ as $p$ is surjective, so $p(U)$ and $p(V)$ constitute a separation of $Y$, contradicting the fact that $Y$ is connected. We conclude that $X$ is connected.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_24_2", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_24_2 {f : (Metric.sphere 0 1 : Set ℝ) → ℝ}\n (hf : Continuous f) : ∃ x, f x = f (-x) := sorry", "formal_proof": null, "informal_stmt": "Let $f: S^{1} \\rightarrow \\mathbb{R}$ be a continuous map. Show there exists a point $x$ of $S^{1}$ such that $f(x)=f(-x)$.\n\\begin{proof}\n Let $f: S^1 \\rightarrow \\mathbb{R}$ be continuous. Let $x \\in S^1$. If $f(x)=f(-x)$ we are done, so assume $f(x) \\neq f(-x)$. Define $g: S^1 \\rightarrow \\mathbb{R}$ by setting $g(x)=f(x)-f(-x)$. Then $g$ is continuous. Suppose $f(x)>f(-x)$, so that $g(x)>0$. Then $-x \\in S^1$ and $g(-x)<0$. By the intermediate value theorem, since $S^1$ is connected and $g(-x)<00$ and $f(1)<1$. Let $g:[0,1] \\rightarrow[0,1]$ be given by $g(x)=f(x)-x$. Then $g$ is continuous, $g(0)>0$ and $g(1)<0$. Since $[0,1]$ is connected and $g(1)<00$. Therefore $X$ must be uncountable.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_28_4", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_4 {X : Type*}\n [TopologicalSpace X] (hT1 : T1Space X) :\n countably_compact X ↔ limit_point_compact X := sorry", "formal_proof": null, "informal_stmt": "A space $X$ is said to be countably compact if every countable open covering of $X$ contains a finite subcollection that covers $X$. Show that for a $T_1$ space $X$, countable compactness is equivalent to limit point compactness.\n\\begin{proof}\n First let $X$ be a countable compact space. Note that if $Y$ is a closed subset of $X$, then $Y$ is countable compact as well, for if $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $Y$, then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}} \\cup(X \\backslash Y)$ is a countable open covering of $X$; there is a finite subcovering of $X$, hence a finite subcovering of $Y$. Now let $A$ be an infinite subset. We show that $A$ has a limit point. Let $B$ be a countable infinite subset of $A$. Suppose that $B$ has no limit point, so that $B$ is closed in $X$. Then $B$ is countable compact. Since $B$ has no limit point, for each $b \\in B$ there is a neighbourhood $U_b$ of $b$ that intersects $B$ in the point $b$ alone. Then $\\left\\{U_b\\right\\}_{b \\in B}$ is an open covering of $B$ with no finite subcovering, contradicting the fact that $B$ is countable compact. Hence $B$ has a limit point, so that $A$ has a limit point as well. Since $A$ was arbitrary, we deduce that $X$ is limit point compact. (Note that the $T_1$ property is not necessary in this direction.)\n\nNow assume that $X$ is a limit point compact $T_1$ space. We show that $X$ is countable compact. Suppose, on the contrary, that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $X$ with no finite subcovering. For each $n$, take a point $x_n$ in $X$ not in $U_1 \\cup \\cdots \\cup U_n$. By assumption, the infinite set $A=\\left\\{x_n \\mid n \\in \\mathbb{Z}_{+}\\right\\}$has a limit point $y \\in X$. Since $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$, there exists $N \\in \\mathbb{Z}_{+}$such that $y \\in U_1 \\cup \\cdots \\cup U_N$. Now $X$ is $T_1$, so for each $i=1, \\ldots, N$ there exists a neighbourhood $V_i$ of $y$ that does not contain $x_i$. Then\n$$\nV=\\left(V_1 \\cap \\cdots \\cap V_N\\right) \\cap\\left(U_1 \\cup \\cdots \\cup U_N\\right)\n$$\nis a neighbourhood of $y$ that does not contain any of the points $x_i$, contradicting the fact that $y$ is a limit point of $A$. It follows that every countable open covering of $X$ must have a finite subcovering, so $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Munkres_exercise_28_5", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_5\n (X : Type*) [TopologicalSpace X] :\n countably_compact X ↔ ∀ (C : ℕ → Set X), (∀ n, IsClosed (C n)) ∧\n (∀ n, C n ≠ ∅) ∧ (∀ n, C n ⊆ C (n + 1)) → ∃ x, ∀ n, x ∈ C n := sorry", "formal_proof": null, "informal_stmt": "Show that X is countably compact if and only if every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed nonempty sets of X has a nonempty intersection.\n\\begin{proof}\nWe could imitate the proof of Theorem 26.9, but we prove directly each direction. First let $X$ be countable compact and let $C_1 \\supset C_2 \\supset \\cdots$ be a nested sequence of closed nonempty sets of $X$. For each $n \\in \\mathbb{Z}_{+}, U_n=X \\backslash C_n$ is open in $X$. Then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable collection of open sets with no finite subcollection covering $X$, for if $U_{i_1} \\cup \\cdots \\cup U_{1_n}$ covers $X$, then $C_{i_1} \\cap \\cdots \\cap C_{i_n}$ is empty, contrary to the assumption. Hence $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$does not cover $X$, so there exist $x \\in X \\backslash \\bigcup_{n \\in \\mathbb{Z}_{+}} U_n=\\bigcap_{n \\in Z_{+}}\\left(X \\backslash U_n\\right)=\\bigcap_{n \\in Z_{+}} C_n$.\n\nConversely, assume that every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed non-empty sets of $X$ has a non-empty intersection and let $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$be a countable open covering of $X$. For each $n$, let $V_n=U_1 \\cup \\cdots \\cup U_n$ and $C_n=X \\backslash V_n$. Suppose that no finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. Then each $C_n$ is non-empty, so $C_1 \\supset C_2 \\supset \\cdots$ is a nested sequence of non-empty closed sets and $\\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$ is non-empty by assumption. Then there exists $x \\in \\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$, so that $x \\notin V_n$ for all $n$, contradicting the fact that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. It follows that there exists $N \\in \\mathbb{Z}_{+}$such that $C_N=\\emptyset$, so that $X=V_N$ and hence some finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. We deduce that $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_28_4", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def countably_compact (X : Type*) [TopologicalSpace X] :=\n ∀ U : ℕ → Set X,\n (∀ i, IsOpen (U i)) ∧ ((univ : Set X) ⊆ ⋃ i, U i) →\n (∃ t : Finset ℕ, (univ : Set X) ⊆ ⋃ i ∈ t, U i)\n\ndef limit_point_compact (X : Type*) [TopologicalSpace X] :=\n ∀ U : Set X, Infinite U → ∃ x ∈ U, ClusterPt x (𝓟 U)\n\ntheorem Munkres_exercise_28_4 {X : Type*}\n [TopologicalSpace X] (hT1 : T1Space X) :\n countably_compact X ↔ limit_point_compact X := sorry", "formal_proof": null, "informal_stmt": "A space $X$ is said to be countably compact if every countable open covering of $X$ contains a finite subcollection that covers $X$. Show that for a $T_1$ space $X$, countable compactness is equivalent to limit point compactness.\n\\begin{proof}\n First let $X$ be a countable compact space. Note that if $Y$ is a closed subset of $X$, then $Y$ is countable compact as well, for if $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $Y$, then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}} \\cup(X \\backslash Y)$ is a countable open covering of $X$; there is a finite subcovering of $X$, hence a finite subcovering of $Y$. Now let $A$ be an infinite subset. We show that $A$ has a limit point. Let $B$ be a countable infinite subset of $A$. Suppose that $B$ has no limit point, so that $B$ is closed in $X$. Then $B$ is countable compact. Since $B$ has no limit point, for each $b \\in B$ there is a neighbourhood $U_b$ of $b$ that intersects $B$ in the point $b$ alone. Then $\\left\\{U_b\\right\\}_{b \\in B}$ is an open covering of $B$ with no finite subcovering, contradicting the fact that $B$ is countable compact. Hence $B$ has a limit point, so that $A$ has a limit point as well. Since $A$ was arbitrary, we deduce that $X$ is limit point compact. (Note that the $T_1$ property is not necessary in this direction.)\n\nNow assume that $X$ is a limit point compact $T_1$ space. We show that $X$ is countable compact. Suppose, on the contrary, that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable open covering of $X$ with no finite subcovering. For each $n$, take a point $x_n$ in $X$ not in $U_1 \\cup \\cdots \\cup U_n$. By assumption, the infinite set $A=\\left\\{x_n \\mid n \\in \\mathbb{Z}_{+}\\right\\}$has a limit point $y \\in X$. Since $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$, there exists $N \\in \\mathbb{Z}_{+}$such that $y \\in U_1 \\cup \\cdots \\cup U_N$. Now $X$ is $T_1$, so for each $i=1, \\ldots, N$ there exists a neighbourhood $V_i$ of $y$ that does not contain $x_i$. Then\n$$\nV=\\left(V_1 \\cap \\cdots \\cap V_N\\right) \\cap\\left(U_1 \\cup \\cdots \\cup U_N\\right)\n$$\nis a neighbourhood of $y$ that does not contain any of the points $x_i$, contradicting the fact that $y$ is a limit point of $A$. It follows that every countable open covering of $X$ must have a finite subcovering, so $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} +{"name": "Munkres_exercise_28_5", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "def countably_compact (X : Type*) [TopologicalSpace X] :=\n ∀ U : ℕ → Set X,\n (∀ i, IsOpen (U i)) ∧ ((univ : Set X) ⊆ ⋃ i, U i) →\n (∃ t : Finset ℕ, (univ : Set X) ⊆ ⋃ i ∈ t, U i)\n\ntheorem Munkres_exercise_28_5\n (X : Type*) [TopologicalSpace X] :\n countably_compact X ↔ ∀ (C : ℕ → Set X), (∀ n, IsClosed (C n)) ∧\n (∀ n, C n ≠ ∅) ∧ (∀ n, C n ⊆ C (n + 1)) → ∃ x, ∀ n, x ∈ C n := sorry", "formal_proof": null, "informal_stmt": "Show that X is countably compact if and only if every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed nonempty sets of X has a nonempty intersection.\n\\begin{proof}\nWe could imitate the proof of Theorem 26.9, but we prove directly each direction. First let $X$ be countable compact and let $C_1 \\supset C_2 \\supset \\cdots$ be a nested sequence of closed nonempty sets of $X$. For each $n \\in \\mathbb{Z}_{+}, U_n=X \\backslash C_n$ is open in $X$. Then $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$is a countable collection of open sets with no finite subcollection covering $X$, for if $U_{i_1} \\cup \\cdots \\cup U_{1_n}$ covers $X$, then $C_{i_1} \\cap \\cdots \\cap C_{i_n}$ is empty, contrary to the assumption. Hence $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$does not cover $X$, so there exist $x \\in X \\backslash \\bigcup_{n \\in \\mathbb{Z}_{+}} U_n=\\bigcap_{n \\in Z_{+}}\\left(X \\backslash U_n\\right)=\\bigcap_{n \\in Z_{+}} C_n$.\n\nConversely, assume that every nested sequence $C_1 \\supset C_2 \\supset \\cdots$ of closed non-empty sets of $X$ has a non-empty intersection and let $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$be a countable open covering of $X$. For each $n$, let $V_n=U_1 \\cup \\cdots \\cup U_n$ and $C_n=X \\backslash V_n$. Suppose that no finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. Then each $C_n$ is non-empty, so $C_1 \\supset C_2 \\supset \\cdots$ is a nested sequence of non-empty closed sets and $\\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$ is non-empty by assumption. Then there exists $x \\in \\bigcap_{n \\in \\mathbb{Z}_{+}} C_n$, so that $x \\notin V_n$ for all $n$, contradicting the fact that $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. It follows that there exists $N \\in \\mathbb{Z}_{+}$such that $C_N=\\emptyset$, so that $X=V_N$ and hence some finite subcollection of $\\left\\{U_n\\right\\}_{n \\in \\mathbb{Z}_{+}}$covers $X$. We deduce that $X$ is countable compact.\n\\end{proof}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} {"name": "Munkres_exercise_28_6", "source": "Munkres.lean", "header": "import Mathlib\n\nopen Filter Set TopologicalSpace\nopen Topology\nnoncomputable section\n", "formal_statement": "theorem Munkres_exercise_28_6 {X : Type*} [MetricSpace X]\n [CompactSpace X] {f : X → X} (hf : Isometry f) :\n Function.Bijective f := sorry", "formal_proof": null, "informal_stmt": "Let $(X, d)$ be a metric space. If $f: X \\rightarrow X$ satisfies the condition $d(f(x), f(y))=d(x, y)$ for all $x, y \\in X$, then $f$ is called an isometry of $X$. Show that if $f$ is an isometry and $X$ is compact, then $f$ is bijective and hence a homeomorphism.\n\\begin{proof}\n Note that $f$ is an imbedding. It remains to prove that $f$ is surjective. Suppose it is not, and let $a \\in f(X)$. Since $X$ is compact, $f(X)$ is compact and hence closed (every metric space is Hausdorff). Thus, there exists $\\varepsilon>0$ such that the $\\varepsilon^{-}$ neighbourhood of $a$ is contained in $X \\backslash f(X)$. Set $x_1=a$, and inductively $x_{n+1}=f\\left(x_n\\right)$ for $n \\in \\mathbb{Z}_{+}$. We show that $d\\left(x_n, x_m\\right) \\geq \\varepsilon$ for $n \\neq m$. Indeed, we may assume $n Set[str]: + """Extract local variable names from a declaration.""" + local_vars = set() + + # Extract type parameters: {X : Type*}, [TopologicalSpace X] + type_params = re.findall(r'[{\[]([^:\]}]+)\s*:', declaration_text) + for param in type_params: + local_vars.update(name.strip() for name in param.split()) + + # Extract regular parameters: (f : ℕ → ℕ) (p : ℕ → ℝ) + param_matches = re.findall(r'\(([^:)]+)\s*:', declaration_text) + for param in param_matches: + local_vars.update(name.strip() for name in param.split()) + + # Extract existential/universal quantifiers: ∃ (X I : Type*), ∀ i, etc. + quant_matches = re.findall(r'[∃∀]\s*\(?([^:,)]+)(?:\s*:\s*[^,)]+)?[,)]', declaration_text) + for quant in quant_matches: + local_vars.update(name.strip() for name in quant.split()) + + # Extract lambda bindings: λ n =>, λ (k : ℕ) => + lambda_matches = re.findall(r'λ\s*\(?([^:)=]+)(?:\s*:\s*[^)=]+)?\)??\s*=>', declaration_text) + for lam in lambda_matches: + local_vars.update(name.strip() for name in lam.split()) + + return local_vars + + +def find_dependencies(declaration_text: str, local_vars: Set[str], available_defs: Dict[str, int]) -> List[str]: + """Find dependencies of a declaration, excluding local variables.""" + dependencies = [] + + # Extract all identifiers (word boundaries) + identifiers = re.findall(r'\b[a-zA-Z_][a-zA-Z0-9_]*\b', declaration_text) + + seen = set() + for identifier in identifiers: + if (identifier not in local_vars and + identifier not in seen and + identifier in available_defs): + dependencies.append(identifier) + seen.add(identifier) + + # Sort by position in file (available_defs maps name to line number) + dependencies.sort(key=lambda x: available_defs[x]) + return dependencies + + +def parse_declarations(lines: List[str]) -> List[Dict]: + """Parse all declarations (def, theorem, instance, noncomputable def) from Lean file.""" + declarations = [] + i = 0 + n = len(lines) + + while i < n: + line = lines[i] + # Match def, theorem, instance, or noncomputable def + match = re.match(r'^\s*(?:noncomputable\s+)?(def|theorem|instance)\s+(\w+)', line) + if match: + decl_type = match.group(1) + name = match.group(2) + start_line = i + + # Collect the complete declaration until blank line + block = [] + while i < n and lines[i].strip() != '': + block.append(lines[i]) + i += 1 + + full_text = '\n'.join(block) + + declarations.append({ + 'type': decl_type, + 'name': name, + 'text': full_text, + 'start_line': start_line + }) + else: + i += 1 + + return declarations + + +def build_dependency_chain(target_decl: Dict, all_declarations: List[Dict]) -> List[Dict]: + """Build the complete dependency chain for a target declaration.""" + # Build map of available definitions (only defs that appear before target) + available_defs = {} + for decl in all_declarations: + if decl['start_line'] < target_decl['start_line'] and decl['type'] == 'def': + available_defs[decl['name']] = decl['start_line'] + + # Extract local bindings from target declaration + local_vars = extract_local_bindings(target_decl['text']) + + # Find direct dependencies + direct_deps = find_dependencies(target_decl['text'], local_vars, available_defs) + + # Recursively collect dependencies of dependencies + all_deps = [] + processed = set() + + def collect_deps(dep_name: str): + if dep_name in processed: + return + processed.add(dep_name) + + # Find the declaration for this dependency + dep_decl = None + for decl in all_declarations: + if decl['name'] == dep_name and decl['type'] == 'def': + dep_decl = decl + break + + if dep_decl: + # Get local vars for this dependency + dep_local_vars = extract_local_bindings(dep_decl['text']) + # Find its dependencies + sub_deps = find_dependencies(dep_decl['text'], dep_local_vars, available_defs) + + # Recursively collect sub-dependencies first + for sub_dep in sub_deps: + collect_deps(sub_dep) + + # Add this dependency + all_deps.append(dep_decl) + + # Collect all dependencies + for dep in direct_deps: + collect_deps(dep) + + return all_deps def parse_formal_file(file_path): - """Parse a Lean file into header and a list of theorem blocks.""" + """Parse a Lean file into header and a list of theorem blocks with dependencies.""" lines = open(file_path, 'r', encoding='utf-8').read().splitlines() - # extract header before first theorem or instance + + # Parse all declarations + all_declarations = parse_declarations(lines) + + # Extract header before first theorem, instance, def, or noncomputable def idx = 0 - while idx < len(lines) and not re.match(r"^\s*(theorem|instance) ", lines[idx]): + while idx < len(lines) and not re.match(r"^\s*(?:noncomputable\s+)?(def|theorem|instance)\s+", lines[idx]): idx += 1 header = "\n".join(lines[:idx]) - entries = [] - n = len(lines) - i = idx - # file prefix for name + # File prefix for name base = os.path.basename(file_path) file_prefix = os.path.splitext(base)[0].replace('-', '_') - while i < n: - line = lines[i] - m_name = re.match(r"\s*(theorem|instance)\s+(\w+)", line) - if m_name: - orig_name = m_name.group(2) - # collect block until blank line - block = [] - while i < n and lines[i].strip() != '': - block.append(lines[i]) - i += 1 - full_text = "\n".join(block) - # split at first ':=' + entries = [] + + # Process only theorems and instances + for decl in all_declarations: + if decl['type'] in ['theorem', 'instance']: + orig_name = decl['name'] + full_text = decl['text'] + + # Build dependency chain + dep_chain = build_dependency_chain(decl, all_declarations) + + # Split theorem at first ':=' if ':=' in full_text: head, sep, tail = full_text.partition(':=') - content = f"{head}{sep} sorry" + theorem_statement = f"{head}{sep} sorry" proof = tail.strip() or None else: - raise ValueError(f"Invalid theorem format in {file_path} at line {i + 1}") - # new name + # Handle case where theorem has no proof (only declaration) + theorem_statement = full_text + if not theorem_statement.endswith('sorry'): + theorem_statement += ' := sorry' + proof = None + + # Build complete formal statement with dependencies + formal_parts = [] + + # Add dependencies first + for dep in dep_chain: + formal_parts.append(dep['text']) + + # Add the theorem itself + formal_parts.append(theorem_statement) + + # Join with double newlines for readability + complete_formal_statement = '\n\n'.join(formal_parts) + + # New name new_name = f"{file_prefix}_{orig_name}" - # update content and proof names - content = content.replace(orig_name, new_name) + + # Update names in the complete statement + complete_formal_statement = complete_formal_statement.replace(orig_name, new_name) if proof: proof = proof.replace(orig_name, new_name) + entries.append({ 'orig_name': orig_name, 'name': new_name, - 'formal_statement': content, + 'formal_statement': complete_formal_statement, 'formal_proof': None if (proof and 'sorry' in proof) else proof }) - else: - i += 1 + return header, os.path.basename(file_path), entries From d2682e0ad76e41cd2bfa8fe7f15bcf0e64e46c66 Mon Sep 17 00:00:00 2001 From: subfishzhou Date: Tue, 10 Jun 2025 19:43:52 +0200 Subject: [PATCH 3/3] sort jsonl --- .gitignore | 4 +- proofnet_lean4.jsonl | 366 ++++++++++++++++----------------- script/build_proofnet_jsonl.py | 90 +++++--- 3 files changed, 249 insertions(+), 211 deletions(-) diff --git a/.gitignore b/.gitignore index 235402c..9f40c0b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ /build /lake-packages/* -/.lake \ No newline at end of file +/.lake +script/missing_informal.log +script/__pycache__/ \ No newline at end of file diff --git a/proofnet_lean4.jsonl b/proofnet_lean4.jsonl index e054f79..f26840d 100644 --- a/proofnet_lean4.jsonl +++ b/proofnet_lean4.jsonl @@ -1,80 +1,31 @@ -{"name": "Shakarchi_exercise_1_13a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13a {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).re = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Re}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Re}(f)=$ constant,\n$$\n\\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 .\n$$\nThus, in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\n3\nThus $f(z)$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_13b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13b {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).im = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Im}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Im}(f)=$ constant,\n$$\n\\frac{\\partial v}{\\partial x}=0, \\frac{\\partial v}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial u}{\\partial x}=\\frac{\\partial v}{\\partial y}=0 .\n$$\nThus in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\nThus $f$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_13c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13c {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, norm (f z) = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $|f|$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nWe first give a mostly correct argument; the reader should pay attention to find the difficulty. Since $|f|=\\sqrt{u^2+v^2}$ is constant,\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{gathered}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 \\\\\n(1.14) \\Rightarrow \\frac{\\partial v}{\\partial x}=\\frac{v}{u} \\frac{\\partial v}{\\partial y}\n\\end{gathered}\n$$\nPlug (1.15) into (1.13) and we get\n$$\n\\frac{u^2+v^2}{u} \\frac{\\partial v}{\\partial y}=0 .\n$$\nSo $u^2+v^2=0$ or $\\frac{\\partial v}{\\partial y}=0$.\n\nIf $u^2+v^2=0$, then, since $u, v$ are real, $u=v=0$, and thus $f=0$ which is constant.\n\nThus we may assume $u^2+v^2$ equals a non-zero constant, and we may divide by it. We multiply both sides by $u$ and find $\\frac{\\partial v}{\\partial y}=0$, then by (1.15), $\\frac{\\partial v}{\\partial x}=0$, and by Cauchy-Riemann, $\\frac{\\partial u}{\\partial x}=0$.\n$$\nf^{\\prime}=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0 .\n$$\nThus $f$ is constant.\nWhy is the above only mostly a proof? The problem is we have a division by $u$, and need to make sure everything is well-defined. Specifically, we need to know that $u$ is never zero. We do have $f^{\\prime}=0$ except at points where $u=0$, but we would need to investigate that a bit more.\nLet's return to\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{array}{r}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 .\n\\end{array}\n$$\nWe multiply the first equation $u$ and the second by $v$, and obtain\n$$\n\\begin{aligned}\nu^2 \\frac{\\partial v}{\\partial y}+u v \\frac{\\partial v}{\\partial x} & =0 \\\\\n-u v \\frac{\\partial v}{\\partial x}+v^2 \\frac{\\partial v}{\\partial y} & =0 .\n\\end{aligned}\n$$\nAdding the two yields\n$$\nu^2 \\frac{\\partial v}{\\partial y}+v^2 \\frac{\\partial v}{\\partial y}=0,\n$$\nor equivalently\n$$\n\\left(u^2+v^2\\right) \\frac{\\partial v}{\\partial y}=0 .\n$$\nWe now argue in a similar manner as before, except now we don't have the annoying $u$ in the denominator. If $u^2+v^2=0$ then $u=v=0$, else we can divide by $u^2+v^2$ and find $\\partial v / \\partial y=0$. Arguing along these lines finishes the proof.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_19a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19a (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z ^ i)) :\n ¬ ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum nz^n$ does not converge on any point of the unit circle.\n\\begin{proof}\n For $z \\in S:=\\{z \\in \\mathbb{C}:|z|=1\\}$ it also holds $z^n \\in S$ for all $n \\in \\mathbb{N}$ (since in this case $\\left.\\left|z^n\\right|=|z|^n=1^n=1\\right)$\nThus, the sequence $\\left(a_n\\right)_{n \\in \\mathbb{N}}$ with $a_n=n z^n$ does not converge to zero which is necessary for the corresponding sum $\\sum_{n \\in \\mathbb{N}} a_n$ to be convergent. Hence this sum does not converge.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_19b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19b (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i ^ 2)) :\n ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n^2$ converges at every point of the unit circle.\n\\begin{proof}\n Since $\\left|z^n / n^2\\right|=1 / n^2$ for all $|z|=1$, then $\\sum z^n / n^2$ converges at every point in the unit circle as $\\sum 1 / n^2$ does ( $p$-series $p=2$.)\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_19c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19c (z : ℂ) (hz : norm z = 1) (hz2 : z ≠ 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i)) :\n ∃ z, Tendsto s atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n$ converges at every point of the unit circle except $z = 1$.\n\\begin{proof}\n If $z=1$ then $\\sum z^n / n=\\sum 1 / n$ is divergent (harmonic series). If $|z|=1$ and $z \\neq 1$, write $z=e^{2 \\pi i t}$ with $t \\in(0,1)$ and apply Dirichlet's test: if $\\left\\{a_n\\right\\}$ is a sequence of real numbers and $\\left\\{b_n\\right\\}$ a sequence of complex numbers satisfying\n- $a_{n+1} \\leq a_n$\n- $\\lim _{n \\rightarrow \\infty} a_n=0$\n- $\\left|\\sum_{n=1}^N b_n\\right| \\leq M$ for every positive integer $N$ and some $M>0$,\nthen $\\sum a_n b_n$ converges. Let $a_n=1 / n$, so $a_n$ satisfies $a_{n+1} \\leq a_n$ and $\\lim _{n \\rightarrow \\infty} a_n=0$. Let $b_n=e^{2 \\pi i n t}$, then\n$$\n\\left|\\sum_{n=1}^N b_n\\right|=\\left|\\sum_{n=1}^N e^{2 \\pi i n t}\\right|=\\left|\\frac{e^{2 \\pi i t}-e^{2 \\pi i(N+1) t}}{1-e^{2 \\pi i t}}\\right| \\leq \\frac{2}{\\left|1-e^{2 \\pi i t}\\right|}=M \\text { for all } N\n$$\nThus $\\sum a_n b_n=\\sum z^n / n$ converges for every point in the unit circle except $z=1$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_1_26", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_26\n (f F₁ F₂ : ℂ → ℂ) (Ω : Set ℂ) (h1 : IsOpen Ω) (h2 : IsConnected Ω)\n (hF₁ : DifferentiableOn ℂ F₁ Ω) (hF₂ : DifferentiableOn ℂ F₂ Ω)\n (hdF₁ : ∀ x ∈ Ω, deriv F₁ x = f x) (hdF₂ : ∀ x ∈ Ω, deriv F₂ x = f x)\n : ∃ c : ℂ, ∀ x, F₁ x = F₂ x + c := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is continuous in a region $\\Omega$. Prove that any two primitives of $f$ (if they exist) differ by a constant.\n\\begin{proof}\n Suppose $F_1$ and $F_2$ are primitives of $F$. Then $(F_1-F_2)^\\prime = f - f = 0$, therefore $F_1$ and $F_2$ differ by a constant. \n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_2_2", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_2 :\n Tendsto (λ y => ∫ x in (0 : ℝ)..y, Real.sin x / x) atTop (𝓝 (Real.pi / 2)) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_{0}^{\\infty} \\frac{\\sin x}{x} d x=\\frac{\\pi}{2}$.\n\\begin{proof}\n We have $\\int_0^{\\infty} \\frac{\\sin x}{x} d x=\\frac{1}{2 * i} \\int_0^{\\infty} \\frac{e^{i * x}-e^{-i * x}}{x} d x=\\frac{1}{2 * i}\\left(\\int_0^{\\infty} \\frac{e^{i * x}-1}{x} d x-\\int_0^{\\infty} \\frac{e^{-i * x}-1}{x} d x=\\right.$ $\\frac{1}{2 * i} \\int_{-\\infty}^{\\infty} \\frac{e^{i * x}-1}{x} d x$. Now integrate along the big and small semicircles $C_0$ and $C_1$ shown below. For $C_0$ : we have that $\\int_{C_0} \\frac{1}{x} d x=\\pi * i$ and $\\left|\\int_{C_0} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $2 *\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right|+\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right|$ where $C_{00}$ and $C_{01}$ are shown below $\\left(C_{01}\\right.$ contains the part of $C_0$ that has points with imaginary parts more than $a$ and $C_{00}$ is one of the other 2 components). We have $\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $\\sup _{x \\in C_{00}}\\left(e^{i * x}\\right) / R * \\int_{C_{00}}|d x| \\leq e^{-a} * \\pi$ and $\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right| \\leq\\left|\\int_{C_{01}} \\frac{1}{x} d x\\right| \\leq$ $\\frac{1}{R} * C * a$ for some constant $C$ (the constant $C$ exists because the length of the curve approaches $a$ as $a / R \\rightarrow 0)$. Thus, the integral of $e^{i * x} / x$ over $C_0$ is bounded by $A * e^{-a}+B * a / R$ for some constants $A$ and $B$. Pick $R$ large and $a=\\sqrt{R}$ and note that the above tends to 0 . About the integral over $C_1$ : We have $e^{i * x}-1=1+O(x)$ for $x \\rightarrow 0$ (this is again from $\\sin (x) / x \\rightarrow 1$ ),\n4\nso $\\left|\\int_{C_1} \\frac{e^{i * x}-1}{x} d x\\right| \\leq O(1) *\\left|\\int_{C_1} d x\\right| \\rightarrow 0$ as $x \\rightarrow 0$. Thus, we only care about the integral over $C_{00}$ which is $-\\pi * i$. Using Cauchy's theorem we get that our integral equals $\\frac{1}{2 * i}(-(\\pi * i))=\\pi / 2$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_2_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_9\n {f : ℂ → ℂ} (Ω : Set ℂ) (b : Bornology.IsBounded Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (z : Ω) (hz : f z = z) (h'z : deriv f z = 1) :\n ∃ (f_lin : ℂ →L[ℂ] ℂ), ∀ x ∈ Ω, f x = f_lin x := sorry", "formal_proof": null, "informal_stmt": "Let $\\Omega$ be a bounded open subset of $\\mathbb{C}$, and $\\varphi: \\Omega \\rightarrow \\Omega$ a holomorphic function. Prove that if there exists a point $z_{0} \\in \\Omega$ such that $\\varphi\\left(z_{0}\\right)=z_{0} \\quad \\text { and } \\quad \\varphi^{\\prime}\\left(z_{0}\\right)=1$ then $\\varphi$ is linear.\n\\begin{proof}\n When $\\Omega$ is connected, if $\\varphi$ is not linear, then there exists $n \\geq 2$ and $a_n \\neq 0$, such that\n$$\n\\varphi(z)=z+a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nAs you have noticed, by induction, it follows that for every $k \\geq 1$,\n$$\n\\varphi^k(z)=z+k a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nLet $r>0$ be such that when $\\left|z-z_0\\right| \\leq r$, then $z \\in \\Omega$. Then by (1),\n$$\nk a_n=\\frac{1}{2 \\pi i} \\int_{\\left|z-z_0\\right|=r} \\frac{\\varphi^k(z)}{\\left(z-z_0\\right)^{n+1}} d z .\n$$\nSince $\\varphi^k(\\Omega) \\subset \\Omega$ and since $\\Omega$ is bounded, there exists $M>0$, independent of $k$, such that $\\left|\\varphi^k\\right| \\leq M$ on $\\Omega$. Then by (2),\n$$\nk\\left|a_n\\right| \\leq M r^{-n} .\n$$\nSince $k$ is arbitrary, $a_n=0$, a contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_2_13", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_13 {f : ℂ → ℂ}\n (hf : ∀ z₀ : ℂ, ∃ (s : Set ℂ) (c : ℕ → ℂ), IsOpen s ∧ z₀ ∈ s ∧\n ∀ z ∈ s, Tendsto (λ n => ∑ i ∈ range n, (c i) * (z - z₀)^i) atTop (𝓝 (f z₀))\n ∧ ∃ i, c i = 0) :\n ∃ (c : ℕ → ℂ) (n : ℕ), f = λ z => ∑ i ∈ range n, (c i) * z ^ n := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is an analytic function defined everywhere in $\\mathbb{C}$ and such that for each $z_0 \\in \\mathbb{C}$ at least one coefficient in the expansion $f(z) = \\sum_{n=0}^\\infty c_n(z - z_0)^n$ is equal to 0. Prove that $f$ is a polynomial.\n\\begin{proof}\nSay that at least one of the coefficients of the Taylor series vanishes is the same as saying that for every $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$.\nConsider $A_n:=\\left\\{z \\in \\mathbb{C}: f^{(n)}(z)=0\\right\\}$ for each $n \\in \\mathbb{N}$. Note that:\n$f$ is polynomial iff $A_n$ is not countable for some $n \\in \\mathbb{N}$.\nIndeed, if $f$ is polynomial of degree $n$, then $f^{(n+1)}(z)=0$ for all $z \\in \\mathbb{C}$, then $A_{n+1}=\\mathbb{C}$, so, $A_{n+1}$ is not countable. Conversely, if there is $n \\in \\mathbb{C}$ such that $A_n$ is not countable, then $A_n$ has a limit point, then by Identity principle we have $f^{(n)}(z)=0$ for all $z \\in \\mathbb{C}$, so, $f$ is a polynomial of degree at most $n-1$.\n\nTherefore, tt suffices to show that there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable. Indeed, consider $\\bigcup_{n \\in \\mathbb{N}} A_n$, by hypothesis for each $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$, then $\\mathbb{C} \\subseteq \\bigcup_{n \\in \\mathbb{N}} A_n$. Therefore, $\\bigcup_{n \\in \\mathbb{N}} A_n$ is not countable, then there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_3_3", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_3 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, Real.cos x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a) / a))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{\\cos x}{x^2 + a^2} dx = \\pi \\frac{e^{-a}}{a}$ for $a > 0$.\n\\begin{proof}\n $\\cos x=\\frac{e^{i x}+e^{-i x}}{2}$. changing $x \\rightarrow-x$ we see that we can just integrate $e^{i x} /\\left(x^2+a^2\\right)$ and we'll get the same answer. Again, we use the same semicircle and part of the real line. The only pole is $x=i a$, it has order 1 and the residue at it is $\\lim _{x \\rightarrow i a} \\frac{e^{i x}}{x^2+a^2}(x-i a)=\\frac{e^{-a}}{2 i a}$, which multiplied by $2 \\pi i$ gives the answer.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_3_4", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_4 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, x * Real.sin x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a)))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{x \\sin x}{x^2 + a^2} dx = \\pi e^{-a}$ for $a > 0$.\n\\begin{proof}\n$$\nx /\\left(x^2+a^2\\right)=x / 2 i a(1 /(x-i a)-1 /(x+i a))=1 / 2 i a(i a /(x-i a)+i a /(x+\n$$\n$i a))=(1 /(x-i a)+1 /(x+i a)) / 2$. So we care about $\\sin (x)(1 /(x-i a)+$ $1 /(x+i a)) / 2$. Its residue at $x=i a$ is $\\sin (i a) / 2=\\left(e^{-a}-e^a\\right) / 4 i$.?\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_3_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_9 : ∫ x in (0 : ℝ)..(1 : ℝ), Real.log (Real.sin (Real.pi * x)) = - Real.log 2 := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_0^1 \\log(\\sin \\pi x) dx = - \\log 2$.\n\\begin{proof}\nConsider\n$$\n\\begin{gathered}\nf(z)=\\log \\left(1-e^{2 \\pi z i}\\right)=\\log \\left(e^{\\pi z i}\\left(e^{-\\pi z i}-e^{\\pi z i}\\right)\\right)=\\log (-2 i)+\\pi z i+\\log \\\\\n(\\sin (\\pi z))\n\\end{gathered}\n$$\nThen we have\n$$\n\\begin{aligned}\n\\int_0^1 f(z) d z & =\\log (-2 i)+\\frac{i \\pi}{2}+\\int_0^1 \\log (\\sin (\\pi z)) d z \\\\\n& =\\int_0^1 \\log (\\sin (\\pi z)) d z+\\log (-2 i)+\\log (i) \\\\\n& =\\log (2)+\\int_0^1 \\log (\\sin (\\pi z)) d z\n\\end{aligned}\n$$\nNow it suffices to show that $\\int_0^1 f(z) d z=0$. Consider the contour $C(\\epsilon, R)$ (which is the contour given in your question) given by the following.\n1. $C_1(\\epsilon, R)$ : The vertical line along the imaginary axis from $i R$ to $i \\epsilon$.\n2. $C_2(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 0 .\n3. $C_3(\\epsilon)$ : Along the real axis from $(\\epsilon, 1-\\epsilon)$.\n4. $C_4(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 1 .\n5. $C_5(\\epsilon, R)$ : The vertical line from $1+i \\epsilon$ to $1+i R$.\n6. $C_6(R)$ : The horizontal line from $1+i R$ to $i R$.\n$f(z)$ is analytic inside the contour $C$ and hence $\\oint_C f(z)=0$. This gives us\n$$\n\\begin{aligned}\n\\int_{C_1(\\epsilon, R)} f d z+\\int_{C_2(\\epsilon)} f d z+\\int_{C_3(\\epsilon)} f d z+\\int_{C_4(\\epsilon)} f d z+\\int_{C_5(\\epsilon, R)} f d z+\\int_{C_6(R)} f d z \\\\\n=0\n\\end{aligned}\n$$\nNow the integral along 1 cancels with the integral along 5 due to symmetry. Integrals along 2 and 4 scale as $\\epsilon \\log (\\epsilon)$. Integral along 6 goes to 0 as $R \\rightarrow \\infty$. This gives us\n$$\n\\lim _{\\epsilon \\rightarrow 0} \\int_{C_3(\\epsilon)} f d z=0\n$$\nwhich is what we need.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_3_14", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_14 {f : ℂ → ℂ} (hf : Differentiable ℂ f)\n (hf_inj : Function.Injective f) :\n ∃ (a b : ℂ), f = (λ z => a * z + b) ∧ a ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that all entire functions that are also injective take the form $f(z) = az + b$, $a, b \\in \\mathbb{C}$ and $a \\neq 0$.\n\\begin{proof}\nLook at $f(1 / z)$. If it has an essential singularity at 0 , then pick any $z_0 \\neq 0$. Now we know that the range of $f$ is dense as $z \\rightarrow 0$. We also know that the image of $f$ in some small ball around $z_0$ contains a ball around $f\\left(z_0\\right)$. But this means that the image of $f$ around this ball intersects the image of $f$ in any arbitrarily small ball around 0 (because of the denseness). Thus, $f$ cannot be injective. So the singularity at 0 is not essential, so $f(1 / z)$ is some polynomial of $1 / z$, so $f$ is some polynomial of $z$. If its degree is more than 1 it is not injective (fundamental theorem of algebra), so the degree of $f$ is 1 .\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_3_22", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_22 (D : Set ℂ) (hD : D = ball 0 1) (f : ℂ → ℂ)\n (hf : DifferentiableOn ℂ f D) (hfc : ContinuousOn f (closure D)) :\n ¬ ∀ z ∈ (sphere (0 : ℂ) 1), f z = 1 / z := sorry", "formal_proof": null, "informal_stmt": "Show that there is no holomorphic function $f$ in the unit disc $D$ that extends continuously to $\\partial D$ such that $f(z) = 1/z$ for $z \\in \\partial D$.\n\\begin{proof}\n Consider $g(r)=\\int_{|z|=r} f(z) d z$. Cauchy theorem implies that $g(r)=0$ for all $r<1$. Now since $\\left.f\\right|_{\\partial D}=1 / z$ we have $\\lim _{r \\rightarrow 1} \\int_{|z|=r} f(z) d z=\\int_{|z|=1} \\frac{1}{z} d z=\\frac{2}{\\pi i} \\neq 0$. Contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} -{"name": "Shakarchi_exercise_5_1", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_5_1 (f : ℂ → ℂ) (hf : DifferentiableOn ℂ f (ball 0 1))\n (hb : Bornology.IsBounded (Set.range f)) (h0 : f ≠ 0) (zeros : ℕ → ℂ) (hz : ∀ n, f (zeros n) = 0)\n (hzz : Set.range zeros = {z | f z = 0 ∧ z ∈ (ball (0 : ℂ) 1)}) :\n ∃ (z : ℂ), Tendsto (λ n => (∑ i ∈ range n, (1 - zeros i))) atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $f$ is holomorphic in the unit disc, bounded and not identically zero, and $z_{1}, z_{2}, \\ldots, z_{n}, \\ldots$ are its zeros $\\left(\\left|z_{k}\\right|<1\\right)$, then $\\sum_{n}\\left(1-\\left|z_{n}\\right|\\right)<\\infty$.\n\\begin{proof}\n Fix $\\mathrm{N}$ and let $D(0, R)$ contains the first $\\mathrm{N}$ zeroes of f. Let $S_N=\\sum_{k=1}^N\\left(1-\\left|z_k\\right|\\right)=$ $\\sum_{k=1}^N \\int_{\\left|z_k\\right|}^1 1 d r$. Let $\\eta_k$ be the characteristic function of the interval $\\left.\\| z_k \\mid, 1\\right]$. We have $S_N=\\sum_{k=1}^N \\int_0^1 \\eta(r) d r=\\int_0^1\\left(\\sum_{k=1}^N \\eta_k(r)\\right) d r \\leq \\int_0^1 n(r) d r$, where $n(r)$ is the number of zeroes of $f$ at the disk $D(0, r)$. For $r \\leq 1$ we have $n(r) \\leq \\frac{n(r)}{r}$. This means that $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}$. If $f(0)=0$ then we have $f(z)=z^m g(z)$ for some integer $\\mathrm{m}$ and some holomorphic $g$ with $g(0) \\neq 0$. The other zeroes of $\\mathrm{f}$ are precisely the zeroes of $g$. Thus we have reduced the problem to $f(0) \\neq 0$. By the Corollary of the Jensen's equality we get $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}=\\frac{1}{2 \\pi} \\int_0^{2 \\pi} \\log \\left|f\\left(R e^{i \\pi}\\right)\\right| d \\phi-\\log |f(0)|j$ (just reverse the roles of $i$ and $j$ otherwise). Then multiply both sides by $\\left(a^j\\right)^{-1}=a^{-j}$ to get\n$$\na^i * a^{-j}=a^{i-j}=e\n$$\nThus the $n=i-j$ is a positive integer such that $a^n=e$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 0$ such that $a^m = e$ for all $a \\in G$.\n\\begin{proof}\n Let $n_1, n_2, \\ldots, n_k$ be the orders of all $k$ elements of $G=$ $\\left\\{a_1, a_2, \\ldots, a_k\\right\\}$. Let $m=\\operatorname{lcm}\\left(n_1, n_2, \\ldots, n_k\\right)$. Then, for any $i=$ $1, \\ldots, k$, there exists an integer $c$ such that $m=n_i c$. Thus\n$$\na_i^m=a_i^{n_i c}=\\left(a_i^{n_i}\\right)^c=e^c=e\n$$\nHence $m$ is a positive integer such that $a^m=e$ for all $a \\in G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n ∀ a b : G, (a*b)^i = a^i * b^i}\n (hP1 : ∃ n : ℕ, P n ∧ P (n+1) ∧ P (n+2)) : CommGroup G := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group in which $(a b)^{i}=a^{i} b^{i}$ for three consecutive integers $i$, prove that $G$ is abelian.\n\\begin{proof}\n Let $G$ be a group, $a, b \\in G$ and $i$ be any integer. Then from given condition,\n$$\n\\begin{aligned}\n(a b)^i & =a^i b^i \\\\\n(a b)^{i+1} & =a^{i+1} b^{i+1} \\\\\n(a b)^{i+2} & =a^{i+2} b^{i+2}\n\\end{aligned}\n$$\nFrom first and second, we get\n$$\na^{i+1} b^{i+1}=(a b)^i(a b)=a^i b^i a b \\Longrightarrow b^i a=a b^i\n$$\nFrom first and third, we get\n$$\na^{i+2} b^{i+2}=(a b)^i(a b)^2=a^i b^i a b a b \\Longrightarrow a^2 b^{i+1}=b^i a b a\n$$\nThis gives\n$$\na^2 b^{i+1}=a\\left(a b^i\\right) b=a b^i a b=b^i a^2 b\n$$\nFinally, we get\n$$\nb^i a b a=b^i a^2 b \\Longrightarrow b a=a b\n$$\nThis shows that $G$ is Abelian.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1)\n (h : ∀ (a b : G), (a * b) ^ n = a ^ n * b ^ n) :\n ∀ (a b : G), (a * b * a⁻¹ * b⁻¹) ^ (n * (n - 1)) = 1 := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a group in which $(a b)^{n}=a^{n} b^{n}$ for some fixed integer $n>1$ for all $a, b \\in G$. For all $a, b \\in G$, prove that $\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e$. \n\\begin{proof}\n We start with the following two intermediate results.\n(1) $(a b)^{n-1}=b^{n-1} a^{n-1}$.\n(2) $a^n b^{n-1}=b^{n-1} a^n$.\nTo prove (1), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen,\n$(b a)^n=b^n a^n \\Longrightarrow b .(a b)(a b) \\ldots .(a b) . a=b\\left(b^{n-1} a^{n-1}\\right) a$, where $(a b)$ occurs $n-1$ times $\\Longrightarrow(a b)^{n-1}=b^{n-1} a^{n-1}$, by cancellation law.\nHence, for all $a, b \\in G$\n$$\n(a b)^{n-1}=b^{n-1} a^{n-1} .\n$$\nTo prove (2), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen we have\n$$\n\\begin{aligned}\n& (b a)^n=b^n a^n \\\\\n\\Longrightarrow & b \\cdot(a b)(a b) \\ldots(a b) \\cdot a=b\\left(b^{n-1} a^{n-1}\\right) a, \\text { where }(a b) \\text { occurs } n-1 \\text { times } \\\\\n\\Longrightarrow & (a b)^{n-1}=b^{n-1} a^{n-1}, \\text { by cancellation law } \\\\\n\\Longrightarrow & (a b)^{n-1}(a b)=\\left(b^{n-1} a^{n-1}\\right)(a b) \\\\\n\\Longrightarrow & (a b)^n=b^{n-1} a^n b \\\\\n\\Longrightarrow & a^n b^n=b^{n-1} a^n b, \\text { given condition } \\\\\n\\Longrightarrow & a^n b^{n-1}=b^{n-1} a^n, \\text { by cancellation law. }\n\\end{aligned}\n$$\nTherefore for all $a, b \\in G$ we have\n$$\na^n b^{n-1}=b^{n-1} a^n\n$$\nIn order to show that\n$$\n\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { for all } a, b \\in G\n$$\nit is enough to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nStep 3\nThis is because of\n$$\n\\begin{aligned}\n(a b)^{n(n-1)}=(b a)^{n(n-1)} & \\left.\\Longrightarrow(b a)^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(a^{-1} b^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}\\left((a b)^n\\right)(n-1)=e \\\\\n& \\Longrightarrow\\left((a b)^n\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}=e, \\text { by }(1) \\\\\n& \\Longrightarrow\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { ( given condition) }\n\\end{aligned}\n$$\nNow, it suffices to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nNow, we have\n$$\n\\begin{aligned}\n(a b)^{n(n-1)} & =\\left(a^n b^n\\right)^{n-1}, \\text { by the given condition } \\\\\n& =\\left(a^n b^{n-1} b\\right)^{n-1} \\\\\n& =\\left(b^{n-1} a^n b\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^n b\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =b^{n-1}\\left(a^n\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =\\left(b^{n-1}\\left(a^{n-1}\\right)^n\\right)\\left(b^{n-1}\\right)^{n-1} \\\\\n& =\\left(a^{n-1}\\right)^n b^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^{n-1}\\right)^n\\left(b^{n-1}\\right)^n \\\\\n& =\\left(a^{n-1} b^{n-1}\\right)^n, \\text { by }(1) \\\\\n& =(b a)^{n(n-1)}, \\text { by }(1) .\n\\end{aligned}\n$$\nThis completes our proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x⁻¹*g*x) '' (centralizer {a}) := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group and $a, x \\in G$, prove that $C\\left(x^{-1} a x\\right)=x^{-1} C(a) x$\n\\begin{proof}\n Note that\n$$\nC(a):=\\{x \\in G \\mid x a=a x\\} .\n$$\nLet us assume $p \\in C\\left(x^{-1} a x\\right)$. Then,\n$$\n\\begin{aligned}\n& p\\left(x^{-1} a x\\right)=\\left(x^{-1} a x\\right) p \\\\\n\\Longrightarrow & \\left(p x^{-1} a\\right) x=x^{-1}(a x p) \\\\\n\\Longrightarrow & x\\left(p x^{-1} a\\right)=(a x p) x^{-1} \\\\\n\\Longrightarrow & \\left(x p x^{-1}\\right) a=a\\left(x p x^{-1}\\right) \\\\\n\\Longrightarrow & x p x^{-1} \\in C(a) .\n\\end{aligned}\n$$\nTherefore,\n$$\np \\in C\\left(x^{-1} a x\\right) \\Longrightarrow x p x^{-1} \\in C(a) .\n$$\nThus,\n$$\nC\\left(x^{-1} a x\\right) \\subset x^{-1} C(a) x .\n$$\nLet us assume\n$$\nq \\in x^{-1} C(a) x .\n$$\nThen there exists an element $y$ in $C(a)$ such that\n$$\nq=x^{-1} y x\n$$\nNow,\n$$\ny \\in C(a) \\Longrightarrow y a=a y .\n$$\nAlso,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=x^{-1}(y a) x=x^{-1}(y a) x=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q .\n$$\nTherefore,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q\n$$\nSo,\n$$\nq \\in C\\left(x^{-1} a x\\right) .\n$$\nConsequently we have\n$$\nx^{-1} C(a) x \\subset C\\left(x^{-1} a x\\right) .\n$$\nIt follows from the aforesaid argument\n$$\nC\\left(x^{-1} a x\\right)=x^{-1} C(a) x .\n$$\nThis completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1) :\n n ∣ (a ^ n - 1).totient := sorry", "formal_proof": null, "informal_stmt": "If $a > 1$ is an integer, show that $n \\mid \\varphi(a^n - 1)$, where $\\phi$ is the Euler $\\varphi$-function.\n\\begin{proof}\n Proof: We have $a>1$. First we propose to prove that\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nIf possible, let us assume that\n$\\operatorname{Gcd}\\left(a, a^n-1\\right)=d$, where $d>1$.\nThen\n$d$ divides $a$ as well as $a^n-1$.\nNow,\n$d$ divides $a \\Longrightarrow d$ divides $a^n$.\nThis is an impossibility, since $d$ divides $a^n-1$ by our assumption. Consequently, $d$ divides 1 , which implies $d=1$. Hence we are contradict to the fact that $d>1$. Therefore\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nThen $a \\in U_{a^n-1}$, where $U_n$ is a group defined by\n$$\nU_n:=\\left\\{\\bar{a} \\in \\mathbb{Z}_n \\mid \\operatorname{Gcd}(a, n)=1\\right\\} .\n$$\nWe know that order of an element divides the order of the group. Here order of the group $U_{a^n-1}$ is $\\phi\\left(a^n-1\\right)$ and $a \\in U_{a^n-1}$. This follows that $\\mathrm{o}(a)$ divides $\\phi\\left(a^n-1\\right)$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $nn$. By lagrange's theorem then $p^{2 n-s}\\left|p^n m \\Longrightarrow p^{n-s}\\right| m \\Longrightarrow p \\mid m$-contradiction. So $\\phi(H)=H$, and $H$ is characteristic subgroup of $G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n\\frac{|G|}{2}$, where\n$$\nb^{-1} A=\\left\\{b^{-1} a \\mid a \\in A\\right\\}\n$$\nFirst notice that if we consider a map $f: A \\rightarrow b^{-1} A$ defined by $f(a)=b^{-1} a$, for all $a \\in A$, then $f$ is a 1-1 map and so $\\left|b^{-1} A\\right| \\geq|A|>\\frac{3}{4}|G|$. Now using inclusion-exclusion principle we have\n$$\n\\left|A \\cap\\left(b^{-1} A\\right)\\right|=|A|+\\left|b^{-1} A\\right|-\\left|A \\cup\\left(b^{-1} A\\right)\\right|>\\frac{3}{4}|G|+\\frac{3}{4}|G|-|G|=\\frac{1}{2}|G|\n$$\n2. Argue that $A \\cap\\left(b^{-1} A\\right) \\subseteq C(b)$, where $C(b)$ is the centralizer of $b$ in $G$.\n\nSuppose $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in A$ and $x \\in b^{-1} A$. Thus there exist an element $a \\in A$ such that $x=$ $b^{-1} a$, which gives us $x b=a \\in A$. Now notice that $x, b \\in A$ and $x b \\in A$, therefore we get\n$$\n\\phi(x b)=(x b)^{-1} \\Longrightarrow \\phi(x) \\phi(b)=(x b)^{-1} \\Longrightarrow x^{-1} b^{-1}=b^{-1} x^{-1} \\Longrightarrow x b=b x\n$$\nTherefore, we get $x b=b x$, for any $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in C(b)$.\n\n3. Argue that $C(b)=G$.\nWe know that centralizer of an element in a group $G$ is a subgroup (See Page 53). Therefore $C(b)$ is a subgroup of $G$. From statements $\\mathbf{1}$ and $\\mathbf{2}$, we have\n$$\n|C(b)| \\geq\\left|A \\cap\\left(b^{-1} A\\right)\\right|>\\frac{|G|}{2}\n$$\nWe need to use the following remark to argue $C(b)=G$ from the above step.\nRemark. Let $G$ be a finite group and $H$ be a subgroup with more then $|G| / 2$ elements then $H=G$.\n\nProof of Remark. Suppose $|H|=p$ Then by Lagrange Theorem, there exist an $n \\in \\mathbb{N}$, such that $|G|=n p$, as $|H|$ divide $|G|$. Now by hypothesis $p>\\frac{G]}{2}$ gives us,\n$$\np>\\frac{|G|}{2} \\Longrightarrow n p>\\frac{n|G|}{2} \\Longrightarrow n<2 \\Longrightarrow n=1\n$$\nTherefore we get $H=G$.\n\nNow notice that $C(b)$ is a subgroup of $G$ with $C(b)$ having more than $|G| / 2$ elements. Therefore, $C(b)=G$.\n\n4. Show that $A \\in Z(G)$.\n\nWe know that $x \\in Z(G)$ if and only if $C(a)=G$. Now notice that, for any $b \\in A$ we have $C(b)=G$. Therefore, every element of $A$ is in the center of $G$, that means, $A \\subseteq Z(G)$.\n\n5. 5how that $Z(G)=G$.\n\nAs it is given that $|A|>\\frac{3|G|}{4}$ and $A \\leq|Z(G)|$, therefore we get\n$$\n|Z(G)|>\\frac{3}{4}|G|>\\frac{1}{2}|G| .\n$$\nAs $Z(G)$ is a subgroup of $G$, so by the above Remark we have $Z(G)=G$. Hence $G$ is abelian.\n\n6. Finally show that $A=G$.\n\nFirst notice that $A$ is a subgroup of $G$. To show this let $p, q \\in A$. Then we have\n$$\n\\phi(p q)=\\phi(p) \\phi(q)=p^{-1} q^{-1}=(q p)^{-1}=(p q)^{-1}, \\quad \\text { As } G \\text { is abelian. }\n$$\nTherefore, $p q \\in A$ and so we have $A$ is a subgroup of $G$. Again by applying the above remark. we get $A=G$. Therefore we have\n$$\n\\phi(y)=y^{-1}, \\quad \\text { for all } y \\in G\n$$\n\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n q) (h1 : q ∣ p - 1) (hG : card G = p*q) (hH : card G = p*q) :\n G ≃* H := sorry", "formal_proof": null, "informal_stmt": "Prove that if $p > q$ are two primes such that $q \\mid p - 1$, then any two nonabelian groups of order $pq$ are isomorphic.\n\\begin{proof}\n For a nonabelian group of order $p q$, the structure of the group $G$ is set by determining the relation $a b a^{-1}=b^{k^{\\frac{p-1}{q}}}$ for some generator $k$ of the cyclic group. Here we are using the fact that $k^{\\frac{p-1}{q}}$ is a generator for the unique subgroup of order $q$ in $U_p$ (a cyclic group of order $m$ has a unique subgroup of order $d$ for each divisor $d$ of $m$ ). The other possible generators of this subgroup are $k^{\\frac{l(p-1)}{q}}$ for each $1 \\leq l \\leq q-1$, so these give potentially new group structures. Let $G^{\\prime}$ be a group with an element $c$ of order $q$, an element $d$ of order $p$ with structure defined by the relation $c d c^{-1}=d^{k^{\\frac{l(p-1)}{q}}}$. We may then define\n$$\n\\begin{aligned}\n\\phi: G^{\\prime} & \\rightarrow G \\\\\nc & \\mapsto a^l \\\\\nd & \\mapsto b\n\\end{aligned}\n$$\nsince $c$ and $a^l$ have the same order and $b$ and $d$ have the same order this is a well defined function.\nSince\n$$\n\\begin{aligned}\n\\phi(c) \\phi(d) \\phi(c)^{-1} & =a^l b a^{-l} \\\\\n& =b^{\\left(k^{\\frac{p-1}{q}}\\right)^l} \\\\\n& =b^{k^{\\frac{l(p-1)}{q}}} \\\\\n& =\\phi(d)^{k^{\\frac{l(p-1)}{q}}}\n\\end{aligned}\n$$\n$\\phi\\left(c^i d^j\\right)=a^{l i} b^j=e$ only if $i=j=0$, so $\\phi$ is 1-to-l. Therefore $G$ and $G^{\\prime}$ are isomorphic and so up to isomorphism there is only one nonabelian group of order $p q$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n1$. Let $g^k$ be an element of $G$ and $h^j$ be an element of $H$. Since the lowest common multiple of $n$ and $m$ is lower than the product $n . m$, that is, $\\operatorname{lcm}(n, m)1$, then $Z(G)$, the center of $G$, has more than one element; that is, if $|G|=p^k$ with $k\\geq 1$, then $|Z(G)|>1$.\n\n\\textit{Proof of the lemma:} Consider the class equation\n$$\n|G|=|Z(G)|+\\sum_{a \\notin Z(G)}[G: C(a)],\n$$\nwhere $C(a)$ denotes the centralizer of $a$ in $G$. If $G=Z(G)$, then the lemma is immediate. Suppose $Z(G)$ is a proper subset of $G$ and consider an element $a\\in G$ such that $a\\notin Z(G)$. Then $C(a)$ is a proper subgroup of $G$. Since $C(a)$ is a subgroup of a $p$-group, $[G:C(a)]$ is divisible by $p$ for all $a\\notin Z(G)$. This implies that $p$ divides $|G|=|Z(G)|+\\sum_{a\\notin Z(G)} [G:C(a)]$.\n\nSince $p$ also divides $|G|$, it follows that $p$ divides $|Z(G)|$. Hence, $|Z(G)|>1$. $\\Box$\n\nThis proves our \\textbf{lemma}.\n\nWe will prove the result by induction on $n$.\nIf $n=1$, the $G$ is a cyclic group of prime order and hence every subgroup of $G$ is normal in $G$. Thus, the result is true for $n=1$.\nSuppose the result is true for all groups of order $p^m$, where $1 \\leq mp^{n-1}$. Thus, $|N(H)|=p^n$ and $N(H)=G$.\nIn this case $H$ is normal in $G$.\nLet $H=N(H)$. Then $Z(G)$, the center of $G$, is a subset of $H$ and $Z(G) \\neq$ $\\{e\\}$.\nBy Cauchy's theorem and the above Claim, there exists $a \\in Z(G)$ such that $o(a)=p$.\nLet $K=\\langle a\\rangle$, a cyclic group generated by $a$.\nThen $K$ is a normal subgroup of $G$ of order $p$. Now, $|H / K|=p^{n-2}$ and $|G / K|=p^{n-1}$.\nThus, by induction hypothesis, $H / K$ is a normal subgroup of $G / K$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n3$.\nLet us take $p=3$. Then the sum\n$$\n\\frac{1}{1}+\\frac{1}{2}+\\ldots+\\frac{1}{(p-1)}\n$$\nbecomes\n$$\n1+\\frac{1}{3-1}=1+\\frac{1}{2}=\\frac{3}{2} .\n$$\nTherefore in this case $\\quad \\frac{a}{b}=\\frac{3}{2} \\quad$ implies $3 \\mid a$, i.e. $p \\mid a$.\nNow for odd prime $p>3$.\nLet us consider $f(x)=(x-1)(x-2) \\ldots(x-(p-1))$.\nNow, by Fermat, we know that the coefficients of $f(x)$ other than the $x^{p-1}$ and $x^0$ are divisible by $p$.\nSo if,\n$$\n\\begin{array}{r}\nf(x)=x^{p-1}+\\sum_{i=0}^{p-2} a_i x^i \\\\\n\\text { and } p>3 .\n\\end{array}\n$$\nThen $p \\mid a_2$, and\n$$\nf(p) \\equiv a_1 p+a_0 \\quad\\left(\\bmod p^3\\right)\n$$\nBut we see that\n$$\nf(x)=(-1)^{p-1} f(p-x) \\text { for any } x,\n$$\nso if $p$ is odd,\n$$\nf(p)=f(0)=a_0,\n$$\nSo it follows that:\n$$\n0=f(p)-a_0 \\equiv a_1 p \\quad\\left(\\bmod p^3\\right)\n$$\nTherefore,\n$$\n0 \\equiv a_1 \\quad\\left(\\bmod p^2\\right) .\n$$\nHence,\n$$\n0 \\equiv a_1 \\quad(\\bmod p) .\n$$\nNow our sum is just $\\frac{a_1}{(p-1) !}=\\frac{a}{b}$.\nIt follows that $p$ divides $a$. This completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x^5 + sqrt 2 * x^3 + sqrt 5 * x^2 + sqrt 7 * x + 11)\n (ha : p a = 0) :\n ∃ p : Polynomial ℂ , p.degree < 80 ∧ a ∈ p.roots ∧\n ∀ n : p.support, ∃ a b : ℤ, p.coeff n = a / b := sorry", "formal_proof": null, "informal_stmt": "If $a \\in C$ is such that $p(a) = 0$, where $p(x) = x^5 + \\sqrt{2}x^3 + \\sqrt{5}x^2 + \\sqrt{7}x + \\sqrt{11}$, show that $a$ is algebraic over $\\mathbb{Q}$ of degree at most 80.\n\\begin{proof}\n Given $a \\in \\mathbb{C}$ such that $p(a)=0$, where\n$$\np(x)=x^5+\\sqrt{2} x^3+\\sqrt{5} x^2+\\sqrt{7} x+\\sqrt{11}\n$$\nHere, we note that $p(x) \\in \\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$ and\n$$\n\\begin{aligned}\n {[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): \\mathbb{Q}] } & =[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7})] \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}): \\mathbb{Q}(\\sqrt{2}, \\sqrt{5})] \\\\\n& \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}): \\mathbb{Q}(\\sqrt{2})] \\cdot[\\mathbb{Q}(\\sqrt{2}): \\mathbb{Q}] \\\\\n& =2 \\cdot 2 \\cdot 2 \\cdot 2 \\\\\n& =16\n\\end{aligned}\n$$\nHere, we note that $p(x)$ is of degree 5 over $\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. If $a$ is root of $p(x)$, then\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}]=[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\cdot 15\n$$\nand $[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\leq 5$. We get equality if $p(x)$ is irreducible over $Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. This gives\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}] \\leq 16 \\cdot 5=80\n$$\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n p (f n)) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Let $(p_n)$ be a sequence and $f:\\mathbb{N}\\to\\mathbb{N}$. The sequence $(q_k)_{k\\in\\mathbb{N}}$ with $q_k=p_{f(k)}$ is called a rearrangement of $(p_n)$. Show that if $f$ is an injection, the limit of a sequence is unaffected by rearrangement.\n\\begin{proof}\n Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_26", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_26 {M : Type*} [TopologicalSpace M]\n (U : Set M) : IsOpen U ↔ ∀ x ∈ U, ¬ ClusterPt x (𝓟 Uᶜ) := sorry", "formal_proof": null, "informal_stmt": "Prove that a set $U \\subset M$ is open if and only if none of its points are limits of its complement.\n\\begin{proof}\n Assume that none of the points of $U$ are limits of its complement, and let us prove that $U$ is open. Assume by contradiction that $U$ is not open, so there exists $p \\in M$ so that $\\forall r>0$ there exists $q \\in M$ with $d(p, q)0$ such that $d(p, x)0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_29", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_29 (M : Type*) [MetricSpace M]\n (O C : Set (Set M))\n (hO : O = {s | IsOpen s})\n (hC : C = {s | IsClosed s}) :\n ∃ f : O → C, Bijective f := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}$ be the collection of open subsets of a metric space $\\mathrm{M}$, and $\\mathcal{K}$ the collection of closed subsets. Show that there is a bijection from $\\mathcal{T}$ onto $\\mathcal{K}$.\n\\begin{proof}\n The bijection given by $x\\mapsto X^C$ suffices. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_32a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_32a (A : Set ℕ) : IsClopen A := sorry", "formal_proof": null, "informal_stmt": "Show that every subset of $\\mathbb{N}$ is clopen.\n\\begin{proof}\n 32. The one-point set $\\{n\\} \\subset \\mathbb{N}$ is open, since it contains all $m \\in \\mathbb{N}$ that satisfy $d(m, n)<\\frac{1}{2}$. Every subset of $\\mathbb{N}$ is a union of one-point sets, hence is open. Then every set it closed, since its complement is necessarily open.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_41", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_41 (m : ℕ) {X : Type*} [NormedSpace ℝ ((Fin m) → ℝ)] :\n IsCompact (Metric.closedBall 0 1) := sorry", "formal_proof": null, "informal_stmt": "Let $\\|\\cdot\\|$ be any norm on $\\mathbb{R}^{m}$ and let $B=\\left\\{x \\in \\mathbb{R}^{m}:\\|x\\| \\leq 1\\right\\}$. Prove that $B$ is compact.\n\\begin{proof}\n Let us call $\\|\\cdot\\|_E$ the Euclidean norm in $\\mathbb{R}^m$. We start by claiming that there exist constants $C_1, C_2>0$ such that\n$$\nC_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E, \\forall x \\in \\mathbb{R}^m .\n$$\nAssuming (1) to be true, let us finish the problem. First let us show that $B$ is bounded w.r.t. $d_E$, which is how we call the Euclidean distance in $\\mathbb{R}^m$. Indeed, given $x \\in B,\\|x\\|_E \\leq \\frac{1}{C_1}\\|x\\| \\leq \\frac{1}{C_1}$. Hence $B \\subset\\left\\{x \\in \\mathbb{R}^m: d_E(x, 0)<\\frac{1}{C_1}+1\\right\\}$, which means $B$ is bounded w.r.t $d_E$.\nNow let us show that $B$ is closed w.r.t. $d_E$. Let $x_n \\rightarrow x$ w.r.t. $d_E$, where $x_n \\in B$. Notice that this implies that $x_n \\rightarrow x$ w.r.t. $d(x, y)=\\|x-y\\|$, the distance coming from $\\|\\cdot\\|$, since by (1) we have\n$$\nd\\left(x_n, x\\right)=\\left\\|x_n-x\\right\\| \\leq C_2\\left\\|x_n-x\\right\\|_E \\rightarrow 0 .\n$$\nAlso, notice that\n$$\n\\|x\\| \\leq\\left\\|x_n-x\\right\\|+\\left\\|x_n\\right\\| \\leq\\left\\|x_n-x\\right\\|+1,\n$$\nhence passing to the limit we obtain that $\\|x\\| \\leq 1$, therefore $x \\in B$ and so $B$ is closed w.r.t. $d_E$. Since $B$ is closed and bounded w.r.t. $d_E$, it must be compact. Now we claim that the identity function, $i d:\\left(\\mathbb{R}^m, d_E\\right) \\rightarrow\\left(\\mathbb{R}^m, d\\right)$ where $\\left(\\mathbb{R}^m, d_E\\right)$ means we are using the distance $d_E$ in $\\mathbb{R}^m$ and $\\left(\\mathbb{R}^m, d\\right)$ means we are using the distance $d$ in $\\mathbb{R}^m$, is a homeomorphism. This follows by (1), since $i d$ is always a bijection, and it is continuous and its inverse is continuous by (1) (if $x_n \\rightarrow x$ w.r.t. $d_E$, then $x_n \\rightarrow x$ w.r.t. $d$ and vice-versa, by (1)). By a result we saw in class, since $B$ is compact in $\\left(\\mathbb{R}^m, d_E\\right)$ and $i d$ is a homeomorphism, then $i d(B)=B$ is compact w.r.t. $d$.\n\nWe are left with proving (1). Notice that it suffices to prove that $C_1 \\leq\\|x\\| \\leq$ $C_2, \\forall x \\in \\mathbb{R}^m$ with $\\|x\\|_E=1$. Indeed, if this is true, given $x \\in \\mathbb{R}^m$, either $\\|x\\|_E=0$ (which implies $x=0$ and (1) holds in this case), or $x /\\|x\\|_E=y$ is such that $\\|y\\|_E=1$, so $C_1 \\leq\\|y\\| \\leq C_2$, which implies $C_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E$.\nWe want to show now that $\\|\\cdot\\|$ is continuous w.r.t. $d_E$, that is, given $\\varepsilon>0$ and $x \\in \\mathbb{R}^m$, there exists $\\delta>0$ such that if $d_E(x, y)<\\delta$, then $\\|\\mid x\\|-\\|y\\| \\|<\\varepsilon$.\n\nBy the triangle inequality, $\\|x\\|-\\|y\\| \\leq\\|x-y\\|$, and $\\|y\\|-\\|x\\| \\leq\\|x-y\\|$, therefore\n$$\n|\\|x||-\\| y|\\|\\leq\\| x-y \\| .\n$$\nWriting now $x=\\sum_{i=1}^m a_i e_i, y=\\sum_{i=1}^m b_i e_i$, where $e_i=(0, \\ldots, 1,0, \\ldots, 0)$ (with 1 in the i-th component), we obtain by the triangle inequality,\n$$\n\\begin{aligned}\n\\|x-y\\| & =\\left\\|\\sum_{i=1}^m\\left(a_i-b_i\\right) e_i\\right\\| \\leq \\sum_{i=1}^m\\left|a_i-b_i\\left\\|\\left|\\left\\|e_i\\right\\| \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| \\sum_{i=1}^m\\right| a_i-b_i \\mid\\right.\\right. \\\\\n& =\\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| d_{s u m}(x, y) \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_{\\max }(x, y) \\\\\n& \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_E(x, y) .\n\\end{aligned}\n$$\nLet $\\delta=\\frac{\\varepsilon}{m \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\|}$. Then if $d_E(x, y)<\\delta,\\|x\\|-\\|y\\|||<\\varepsilon$.\nSince $\\|\\cdot\\|$ is continuous w.r.t. $d_E$ and $K=\\left\\{x \\in \\mathbb{R}^m:\\|x\\|_E=1\\right\\}$ is compact w.r.t. $d_E$, then the function $\\|\\cdot\\|$ achieves a maximum and a minimum value on $K$. Call $C_1=\\min _{x \\in K}\\|x\\|, C_2=\\max _{x \\in K}\\|x\\|$. Then\n$$\nC_1 \\leq\\|x\\| \\leq C_2, \\forall x \\in \\mathbb{R}^m \\text { such that }\\|x\\|_E=1,\n$$\nwhich is what we needed.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_46", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_46 {M : Type*} [MetricSpace M]\n {A B : Set M} (hA : IsCompact A) (hB : IsCompact B)\n (hAB : Disjoint A B) (hA₀ : A ≠ ∅) (hB₀ : B ≠ ∅) :\n ∃ a₀ b₀, a₀ ∈ A ∧ b₀ ∈ B ∧ ∀ (a : M) (b : M),\n a ∈ A → b ∈ B → dist a₀ b₀ ≤ dist a b := sorry", "formal_proof": null, "informal_stmt": "Assume that $A, B$ are compact, disjoint, nonempty subsets of $M$. Prove that there are $a_0 \\in A$ and $b_0 \\in B$ such that for all $a \\in A$ and $b \\in B$ we have $d(a_0, b_0) \\leq d(a, b)$.\n\\begin{proof}\nLet $A$ and $B$ be compact, disjoint and non-empty subsets of $M$. We want to show that there exist $a_0 \\in A, b_0 \\in B$ such that for all $a \\in A, b \\in B$,\n$$\nd\\left(a_0, b_0\\right) \\leq d(a, b) .\n$$\nWe saw in class that the distance function $d: M \\times M \\rightarrow \\mathbb{R}$ is continuous. We also saw in class that any continuous, real-valued function assumes maximum and minimum values on a compact set. Since $A$ and $B$ are compact, $A \\times B$ is (non-empty) compact in $M \\times M$. Therefore there exists $\\left(a_0, b_0\\right) \\in A \\times B$ such that $d\\left(a_0, b_0\\right) \\leq d(a, b), \\forall(a, b) \\in A \\times B$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_57", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_57 {X : Type*} [TopologicalSpace X]\n : ∃ (S : Set X), IsConnected S ∧ ¬ IsConnected (interior S) := sorry", "formal_proof": null, "informal_stmt": "Show that if $S$ is connected, it is not true in general that its interior is connected.\n\\begin{proof}\n Consider $X=\\mathbb{R}^2$ and\n$$\nA=([-2,0] \\times[-2,0]) \\cup([0,2] \\times[0,2])\n$$\nwhich is connected, while $\\operatorname{int}(A)$ is not connected.\nTo see this consider the continuous function $f: \\mathbb{R}^2 \\rightarrow \\mathbb{R}$ is defined by $f(x, y)=x+y$. Let $U=f^{-1}(0,+\\infty)$ which is open in $\\mathbb{R}^2$ and so $U \\cap \\operatorname{int}(A)$ is open in $\\operatorname{int}(A)$. Also, since $(0,0) \\notin \\operatorname{int}(A)$, so for all $(x, y) \\in \\operatorname{int}(A), f(x, y) \\neq 0$ and $U \\cap \\operatorname{int}(A)=f^{-1}[0,+\\infty) \\cap \\operatorname{int}(A)$ is closed in $\\operatorname{int}(A)$. Furthermore, $(1,1)=f^{-1}(2) \\in U \\cap \\operatorname{int}(A)$ shows that $U \\cap \\operatorname{int}(A) \\neq \\emptyset$ while $(-1,-1) \\in \\operatorname{int}(A)$ and $(-1,-1) \\notin U$ shows that $U \\cap \\operatorname{int}(A) \\neq \\operatorname{int}(A)$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_92", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_92 {α : Type*} [TopologicalSpace α]\n {s : ℕ → Set α}\n (hs : ∀ i, IsCompact (s i))\n (hs : ∀ i, (s i).Nonempty)\n (hs : ∀ i, (s i) ⊃ (s (i + 1))) :\n (⋂ i, s i).Nonempty := sorry", "formal_proof": null, "informal_stmt": "Give a direct proof that the nested decreasing intersection of nonempty covering compact sets is nonempty.\n\\begin{proof}\n Let\n$$\nA_1 \\supset A_2 \\supset \\cdots \\supset A_n \\supset \\cdots\n$$\nbe a nested decreasing sequence of compacts. Suppose that $\\bigcap A_n=\\emptyset$. Take $U_n=A_n^c$, then\n$$\n\\bigcup U_n=\\bigcup A_n^c=\\left(\\bigcap A_n\\right)^c=A_1 .\n$$\nHere, I'm thinking of $A_1$ as the main metric space. Since $\\left\\{U_n\\right\\}$ is an open covering of $A_1$, we can extract a finite subcovering, that is,\n$$\nA_{\\alpha_1}^c \\cup A_{\\alpha_2}^c \\cup \\cdots \\cup A_{\\alpha_m}^c \\supset A_1\n$$\nor\n$$\n\\left(A_1 \\backslash A_{\\alpha_1}\\right) \\cup\\left(A_1 \\backslash A_{\\alpha_2}\\right) \\cup \\cdots \\cup\\left(A_1 \\backslash A_{\\alpha_m}\\right) \\supset A_1 .\n$$\nBut, this is true only if $A_{\\alpha_i}=\\emptyset$ for some $i$, a contradiction.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_2_126", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_126 {E : Set ℝ}\n (hE : ¬ Set.Countable E) : ∃ (p : ℝ), ClusterPt p (𝓟 E) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $E$ is an uncountable subset of $\\mathbb{R}$. Prove that there exists a point $p \\in \\mathbb{R}$ at which $E$ condenses.\n\\begin{proof}\n I think this is the proof by contrapositive that you were getting at.\nSuppose that $E$ has no limit points at all. Pick an arbitrary point $x \\in E$. Then $x$ cannot be a limit point, so there must be some $\\delta>0$ such that the ball of radius $\\delta$ around $x$ contains no other points of $E$ :\n$$\nB_\\delta(x) \\cap E=\\{x\\}\n$$\nCall this \"point 1 \". For the next point, take the closest element to $x$ and on its left; that is, choose the point\n$$\n\\max [E \\cap(-\\infty, x)]\n$$\nif it exists (that is important - if not, skip to the next step). Note that by the argument above, this supremum, should it exist, cannot equal $x$ and is therefore a new point in $E$.\n\nCall this \"point 2 \". Now take the first point to the right of $x$ for \"point 3 \". Take the first point to the left of point 2 for \"point 4 \". And so on, ad infinitum.\n\nThis gives a countable list of unique points; we must show that it exhausts the entire set $E$. Suppose not. Suppose there is some element $aa_1 \\in E$ such that $a_2$ is not in the list. Repeating, we generate an infinite monotone-increasing sequence $\\left\\{a_i\\right\\}$ of elements in $E$ and not in the list, which is clearly bounded above by $x$. By the Monotone\nConvergence Theorem this sequence has a limit. But that means the sequence $\\left\\{a_i\\right\\} \\subset E$ converges to a limit, and hence $E$ has a limit point, contradicting the assumption. Therefore our list exhausts $E$, and we have enumerated all its elements.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_3_1", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_1 {f : ℝ → ℝ}\n (hf : ∀ x y, |f x - f y| ≤ |x - y| ^ 2) :\n ∃ c, f = λ x => c := sorry", "formal_proof": null, "informal_stmt": "Assume that $f \\colon \\mathbb{R} \\rightarrow \\mathbb{R}$ satisfies $|f(t)-f(x)| \\leq|t-x|^{2}$ for all $t, x$. Prove that $f$ is constant.\n\\begin{proof}\n We have $|f(t)-f(x)| \\leq|t-x|^2, \\forall t, x \\in \\mathbb{R}$. Fix $x \\in \\mathbb{R}$ and let $t \\neq x$. Then\n$$\n\\left|\\frac{f(t)-f(x)}{t-x}\\right| \\leq|t-x| \\text {, hence } \\lim _{t \\rightarrow x}\\left|\\frac{f(t)-f(x)}{t-x}\\right|=0 \\text {, }\n$$\nso $f$ is differentiable in $\\mathbb{R}$ and $f^{\\prime}=0$. This implies that $f$ is constant, as seen in class.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_3_4", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_4 (n : ℕ) :\n Tendsto (λ n => (sqrt (n + 1) - sqrt n)) atTop (𝓝 0) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sqrt{n+1}-\\sqrt{n} \\rightarrow 0$ as $n \\rightarrow \\infty$.\n\\begin{proof}\n $$\n\\sqrt{n+1}-\\sqrt{n}=\\frac{(\\sqrt{n+1}-\\sqrt{n})(\\sqrt{n+1}+\\sqrt{n})}{\\sqrt{n+1}+\\sqrt{n}}=\\frac{1}{\\sqrt{n+1}+\\sqrt{n}}<\\frac{1}{2 \\sqrt{n}}\n$$\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_3_63a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63a (p : ℝ) (f : ℕ → ℝ) (hp : p > 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ converges when $p > 1$.\n\\begin{proof}\n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_3_63b", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63b (p : ℝ) (f : ℕ → ℝ) (hp : p ≤ 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ¬ ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ diverges when $p \\leq 1$.\n\\begin{proof} \n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} -{"name": "Pugh_exercise_4_15a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_4_15a {α : Type*}\n (a b : ℝ) (F : Set (ℝ → ℝ)) :\n (∀ x : ℝ, ∀ ε > 0, ∃ U ∈ (𝓝 x),\n (∀ y z : U, ∀ f : ℝ → ℝ, f ∈ F → (dist (f y) (f z) < ε)))\n ↔\n ∃ (μ : ℝ → ℝ), ∀ (x : ℝ), (0 : ℝ) ≤ μ x ∧ Tendsto μ (𝓝 0) (𝓝 0) ∧\n (∀ (s t : ℝ) (f : ℝ → ℝ), f ∈ F → |(f s) - (f t)| ≤ μ (|s - t|)) := sorry", "formal_proof": null, "informal_stmt": "A continuous, strictly increasing function $\\mu \\colon (0, \\infty) \\rightarrow (0, \\infty)$ is a modulus of continuity if $\\mu(s) \\rightarrow 0$ as $s \\rightarrow 0$. A function $f \\colon [a, b] \\rightarrow \\mathbb{R}$ has modulus of continuity $\\mu$ if $|f(s) - f(t)| \\leq \\mu(|s - t|)$ for all $s, t \\in [a, b]$. Prove that a function is uniformly continuous if and only if it has a modulus of continuity.\n\\begin{proof}\n Suppose there exists a modulus of continuity $w$ for $f$, then fix $\\varepsilon>0$, since $\\lim _{s \\rightarrow 0} w(s)=0$, there exists $\\delta>0$ such that for any $|s|<\\delta$, we have $w(s)<\\varepsilon$, then we have for any $x, z \\in X$ such that $d_X(x, z)<\\delta$, we have $d_Y(f(x), f(z)) \\leq w\\left(d_X(x, z)\\right)<\\varepsilon$, which means $f$ is uniformly continuous.\n\nSuppose $f:\\left(X, d_X\\right) \\rightarrow\\left(Y, d_Y\\right)$ is uniformly continuous.\nLet $\\delta_1>0$ be such that $d_X(a, b)<\\delta_1$ implies $d_Y(f(a), f(b))<1$.\nDefine $w:[0, \\infty) \\rightarrow[0, \\infty]$ by\n$$\nw(s)= \\begin{cases}\\left.\\sup \\left\\{d_Y(f(a), f(b))\\right\\} \\mid d_X(a, b) \\leq s\\right\\} & \\text { if } s \\leq \\delta_1 \\\\ \\infty & \\text { if } s>\\delta_1\\end{cases}\n$$\nWe'll show that $w$ is a modulus of continuity for $f \\ldots$\nBy definition of $w$, it's immediate that $w(0)=0$ and it's clear that\n$$\nd_Y(f(a), f(b)) \\leq w\\left(d_X(a, b)\\right)\n$$\nfor all $a, b \\in X$.\nIt remains to show $\\lim _{s \\rightarrow 0^{+}} w(s)=0$.\nIt's easily seen that $w$ is nonnegative and non-decreasing, hence $\\lim _{s \\rightarrow 0^{+}}=L$ for some $L \\geq 0$, where $L=\\inf w((0, \\infty))$\nLet $\\epsilon>0$.\nBy uniform continuity of $f$, there exists $\\delta>0$ such that $d_X(a, b)<\\delta$ implies $d_Y(f(a), f(b))<\\epsilon$, hence by definition of $w$, we get $w(\\delta) \\leq \\epsilon$.\nThus $L \\leq \\epsilon$ for all $\\epsilon>0$, hence $L=0$.\nThis completes the proof.\n\\end{proof}\n\\end{document}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Artin_exercise_2_2_9", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_2_9 {G : Type*} [Group G] {a b : G}\n (h : a * b = b * a) :\n ∀ x y : closure {x | x = a ∨ x = b}, x*y = y*x := sorry", "formal_proof": null, "informal_stmt": "Let $H$ be the subgroup generated by two elements $a, b$ of a group $G$. Prove that if $a b=b a$, then $H$ is an abelian group.\n\\begin{proof}\n Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_3_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_3_2 {G : Type*} [Group G] (a b : G) :\n ∃ g : G, b* a = g * a * b * g⁻¹ := sorry", "formal_proof": null, "informal_stmt": "Prove that the products $a b$ and $b a$ are conjugate elements in a group.\n\\begin{proof}\n We have that $(a^{-1})ab(a^{-1})^{-1} = ba$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_4_19", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_4_19 {G : Type*} [Group G] {x : G}\n (hx : orderOf x = 2) (hx1 : ∀ y, orderOf y = 2 → y = x) :\n x ∈ center G := sorry", "formal_proof": null, "informal_stmt": "Prove that if a group contains exactly one element of order 2 , then that element is in the center of the group.\n\\begin{proof}\n Let $x$ be the element of order two. Consider the element $z=y^{-1} x y$, we have: $z^2=\\left(y^{-1} x y\\right)^2=\\left(y^{-1} x y\\right)\\left(y^{-1} x y\\right)=e$. So: $z=x$, and $y^{-1} x y=x$. So: $x y=y x$. So: $x$ is in the center of $G$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_8_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Artin_exercise_2_8_6 {G H : Type*} [Group G] [Group H] :\n center (G × H) ≃* (center G) × (center H) := sorry", "formal_proof": null, "informal_stmt": "Prove that the center of the product of two groups is the product of their centers.\n\\begin{proof}\n We have that $(g_1, g_2)\\cdot (h_1, h_2) = (h_1, h_2)\\cdot (g_1, g_2)$ if and only if $g_1h_1 = h_1g_1$ and $g_2h_2 = h_2g_2$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_2_11_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_11_3 {G : Type*} [Group G] [Fintype G]\n (hG : Even (card G)) : ∃ x : G, orderOf x = 2 := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of even order contains an element of order $2 .$\n\\begin{proof}\n Pair up if possible each element of $G$ with its inverse, and observe that\n$$\ng^2 \\neq e \\Longleftrightarrow g \\neq g^{-1} \\Longleftrightarrow \\text { there exists the pair }\\left(g, g^{-1}\\right)\n$$\nNow, there is one element that has no pairing: the unit $e$ (since indeed $e=e^{-1} \\Longleftrightarrow e^2=e$ ), so since the number of elements of $G$ is even there must be at least one element more, say $e \\neq a \\in G$, without a pairing, and thus $a=a^{-1} \\Longleftrightarrow a^2=e$\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_2_7", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_2_7 {F : Type*} [Field F] {G : Type*} [Field G]\n (φ : F →+* G) : Injective φ := sorry", "formal_proof": null, "informal_stmt": "Prove that every homomorphism of fields is injective.\n\\begin{proof}\n Suppose $f(a)=f(b)$, then $f(a-b)=0=f(0)$. If $u=(a-b) \\neq 0$, then $f(u) f\\left(u^{-1}\\right)=f(1)=1$, but that means that $0 f\\left(u^{-1}\\right)=1$, which is impossible. Hence $a-b=0$ and $a=b$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_5_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_5_6 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {S : Set V} (hS : Set.Countable S)\n (hS1 : span K S = ⊤) {ι : Type*} (R : ι → V)\n (hR : LinearIndependent K R) : Countable ι := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space which is spanned by a countably infinite set. Prove that every linearly independent subset of $V$ is finite or countably infinite.\n\\begin{proof}\n Let $A$ be the countable generating set, and let $U$ be an uncountable linearly independent set. It can be extended to a basis $B$ of the whole space. Now consider the subset $C$ of elements of $B$ that appear in the $B$-decompositions of elements of $A$.\nSince only finitely many elements are involved in the decomposition of each element of $A$, the set $C$ is countable. But $C$ also clearly generates the vector space $V$. This contradicts the fact that it is a proper subset of the basis $B$ (since $B$ is uncountable).\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_3_7_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_7_2 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {ι : Type*} [Fintype ι] (γ : ι → Submodule K V)\n (h : ∀ i : ι, γ i ≠ ⊤) :\n (⋂ (i : ι), (γ i : Set V)) ≠ ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space over an infinite field $F$. Prove that $V$ is not the union of finitely many proper subspaces.\n\\begin{proof}\n If $V$ is the set-theoretic union of $n$ proper subspaces $W_i$ ( $1 \\leq i \\leq n$ ), then $|F| \\leq n-1$.\nProof. We may suppose no $W_i$ is contained in the union of the other subspaces. Let $u \\in W_i, \\quad u \\notin \\bigcup_{j \\neq i} W_j$ and $v \\notin W_i$.\nThen $(v+F u) \\cap W_i=\\varnothing$ and $(v+F u) \\cap W_j(j \\neq i)$ contains at most one vector since otherwise $W_j$ would contain $u$. Hence\n$$\n|v+F u|=|F| \\leq n-1 .\n$$\nCorollary: Avoidance lemma for vector spaces.\nLet $E$ be a vector space over an infinite field. If a subspace is contained in a finite union of subspaces, it is contained in one of them.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_1_14", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_1_14 (G : Type*) [Group G]\n (hG : IsCyclic $ G ⧸ (center G)) :\n center G = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $Z$ be the center of a group $G$. Prove that if $G / Z$ is a cyclic group, then $G$ is abelian and hence $G=Z$.\n\\begin{proof}\n We have that $G / Z(G)$ is cyclic, and so there is an element $x \\in G$ such that $G / Z(G)=\\langle x Z(G)\\rangle$, where $x Z(G)$ is the coset with representative $x$. Now let $g \\in G$\nWe know that $g Z(G)=(x Z(G))^m$ for some $m$, and by definition $(x Z(G))^m=x^m Z(G)$.\nNow, in general, if $H \\leq G$, we have by definition too that $a H=b H$ if and only if $b^{-1} a \\in H$.\nIn our case, we have that $g Z(G)=x^m Z(G)$, and this happens if and only if $\\left(x^m\\right)^{-1} g \\in Z(G)$.\nThen, there's a $z \\in Z(G)$ such that $\\left(x^m\\right)^{-1} g=z$, and so $g=x^m z$.\n\n$g, h \\in G$ implies that $g=x^{a_1} z_1$ and $h=x^{a_2} z_2$, so\n$$\n\\begin{aligned}\ng h & =\\left(x^{a_1} z_1\\right)\\left(x^{a_2} z_2\\right) \\\\\n& =x^{a_1} x^{a_2} z_1 z_2 \\\\\n& =x^{a_1+a_2} z_2 z_1 \\\\\n& =\\ldots=\\left(x^{a_2} z_2\\right)\\left(x^{a_1} z_1\\right)=h g .\n\\end{aligned}\n$$\nTherefore, $G$ is abelian.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_4_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_2 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p*q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n If $|G|=n=p q$ then the only two Sylow subgroups are of order $p$ and $q$.\nFrom Sylow's third theorem we know that $n_p \\mid q$ which means that $n_p=1$ or $n_p=q$.\nIf $n_p=1$ then we are done (by a corollary of Sylow's theorem)\nIf $n_p=q$ then we have accounted for $q(p-1)=p q-q$ elements of $G$ and so there is only one group of order $q$ and again we are done.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_6_4_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_3 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p^2 *q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p^2 q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n We may as well assume $p0$ and $b^2>0$, so $-a^2-b^2<0$. Furthermore, it is an integer. Thus, we have found a nonzero integer in $I$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_10_7_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_7_10 {R : Type*} [Ring R]\n (M : Ideal R) (hM : ∀ (x : R), x ∉ M → IsUnit x)\n (hProper : ∃ x : R, x ∉ M) :\n IsMaximal M ∧ ∀ (N : Ideal R), IsMaximal N → N = M := sorry", "formal_proof": null, "informal_stmt": "Let $R$ be a ring, with $M$ an ideal of $R$. Suppose that every element of $R$ which is not in $M$ is a unit of $R$. Prove that $M$ is a maximal ideal and that moreover it is the only maximal ideal of $R$.\n\\begin{proof}\nSuppose there is an ideal $M\\subset I\\subset R$. If $I\\neq M$, then $I$ contains a unit, thus $I=R$. Therefore $M$ is a maximal ideal. \n\nSuppose we have an arbitrary maximal ideal $M^\\prime$ of $R$. The ideal $M^\\prime$ cannot contain a unit, otherwise $M^\\prime =R$. Therefore $M^\\prime \\subset M$. But we cannot have $M^\\prime \\subsetneq M \\subsetneq R$, therefore $M=M^\\prime$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_2_13", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_2_13 (a b : ℤ) :\n (ofInt a : GaussianInt) ∣ ofInt b → a ∣ b := sorry", "formal_proof": null, "informal_stmt": "If $a, b$ are integers and if $a$ divides $b$ in the ring of Gauss integers, then $a$ divides $b$ in $\\mathbb{Z}$.\n\\begin{proof}\n Suppose $a|b$ in $\\mathbb{Z}[i]$ and $a,b\\in\\mathbb{Z}$. Then $a(x+yi)=b$ for $x,y\\in\\mathbb{Z}$. Expanding this we get $ax+ayi=b$, and equating imaginary parts gives us $ay=0$, implying $y=0$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_1b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_1b {F : Type*} [Field F] [Fintype F] (hF : card F = 2) :\n Irreducible (12 + 6 * X + X ^ 3 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 + 6x + 12$ is irreducible in $\\mathbb{Q}$.\n\\begin{proof}\n Apply Eisenstein's criterion with $p=3$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6a", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6a {F : Type*} [Field F] [Fintype F] (hF : card F = 7) :\n Irreducible (X ^ 2 + 1 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+x+1$ is irreducible in the field $\\mathbb{F}_2$.\n\\begin{proof}\n If $x^2+x+1$ were reducible in $\\mathbb{F}_2$, its factors must be linear. But we neither have that $0^2+0+1=$ nor $1^2+1+1=0$, therefore $x^2+x+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6b {F : Type*} [Field F] [Fintype F] (hF : card F = 31) :\n Irreducible (X ^ 3 - 9 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+1$ is irreducible in $\\mathbb{F}_7$\n\\begin{proof}\n If $p(x)=x^2+1$ were reducible, its factors must be linear. But no $p(a)$ for $a\\in\\mathbb{F}_7$ evaluates to 0, therefore $x^2+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_6c", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6c : Irreducible (X^3 - 9 : Polynomial (ZMod 31)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 - 9$ is irreducible in $\\mathbb{F}_{31}$.\n\\begin{proof}\n If $p(x) = x^3-9$ were reducible, it would have a linear factor, since it either has a linear factor and a quadratic factor or three linear factors. We can then verify by brute force that $p(x)\\neq 0$ for $x \\in \\mathbb{F}_31$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_4_8", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_8 (p : ℕ) (hp : Prime p) (n : ℕ) :\n -- p ∈ ℕ can be written as p ∈ ℚ[X]\n Irreducible (X ^ n - (p : Polynomial ℚ) : Polynomial ℚ) := sorry", "formal_proof": null, "informal_stmt": "Let $p$ be a prime integer. Prove that the polynomial $x^n-p$ is irreducible in $\\mathbb{Q}[x]$.\n\\begin{proof}\n Straightforward application of Eisenstein's criterion with $p$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_11_13_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_13_3 (N : ℕ):\n ∃ p ≥ N, Nat.Prime p ∧ p + 1 ≡ 0 [MOD 4] := sorry", "formal_proof": null, "informal_stmt": "Prove that there are infinitely many primes congruent to $-1$ (modulo $4$).\n\\begin{proof}\n First we show a lemma: if $a \\equiv 3(\\bmod 4)$ then there exists a prime $p$ such that $p \\mid a$ and $p \\equiv 3(\\bmod 4)$.\n\n Clearly, all primes dividing $a$ are odd. Suppose all of them would be $\\equiv 1(\\bmod 4)$. Then their product would also be $a \\equiv 1(\\bmod 4)$, which is a contradiction.\n\nTo prove the main claim, suppose that $p_1, \\ldots, p_n$ would be all such primes. (In particular, we have $p_1=3$.) Consider $a=4 p_2 \\cdots p_n+3$. (Or you can take $a=4 p_2 \\cdots p_n-1$.) Show that $p_i \\nmid a$ for $i=1, \\ldots, n$. (The case $3 \\nmid a$ is solved differently than the other primes - this is the reason for omitting $p_1$ in the definition of $a$.) Then use the above lemma to get a contradiction.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_13_4_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_4_10\n {p : ℕ} {hp : Nat.Prime p} (h : ∃ r : ℕ, p = 2 ^ r + 1) :\n ∃ (k : ℕ), p = 2 ^ (2 ^ k) + 1 := sorry", "formal_proof": null, "informal_stmt": "Prove that if a prime integer $p$ has the form $2^r+1$, then it actually has the form $2^{2^k}+1$.\n\\begin{proof}\n In particular, we have\n$$\n\\frac{x^a+1}{x+1}=\\frac{(-x)^a-1}{(-x)-1}=1-x+x^2-\\cdots+(-x)^{a-1}\n$$\nby the geometric sum formula. In this case, specialize to $x=2^{2^m}$ and we have a nontrivial divisor.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Artin_exercise_13_6_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_6_10 {K : Type*} [Field K] [Fintype Kˣ] :\n (∏ x : Kˣ, x) = -1 := sorry", "formal_proof": null, "informal_stmt": "Let $K$ be a finite field. Prove that the product of the nonzero elements of $K$ is $-1$.\n\\begin{proof}\n Since we are working with a finite field with $q$ elements, anyone of them is a root of the following polynomial\n$$\nx^q-x=0 .\n$$\nIn particular if we rule out the 0 element, any $a_i \\neq 0$ is a root of\n$$\nx^{q-1}-1=0 .\n$$\nThis polynomial splits completely in $\\mathbb{F}_q$ so we find\n$$\n\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)=0\n$$\nin particular\n$$\nx^{q-1}-1=\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)\n$$\nThus $a_1 \\cdots a_{q-1}=-1$.\n\\end{proof}\n\\end{document}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} {"name": "Axler_exercise_1_2", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_2 :\n (⟨-1/2, Real.sqrt 3 / 2⟩ : ℂ) ^ 3 = -1 := sorry", "formal_proof": null, "informal_stmt": "Show that $\\frac{-1 + \\sqrt{3}i}{2}$ is a cube root of 1 (meaning that its cube equals 1).\n\\begin{proof}\n$$\n\\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2},\n$$\nhence\n$$\n\\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1\n$$\nThis means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} {"name": "Axler_exercise_1_3", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_3 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] {v : V} : -(-v) = v := sorry", "formal_proof": null, "informal_stmt": "Prove that $-(-v) = v$ for every $v \\in V$.\n\\begin{proof}\n By definition, we have\n$$\n(-v)+(-(-v))=0 \\quad \\text { and } \\quad v+(-v)=0 .\n$$\nThis implies both $v$ and $-(-v)$ are additive inverses of $-v$, by the uniqueness of additive inverse, it follows that $-(-v)=v$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} {"name": "Axler_exercise_1_4", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_1_4 {F V : Type*} [AddCommGroup V] [Field F]\n [Module F V] (v : V) (a : F): a • v = 0 ↔ a = 0 ∨ v = 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that if $a \\in \\mathbf{F}$, $v \\in V$, and $av = 0$, then $a = 0$ or $v = 0$.\n\\begin{proof}\n If $a=0$, then we immediately have our result. So suppose $a \\neq 0$. Then, because $a$ is some nonzero real or complex number, it has a multiplicative inverse $\\frac{1}{a}$. Now suppose that $v$ is some vector such that\n$$\na v=0\n$$\nMultiply by $\\frac{1}{a}$ on both sides of this equation to get\n$$\n\\begin{aligned}\n\\frac{1}{a}(a v) & =\\frac{1}{a} 0 & & \\\\\n\\frac{1}{a}(a v) & =0 & & \\\\\n\\left(\\frac{1}{a} \\cdot a\\right) v & =0 & & \\text { (associativity) } \\\\\n1 v & =0 & & \\text { (definition of } 1/a) \\\\\nv & =0 & & \\text { (multiplicative identity) }\n\\end{aligned}\n$$\nHence either $a=0$ or, if $a \\neq 0$, then $v=0$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} @@ -103,6 +54,9 @@ {"name": "Axler_exercise_7_10", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_10 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] (T : End ℂ V)\n (hT : T * adjoint T = adjoint T * T) (hT1 : T^9 = T^8) :\n IsSelfAdjoint T ∧ T^2 = T := sorry", "formal_proof": null, "informal_stmt": "Suppose $V$ is a complex inner-product space and $T \\in \\mathcal{L}(V)$ is a normal operator such that $T^{9}=T^{8}$. Prove that $T$ is self-adjoint and $T^{2}=T$.\n\\begin{proof}\n Based on the complex spectral theorem, there is an orthonormal basis of $\\left(e_1, \\ldots, e_n\\right)$ of $V$ consisting of eigenvectors of $T$. Now, let $\\lambda_1, \\ldots, \\lambda_n$ be the corresponding eigenvalues. Therefore,\n$$\nT e_1=\\lambda_j e_j\n$$\nfor $j=1 \\ldots n$.\n\nNext, by applying $T$ repeatedly to both sides of the equation above, we get $T^9 e_j=\\left(\\lambda_j\\right)^9 e_j$ and rei =8ej. Thus $T^8 e_j=\\left(\\lambda_j\\right)^8 e_j$, which implies that $\\lambda_j$ equals 0 or 1 . In particular, all the eigenvalues of $T$ are real. This would then imply that $T$ is self-adjoint.\n\nNow, by applying $T$ to both sides of the equation above, we get\n$$\n\\begin{aligned}\nT^2 e_j & =\\left(\\lambda_j\\right)^2 e_j \\\\\n& =\\lambda_j e_j \\\\\n& =T e_j\n\\end{aligned}\n$$\nwhich is where the second equality holds because $\\lambda_j$ equals 0 or 1 . Because $T^2$ and $T$ agree on a basis, they must be equal.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} {"name": "Axler_exercise_7_11", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_11 {V : Type*} [NormedAddCommGroup V] [InnerProductSpace ℂ V]\n [FiniteDimensional ℂ V] {T : End ℂ V} (hT : T*adjoint T = adjoint T*T) :\n ∃ (S : End ℂ V), S ^ 2 = T := sorry", "formal_proof": null, "informal_stmt": "Suppose $V$ is a complex inner-product space. Prove that every normal operator on $V$ has a square root. (An operator $S \\in \\mathcal{L}(V)$ is called a square root of $T \\in \\mathcal{L}(V)$ if $S^{2}=T$.)\n\\begin{proof}\n Let $V$ be a complex inner product space.\nIt is known that an operator $S \\in \\mathcal{L}(V)$ is called a square root of $T \\in \\mathcal{L}(V)$ if\n$$\nS^2=T\n$$\nNow, suppose that $T$ is a normal operator on $V$.\nBy the Complex Spectral Theorem, there is $e_1, \\ldots, e_n$ an orthonormal basis of $V$ consisting of eigenvalues of $T$ and let $\\lambda_1, \\ldots, \\lambda_n$ denote their corresponding eigenvalues.\nDefine $S$ by\n$$\nS e_j=\\sqrt{\\lambda_j} e_j,\n$$\nfor each $j=1, \\ldots, n$.\nObviously, $S^2 e_j=\\lambda_j e_j=T e_j$.\nHence, $S^2=T$ so there exist a square root of $T$.\n\\end{proof}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} {"name": "Axler_exercise_7_14", "source": "Axler.lean", "header": "import Mathlib\n\nopen Fintype Complex Polynomial LinearMap FiniteDimensional Module Module.End\nopen scoped BigOperators InnerProductSpace\n", "formal_statement": "theorem Axler_exercise_7_14 {𝕜 V : Type*} [RCLike 𝕜] [NormedAddCommGroup V]\n [InnerProductSpace 𝕜 V] [FiniteDimensional 𝕜 V]\n {T : End 𝕜 V} (hT : IsSelfAdjoint T)\n {l : 𝕜} {ε : ℝ} (he : ε > 0) : ∃ v : V, ‖v‖= 1 ∧ (‖T v - l • v‖ < ε →\n (∃ l' : T.Eigenvalues, ‖l - l'‖ < ε)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $T \\in \\mathcal{L}(V)$ is self-adjoint, $\\lambda \\in \\mathbf{F}$, and $\\epsilon>0$. Prove that if there exists $v \\in V$ such that $\\|v\\|=1$ and $\\|T v-\\lambda v\\|<\\epsilon,$ then $T$ has an eigenvalue $\\lambda^{\\prime}$ such that $\\left|\\lambda-\\lambda^{\\prime}\\right|<\\epsilon$.\n\\begin{proof}\n Let $T \\in \\mathcal{L}(V)$ be a self-adjoint, and let $\\lambda \\in \\mathbf{F}$ and $\\epsilon>0$.\nBy the Spectral Theorem, there is $e_1, \\ldots, e_n$ an orthonormal basis of $V$ consisting of eigenvectors of $T$ and let $\\lambda_1, \\ldots, \\lambda_n$ denote their corresponding eigenvalues.\nChoose an eigenvalue $\\lambda^{\\prime}$ of $T$ such that $\\left|\\lambda^{\\prime}-\\lambda\\right|^2$ is minimized.\nThere are $a_1, \\ldots, a_n \\in \\mathbb{F}$ such that\n$$\nv=a_1 e_1+\\cdots+a_n e_n .\n$$\nThus, we have\n$$\n\\begin{aligned}\n\\epsilon^2 & >|| T v-\\left.\\lambda v\\right|^2 \\\\\n& =\\left|\\left\\langle T v-\\lambda v, e_1\\right\\rangle\\right|^2+\\cdots+\\left|\\left\\langle T v-\\lambda v, e_n\\right\\rangle\\right|^2 \\\\\n& =\\left|\\lambda_1 a_1-\\lambda a_1\\right|^2+\\cdots+\\left|\\lambda_n a_n-\\lambda a_n\\right|^2 \\\\\n& =\\left|a_1\\right|^2\\left|\\lambda_1-\\lambda\\right|^2+\\cdots+\\left|a_n\\right|^2\\left|\\lambda_n-\\lambda\\right|^2 \\\\\n& \\geq\\left|a_1\\right|^2\\left|\\lambda^{\\prime}-\\lambda\\right|^2+\\cdots+\\left|a_n\\right|^2\\left|\\lambda^{\\prime}-\\lambda\\right|^2 \\\\\n& =\\left|\\lambda^{\\prime}-\\lambda\\right|^2\n\\end{aligned}\n$$\nwhere the second and fifth lines follow from $6.30$ (the fifth because $\\|v\\|=1$ ). Now, we taking the square root.\nHence, $T$ has an eigenvalue $\\lambda^{\\prime}$ such that $\\left|\\lambda^{\\prime}-\\lambda\\right|<\\epsilon$\n\\end{proof}\n\n\n\n\\end{document}", "informal_proof": "$$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^2=\\frac{-1-\\sqrt{3} i}{2}, $$ hence $$ \\left(\\frac{-1+\\sqrt{3} i}{2}\\right)^3=\\frac{-1-\\sqrt{3} i}{2} \\cdot \\frac{-1+\\sqrt{3} i}{2}=1 $$ This means $\\frac{-1+\\sqrt{3} i}{2}$ is a cube root of 1."} +{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_1E_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_1E_a : ∀ N : ℕ, ∃ n ≥ N, (3*n+1).Prime ∧ (3*n+1) ≥ N := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} +{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_2D_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_2D_a : Irrational (2^((1:ℝ)/3) + 3^((1:ℝ)/3)) := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} +{"name": "Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i (U : Set ℂ) (hU : IsOpen U)\n (hU1 : Nonempty U) (hU2 : IsConnected U) (f : ℕ → ℂ → ℂ) (f' : ℂ → ℂ)\n (hf : ∀ n : ℕ, DifferentiableOn ℂ (f n) U)\n (hf1 : ∀ X ⊂ U, CompactSpace X →\n (TendstoUniformly (λ n => restrict X (f n)) (restrict X f') atTop)) :\n DifferentiableOn ℂ f' U := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} {"name": "Dummit_Foote_exercise_1_1_2a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_2a : ∃ a b : ℤ, a - b ≠ b - a := sorry", "formal_proof": null, "informal_stmt": "Prove the the operation $\\star$ on $\\mathbb{Z}$ defined by $a\\star b=a-b$ is not commutative.\n\\begin{proof}\n Not commutative since\n$$\n1 \\star(-1)=1-(-1)=2\n$$\n$$\n(-1) \\star 1=-1-1=-2 .\n$$\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_1_1_3", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_3 (n : ℤ) :\n ∀ (a b c : ℤ), (a+b)+c ≡ a+(b+c) [ZMOD n] := sorry", "formal_proof": null, "informal_stmt": "Prove that the addition of residue classes $\\mathbb{Z}/n\\mathbb{Z}$ is associative.\n\\begin{proof}\n We have\n$$\n\\begin{aligned}\n(\\bar{a}+\\bar{b})+\\bar{c} &=\\overline{a+b}+\\bar{c} \\\\\n&=\\overline{(a+b)+c} \\\\\n&=\\overline{a+(b+c)} \\\\\n&=\\bar{a}+\\overline{b+c} \\\\\n&=\\bar{a}+(\\bar{b}+\\bar{c})\n\\end{aligned}\n$$\nsince integer addition is associative.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_1_1_4", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_1_1_4 (n : ℕ) :\n ∀ (a b c : ℕ), (a * b) * c ≡ a * (b * c) [ZMOD n] := sorry", "formal_proof": null, "informal_stmt": "Prove that the multiplication of residue class $\\mathbb{Z}/n\\mathbb{Z}$ is associative.\n\\begin{proof}\n We have\n$$\n\\begin{aligned}\n(\\bar{a} \\cdot \\bar{b}) \\cdot \\bar{c} &=\\overline{a \\cdot b} \\cdot \\bar{c} \\\\\n&=\\overline{(a \\cdot b) \\cdot c} \\\\\n&=\\overline{a \\cdot(b \\cdot c)} \\\\\n&=\\bar{a} \\cdot \\overline{b \\cdot c} \\\\\n&=\\bar{a} \\cdot(\\bar{b} \\cdot \\bar{c})\n\\end{aligned}\n$$\nsince integer multiplication is associative.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} @@ -142,9 +96,9 @@ {"name": "Dummit_Foote_exercise_3_4_5b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_5b {G : Type*} [Group G] [IsSolvable G]\n (H : Subgroup G) [Normal H] :\n IsSolvable (G ⧸ H) := sorry", "formal_proof": null, "informal_stmt": "Prove that quotient groups of a solvable group are solvable.\n\\begin{proof}\n Next, note that\n$$\nH_i=G_i \\cap H=\\left(G_i \\cap G_{i+1}\\right) \\cap H=G_i \\cap H_{i+1} .\n$$\nBy the Second Isomorphism Theorem, we then have\n$$\nH_{i+1} / H_i=H_{i+1} /\\left(H_{i+1} \\cap G_i\\right) \\cong H_{i+1} G_i / G_i \\leq G_{i+1} / G_i .\n$$\nSince $H_{i+1} / H_i$ is isomorphic to a subgroup of the abelian group $G_{i+1} / G_i$, it follows that $H_{i+1} / H_i$ is also abelian. This completes the proof that $H$ is solvable.\nNext, let $N \\unlhd G$. For each $i$, define\n$$\nN_i=G_i N, \\quad 0 \\leq i \\leq n .\n$$\nNow let $g \\in N_{i+1}$, where $g=g_0 n_0$ with $g_0 \\in G_{i+1}$ and $n_0 \\in N$. Also let $x \\in N_i$, where $x=g_1 n_1$ with $g_1 \\in G_i$ and $n_1 \\in N$. Then\n$$\ng x g^{-1}=g_0 n_0 g_1 n_1 n_0^{-1} g_0^{-1} .\n$$\nNow, since $N$ is normal in $G, N g=g N$, so $n_0 g_1=g_1 n_2$ for some $n_2 \\in N$. Then\n$$\ng x g^{-1}=g_0 g_1\\left(n_2 n_1 n_0^{-1}\\right) g_0^{-1}=g_0 g_1 n_3 g_0^{-1}\n$$\nfor some $n_3 \\in N$. Then $n_3 g_0^{-1}=g_0^{-1} n_4$ for some $n_4 \\in N$. And $g_0 g_1 g_0^{-1} \\in G_i$ since $G_i \\unlhd G_{i+1}$, so\n$$\ng x g^{-1}=g_0 g_1 g_0^{-1} n_4 \\in N_i .\n$$\nThis shows that $N_i \\unlhd N_{i+1}$. So by the Lattice Isomorphism Theorem, we have $N_{i+1} / N \\unlhd N_i / N$. This shows that\n$$\n1=N_0 / N \\unlhd N_1 / N \\unlhd N_2 / N \\unlhd \\cdots \\unlhd N_n / N=G / N .\n$$\nMoreover, the Third Isomorphism Theorem says that\n$$\n\\left(N_{i+1} / N\\right) /\\left(N_i / N\\right) \\cong N_{i+1} / N_i,\n$$\nso the proof will be complete if we can show that $N_{i+1} / N_i$ is abelian.\nLet $x, y \\in N_{i+1} / N_i$. Then\n$$\nx=\\left(g_0 n_0\\right) N_i \\quad \\text { and } \\quad y=\\left(g_1 n_1\\right) N_i\n$$\nfor some $g_0, g_1 \\in G_{i+1}$ and $n_0, n_1 \\in N$. We have\n$$\n\\begin{aligned}\nx y x^{-1} y^{-1} & =\\left(g_0 n_0\\right)\\left(g_1 n_1\\right)\\left(g_0 n_0\\right)^{-1}\\left(g_1 n_1\\right)^{-1} N_i \\\\\n& =g_0 n_0 g_1 n_1 n_0^{-1} g_0^{-1} n_1^{-1} g_1^{-1} N_i .\n\\end{aligned}\n$$\nSince $N \\unlhd G, g N=N g$ for any $g \\in G$, so we can find $n_2 \\in N$ such that\n$$\nx y x^{-1} y^{-1}=g_0 g_1 g_0^{-1} g^{-1} n_2 N_i .\n$$\nNow $N_i=G_i N=N G_i$ since $N \\unlhd G$ (see Proposition 14 and its corollary). Therefore\n$$\nn_2 N_i=n_2 N G_i=N G_i=G_i N\n$$\nand we get\n$$\nx y x^{-1} y^{-1}=g_0 g_1 g_0^{-1} g^{-1} G_i N=G_i N .\n$$\nSo $x y x^{-1} y^{-1}=1 N_i$ or $x y=y x$. This completes the proof that $G / N$ is solvable.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_3_4_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_3_4_11 {G : Type*} [Group G] [IsSolvable G]\n {H : Subgroup G} (hH : H ≠ ⊥) [H.Normal] :\n ∃ A ≤ H, A.Normal ∧ ∀ a b : A, a*b = b*a := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ is a nontrivial normal subgroup of the solvable group $G$ then there is a nontrivial subgroup $A$ of $H$ with $A \\unlhd G$ and $A$ abelian.\n\\begin{proof}\n Suppose $H$ is a nontrivial normal subgroup of the solvable group $G$.\nFirst, notice that $H$, being a subgroup of a solvable group, is itself solvable. By exercise $8, H$ has a chain of subgroups\n$$\n1 \\leq H_1 \\leq \\ldots \\leq H\n$$\nsuch that each $H_i$ is a normal subgroup of $H$ itself and $H_{i+1} / H_i$ is abelian. But then the first group in the series\n$$\nH_1 / 1 \\cong H\n$$\nis an abelian subgroup of $H$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_2_8", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_8 {G : Type*} [Group G] {H : Subgroup G}\n {n : ℕ} (hn : n > 0) (hH : H.index = n) :\n ∃ K ≤ H, K.Normal ∧ K.index ≤ n.factorial := sorry", "formal_proof": null, "informal_stmt": "Prove that if $H$ has finite index $n$ then there is a normal subgroup $K$ of $G$ with $K \\leq H$ and $|G: K| \\leq n!$.\n\\begin{proof}\n Solution: $G$ acts on the cosets $G / H$ by left multiplication. Let $\\lambda: G \\rightarrow S_{G / H}$ be the permutation representation induced by this action, and let $K$ be the kernel of the representation.\nNow $K$ is normal in $G$, and $K \\leq \\operatorname{stab}_G(H)=H$. By the First Isomorphism Theorem, we have an injective group homomorphism $\\bar{\\lambda}: G / K \\rightarrow S_{G / H}$. Since $\\left|S_{G / H}\\right|=n !$, we have $[G: K] \\leq n !$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} -{"name": "Dummit_Foote_exercise_4_3_26", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_3_26 {α : Type*} [Fintype α] (ha : card α > 1)\n (h_tran : ∀ a b: α, ∃ σ : Equiv.Perm α, σ a = b) :\n ∃ σ : Equiv.Perm α, ∀ a : α, σ a ≠ a := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a transitive permutation group on the finite set $A$ with $|A|>1$. Show that there is some $\\sigma \\in G$ such that $\\sigma(a) \\neq a$ for all $a \\in A$.\n\\begin{proof}\n Let $G$ be a transitive permutation group on the finite set $A,|A|>1$. We want to find an element $\\sigma$ which doesn't stabilize anything, that is, we want a $\\sigma$ such that\n$$\n\\sigma \\notin G_a\n$$\nfor all $a \\in A$.\nSince the group is transitive, there is always a $g \\in G$ such that $b=g \\cdot a$. Let us see in what relationship the stabilizers of $a$ and $b$ are. We find\n$$\n\\begin{aligned}\nG_b & =\\{h \\in G \\mid h \\cdot b=b\\} \\\\\n& =\\{h \\in G \\mid h g \\cdot a=g \\cdot a\\} \\\\\n& =\\left\\{h \\in G \\mid g^{-1} h g \\cdot a=a\\right\\}\n\\end{aligned}\n$$\nPutting $h^{\\prime}=g^{-1} h g$, we have $h=g h^{\\prime} g^{-1}$ and\n$$\n\\begin{aligned}\nG_b & =g\\left\\{h^{\\prime} \\in H \\mid h^{\\prime} \\cdot a=a\\right\\} g^{-1} \\\\\n& =g G_a g^{-1}\n\\end{aligned}\n$$\nBy the above, the stabilizer subgroup of any element is conjugate to some other stabilizer subgroup. Now, the stabilizer cannot be all of $G$ (else $\\{a\\}$ would be a orbit). Thus it is a proper subgroup of $G$. By the previous exercise, we have\n$$\n\\bigcup_{a \\in A} G_a=\\bigcup_{g \\in G} g G_a g^{-1} \\subset G\n$$\n(the union of conjugates of a proper subgroup can never be all of $G$ ). This shows there is an element $\\sigma$ which is not in any stabilizer of any element of $A$. Then $\\sigma(a) \\neq a$ for all $a \\in A$, as we wanted to show.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_2_9a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_9a {G : Type*} [Fintype G] [Group G] {p α : ℕ}\n (hp : p.Prime) (ha : α > 0) (hG : card G = p ^ α) :\n ∀ H : Subgroup G, H.index = p → H.Normal := sorry", "formal_proof": null, "informal_stmt": "Prove that if $p$ is a prime and $G$ is a group of order $p^{\\alpha}$ for some $\\alpha \\in \\mathbb{Z}^{+}$, then every subgroup of index $p$ is normal in $G$.\n\\begin{proof}\n Solution: Let $G$ be a group of order $p^k$ and $H \\leq G$ a subgroup with $[G: H]=p$. Now $G$ acts on the conjugates $g H g^{-1}$ by conjugation, since\n$$\ng_1 g_2 \\cdot H=\\left(g_1 g_2\\right) H\\left(g_1 g_2\\right)^{-1}=g_1\\left(g_2 H g_2^{-1}\\right) g_1^{-1}=g_1 \\cdot\\left(g_2 \\cdot H\\right)\n$$\nand $1 \\cdot H=1 H 1=H$. Moreover, under this action we have $H \\leq \\operatorname{stab}(H)$. By Exercise 3.2.11, we have\n$$\n[G: \\operatorname{stab}(H)][\\operatorname{stab}(H): H]=[G: H]=p,\n$$\na prime.\nIf $[G: \\operatorname{stab}(H)]=p$, then $[\\operatorname{stab}(H): H]=1$ and we have $H=\\operatorname{stab}(H)$; moreover, $H$ has exactly $p$ conjugates in $G$. Let $\\varphi: G \\rightarrow S_p$ be the permutation representation induced by the action of $G$ on the conjugates of $H$, and let $K$ be the kernel of this representation. Now $K \\leq \\operatorname{stab}(H)=H$. By the first isomorphism theorem, the induced map $\\bar{\\varphi}: G / K \\rightarrow S_p$ is injective, so that $|G / K|$ divides $p$ !. Note, however, that $|G / K|$ is a power of $p$ and that the only powers of $p$ that divide $p$ ! are 1 and $p$. So $[G: K]$ is 1 or $p$. If $[G: K]=1$, then $G=K$ so that $g H g^{-1}=H$ for all $g \\in G$; then $\\operatorname{stab}(H)=G$ and we have $[G: \\operatorname{stab}(H)]=1$, a contradiction. Now suppose $[G: K]=p$. Again by Exercise $3.2$.11 we have $[G: K]=[G: H][H: K]$, so that $[H: K]=1$, hence $H=K$. Again, this implies that $H$ is normal so that $g H g^{-1}=H$ for all $g \\in G$, and we have $[G: \\operatorname{stab}(H)]=1$, a contradiction. Thus $[G: \\operatorname{stab}(H)] \\neq p$\nIf $[G: \\operatorname{stab}(H)]=1$, then $G=\\operatorname{stab}(H)$. That is, $g H g^{-1}=H$ for all $g \\in G$; thus $H \\leq G$ is normal.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_2_14", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_2_14 {G : Type*} [Fintype G] [Group G]\n (hG : ¬ (card G).Prime) (hG1 : ∀ k : ℕ, k ∣ card G →\n ∃ (H : Subgroup G) (fH : Fintype H), @card H fH = k) :\n ¬ IsSimpleGroup G := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a finite group of composite order $n$ with the property that $G$ has a subgroup of order $k$ for each positive integer $k$ dividing $n$. Prove that $G$ is not simple.\n\\begin{proof}\n Solution: Let $p$ be the smallest prime dividing $n$, and write $n=p m$. Now $G$ has a subgroup $H$ of order $m$, and $H$ has index $p$. Then $H$ is normal in $G$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} +{"name": "Dummit_Foote_exercise_4_3_26", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_3_26 {α : Type*} [Fintype α] (ha : card α > 1)\n (h_tran : ∀ a b: α, ∃ σ : Equiv.Perm α, σ a = b) :\n ∃ σ : Equiv.Perm α, ∀ a : α, σ a ≠ a := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a transitive permutation group on the finite set $A$ with $|A|>1$. Show that there is some $\\sigma \\in G$ such that $\\sigma(a) \\neq a$ for all $a \\in A$.\n\\begin{proof}\n Let $G$ be a transitive permutation group on the finite set $A,|A|>1$. We want to find an element $\\sigma$ which doesn't stabilize anything, that is, we want a $\\sigma$ such that\n$$\n\\sigma \\notin G_a\n$$\nfor all $a \\in A$.\nSince the group is transitive, there is always a $g \\in G$ such that $b=g \\cdot a$. Let us see in what relationship the stabilizers of $a$ and $b$ are. We find\n$$\n\\begin{aligned}\nG_b & =\\{h \\in G \\mid h \\cdot b=b\\} \\\\\n& =\\{h \\in G \\mid h g \\cdot a=g \\cdot a\\} \\\\\n& =\\left\\{h \\in G \\mid g^{-1} h g \\cdot a=a\\right\\}\n\\end{aligned}\n$$\nPutting $h^{\\prime}=g^{-1} h g$, we have $h=g h^{\\prime} g^{-1}$ and\n$$\n\\begin{aligned}\nG_b & =g\\left\\{h^{\\prime} \\in H \\mid h^{\\prime} \\cdot a=a\\right\\} g^{-1} \\\\\n& =g G_a g^{-1}\n\\end{aligned}\n$$\nBy the above, the stabilizer subgroup of any element is conjugate to some other stabilizer subgroup. Now, the stabilizer cannot be all of $G$ (else $\\{a\\}$ would be a orbit). Thus it is a proper subgroup of $G$. By the previous exercise, we have\n$$\n\\bigcup_{a \\in A} G_a=\\bigcup_{g \\in G} g G_a g^{-1} \\subset G\n$$\n(the union of conjugates of a proper subgroup can never be all of $G$ ). This shows there is an element $\\sigma$ which is not in any stabilizer of any element of $A$. Then $\\sigma(a) \\neq a$ for all $a \\in A$, as we wanted to show.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_4_2", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_2 {G : Type*} [Fintype G] [Group G]\n {p q : Nat.Primes} (hpq : p ≠ q) (hG : card G = p*q) :\n IsCyclic G := sorry", "formal_proof": null, "informal_stmt": "Prove that if $G$ is an abelian group of order $p q$, where $p$ and $q$ are distinct primes, then $G$ is cyclic.\n\\begin{proof}\n Let $G$ be an abelian group of order $p q$. We need to prove that if $p$ and $q$ are distinct primes than $G$ is cyclic. By Cauchy's theorem there are $a, b \\in G$ with $a$ of order $p$ and $b$ of order $q$. Since $(|a|,|b|)=1$ and $a b=b a$ then $|a b|=|a| \\cdot|b|=p q$. Therefore $a b$ is an element of order $p q$, the order of $G$, which means $G$ is cyclic.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_4_6a", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_6a {G : Type*} [Group G] (H : Subgroup G)\n [Characteristic H] : Normal H := sorry", "formal_proof": null, "informal_stmt": "Prove that characteristic subgroups are normal.\n\\begin{proof}\n Let $H$ be a characteristic subgroup of $G$. By definition $\\alpha(H) \\subset H$ for every $\\alpha \\in \\operatorname{Aut}(G)$. So, $H$ is in particular invariant under the inner automorphism. Let $\\phi_g$ denote the conjugation automorphism by $g$. Then $\\phi_g(H) \\subset H \\Longrightarrow$ $g H g^{-1} \\subset H$. So, $H$ is normal. \n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_4_4_6b", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_4_4_6b :\n ∃ (G : Type*) (hG : Group G) (H : @Subgroup G hG), @Characteristic G hG H ∧ ¬ @Normal G hG H := sorry", "formal_proof": null, "informal_stmt": "Prove that there exists a normal subgroup that is not characteristic.\n\\begin{proof}\n We have to produce a group $G$ and a subgroup $H$ such that $H$ is normal in $G$, but not characteristic. Consider the Klein's four group $G=\\{ e, a, b, a b\\}$. This is an abelian group with each element having order 2. Consider $H=\\{ e, a\\}$. $H$ is normal in $G$. Define $\\sigma: G \\rightarrow G$ as $\\sigma(a)=b, \\sigma(b)=a, \\sigma(a b)=a b$. Clearly $\\sigma$ does not fix $H$. So, $H$ is not characteristic.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} @@ -190,104 +144,53 @@ {"name": "Dummit_Foote_exercise_9_4_9", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_9 :\n Irreducible (X^2 - C Zsqrtd.sqrtd : Polynomial (Zsqrtd 2)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the polynomial $x^{2}-\\sqrt{2}$ is irreducible over $\\mathbb{Z}[\\sqrt{2}]$. You may assume that $\\mathbb{Z}[\\sqrt{2}]$ is a U.F.D.\n\\begin{proof}\n$Z[\\sqrt{2}]$ is an Euclidean domain, and so a unique factorization domain.\nWe have to prove $p(x)=x^2-\\sqrt{2}$ irreducible.\nSuppose to the contrary.\nif $p(x)$ is reducible then it must have root.\nLet $a+b \\sqrt{2}$ be a root of $x^2-\\sqrt{2}$.\nNow we have\n$$\na^2+2 b^2+2 a b \\sqrt{2}=\\sqrt{2}\n$$\nBy comparing the coefficients we get $2 a b=1$ for some pair of integers $a$ and $b$, a contradiction.\nSo $p(x)$ is irredicible over $Z[\\sqrt{2}]$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_9_4_11", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Dummit_Foote_exercise_9_4_11 :\n Irreducible ((MvPolynomial.X 0)^2 + (MvPolynomial.X 1)^2 - 1 : MvPolynomial (Fin 2) ℚ) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+y^2-1$ is irreducible in $\\mathbb{Q}[x,y]$.\n\\begin{proof}\n$$\np(x)=x^2+y^2-1 \\in Q[y][x] \\cong Q[y, x]\n$$\nWe have that $y+1 \\in Q[y]$ is prime and $Q[y]$ is an UFD, since $p(x)=x^2+y^2-1=x^2+$ $(y+1)(y-1)$ by the Eisenstein's Criterion $x^2+y^2-1$ is irreducibile in $Q[x, y]$.\n\\end{proof}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} {"name": "Dummit_Foote_exercise_11_1_13", "source": "Dummit-Foote.lean", "header": "import Mathlib\n\nopen Fintype Subgroup Set Polynomial Ideal\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Dummit_Foote_exercise_11_1_13 {ι : Type*} [Fintype ι] :\n (ι → ℝ) ≃ₗ[ℚ] ℝ := sorry", "formal_proof": null, "informal_stmt": "Prove that as vector spaces over $\\mathbb{Q}, \\mathbb{R}^n \\cong \\mathbb{R}$, for all $n \\in \\mathbb{Z}^{+}$.\n\\begin{proof} \nSince $B$ is a basis of $V$, every element of $V$ can be written uniquely as a finite linear combination of elements of $B$. Let $X$ be the set of all such finite linear combinations. Then $X$ has the same cardinality as $V$, since the map from $X$ to $V$ that takes each linear combination to the corresponding element of $V$ is a bijection.\n\nWe will show that $X$ has the same cardinality as $B$. Since $B$ is countable and $X$ is a union of countable sets, it suffices to show that each set $X_n$, consisting of all finite linear combinations of $n$ elements of $B$, is countable.\n\nLet $P_n(X)$ be the set of all subsets of $X$ with cardinality $n$. Then we have $X_n \\subseteq P_n(B)$. Since $B$ is countable, we have $\\mathrm{card}(P_n(B)) \\leq \\mathrm{card}(B^n) = \\mathrm{card}(B)$, where $B^n$ is the Cartesian product of $n$ copies of $B$.\n\nThus, we have $\\mathrm{card}(X_n) \\leq \\mathrm{card}(P_n(B)) \\leq \\mathrm{card}(B)$, so $X_n$ is countable. It follows that $X$ is countable, and hence has the same cardinality as $B$.\n\nTherefore, we have shown that the cardinality of $V$ is equal to the cardinality of $B$. Since $F$ is countable, it follows that the cardinality of $V$ is countable as well.\n\nNow let $Q$ be a countable field, and let $R$ be a vector space over $Q$. Let $n$ be a positive integer. Then any basis of $R^n$ over $Q$ has the same cardinality as $R^n$, which is countable. Since $R$ is a direct sum of $n$ copies of $R^n$, it follows that any basis of $R$ over $Q$ has the same cardinality as $R$. Hence, the cardinality of $R$ is countable.\n\nFinally, since $R$ is a countable vector space and $Q$ is a countable field, it follows that $R$ and $Q^{\\oplus \\mathrm{card}(R)}$ are isomorphic as additive abelian groups. Therefore, we have $R \\cong_Q Q^{\\oplus \\mathrm{card}(R)}$, and in particular $R \\cong_Q R^n$ for any positive integer $n$.\n\\end{proof}\n\n\n\n\n\\end{document}", "informal_proof": "Not commutative since $$ 1 \\star(-1)=1-(-1)=2 $$ $$ (-1) \\star 1=-1-1=-2 . $$"} -{"name": "Rudin_exercise_1_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_1a\n (x : ℝ) (y : ℚ) :\n ( Irrational x ) -> Irrational ( x + y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $r+x$ is irrational.\n\\begin{proof}\n If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_1b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_1b\n(x : ℝ)\n(y : ℚ)\n(h : y ≠ 0)\n: ( Irrational x ) -> Irrational ( x * y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $rx$ is irrational.\n\\begin{proof}\n If $r x$ were rational, then $x=\\frac{r x}{r}$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_2 : ¬ ∃ (x : ℚ), ( x ^ 2 = 12 ) := sorry", "formal_proof": null, "informal_stmt": "Prove that there is no rational number whose square is $12$.\n\\begin{proof}\n Suppose $m^2=12 n^2$, where $m$ and $n$ have no common factor. It follows that $m$ must be even, and therefore $n$ must be odd. Let $m=2 r$. Then we have $r^2=3 n^2$, so that $r$ is also odd. Let $r=2 s+1$ and $n=2 t+1$. Then\n$$\n4 s^2+4 s+1=3\\left(4 t^2+4 t+1\\right)=12 t^2+12 t+3,\n$$\nso that\n$$\n4\\left(s^2+s-3 t^2-3 t\\right)=2 .\n$$\nBut this is absurd, since 2 cannot be a multiple of 4 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_4\n(α : Type*) [PartialOrder α]\n(s : Set α)\n(x y : α)\n(h₀ : Set.Nonempty s)\n(h₁ : x ∈ lowerBounds s)\n(h₂ : y ∈ upperBounds s)\n: x ≤ y := sorry", "formal_proof": null, "informal_stmt": "Let $E$ be a nonempty subset of an ordered set; suppose $\\alpha$ is a lower bound of $E$ and $\\beta$ is an upper bound of $E$. Prove that $\\alpha \\leq \\beta$.\n\\begin{proof}\nSince $E$ is nonempty, there exists $x \\in E$. Then by definition of lower and upper bounds we have $\\alpha \\leq x \\leq \\beta$, and hence by property $i i$ in the definition of an ordering, we have $\\alpha<\\beta$ unless $\\alpha=x=\\beta$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_5 (A minus_A : Set ℝ) (hA : A.Nonempty)\n (hA_bdd_below : BddBelow A) (hminus_A : minus_A = {x | -x ∈ A}) :\n Min A = Max minus_A := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be a nonempty set of real numbers which is bounded below. Let $-A$ be the set of all numbers $-x$, where $x \\in A$. Prove that $\\inf A=-\\sup (-A)$.\n\\begin{proof}\n We need to prove that $-\\sup (-A)$ is the greatest lower bound of $A$. For brevity, let $\\alpha=-\\sup (-A)$. We need to show that $\\alpha \\leq x$ for all $x \\in A$ and $\\alpha \\geq \\beta$ if $\\beta$ is any lower bound of $A$.\n\nSuppose $x \\in A$. Then, $-x \\in-A$, and, hence $-x \\leq \\sup (-A)$. It follows that $x \\geq-\\sup (-A)$, i.e., $\\alpha \\leq x$. Thus $\\alpha$ is a lower bound of $A$.\n\nNow let $\\beta$ be any lower bound of $A$. This means $\\beta \\leq x$ for all $x$ in $A$. Hence $-x \\leq-\\beta$ for all $x \\in A$, which says $y \\leq-\\beta$ for all $y \\in-A$. This means $-\\beta$ is an upper bound of $-A$. Hence $-\\beta \\geq \\sup (-A)$ by definition of sup, i.e., $\\beta \\leq-\\sup (-A)$, and so $-\\sup (-A)$ is the greatest lower bound of $A$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_8", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_8 : ¬ ∃ (r : ℂ → ℂ → Prop), IsLinearOrder ℂ r := sorry", "formal_proof": null, "informal_stmt": "Prove that no order can be defined in the complex field that turns it into an ordered field.\n\\begin{proof}\n By Part (a) of Proposition $1.18$, either $i$ or $-i$ must be positive. Hence $-1=i^2=(-i)^2$ must be positive. But then $1=(-1)^2$, must also be positive, and this contradicts Part $(a)$ of Proposition 1.18, since 1 and $-1$ cannot both be positive.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_11a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_11a (z : ℂ) :\n ∃ (r : ℝ) (w : ℂ), norm w = 1 ∧ z = r * w := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number, prove that there exists an $r\\geq 0$ and a complex number $w$ with $| w | = 1$ such that $z = rw$.\n\\begin{proof}\n If $z=0$, we take $r=0, w=1$. (In this case $w$ is not unique.) Otherwise we take $r=|z|$ and $w=z /|z|$, and these choices are unique, since if $z=r w$, we must have $r=r|w|=|r w|=|z|, z / r$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_12 (n : ℕ) (f : ℕ → ℂ) :\n norm (∑ i ∈ range n, f i) ≤ ∑ i ∈ range n, norm (f i) := sorry", "formal_proof": null, "informal_stmt": "If $z_1, \\ldots, z_n$ are complex, prove that $|z_1 + z_2 + \\ldots + z_n| \\leq |z_1| + |z_2| + \\cdots + |z_n|$.\n\\begin{proof}\n We can apply the case $n=2$ and induction on $n$ to get\n$$\n\\begin{aligned}\n\\left|z_1+z_2+\\cdots z_n\\right| &=\\left|\\left(z_1+z_2+\\cdots+z_{n-1}\\right)+z_n\\right| \\\\\n& \\leq\\left|z_1+z_2+\\cdots+z_{n-1}\\right|+\\left|z_n\\right| \\\\\n& \\leq\\left|z_1\\right|+\\left|z_2\\right|+\\cdots+\\left|z_{n-1}\\right|+\\left|z_n\\right|\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_13 (x y : ℂ) :\n |(norm x) - (norm y)| ≤ norm (x - y) := sorry", "formal_proof": null, "informal_stmt": "If $x, y$ are complex, prove that $||x|-|y|| \\leq |x-y|$.\n\\begin{proof}\n Since $x=x-y+y$, the triangle inequality gives\n$$\n|x| \\leq|x-y|+|y|\n$$\nso that $|x|-|y| \\leq|x-y|$. Similarly $|y|-|x| \\leq|x-y|$. Since $|x|-|y|$ is a real number we have either ||$x|-| y||=|x|-|y|$ or ||$x|-| y||=|y|-|x|$. In either case, we have shown that ||$x|-| y|| \\leq|x-y|$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_14", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_14\n (z : ℂ) (h : norm z = 1)\n : (norm (1 + z)) ^ 2 + (norm (1 - z)) ^ 2 = 4 := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number such that $|z|=1$, that is, such that $z \\bar{z}=1$, compute $|1+z|^{2}+|1-z|^{2}$.\n\\begin{proof}\n $|1+z|^2=(1+z)(1+\\bar{z})=1+\\bar{z}+z+z \\bar{z}=2+z+\\bar{z}$. Similarly $|1-z|^2=(1-z)(1-\\bar{z})=1-z-\\bar{z}+z \\bar{z}=2-z-\\bar{z}$. Hence\n$$\n|1+z|^2+|1-z|^2=4 \\text {. }\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_16a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_16a\n (n : ℕ)\n (d r : ℝ)\n (x y z : EuclideanSpace ℝ (Fin n)) -- R^n\n (h₁ : n ≥ 3)\n (h₂ : ‖x - y‖ = d)\n (h₃ : d > 0)\n (h₄ : r > 0)\n (h₅ : 2 * r > d)\n : Set.Infinite {z : EuclideanSpace ℝ (Fin n) | ‖z - x‖ = r ∧ ‖z - y‖ = r} := sorry", "formal_proof": null, "informal_stmt": "Suppose $k \\geq 3, x, y \\in \\mathbb{R}^k, |x - y| = d > 0$, and $r > 0$. Prove that if $2r > d$, there are infinitely many $z \\in \\mathbb{R}^k$ such that $|z-x|=|z-y|=r$.\n\\begin{proof}\n (a) Let w be any vector satisfying the following two equations:\n$$\n\\begin{aligned}\n\\mathbf{w} \\cdot(\\mathbf{x}-\\mathbf{y}) &=0, \\\\\n|\\mathbf{w}|^2 &=r^2-\\frac{d^2}{4} .\n\\end{aligned}\n$$\nFrom linear algebra it is known that all but one of the components of a solution $\\mathbf{w}$ of the first equation can be arbitrary. The remaining component is then uniquely determined. Also, if $w$ is any non-zero solution of the first equation, there is a unique positive number $t$ such that $t$ w satisfies both equations. (For example, if $x_1 \\neq y_1$, the first equation is satisfied whenever\n$$\nz_1=\\frac{z_2\\left(x_2-y_2\\right)+\\cdots+z_k\\left(x_k-y_k\\right)}{y_1-x_1} .\n$$\nIf $\\left(z_1, z_2, \\ldots, z_k\\right)$ satisfies this equation, so does $\\left(t z_1, t z_2, \\ldots, t z_k\\right)$ for any real number $t$.) Since at least two of these components can vary independently, we can find a solution with these components having any prescribed ratio. This ratio does not change when we multiply by the positive number $t$ to obtain a solution of both equations. Since there are infinitely many ratios, there are infinitely many distinct solutions. For each such solution $\\mathbf{w}$ the vector $\\mathbf{z}=$ $\\frac{1}{2} \\mathrm{x}+\\frac{1}{2} \\mathrm{y}+\\mathrm{w}$ is a solution of the required equation. For\n$$\n\\begin{aligned}\n|\\mathrm{z}-\\mathbf{x}|^2 &=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}+\\mathbf{w}\\right|^2 \\\\\n&=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}\\right|^2+2 \\mathbf{w} \\cdot \\frac{\\mathbf{x}-\\mathbf{y}}{2}+|\\mathbf{w}|^2 \\\\\n&=\\frac{d^2}{4}+0+r^2-\\frac{d^2}{4} \\\\\n&=r^2\n\\end{aligned}\n$$\nand a similar relation holds for $|z-y|^2$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_17\n (n : ℕ)\n (x y : EuclideanSpace ℝ (Fin n)) -- R^n\n : ‖x + y‖^2 + ‖x - y‖^2 = 2*‖x‖^2 + 2*‖y‖^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that $|\\mathbf{x}+\\mathbf{y}|^{2}+|\\mathbf{x}-\\mathbf{y}|^{2}=2|\\mathbf{x}|^{2}+2|\\mathbf{y}|^{2}$ if $\\mathbf{x} \\in R^{k}$ and $\\mathbf{y} \\in R^{k}$.\n\\begin{proof}\n The proof is a routine computation, using the relation\n$$\n|x \\pm y|^2=(x \\pm y) \\cdot(x \\pm y)=|x|^2 \\pm 2 x \\cdot y+|y|^2 .\n$$\nIf $\\mathrm{x}$ and $\\mathrm{y}$ are the sides of a parallelogram, then $\\mathrm{x}+\\mathrm{y}$ and $\\mathbf{x}-\\mathrm{y}$ are its diagonals. Hence this result says that the sum of the squares on the diagonals of a parallelogram equals the sum of the squares on the sides.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_18a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18a\n (n : ℕ)\n (h : n > 1)\n (x : EuclideanSpace ℝ (Fin n)) -- R^n\n : ∃ (y : EuclideanSpace ℝ (Fin n)), y ≠ 0 ∧ (inner ℝ x y) = (0 : ℝ) := sorry", "formal_proof": null, "informal_stmt": "If $k \\geq 2$ and $\\mathbf{x} \\in R^{k}$, prove that there exists $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n If $\\mathbf{x}$ has any components equal to 0 , then $\\mathbf{y}$ can be taken to have the corresponding components equal to 1 and all others equal to 0 . If all the components of $\\mathbf{x}$ are nonzero, $\\mathbf{y}$ can be taken as $\\left(-x_2, x_1, 0, \\ldots, 0\\right)$. This is, of course, not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_18b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18b\n : ¬ ∀ (x : ℝ), ∃ (y : ℝ), y ≠ 0 ∧ x * y = 0 := sorry", "formal_proof": null, "informal_stmt": "If $k = 1$ and $\\mathbf{x} \\in R^{k}$, prove that there does not exist $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n Not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_1_19", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_19\n (n : ℕ)\n (a b c x : EuclideanSpace ℝ (Fin n))\n (r : ℝ)\n (h₁ : r > 0)\n (h₂ : 3 • c = 4 • b - a)\n (h₃ : 3 * r = 2 * ‖x - b‖)\n : ‖x - a‖ = 2 * ‖x - b‖ ↔ ‖x - c‖ = r := sorry", "formal_proof": null, "informal_stmt": "Suppose $a, b \\in R^k$. Find $c \\in R^k$ and $r > 0$ such that $|x-a|=2|x-b|$ if and only if $| x - c | = r$. Prove that $3c = 4b - a$ and $3r = 2 |b - a|$.\n\\begin{proof}\n Since the solution is given to us, all we have to do is verify it, i.e., we need to show that the equation\n$$\n|\\mathrm{x}-\\mathrm{a}|=2|\\mathrm{x}-\\mathrm{b}|\n$$\nis equivalent to $|\\mathrm{x}-\\mathbf{c}|=r$, which says\n$$\n\\left|\\mathbf{x}-\\frac{4}{3} \\mathbf{b}+\\frac{1}{3} \\mathbf{a}\\right|=\\frac{2}{3}|\\mathbf{b}-\\mathbf{a}| .\n$$\nIf we square both sides of both equations, we an equivalent pair of equations, the first of which reduces to\n$$\n3|\\mathbf{x}|^2+2 \\mathbf{a} \\cdot \\mathbf{x}-8 \\mathbf{b} \\cdot \\mathbf{x}-|\\mathbf{a}|^2+4|\\mathbf{b}|^2=0,\n$$\nand the second of which reduces to this equation divided by 3 . Hence these equations are indeed equivalent.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_19a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_19a {X : Type*} [MetricSpace X]\n (A B : Set X) (hA : IsClosed A) (hB : IsClosed B) (hAB : Disjoint A B) :\n SeparatedNhds A B := sorry", "formal_proof": null, "informal_stmt": "If $A$ and $B$ are disjoint closed sets in some metric space $X$, prove that they are separated.\n\\begin{proof}\n We are given that $A \\cap B=\\varnothing$. Since $A$ and $B$ are closed, this means $A \\cap \\bar{B}=\\varnothing=\\bar{A} \\cap B$, which says that $A$ and $B$ are separated.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_24 {X : Type*} [MetricSpace X]\n (hX : ∀ (A : Set X), Infinite A → ∃ (x : X), x ∈ closure A) :\n SeparableSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a metric space in which every infinite subset has a limit point. Prove that $X$ is separable.\n\\begin{proof}\n We observe that if the process of constructing $x_j$ did not terminate, the result would be an infinite set of points $x_j, j=1,2, \\ldots$, such that $d\\left(x_i, x_j\\right) \\geq \\delta$ for $i \\neq j$. It would then follow that for any $x \\in X$, the open ball $B_{\\frac{\\delta}{2}}(x)$ contains at most one point of the infinite set, hence that no point could be a limit point of this set, contrary to hypothesis. Hence $X$ is totally bounded, i.e., for each $\\delta>0$ there is a finite set $x_1, \\ldots, x_{N\\delta}$such that $X=\\bigcup_{j / 1}^{N\\delta} B_\\delta\\left(x_j\\right)$\n\nLet $x_{n_1}, \\ldots, x_{n N_n}$ be such that $X=\\bigcup_{j / 1}^{N_n} B_{\\frac{1}{n}}\\left(x_{n j}\\right), n=1,2, \\ldots$ We claim that $\\left\\{x_{n j}: 1 \\leq j \\leq N_n ; n=1,2, \\ldots\\right\\}$ is a countable dense subset of $X$. Indeed\n25\nif $x \\in X$ and $\\delta>0$, then $x \\in B_{\\frac{1}{n}}\\left(x_{n j}\\right)$ for some $x_{n j}$ for some $n>\\frac{1}{\\delta}$, and hence $d\\left(x, x_{n j}\\right)<\\delta$. By definition, this means that $\\left\\{x_{n j}\\right\\}$ is dense in $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_25", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_25 {K : Type*} [MetricSpace K] [CompactSpace K] :\n ∃ (B : Set (Set K)), Set.Countable B ∧ IsTopologicalBasis B := sorry", "formal_proof": null, "informal_stmt": "Prove that every compact metric space $K$ has a countable base.\n\\begin{proof}\n $K$ can be covered by a finite union of neighborhoods of radius $1 / n$, and this shows that this implies that $K$ is separable.\n\nIt is not entirely obvious that a metric space with a countable base is separable. To prove this, let $\\left\\{V_n\\right\\}_{n=1}^{\\infty}$ be a countable base, and let $x_n \\in V_n$. The points $V_n$ must be dense in $X$. For if $G$ is any non-empty open set, then $G$ contains $V_n$ for some $n$, and hence $x_n \\in G$. (Thus for a metric space, having a countable base and being separable are equivalent.)\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_27a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27a (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, ¬ Set.Countable (P ∩ E)}) :\n IsClosed P ∧ P = {x | ClusterPt x (𝓟 P)} := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that $P$ is perfect.\n\\begin{proof}\n We see that $E \\cap W$ is at most countable, being a countable union of at-most-countable sets. It remains to show that $P=W^c$, and that $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_27b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27b (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, (P ∩ E).Nonempty ∧ ¬ Set.Countable (P ∩ E)}) :\n Set.Countable (E \\ P) := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that at most countably many points of $E$ are not in $P$.\n\\begin{proof}\n If $x \\in W^c$, and $O$ is any neighborhood of $x$, then $x \\in V_n \\subseteq O$ for some n. Since $x \\notin W, V_n \\cap E$ is uncountable. Hence $O$ contains uncountably many points of $E$, and so $x$ is a condensation point of $E$. Thus $x \\in P$, i.e., $W^c \\subseteq P$.\nConversely if $x \\in W$, then $x \\in V_n$ for some $V_n$ such that $V_n \\cap E$ is countable. Hence $x$ has a neighborhood (any neighborhood contained in $V_n$ ) containing at most a countable set of points of $E$, and so $x \\notin P$, i.e., $W \\subseteq P^c$. Hence $P=W^c$.\nIt is clear that $P$ is closed (since its complement $W$ is open), so that we need only show that $P \\subseteq P^{\\prime}$. Hence suppose $x \\in P$, and $O$ is any neighborhood of $x$. (By definition of $P$ this means $O \\cap E$ is uncountable.) We need to show that there is a point $y \\in P \\cap(O \\backslash\\{x\\})$. If this is not the case, i.e., if every point $y$ in $O \\backslash\\{x\\}$ is in $P^c$, then for each such point $y$ there is a set $V_n$ containing $y$ such that $V_n \\cap E$ is at most countable. That would mean that $y \\in W$, i.e., that $O \\backslash\\{x\\}$ is contained in $W$. It would follow that $O \\cap E \\subseteq\\{x\\} \\cup(W \\cap E)$, and so $O \\cap E$ contains at most a countable set of points, contrary to the hypothesis that $x \\in P$. Hence $O$ contains a point of $P$ different from $x$, and so $P \\subseteq P^{\\prime}$. Thus $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_28", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_28 (X : Type*) [MetricSpace X] [SeparableSpace X]\n (A : Set X) (hA : IsClosed A) :\n ∃ P₁ P₂ : Set X, A = P₁ ∪ P₂ ∧\n IsClosed P₁ ∧ P₁ = {x | ClusterPt x (𝓟 P₁)} ∧\n Set.Countable P₂ := sorry", "formal_proof": null, "informal_stmt": "Prove that every closed set in a separable metric space is the union of a (possibly empty) perfect set and a set which is at most countable.\n\\begin{proof}\n If $E$ is closed, it contains all its limit points, and hence certainly all its condensation points. Thus $E=P \\cup(E \\backslash P)$, where $P$ is perfect (the set of all condensation points of $E$ ), and $E \\backslash P$ is at most countable.\n\nSince a perfect set in a separable metric space has the same cardinality as the real numbers, the set $P$ must be empty if $E$ is countable. The at-most countable set $E \\backslash P$ cannot be perfect, hence must have isolated points if it is nonempty.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_2_29", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_29 (U : Set ℝ) (hU : IsOpen U) :\n ∃ (f : ℕ → Set ℝ), (∀ n, ∃ a b : ℝ, f n = {x | a < x ∧ x < b}) ∧ (∀ n, f n ⊆ U) ∧\n (∀ n m, n ≠ m → f n ∩ f m = ∅) ∧\n U = ⋃ n, f n := sorry", "formal_proof": null, "informal_stmt": "Prove that every open set in $\\mathbb{R}$ is the union of an at most countable collection of disjoint segments.\n\\begin{proof}\n Let $O$ be open. For each pair of points $x \\in O, y \\in O$, we define an equivalence relation $x \\sim y$ by saying $x \\sim y$ if and only if $[\\min (x, y), \\max (x, y)] \\subset$ 0 . This is an equivalence relation, since $x \\sim x([x, x] \\subset O$ if $x \\in O)$; if $x \\sim y$, then $y \\sim x$ (since $\\min (x, y)=\\min (y, x)$ and $\\max (x, y)=\\max (y, x))$; and if $x \\sim y$ and $y \\sim z$, then $x \\sim z([\\min (x, z), \\max (x, z)] \\subseteq[\\min (x, y), \\max (x, y)] \\cup$ $[\\min (y, z), \\max (y, z)] \\subseteq O)$. In fact it is easy to prove that\n$$\n\\min (x, z) \\geq \\min (\\min (x, y), \\min (y, z))\n$$\nand\n$$\n\\max (x, z) \\leq \\max (\\max (x, y), \\max (y, z))\n$$\nIt follows that $O$ can be written as a disjoint union of pairwise disjoint equivalence classes. We claim that each equivalence class is an open interval.\n\nTo show this, for each $x \\in O$; let $A=\\{z:[z, x] \\subseteq O\\}$ and $B=\\{z:[x, z] \\subseteq$ $O\\}$, and let $a=\\inf A, b=\\sup B$. We claim that $(a, b) \\subset O$. Indeed if $az$. Then $z \\in[c, x] \\cup[x, d] \\subseteq O$. We now claim that $(a, b)$ is the equivalence class containing $x$. It is clear that each element of $(a, b)$ is equivalent to $x$ by the way in which $a$ and $b$ were chosen. We need to show that if $z \\notin(a, b)$, then $z$ is not equivalent to $x$. Suppose that $zb$ and $z \\sim x$, then $b$ could not be an upper bound for $B$.\n\nWe have now established that $O$ is a union of pairwise disjoint open intervals. Such a union must be at most countable, since each open interval contains a rational number not in any other interval.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_1a\n (f : ℕ → ℝ)\n (h : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => f n) atTop (𝓝 a))\n : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => |f n|) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Prove that convergence of $\\left\\{s_{n}\\right\\}$ implies convergence of $\\left\\{\\left|s_{n}\\right|\\right\\}$.\n\\begin{proof}\n Let $\\varepsilon>0$. Since the sequence $\\left\\{s_n\\right\\}$ is a Cauchy sequence, there exists $N$ such that $\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. We then have $\\left| |s_m| - |s_n| \\right| \\leq\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. Hence the sequence $\\left\\{\\left|s_n\\right|\\right\\}$ is also a Cauchy sequence, and therefore must converge.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_2a\n : Tendsto (λ (n : ℝ) => (sqrt (n^2 + n) - n)) atTop (𝓝 (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty}\\sqrt{n^2 + n} -n = 1/2$.\n\\begin{proof}\n Multiplying and dividing by $\\sqrt{n^2+n}+n$ yields\n$$\n\\sqrt{n^2+n}-n=\\frac{n}{\\sqrt{n^2+n}+n}=\\frac{1}{\\sqrt{1+\\frac{1}{n}}+1} .\n$$\nIt follows that the limit is $\\frac{1}{2}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "noncomputable def f : ℕ → ℝ\n| 0 => sqrt 2\n| (n + 1) => sqrt (2 + sqrt (f n))\n\ntheorem Rudin_exercise_3_3\n : ∃ (x : ℝ), Tendsto f atTop (𝓝 x) ∧ ∀ n, f n < 2 := sorry", "formal_proof": null, "informal_stmt": "If $s_{1}=\\sqrt{2}$, and $s_{n+1}=\\sqrt{2+\\sqrt{s_{n}}} \\quad(n=1,2,3, \\ldots),$ prove that $\\left\\{s_{n}\\right\\}$ converges, and that $s_{n}<2$ for $n=1,2,3, \\ldots$.\n\\begin{proof}\n Since $\\sqrt{2}<2$, it is manifest that if $s_n<2$, then $s_{n+1}<\\sqrt{2+2}=2$. Hence it follows by induction that $\\sqrt{2}1$, i.e., $s_n>s_n^2-2=s_{n-1}$. Hence the sequence is an increasing sequence that is bounded above (by 2 ) and so converges. Since the limit $s$ satisfies $s^2-s-2=0$, it follows that the limit is 2.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_5\n (a b : ℕ → ℝ)\n (h : limsup a + limsup b ≠ 0) :\n limsup (λ n => a n + b n) ≤ limsup a + limsup b := sorry", "formal_proof": null, "informal_stmt": "For any two real sequences $\\left\\{a_{n}\\right\\},\\left\\{b_{n}\\right\\}$, prove that $\\limsup _{n \\rightarrow \\infty}\\left(a_{n}+b_{n}\\right) \\leq \\limsup _{n \\rightarrow \\infty} a_{n}+\\limsup _{n \\rightarrow \\infty} b_{n},$ provided the sum on the right is not of the form $\\infty-\\infty$.\n\\begin{proof}\n Since the case when $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$ and $\\limsup _{n \\rightarrow \\infty} b_n=-\\infty$ has been excluded from consideration, we note that the inequality is obvious if $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$. Hence we shall assume that $\\left\\{a_n\\right\\}$ is bounded above.\n\nLet $\\left\\{n_k\\right\\}$ be a subsequence of the positive integers such that $\\lim _{k \\rightarrow \\infty}\\left(a_{n_k}+\\right.$ $\\left.b_{n_k}\\right)=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Then choose a subsequence of the positive integers $\\left\\{k_m\\right\\}$ such that\n$$\n\\lim _{m \\rightarrow \\infty} a_{n_{k_m}}=\\limsup _{k \\rightarrow \\infty} a_{n_k} .\n$$\nThe subsequence $a_{n_{k_m}}+b_{n_{k_m}}$ still converges to the same limit as $a_{n_k}+b_{n_k}$, i.e., to $\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Hence, since $a_{n_k}$ is bounded above (so that $\\limsup _{k \\rightarrow \\infty} a_{n_k}$ is finite), it follows that $b_{n_{k_m}}$ converges to the difference\n$$\n\\lim _{m \\rightarrow \\infty} b_{n_{k_m}}=\\lim _{m \\rightarrow \\infty}\\left(a_{n_{k_m}}+b_{n_{k_m}}\\right)-\\lim _{m \\rightarrow \\infty} a_{n_{k_m}} .\n$$\nThus we have proved that there exist subsequences $\\left\\{a_{n_{k_m}}\\right\\}$ and $\\left\\{b_{n_{k_m}}\\right\\}$ which converge to limits $a$ and $b$ respectively such that $a+b=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n^*\\right)$. Since $a$ is the limit of a subsequence of $\\left\\{a_n\\right\\}$ and $b$ is the limit of a subsequence of $\\left\\{b_n\\right\\}$, it follows that $a \\leq \\limsup _{n \\rightarrow \\infty} a_n$ and $b \\leq \\limsup _{n \\rightarrow \\infty} b_n$, from which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_6a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "def g (n : ℕ) : ℝ := sqrt (n + 1) - sqrt n\n\ntheorem Rudin_exercise_3_6a\n: Tendsto (λ (n : ℕ) => (∑ i ∈ range n, g i)) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty} \\sum_{i (∑ i ∈ (range n), a i)) atTop (𝓝 y))) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), sqrt (a i) / n)) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the convergence of $\\Sigma a_{n}$ implies the convergence of $\\sum \\frac{\\sqrt{a_{n}}}{n}$ if $a_n\\geq 0$.\n\\begin{proof}\n Since $\\left(\\sqrt{a_n}-\\frac{1}{n}\\right)^2 \\geq 0$, it follows that\n$$\n\\frac{\\sqrt{a_n}}{n} \\leq \\frac{1}{2}\\left(a_n^2+\\frac{1}{n^2}\\right) .\n$$\nNow $\\Sigma a_n^2$ converges by comparison with $\\Sigma a_n$ (since $\\Sigma a_n$ converges, we have $a_n<1$ for large $n$, and hence $\\left.a_n^2 (∑ i ∈ (range n), a i)) atTop (𝓝 y)))\n (h2 : Monotone b)\n (h3 : Bornology.IsBounded (Set.range b)) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), (a i) * (b i))) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "If $\\Sigma a_{n}$ converges, and if $\\left\\{b_{n}\\right\\}$ is monotonic and bounded, prove that $\\Sigma a_{n} b_{n}$ converges.\n\\begin{proof}\n We shall show that the partial sums of this series form a Cauchy sequence, i.e., given $\\varepsilon>0$ there exists $N$ such that $\\left|\\sum_{k=m+1}^n a_k b_k\\right|\\langle\\varepsilon$ if $n\\rangle$ $m \\geq N$. To do this, let $S_n=\\sum_{k=1}^n a_k\\left(S_0=0\\right)$, so that $a_k=S_k-S_{k-1}$ for $k=1,2, \\ldots$ Let $M$ be an upper bound for both $\\left|b_n\\right|$ and $\\left|S_n\\right|$, and let $S=\\sum a_n$ and $b=\\lim b_n$. Choose $N$ so large that the following three inequalities hold for all $m>N$ and $n>N$ :\n$$\n\\left|b_n S_n-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m S_m-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M} .\n$$\nThen if $n>m>N$, we have, from the formula for summation by parts,\n$$\n\\sum_{k=m+1}^n a_n b_n=b_n S_n-b_m S_m+\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\n$$\nOur assumptions yield immediately that $\\left|b_n S_n-b_m S_m\\right|<\\frac{2 \\varepsilon}{3}$, and\n$$\n\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\\right| \\leq M \\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right| .\n$$\nSince the sequence $\\left\\{b_n\\right\\}$ is monotonic, we have\n$$\n\\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right|=\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right)\\right|=\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M},\n$$\nfrom which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_13\n (a b : ℕ → ℝ)\n (ha : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |a i|)) atTop (𝓝 y)))\n (hb : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |b i|)) atTop (𝓝 y))) :\n ∃ y, (Tendsto (λ n => (∑ i ∈ (range n),\n λ i => (∑ j ∈ range (i + 1), a j * b (i - j)))) atTop (𝓝 y)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the Cauchy product of two absolutely convergent series converges absolutely.\n\\begin{proof}\n Since both the hypothesis and conclusion refer to absolute convergence, we may assume both series consist of nonnegative terms. We let $S_n=\\sum_{k=0}^n a_n, T_n=\\sum_{k=0}^n b_n$, and $U_n=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l}$. We need to show that $U_n$ remains bounded, given that $S_n$ and $T_n$ are bounded. To do this we make the convention that $a_{-1}=T_{-1}=0$, in order to save ourselves from having to separate off the first and last terms when we sum by parts. We then have\n$$\n\\begin{aligned}\nU_n &=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l} \\\\\n&=\\sum_{k=0}^n \\sum_{l=0}^k a_l\\left(T_{k-l}-T_{k-l-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k a_{k-j}\\left(T_j-T_{j-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k\\left(a_{k-j}-a_{k-j-1}\\right) T_j \\\\\n&=\\sum_{j=0}^n \\sum_{k=j}^n\\left(a_{k-j}-a_{k-j-1}\\right) T_j\n&=\\sum_{j=0}^n a_{n-j} T_j \\\\\n&\\leq T \\sum_{m=0}^n a_m \\\\\n&=T S_n \\\\\n&\\leq S T .\n\\end{aligned}\n$$\nThus $U_n$ is bounded, and hence approaches a finite limit.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_20", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_20 {X : Type*} [MetricSpace X]\n (p : ℕ → X) (l : ℕ) (r : X)\n (hp : CauchySeq p)\n (hpl : Tendsto (λ n => p (l * n)) atTop (𝓝 r)) :\n Tendsto p atTop (𝓝 r) := sorry", "formal_proof": null, "informal_stmt": "Suppose $\\left\\{p_{n}\\right\\}$ is a Cauchy sequence in a metric space $X$, and some sequence $\\left\\{p_{n l}\\right\\}$ converges to a point $p \\in X$. Prove that the full sequence $\\left\\{p_{n}\\right\\}$ converges to $p$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $N_1$ so large that $d\\left(p_m, p_n\\right)<\\frac{\\varepsilon}{2}$ if $m>N_1$ and $n>N_1$. Then choose $N \\geq N_1$ so large that $d\\left(p_{n_k}, p\\right)<\\frac{\\varepsilon}{2}$ if $k>N$. Then if $n>N$, we have\n$$\nd\\left(p_n, p\\right) \\leq d\\left(p_n, p_{n_{N+1}}\\right)+d\\left(p_{n_{N+1}}, p\\right)<\\varepsilon\n$$\nFor the first term on the right is less than $\\frac{\\varepsilon}{2}$ since $n>N_1$ and $n_{N+1}>N+1>$ $N_1$. The second term is less than $\\frac{\\varepsilon}{2}$ by the choice of $N$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_21", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_21\n {X : Type*} [MetricSpace X] [CompleteSpace X]\n (E : ℕ → Set X)\n (hE : ∀ n, E n ⊃ E (n + 1))\n (hE' : Tendsto (λ n => Metric.diam (E n)) atTop (𝓝 0)) :\n ∃ a, Set.iInter E = {a} := sorry", "formal_proof": null, "informal_stmt": "If $\\left\\{E_{n}\\right\\}$ is a sequence of closed nonempty and bounded sets in a complete metric space $X$, if $E_{n} \\supset E_{n+1}$, and if $\\lim _{n \\rightarrow \\infty} \\operatorname{diam} E_{n}=0,$ then $\\bigcap_{1}^{\\infty} E_{n}$ consists of exactly one point.\n\\begin{proof}\n Choose $x_n \\in E_n$. (We use the axiom of choice here.) The sequence $\\left\\{x_n\\right\\}$ is a Cauchy sequence, since the diameter of $E_n$ tends to zero as $n$ tends to infinity and $E_n$ contains $E_{n+1}$. Since the metric space $X$ is complete, the sequence $x_n$ converges to a point $x$, which must belong to $E_n$ for all $n$, since $E_n$ is closed and contains $x_m$ for all $m \\geq n$. There cannot be a second point $y$ in all of the $E_n$, since for any point $y \\neq x$ the diameter of $E_n$ is less $\\operatorname{than} d(x, y)$ for large $n$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_3_22", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_22 (X : Type*) [MetricSpace X] [CompleteSpace X]\n (G : ℕ → Set X) (hG : ∀ n, IsOpen (G n) ∧ Dense (G n)) :\n ∃ x, ∀ n, x ∈ G n := sorry", "formal_proof": null, "informal_stmt": "Suppose $X$ is a nonempty complete metric space, and $\\left\\{G_{n}\\right\\}$ is a sequence of dense open sets of $X$. Prove Baire's theorem, namely, that $\\bigcap_{1}^{\\infty} G_{n}$ is not empty.\n\\begin{proof}\n Let $F_n$ be the complement of $G_n$, so that $F_n$ is closed and contains no open sets. We shall prove that any nonempty open set $U$ contains a point not in any $F_n$, hence in all $G_n$. To this end, we note that $U$ is not contained in $F_1$, so that there is a point $x_1 \\in U \\backslash F_1$. Since $U \\backslash F_1$ is open, there exists $r_1>0$ such that $B_1$, defined as the open ball of radius $r_1$ about $x_1$, is contained in $U \\backslash F_1$. Let $E_1$ be the open ball of radius $\\frac{r_1}{2}$ about $x_1$, so that the closure of $E_1$ is contained in $B_1$. Now $F_2$ does not contain $E_1$, and so we can find a point $x_2 \\in E_1 \\backslash F_2$. Since $E_1 \\backslash F_2$ is an open set, there exists a positive number $r_2$ such that $B_2$, the open ball of radius $R_2$ about $x_2$, is contained in $E_1 \\backslash F_2$, which in turn is contained in $U \\backslash\\left(F_1 \\cup F_2\\right)$. We let $E_2$ be the open ball of radius $\\frac{r_2}{2}$ about $x_2$, so that $\\bar{E}_2 \\subseteq B_2$. Proceeding in this way, we construct a sequence of open balls $E_j$, such that $E_j \\supseteq \\bar{E}_{j+1}$, and the diameter of $E_j$ tends to zero. By the previous exercise, there is a point $x$ belonging to all the sets $\\bar{E}_j$, hence to all the sets $U \\backslash\\left(F_1 \\cup F_2 \\cup \\cdots \\cup F_n\\right)$. Thus the point $x$ belongs to $U \\cap\\left(\\cap_1^{\\infty} G_n\\right)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_1a\n : ∃ (f : ℝ → ℝ), (∀ (x : ℝ), Tendsto (λ y => f (x + y) - f (x - y)) (𝓝 0) (𝓝 0)) ∧ ¬ Continuous f := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real function defined on $\\mathbb{R}$ which satisfies $\\lim_{h \\rightarrow 0} f(x + h) - f(x - h) = 0$ for every $x \\in \\mathbb{R}$. Show that $f$ does not need to be continuous.\n\\begin{proof}\n $$\nf(x)= \\begin{cases}1 & \\text { if } x \\text { is an integer } \\\\ 0 & \\text { if } x \\text { is not an integer. }\\end{cases}\n$$\n(If $x$ is an integer, then $f(x+h)-f(x-h) \\equiv 0$ for all $h$; while if $x$ is not an integer, $f(x+h)-f(x-h)=0$ for $|h|<\\min (x-[x], 1+[x]-x)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_2a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (h₁ : Continuous f)\n : ∀ (x : Set α), f '' (closure x) ⊆ closure (f '' x) := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a continuous mapping of a metric space $X$ into a metric space $Y$, prove that $f(\\overline{E}) \\subset \\overline{f(E)}$ for every set $E \\subset X$. ($\\overline{E}$ denotes the closure of $E$).\n\\begin{proof}\n Let $x \\in \\bar{E}$. We need to show that $f(x) \\in \\overline{f(E)}$. To this end, let $O$ be any neighborhood of $f(x)$. Since $f$ is continuous, $f^{-1}(O)$ contains (is) a neighborhood of $x$. Since $x \\in \\bar{E}$, there is a point $u$ of $E$ in $f^{-1}(O)$. Hence $\\frac{f(u)}{f(E)} \\in O \\cap f(E)$. Since $O$ was any neighborhood of $f(x)$, it follows that $f(x) \\in \\overline{f(E)}$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_3\n {α : Type} [MetricSpace α]\n (f : α → ℝ) (h : Continuous f) (z : Set α) (g : z = f⁻¹' {0})\n : IsClosed z := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a continuous real function on a metric space $X$. Let $Z(f)$ (the zero set of $f$ ) be the set of all $p \\in X$ at which $f(p)=0$. Prove that $Z(f)$ is closed.\n\\begin{proof}\n $Z(f)=f^{-1}(\\{0\\})$, which is the inverse image of a closed set. Hence $Z(f)$ is closed.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_4a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Dense s)\n : f '' Set.univ ⊆ closure (f '' s) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that $f(E)$ is dense in $f(X)$.\n\\begin{proof}\n To prove that $f(E)$ is dense in $f(X)$, simply use that $f(X)=f(\\bar{E}) \\subseteq \\overline{f(E)}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_4b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4b\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f g : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Continuous g)\n (h₃ : Dense s)\n (h₄ : ∀ x ∈ s, f x = g x)\n : f = g := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that if $g(p) = f(p)$ for all $p \\in P$ then $g(p) = f(p)$ for all $p \\in X$.\n\\begin{proof}\n The function $\\varphi: X \\rightarrow R^1$ given by\n$$\n\\varphi(p)=d_Y(f(p), g(p))\n$$\nis continuous, since\n$$\n\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right| \\leq d_Y(f(p), f(q))+d_Y(g(p), g(q))\n$$\n(This inequality follows from the triangle inequality, since\n$$\nd_Y(f(p), g(p)) \\leq d_Y(f(p), f(q))+d_Y(f(q), g(q))+d_Y(g(q), g(p)),\n$$\nand the same inequality holds with $p$ and $q$ interchanged. The absolute value $\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right|$ must be either $d_Y(f(p), g(p))-d_Y(f(q), g(q))$ or $d_Y(f(q), g(q))-d_Y(f(p), g(p))$, and the triangle inequality shows that both of these numbers are at most $d_Y(f(p), f(q))+d_Y(g(p), g(q))$.)\nBy the previous problem, the zero set of $\\varphi$ is closed. But by definition\n$$\nZ(\\varphi)=\\{p: f(p)=g(p)\\} .\n$$\nHence the set of $p$ for which $f(p)=g(p)$ is closed. Since by hypothesis it is dense, it must be $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_5a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_5a\n (f : ℝ → ℝ)\n (E : Set ℝ)\n (h₁ : IsClosed E)\n (h₂ : ContinuousOn f E)\n : ∃ (g : ℝ → ℝ), Continuous g ∧ ∀ x ∈ E, f x = g x := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a real continuous function defined on a closed set $E \\subset \\mathbb{R}$, prove that there exist continuous real functions $g$ on $\\mathbb{R}$ such that $g(x)=f(x)$ for all $x \\in E$.\n\\begin{proof}\nFollowing the hint, let the complement of $E$ consist of a countable collection of finite open intervals $\\left(a_k, b_k\\right)$ together with possibly one or both of the the semi-infinite intervals $(b,+\\infty)$ and $(-\\infty, a)$. The function $f(x)$ is already defined at $a_k$ and $b_k$, as well as at $a$ and $b$ (if these last two points exist). Define $g(x)$ to be $f(b)$ for $x>b$ and $f(a)$ for $x0$. To choose $\\delta>0$ such that $|x-u|<\\delta$ implies $|g(x)-g(u)|<\\varepsilon$, we consider three cases.\ni. If $x>b$, let $\\delta=x-b$. Then if $|x-u|<\\delta$, it follows that $u>b$ also, so that $g(u)=f(b)=g(x)$, and $|g(u)-g(x)|=0<\\varepsilon$. Similarly if $xa_k+\\delta_1$. Let us consider the second of these cases and show how to get $|f(u)-f(x)|<\\varepsilon$ for $xx$ we have $a_k0$ be given. Choose $\\eta>0$ so that $d_Y(f(x), f(u))<\\frac{\\varepsilon}{2}$ if $d_E(x, y)<\\eta$. Then let $\\delta=\\min \\left(\\eta, \\frac{\\varepsilon}{2}\\right)$. It is easy to see that $\\rho(\\varphi(x), \\varphi(u))<\\varepsilon$ if $d_E(x, u)<\\delta$. Conversely if $\\varphi$ is continuous, it is obvious from the inequality $\\rho(\\varphi(x), \\varphi(u)) \\geq d_Y(f(x), f(u))$ that $f$ is continuous.\n\nFrom these facts we deduce immediately that the graph of a continuous function $f$ on a compact set $E$ is compact, being the image of $E$ under the continuous mapping $\\varphi$. Conversely, if $f$ is not continuous at some point $x$, there is a sequence of points $x_n$ converging to $x$ such that $f\\left(x_n\\right)$ does not converge to $f(x)$. If no subsequence of $f\\left(x_n\\right)$ converges, then the sequence $\\left\\{\\left(x_n, f\\left(x_n\\right)\\right\\}_{n=1}^{\\infty}\\right.$ has no convergent subsequence, and so the graph is not compact. If some subsequence of $f\\left(x_n\\right)$ converges, say $f\\left(x_{n_k}\\right) \\rightarrow z$, but $z \\neq f(x)$, then the graph of $f$ fails to contain the limit point $(x, z)$, and hence is not closed. A fortiori it is not compact.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_8a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_8a\n (E : Set ℝ) (f : ℝ → ℝ) (hf : UniformContinuousOn f E)\n (hE : Bornology.IsBounded E) : Bornology.IsBounded (Set.image f E) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real uniformly continuous function on the bounded set $E$ in $R^{1}$. Prove that $f$ is bounded on $E$.\n\\begin{proof}\n Let $a=\\inf E$ and $b=\\sup E$, and let $\\delta>0$ be such that $|f(x)-f(y)|<1$ if $x, y \\in E$ and $|x-y|<\\delta$. Now choose a positive integer $N$ larger than $(b-a) / \\delta$, and consider the $N$ intervals $I_k=\\left[a+\\frac{k-1}{b-a}, a+\\frac{k}{b-a}\\right], k=1,2, \\ldots, N$. For each $k$ such that $I_k \\cap E \\neq \\varnothing$ let $x_k \\in E \\cap I_k$. Then let $M=1+\\max \\left\\{\\left|f\\left(x_k\\right)\\right|\\right\\}$. If $x \\in E$, we have $\\left|x-x_k\\right|<\\delta$ for some $k$, and hence $|f(x)| f (x n)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a uniformly continuous mapping of a metric space $X$ into a metric space $Y$ and prove that $\\left\\{f\\left(x_{n}\\right)\\right\\}$ is a Cauchy sequence in $Y$ for every Cauchy sequence $\\{x_n\\}$ in $X$.\n\\begin{proof}\n Suppose $\\left\\{x_n\\right\\}$ is a Cauchy sequence in $X$. Let $\\varepsilon>0$ be given. Let $\\delta>0$ be such that $d_Y(f(x), f(u))<\\varepsilon$ if $d_X(x, u)<\\delta$. Then choose $N$ so that $d_X\\left(x_n, x_m\\right)<\\delta$ if $n, m>N$. Obviously $d_Y\\left(f\\left(x_n\\right), f\\left(x_m\\right)\\right)<\\varepsilon$ if $m, n>N$, showing that $\\left\\{f\\left(x_n\\right)\\right\\}$ is a Cauchy sequence.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_12\n {α β γ : Type*} [UniformSpace α] [UniformSpace β] [UniformSpace γ]\n {f : α → β} {g : β → γ}\n (hf : UniformContinuous f) (hg : UniformContinuous g) :\n UniformContinuous (g ∘ f) := sorry", "formal_proof": null, "informal_stmt": "A uniformly continuous function of a uniformly continuous function is uniformly continuous.\n\\begin{proof}\n Let $f: X \\rightarrow Y$ and $g: Y \\rightarrow Z$ be uniformly continuous. Then $g \\circ f: X \\rightarrow Z$ is uniformly continuous, where $g \\circ f(x)=g(f(x))$ for all $x \\in X$.\nTo prove this fact, let $\\varepsilon>0$ be given. Then, since $g$ is uniformly continuous, there exists $\\eta>0$ such that $d_Z(g(u), g(v))<\\varepsilon$ if $d_Y(u, v)<\\eta$. Since $f$ is uniformly continuous, there exists $\\delta>0$ such that $d_Y(f(x), f(y))<\\eta$ if $d_X(x, y)<\\delta$\n\nIt is then obvious that $d_Z(g(f(x)), g(f(y)))<\\varepsilon$ if $d_X(x, y)<\\delta$, so that $g \\circ f$ is uniformly continuous.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_15 {f : ℝ → ℝ}\n (hf : Continuous f) (hof : IsOpenMap f) :\n Monotone f := sorry", "formal_proof": null, "informal_stmt": "Prove that every continuous open mapping of $R^{1}$ into $R^{1}$ is monotonic.\n\\begin{proof}\n Suppose $f$ is continuous and not monotonic, say there exist points $a 0 ∧ ∀ (p q : X), p ∈ K → q ∈ F → dist p q ≥ δ := sorry", "formal_proof": null, "informal_stmt": "Suppose $K$ and $F$ are disjoint sets in a metric space $X, K$ is compact, $F$ is closed. Prove that there exists $\\delta>0$ such that $d(p, q)>\\delta$ if $p \\in K, q \\in F$.\n\\begin{proof}\nFollowing the hint, we observe that $\\rho_F(x)$ must attain its minimum value on $K$, i.e., there is some point $r \\in K$ such that\n$$\n\\rho_F(r)=\\min _{q \\in K} \\rho_F(q) .\n$$\nSince $F$ is closed and $r \\notin F$, it follows from Exercise $4.20$ that $\\rho_F(r)>0$. Let $\\delta$ be any positive number smaller than $\\rho_F(r)$. Then for any $p \\in F, q \\in K$, we have\n$$\nd(p, q) \\geq \\rho_F(q) \\geq \\rho_F(r)>\\delta .\n$$\nThis proves the positive assertion.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_4_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_24 {f : ℝ → ℝ}\n (hf : Continuous f) (a b : ℝ) (hab : a < b)\n (h : ∀ x y : ℝ, a < x → x < b → a < y → y < b → f ((x + y) / 2) ≤ (f x + f y) / 2) :\n ConvexOn ℝ (Set.Ioo a b) f := sorry", "formal_proof": null, "informal_stmt": "Assume that $f$ is a continuous real function defined in $(a, b)$ such that $f\\left(\\frac{x+y}{2}\\right) \\leq \\frac{f(x)+f(y)}{2}$ for all $x, y \\in(a, b)$. Prove that $f$ is convex.\n\\begin{proof}\n We shall prove that\n$$\nf(\\lambda x+(1-\\lambda) y) \\leq \\lambda f(x)+(1-\\lambda) f(y)\n$$\nfor all \"dyadic rational\" numbers, i.e., all numbers of the form $\\lambda=\\frac{k}{2^n}$, where $k$ is a nonnegative integer not larger than $2^n$. We do this by induction on $n$. The case $n=0$ is trivial (since $\\lambda=0$ or $\\lambda=1$ ). In the case $n=1$ we have $\\lambda=0$ or $\\lambda=1$ or $\\lambda=\\frac{1}{2}$. The first two cases are again trivial, and the third is precisely the hypothesis of the theorem. Suppose the result is proved for $n \\leq r$, and consider $\\lambda=\\frac{k}{2^{r+1}}$. If $k$ is even, say $k=2 l$, then $\\frac{k}{2^{r+1}}=\\frac{l}{2^r}$, and we can appeal to the induction hypothesis. Now suppose $k$ is odd. Then $1 \\leq k \\leq 2^{r+1}-1$, and so the numbers $l=\\frac{k-1}{2}$ and $m=\\frac{k+1}{2}$ are integers with $0 \\leq l c := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be defined for all real $x$, and suppose that $|f(x)-f(y)| \\leq (x-y)^{2}$ for all real $x$ and $y$. Prove that $f$ is constant.\n\\begin{proof}\n Dividing by $x-y$, and letting $x \\rightarrow y$, we find that $f^{\\prime}(y)=0$ for all $y$. Hence $f$ is constant.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_2 {a b : ℝ}\n {f g : ℝ → ℝ} (hf : ∀ x ∈ Set.Ioo a b, deriv f x > 0)\n (hg : g = f⁻¹)\n (hg_diff : DifferentiableOn ℝ g (Set.Ioo a b)) :\n DifferentiableOn ℝ g (Set.Ioo a b) ∧\n ∀ x ∈ Set.Ioo a b, deriv g x = 1 / deriv f x := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x)>0$ in $(a, b)$. Prove that $f$ is strictly increasing in $(a, b)$, and let $g$ be its inverse function. Prove that $g$ is differentiable, and that $g^{\\prime}(f(x))=\\frac{1}{f^{\\prime}(x)} \\quad(a0$. Hence $f(c)0$ there exists $\\eta>0$ such that\n$$\n\\left|\\frac{1}{\\frac{f(x+h)-f(x)}{h}}-\\frac{1}{f^{\\prime}(x)}\\right|<\\varepsilon\n$$\nif $0<|h|<\\eta$. Since $h=g(y+k)-g(y)$, there exists $\\delta>0$ such that $0<|h|<\\eta$ if $0<|k|<\\delta$. The proof is now complete. \n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_3 {g : ℝ → ℝ} (hg : Continuous g)\n (hg' : ∃ M : ℝ, ∀ x : ℝ, |deriv g x| ≤ M) :\n ∃ N, ∀ ε > 0, ε < N → Function.Injective (λ x : ℝ => x + ε * g x) := sorry", "formal_proof": null, "informal_stmt": "Suppose $g$ is a real function on $R^{1}$, with bounded derivative (say $\\left|g^{\\prime}\\right| \\leq M$ ). Fix $\\varepsilon>0$, and define $f(x)=x+\\varepsilon g(x)$. Prove that $f$ is one-to-one if $\\varepsilon$ is small enough.\n\\begin{proof}\n If $0<\\varepsilon<\\frac{1}{M}$, we certainly have\n$$\nf^{\\prime}(x) \\geq 1-\\varepsilon M>0,\n$$\nand this implies that $f(x)$ is one-to-one, by the preceding problem.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_4 {n : ℕ}\n (C : ℕ → ℝ)\n (hC : ∑ i ∈ (range (n + 1)), (C i) / (i + 1) = 0) :\n ∃ x, x ∈ (Set.Icc (0 : ℝ) 1) ∧ ∑ i ∈ range (n + 1), (C i) * (x^i) = 0 := sorry", "formal_proof": null, "informal_stmt": "If $C_{0}+\\frac{C_{1}}{2}+\\cdots+\\frac{C_{n-1}}{n}+\\frac{C_{n}}{n+1}=0,$ where $C_{0}, \\ldots, C_{n}$ are real constants, prove that the equation $C_{0}+C_{1} x+\\cdots+C_{n-1} x^{n-1}+C_{n} x^{n}=0$ has at least one real root between 0 and 1.\n\\begin{proof}\n Consider the polynomial\n$$\np(x)=C_0 x+\\frac{C_1}{2} x^2+\\cdots+\\frac{C_{n-1}}{n} x^n+\\frac{C_n}{n+1} x^{n+1},\n$$\nwhose derivative is\n$$\np^{\\prime}(x)=C_0+C_1 x+\\cdots+C_{n-1} x^{n-1}+C_n x^n .\n$$\nIt is obvious that $p(0)=0$, and the hypothesis of the problem is that $p(1)=0$. Hence Rolle's theorem implies that $p^{\\prime}(x)=0$ for some $x$ between 0 and 1 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_5\n {f : ℝ → ℝ}\n (hfd : Differentiable ℝ f)\n (hf : Tendsto (deriv f) atTop (𝓝 0)) :\n Tendsto (λ x => f (x + 1) - f x) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is defined and differentiable for every $x>0$, and $f^{\\prime}(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$. Put $g(x)=f(x+1)-f(x)$. Prove that $g(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $x_0$ such that $\\left|f^{\\prime}(x)\\right|<\\varepsilon$ if $x>x_0$. Then for any $x \\geq x_0$ there exists $x_1 \\in(x, x+1)$ such that\n$$\nf(x+1)-f(x)=f^{\\prime}\\left(x_1\\right) .\n$$\nSince $\\left|f^{\\prime}\\left(x_1\\right)\\right|<\\varepsilon$, it follows that $|f(x+1)-f(x)|<\\varepsilon$, as required.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_6", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_6\n {f : ℝ → ℝ}\n (hf1 : Continuous f)\n (hf2 : ∀ x, DifferentiableAt ℝ f x)\n (hf3 : f 0 = 0)\n (hf4 : Monotone (deriv f)) :\n MonotoneOn (λ x => f x / x) (Set.Ioi 0) := sorry", "formal_proof": null, "informal_stmt": "Suppose (a) $f$ is continuous for $x \\geq 0$, (b) $f^{\\prime}(x)$ exists for $x>0$, (c) $f(0)=0$, (d) $f^{\\prime}$ is monotonically increasing. Put $g(x)=\\frac{f(x)}{x} \\quad(x>0)$ and prove that $g$ is monotonically increasing.\n\\begin{proof}\n Put\n$$\ng(x)=\\frac{f(x)}{x} \\quad(x>0)\n$$\nand prove that $g$ is monotonically increasing.\nBy the mean-value theorem\n$$\nf(x)=f(x)-f(0)=f^{\\prime}(c) x\n$$\nfor some $c \\in(0, x)$. Since $f^{\\prime}$ is monotonically increasing, this result implies that $f(x)0,\n$$\nso that $g$ is also monotonically increasing.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_7", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_7\n {f g : ℝ → ℝ} {x : ℝ}\n (hf' : DifferentiableAt ℝ f 0)\n (hg' : DifferentiableAt ℝ g 0)\n (hg'_ne_0 : deriv g 0 ≠ 0)\n (f0 : f 0 = 0) (g0 : g 0 = 0) :\n Tendsto (λ x => f x / g x) (𝓝 x) (𝓝 (deriv f x / deriv g x)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x), g^{\\prime}(x)$ exist, $g^{\\prime}(x) \\neq 0$, and $f(x)=g(x)=0$. Prove that $\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)}=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}.$\n\\begin{proof}\n Since $f(x)=g(x)=0$, we have\n$$\n\\begin{aligned}\n\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)} &=\\lim _{t \\rightarrow x} \\frac{\\frac{f(t)-f(x)}{t-x}}{\\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{\\lim _{t \\rightarrow x} \\frac{f(t)-f(x)}{t-x}}{\\lim _{t \\rightarrow x} \\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_15 {f : ℝ → ℝ} (a M0 M1 M2 : ℝ)\n (hf' : DifferentiableOn ℝ f (Set.Ici a))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Ici a))\n (hM0 : M0 = sSup {(|f x|) | x ∈ (Set.Ici a)})\n (hM1 : M1 = sSup {(|deriv f x|) | x ∈ (Set.Ici a)})\n (hM2 : M2 = sSup {(|deriv (deriv f) x|) | x ∈ (Set.Ici a)}) :\n (M1 ^ 2) ≤ 4 * M0 * M2 := sorry", "formal_proof": null, "informal_stmt": "Suppose $a \\in R^{1}, f$ is a twice-differentiable real function on $(a, \\infty)$, and $M_{0}, M_{1}, M_{2}$ are the least upper bounds of $|f(x)|,\\left|f^{\\prime}(x)\\right|,\\left|f^{\\prime \\prime}(x)\\right|$, respectively, on $(a, \\infty)$. Prove that $M_{1}^{2} \\leq 4 M_{0} M_{2} .$\n\\begin{proof}\n The inequality is obvious if $M_0=+\\infty$ or $M_2=+\\infty$, so we shall assume that $M_0$ and $M_2$ are both finite. We need to show that\n$$\n\\left|f^{\\prime}(x)\\right| \\leq 2 \\sqrt{M_0 M_2}\n$$\nfor all $x>a$. We note that this is obvious if $M_2=0$, since in that case $f^{\\prime}(x)$ is constant, $f(x)$ is a linear function, and the only bounded linear function is a constant, whose derivative is zero. Hence we shall assume from now on that $0-1$. Now $f^{\\prime}(x)=\\frac{4 x}{\\left(x^2+1\\right)^2}$ for $x>0$ and $f^{\\prime}(x)=4 x$ for $x<0$. It thus follows from Exercise 9 above that $f^{\\prime}(0)=0$, and that $f^{\\prime}(x)$ is continuous. Likewise $f^{\\prime \\prime}(x)=4$ for $x<0$ and $f^{\\prime \\prime}(x)=\\frac{4-4 x^2}{\\left(x^2+1\\right)^3}=-4 \\frac{x^2-1}{\\left(x^2+1\\right)^3}$. This shows that $\\left|f^{\\prime \\prime}(x)\\right|<4$ for $x>0$ and also that $\\lim _{x \\rightarrow 0} f^{\\prime \\prime}(x)=4$. Hence Exercise 9 again implies that $f^{\\prime \\prime}(x)$ is continuous and $f^{\\prime \\prime}(0)=4$.\n\nOn $n$-dimensional space let $\\mathbf{f}(x)=\\left(f_1(x), \\ldots, f_n(x)\\right), M_0=\\sup |\\mathbf{f}(x)|$, $M_1=\\sup \\left|\\mathbf{f}^{\\prime}(x)\\right|$, and $M_2=\\sup \\left|\\mathbf{f}^{\\prime \\prime}(x)\\right|$. Just as in the numerical case, there is nothing to prove if $M_2=0$ or $M_0=+\\infty$ or $M_2=+\\infty$, and so we assume $0a$, and let $\\mathbf{u}=\\frac{1}{\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|} \\mathbf{f}^{\\prime}\\left(x_0\\right)$. Consider the real-valued function $\\varphi(x)=\\mathrm{u} \\cdot \\mathrm{f}(x)$. Let $N_0, N_1$, and $N_2$ be the suprema of $|\\varphi(x)|,\\left|\\varphi^{\\prime}(x)\\right|$, and $\\left|\\varphi^{\\prime \\prime}(x)\\right|$ respectively. By the Schwarz inequality we have (since $|\\mathbf{u}|=1) N_0 \\leq M_0$ and $N_2 \\leq M_2$, while $N_1 \\geq \\varphi\\left(x_0\\right)=\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|>a$. We therefore have $a^2<4 N_0 N_2 \\leq 4 M_0 M_2$. Since $a$ was any positive number less than $M_1$, we have $M_1^2 \\leq 4 M_0 M_2$, i.e., the result holds also for vector-valued functions.\n\nEquality can hold on any $R^n$, as we see by taking $\\mathbf{f}(x)=(f(x), 0, \\ldots, 0)$ or $\\mathbf{f}(x)=(f(x), f(x), \\ldots, f(x))$, where $f(x)$ is a real-valued function for which equality holds.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Rudin_exercise_5_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_17\n {f : ℝ → ℝ}\n (hf' : DifferentiableOn ℝ f (Set.Icc (-1) 1))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Icc 1 1))\n (hf''' : DifferentiableOn ℝ (deriv (deriv f)) (Set.Icc 1 1))\n (hf0 : f (-1) = 0)\n (hf1 : f 0 = 0)\n (hf2 : f 1 = 1)\n (hf3 : deriv f 0 = 0) :\n ∃ x, x ∈ Set.Ioo (-1 : ℝ) 1 ∧ deriv (deriv (deriv f)) x ≥ 3 := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real, three times differentiable function on $[-1,1]$, such that $f(-1)=0, \\quad f(0)=0, \\quad f(1)=1, \\quad f^{\\prime}(0)=0 .$ Prove that $f^{(3)}(x) \\geq 3$ for some $x \\in(-1,1)$.\n\\begin{proof}\n Following the hint, we observe that Theorem $5.15$ (Taylor's formula with remainder) implies that\n$$\n\\begin{aligned}\nf(1) &=f(0)+f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)+\\frac{1}{6} f^{(3)}(s) \\\\\nf(-1) &=f(0)-f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)-\\frac{1}{6} f^{(3)}(t)\n\\end{aligned}\n$$\nfor some $s \\in(0,1), t \\in(-1,0)$. By subtracting the second equation from the first and using the given values of $f(1), f(-1)$, and $f^{\\prime}(0)$, we obtain\n$$\n1=\\frac{1}{6}\\left(f^{(3)}(s)+f^{(3)}(t)\\right),\n$$\nwhich is the desired result. Note that we made no use of the hypothesis $f(0)=0$.\n\\end{proof}\n\n\n\n\\end{document}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} -{"name": "Putnam_exercise_2020_b5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2020_b5 (z : Fin 4 → ℂ) (hz0 : ∀ n, ‖z n‖ < 1)\n (hz1 : ∀ n : Fin 4, z n ≠ 1) :\n 3 - z 0 - z 1 - z 2 - z 3 + (z 0) * (z 1) * (z 2) * (z 3) ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "For $j \\in\\{1,2,3,4\\}$, let $z_{j}$ be a complex number with $\\left|z_{j}\\right|=1$ and $z_{j} \\neq 1$. Prove that $3-z_{1}-z_{2}-z_{3}-z_{4}+z_{1} z_{2} z_{3} z_{4} \\neq 0 .$\n\\begin{proof}\n It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1.\n\nTo this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \n\\[\nf(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2.\n\\]\n A routine calculation shows that \n\\begin{align*}\nf(\\alpha, \\beta, \\gamma)&=\n10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\\n&\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\\n&\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha).\n\\end{align*}\nSince the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \n\\begin{align*}\n\\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &=\n6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\\n&=\n24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right)\n\\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right).\n\\end{align*}\nHence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \n\\[\nf = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2;\n\\]\nsince $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$. \n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2018_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_a5 (f : ℝ → ℝ) (hf : ContDiff ℝ ⊤ f)\n (hf0 : f 0 = 0) (hf1 : f 1 = 1) (hf2 : ∀ x, f x ≥ 0) :\n ∃ (n : ℕ) (x : ℝ), iteratedDeriv n f x = 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f: \\mathbb{R} \\rightarrow \\mathbb{R}$ be an infinitely differentiable function satisfying $f(0)=0, f(1)=1$, and $f(x) \\geq 0$ for all $x \\in$ $\\mathbb{R}$. Show that there exist a positive integer $n$ and a real number $x$ such that $f^{(n)}(x)<0$.\n\\begin{proof}\n Call a function $f\\colon \\mathbb{R} \\to \\mathbb{R}$ \\textit{ultraconvex} if $f$ is infinitely differentiable and $f^{(n)}(x) \\geq 0$ for all $n \\geq 0$ and all $x \\in \\mathbb{R}$, where $f^{(0)}(x) = f(x)$;\nnote that if $f$ is ultraconvex, then so is $f'$.\nDefine the set\n\\[\nS = \\{ f :\\thinspace \\mathbb{R} \\to \\mathbb{R} \\,|\\,f \\text{ ultraconvex and } f(0)=0\\}.\n\\]\nFor $f \\in S$, we must have $f(x) = 0$ for all $x < 0$: if $f(x_0) > 0$ for some $x_0 < 0$, then\nby the mean value theorem there exists $x \\in (0,x_0)$ for which $f'(x) = \\frac{f(x_0)}{x_0} < 0$.\nIn particular, $f'(0) = 0$, so $f' \\in S$ also.\n\nWe show by induction that for all $n \\geq 0$,\n\\[\nf(x) \\leq \\frac{f^{(n)}(1)}{n!} x^n \\qquad (f \\in S, x \\in [0,1]).\n\\]\nWe induct with base case $n=0$, which holds because any $f \\in S$ is nondecreasing. Given the claim for $n=m$,\nwe apply the induction hypothesis to $f' \\in S$ to see that\n\\[\nf'(t) \\leq \\frac{f^{(n+1)}(1)}{n!} t^n \\qquad (t \\in [0,1]),\n\\]\nthen integrate both sides from $0$ to $x$ to conclude.\n\nNow for $f \\in S$, we have $0 \\leq f(1) \\leq \\frac{f^{(n)}(1)}{n!}$ for all $n \\geq 0$. \nOn the other hand, by Taylor's theorem with remainder,\n\\[\nf(x) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}(x-1)^k \\qquad (x \\geq 1).\n\\]\nApplying this with $x=2$, we obtain $f(2) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}$ for all $n$;\nthis implies that $\\lim_{n\\to\\infty} \\frac{f^{(n)}(1)}{n!} = 0$.\nSince $f(1) \\leq \\frac{f^{(n)}(1)}{n!}$, we must have $f(1) = 0$.\n\nFor $f \\in S$, we proved earlier that $f(x) = 0$ for all $x\\leq 0$, as well as for $x=1$. Since\nthe function $g(x) = f(cx)$ is also ultraconvex for $c>0$, we also have $f(x) = 0$ for all $x>0$;\nhence $f$ is identically zero.\n\nTo sum up, if $f\\colon \\mathbb{R} \\to \\mathbb{R}$ is infinitely differentiable, $f(0)=0$, and $f(1) = 1$,\nthen $f$ cannot be ultraconvex. This implies the desired result.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2018_b2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b2 (n : ℕ) (hn : n > 0) (f : ℕ → ℂ → ℂ)\n (hf : ∀ n : ℕ, f n = λ (z : ℂ) => (∑ i : Fin n, (n-i)* z^(i : ℕ))) :\n ¬ (∃ z : ℂ, ‖z‖ ≤ 1 ∧ f n z = 0) := sorry", "formal_proof": null, "informal_stmt": "Let $n$ be a positive integer, and let $f_{n}(z)=n+(n-1) z+$ $(n-2) z^{2}+\\cdots+z^{n-1}$. Prove that $f_{n}$ has no roots in the closed unit disk $\\{z \\in \\mathbb{C}:|z| \\leq 1\\}$.\n\\begin{proof}\n Note first that $f_n(1) > 0$, so $1$ is not a root of $f_n$.\nNext, note that\n\\[\n(z-1)f_n(z) = z^n + \\cdots + z - n;\n\\]\nhowever, for $\\left| z \\right| \\leq 1$, we have \n$\\left| z^n + \\cdots + z \\right| \\leq n$ by the triangle inequality;\nequality can only occur if $z,\\dots,z^n$ have norm 1 and the same argument, which only happens for $z=1$.\nThus there can be no root of $f_n$ with $|z| \\leq 1$.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2018_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b4 (a : ℝ) (x : ℕ → ℝ) (hx0 : x 0 = a)\n (hx1 : x 1 = a)\n (hxn : ∀ n : ℕ, n ≥ 2 → x (n+1) = 2*(x n)*(x (n-1)) - x (n-2))\n (h : ∃ n, x n = 0) :\n ∃ c, Function.Periodic x c := sorry", "formal_proof": null, "informal_stmt": "Given a real number $a$, we define a sequence by $x_{0}=1$, $x_{1}=x_{2}=a$, and $x_{n+1}=2 x_{n} x_{n-1}-x_{n-2}$ for $n \\geq 2$. Prove that if $x_{n}=0$ for some $n$, then the sequence is periodic.\n\\begin{proof}\n We first rule out the case $|a|>1$. In this case, we prove that $|x_{n+1}| \\geq |x_n|$ for all $n$, meaning that we cannot have $x_n = 0$. We proceed by induction; the claim is true for $n=0,1$ by hypothesis. To prove the claim for $n \\geq 2$, write\n\\begin{align*}\n|x_{n+1}| &= |2x_nx_{n-1}-x_{n-2}| \\\\\n&\\geq 2|x_n||x_{n-1}|-|x_{n-2}| \\\\\n&\\geq |x_n|(2|x_{n-1}|-1) \\geq |x_n|,\n\\end{align*} \nwhere the last step follows from $|x_{n-1}| \\geq |x_{n-2}| \\geq \\cdots \\geq |x_0| = 1$.\n\nWe may thus assume hereafter that $|a|\\leq 1$. We can then write $a = \\cos b$ for some $b \\in [0,\\pi]$. \nLet $\\{F_n\\}$ be the Fibonacci sequence, defined as usual by $F_1=F_2=1$ and $F_{n+1}=F_n+F_{n-1}$. We show by induction that\n\\[\nx_n = \\cos(F_n b) \\qquad (n \\geq 0).\n\\]\nIndeed, this is true for $n=0,1,2$; given that it is true for $n \\leq m$, then\n\\begin{align*}\n2x_mx_{m-1}&=2\\cos(F_mb)\\cos(F_{m-1}b) \\\\\n&= \\cos((F_m-F_{m-1})b)+\\cos((F_m+F_{m-1})b) \\\\\n&= \\cos(F_{m-2}b)+\\cos(F_{m+1}b)\n\\end{align*}\nand so \n$x_{m+1} = 2x_mx_{m-1}-x_{m-2} = \\cos(F_{m+1}b)$. This completes the induction.\n\n\nSince $x_n = \\cos(F_n b)$, if $x_n=0$ for some $n$ then $F_n b = \\frac{k}{2} \\pi$ for some odd integer $k$. In particular, we can write $b = \\frac{c}{d}(2\\pi)$ where $c = k$ and $d = 4F_n$ are integers.\n\n\nLet $x_n$ denote the pair $(F_n,F_{n+1})$, where each entry in this pair is viewed as an element of $\\mathbb{Z}/d\\mathbb{Z}$. Since there are only finitely many possibilities for $x_n$, there must be some $n_2>n_1$ such that $x_{n_1}=x_{n_2}$. Now $x_n$ uniquely determines both $x_{n+1}$ and $x_{n-1}$, and it follows that the sequence $\\{x_n\\}$ is periodic: for $\\ell = n_2-n_1$, $x_{n+\\ell} = x_n$ for all $n \\geq 0$. In particular, $F_{n+\\ell} \\equiv F_n \\pmod{d}$ for all $n$. But then $\\frac{F_{n+\\ell}c}{d}-\\frac{F_n c}{d}$ is an integer, and so\n\\begin{align*}\nx_{n+\\ell} &= \\cos\\left(\\frac{F_{n+\\ell}c}{d}(2\\pi)\\right)\\\\\n& = \\cos\\left(\\frac{F_n c}{d}(2\\pi)\\right) = x_n\n\\end{align*}\nfor all $n$. Thus the sequence $\\{x_n\\}$ is periodic, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2017_b3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2017_b3 (f : ℝ → ℝ) (c : ℕ → ℝ)\n (hf : f = λ x => (∑' (i : ℕ), (c i) * x^i))\n (hc : ∀ n, c n = 0 ∨ c n = 1)\n (hf1 : f (2/3) = 3/2) :\n Irrational (f (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f(x)=\\sum_{i=0}^{\\infty} c_{i} x^{i}$ is a power series for which each coefficient $c_{i}$ is 0 or 1 . Show that if $f(2 / 3)=3 / 2$, then $f(1 / 2)$ must be irrational.\n\\begin{proof}\n Suppose by way of contradiction that $f(1/2)$ is rational. Then $\\sum_{i=0}^{\\infty} c_i 2^{-i}$ is the binary expansion of a rational number, and hence must be eventually periodic; that is, there exist some integers $m,n$ such that\n$c_i = c_{m+i}$ for all $i \\geq n$. We may then write\n\\[\nf(x) = \\sum_{i=0}^{n-1} c_i x^i + \\frac{x^n}{1-x^m} \\sum_{i=0}^{m-1} c_{n+i} x^i.\n\\]\nEvaluating at $x = 2/3$, we may equate $f(2/3) = 3/2$ with \n\\[\n\\frac{1}{3^{n-1}} \\sum_{i=0}^{n-1} c_i 2^i 3^{n-i-1} + \\frac{2^n 3^m}{3^{n+m-1}(3^m-2^m)} \\sum_{i=0}^{m-1} c_{n+i} 2^i 3^{m-1-i};\n\\]\nsince all terms on the right-hand side have odd denominator, the same must be true of the sum, a contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2014_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2014_a5 (P : ℕ → Polynomial ℤ)\n (hP : ∀ n, P n = ∑ i : Fin n, (n+1) * Polynomial.X ^ n) :\n ∀ (j k : ℕ), j ≠ k → IsCoprime (P j) (P k) := sorry", "formal_proof": null, "informal_stmt": "Let\n$P_n(x)=1+2 x+3 x^2+\\cdots+n x^{n-1} .$ Prove that the polynomials $P_j(x)$ and $P_k(x)$ are relatively prime for all positive integers $j$ and $k$ with $j \\neq k$.\n\\begin{proof}\n Suppose to the contrary that there exist positive integers $i \\neq j$ and a complex number $z$ such that $P_i(z) = P_j(z) = 0$. Note that $z$ cannot be a nonnegative real number or else $P_i(z), P_j(z) > 0$; we may put $w = z^{-1} \\neq 0,1$. For $n \\in \\{i+1,j+1\\}$ we compute that\n\\[\nw^n = n w - n + 1,\n\\qquad \\overline{w}^n = n \\overline{w} - n + 1;\n\\]\nnote crucially that these equations also hold for $n \\in \\{0,1\\}$.\nTherefore, the function $f: [0, +\\infty) \\to \\mathbb{R}$ given by\n\\[\nf(t) = \\left| w \\right|^{2t} - t^2 \\left| w \\right|^2 + 2t(t-1)\\mathrm{Re}(w) - (t-1)^2\n\\]\nsatisfies $f(t) = 0$ for $t \\in \\{0,1,i+1,j+1\\}$. On the other hand, for all $t \\geq 0$ we have\n\\[\nf'''(t) = (2 \\log \\left| w \\right|)^3 \\left| w \\right|^{2t} > 0,\n\\]\nso by Rolle's theorem, the equation $f^{(3-k)}(t) = 0$ has at most $k$ distinct solutions for $k=0,1,2,3$. This yields the desired contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2010_a4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2010_a4 (n : ℕ) :\n ¬ Nat.Prime (10^10^10^n + 10^10^n + 10^n - 1) := sorry", "formal_proof": null, "informal_stmt": "Prove that for each positive integer $n$, the number $10^{10^{10^n}}+10^{10^n}+10^n-1$ is not prime.\n\\begin{proof}\n Put\n\\[\nN = 10^{10^{10^n}} + 10^{10^n} + 10^n - 1.\n\\]\nWrite $n = 2^m k$ with $m$ a nonnegative integer and $k$ a positive odd integer.\nFor any nonnegative integer $j$,\n\\[\n10^{2^m j} \\equiv (-1)^j \\pmod{10^{2^m} + 1}.\n\\]\nSince $10^n \\geq n \\geq 2^m \\geq m+1$, $10^n$ is divisible by $2^n$ and hence by $2^{m+1}$,\nand similarly $10^{10^n}$ is divisible by $2^{10^n}$ and hence by $2^{m+1}$. It follows that\n\\[\nN \\equiv 1 + 1 + (-1) + (-1) \\equiv 0 \\pmod{10^{2^m} + 1}.\n\\]\nSince $N \\geq 10^{10^n} > 10^n + 1 \\geq 10^{2^m} + 1$, it follows that $N$ is composite.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2001_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2001_a5 :\n ∃! a : ℕ × ℕ, a.1 > 0 ∧ a.2 > 0 ∧ a.1^(a.2+1) - (a.1+1)^a.2 = 2001 := sorry", "formal_proof": null, "informal_stmt": "Prove that there are unique positive integers $a, n$ such that $a^{n+1}-(a+1)^n=2001$.\n\\begin{proof}\n Suppose $a^{n+1} - (a+1)^n = 2001$.\nNotice that $a^{n+1} + [(a+1)^n - 1]$ is a multiple of $a$; thus\n$a$ divides $2002 = 2 \\times 7 \\times 11 \\times 13$.\n\nSince $2001$ is divisible by 3, we must have $a \\equiv 1 \\pmod{3}$,\notherwise one of $a^{n+1}$ and $(a+1)^n$ is a multiple of 3 and the\nother is not, so their difference cannot be divisible by 3. Now\n$a^{n+1} \\equiv 1 \\pmod{3}$, so we must have $(a+1)^n \\equiv 1\n\\pmod{3}$, which forces $n$ to be even, and in particular at least 2.\n\nIf $a$ is even, then $a^{n+1} - (a+1)^n \\equiv -(a+1)^n \\pmod{4}$.\nSince $n$ is even, $-(a+1)^n \\equiv -1 \\pmod{4}$. Since $2001 \\equiv 1\n\\pmod{4}$, this is impossible. Thus $a$ is odd, and so must divide\n$1001 = 7 \\times 11 \\times 13$. Moreover, $a^{n+1} - (a+1)^n \\equiv a\n\\pmod{4}$, so $a \\equiv 1 \\pmod{4}$.\n\nOf the divisors of $7 \\times 11 \\times 13$, those congruent to 1 mod 3\nare precisely those not divisible by 11 (since 7 and 13 are both\ncongruent to 1 mod 3). Thus $a$ divides $7 \\times 13$. Now\n$a \\equiv 1 \\pmod{4}$ is only possible if $a$ divides $13$.\n\nWe cannot have $a=1$, since $1 - 2^n \\neq 2001$ for any $n$. Thus\nthe only possibility is $a = 13$. One easily checks that $a=13, n=2$ is a\nsolution; all that remains is to check that no other $n$ works. In fact,\nif $n > 2$, then $13^{n+1} \\equiv 2001 \\equiv 1 \\pmod{8}$.\nBut $13^{n+1} \\equiv 13 \\pmod{8}$ since $n$ is even, contradiction.\nThus $a=13, n=2$ is the unique solution.\n\nNote: once one has that $n$ is even, one can use that $2002\n=a^{n+1} + 1 - (a+1)^n$ is divisible by $a+1$ to rule out cases.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_2000_a2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2000_a2 :\n ∀ N : ℕ, ∃ n : ℕ, n > N ∧ ∃ i : Fin 6 → ℕ, n = (i 0)^2 + (i 1)^2 ∧\n n + 1 = (i 2)^2 + (i 3)^2 ∧ n + 2 = (i 4)^2 + (i 5)^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that there exist infinitely many integers $n$ such that $n, n+1, n+2$ are each the sum of the squares of two integers. \n\\begin{proof}\n It is well-known that the equation $x^2-2y^2=1$ has infinitely\nmany solutions (the so-called ``Pell'' equation). Thus setting\n$n=2y^2$ (so that $n=y^2+y^2$, $n+1=x^2+0^2$, $n+2=x^2+1^2$)\nyields infinitely many $n$ with the desired property.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_1999_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1999_b4 (f : ℝ → ℝ) (hf: ContDiff ℝ 3 f)\n (hf1 : ∀ n ≤ 3, ∀ x : ℝ, iteratedDeriv n f x > 0)\n (hf2 : ∀ x : ℝ, iteratedDeriv 3 f x ≤ f x) :\n ∀ x : ℝ, deriv f x < 2 * f x := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function with a continuous third derivative such that $f(x), f^{\\prime}(x), f^{\\prime \\prime}(x), f^{\\prime \\prime \\prime}(x)$ are positive for all $x$. Suppose that $f^{\\prime \\prime \\prime}(x) \\leq f(x)$ for all $x$. Show that $f^{\\prime}(x)<2 f(x)$ for all $x$.\n\\begin{proof} \n\\setcounter{equation}{0}\nWe make repeated use of the following fact: if $f$ is a differentiable function on all of\n$\\mathbb{R}$, $\\lim_{x \\to -\\infty} f(x) \\geq 0$, and $f'(x) > 0$ for all $x \\in \\mathbb{R}$, then\n$f(x) > 0$ for all $x \\in \\mathbb{R}$. (Proof: if $f(y) < 0$ for some $x$, then $f(x)< f(y)$ for all\n$x0$, but then $\\lim_{x \\to -\\infty} f(x) \\leq f(y) < 0$.)\n\nFrom the inequality $f'''(x) \\leq f(x)$ we obtain\n\\[\nf'' f'''(x) \\leq f''(x) f(x) < f''(x) f(x) + f'(x)^2\n\\]\nsince $f'(x)$ is positive. Applying the fact to the difference between the right and left sides,\nwe get\n\\begin{equation}\n\\frac{1}{2} (f''(x))^2 < f(x) f'(x).\n\\end{equation}\n\nOn the other hand, since $f(x)$ and $f'''(x)$ are both positive for all $x$,\nwe have\n\\[\n2f'(x) f''(x) < 2f'(x)f''(x) + 2f(x) f'''(x).\n\\]\nApplying the fact to the difference between the sides yields\n\\begin{equation}\nf'(x)^2 \\leq 2f(x) f''(x).\n\\end{equation}\nCombining (1) and (2), we obtain\n\\begin{align*}\n\\frac{1}{2} \\left( \\frac{f'(x)^2}{2f(x)} \\right)^2\n&< \\frac{1}{2} (f''(x))^2 \\\\\n&< f(x) f'(x),\n\\end{align*}\nor $(f'(x))^3 < 8 f(x)^3$. We conclude $f'(x) < 2f(x)$, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_1998_a3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_a3 (f : ℝ → ℝ) (hf : ContDiff ℝ 3 f) :\n ∃ a : ℝ, (f a) * (deriv f a) * (iteratedDeriv 2 f a) * (iteratedDeriv 3 f a) ≥ 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function on the real line with continuous third derivative. Prove that there exists a point $a$ such that\n$f(a) \\cdot f^{\\prime}(a) \\cdot f^{\\prime \\prime}(a) \\cdot f^{\\prime \\prime \\prime}(a) \\geq 0$. \n\\begin{proof}\n If at least one of $f(a)$, $f'(a)$, $f''(a)$, or $f'''(a)$ vanishes\nat some point $a$, then we are done. Hence we may assume each of\n$f(x)$, $f'(x)$, $f''(x)$, and $f'''(x)$ is either strictly positive\nor strictly negative on the real line. By replacing $f(x)$ by $-f(x)$\nif necessary, we may assume $f''(x)>0$; by replacing $f(x)$\nby $f(-x)$ if necessary, we may assume $f'''(x)>0$. (Notice that these\nsubstitutions do not change the sign of $f(x) f'(x) f''(x) f'''(x)$.)\nNow $f''(x)>0$ implies that $f'(x)$ is increasing, and $f'''(x)>0$\nimplies that $f'(x)$ is convex, so that $f'(x+a)>f'(x)+a f''(x)$\nfor all $x$ and $a$. By\nletting $a$ increase in the latter inequality, we see that $f'(x+a)$\nmust be positive for sufficiently large $a$; it follows that\n$f'(x)>0$\nfor all $x$. Similarly, $f'(x)>0$ and $f''(x)>0$ imply\nthat $f(x)>0$ for all $x$. Therefore $f(x) f'(x) f''(x) f'''(x)>0$ for\nall $x$, and we are done.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Putnam_exercise_1998_b6", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_b6 (a b c : ℤ) :\n ∃ n : ℤ, n > 0 ∧ ¬ ∃ m : ℤ, Real.sqrt (n^3 + a*n^2 + b*n + c) = m := sorry", "formal_proof": null, "informal_stmt": "Prove that, for any integers $a, b, c$, there exists a positive integer $n$ such that $\\sqrt{n^3+a n^2+b n+c}$ is not an integer.\n\\begin{proof}\n We prove more generally that for any polynomial $P(z)$ with integer\ncoefficients which is not a perfect square, there exists a positive\ninteger $n$ such that $P(n)$ is not a perfect square. Of course it\nsuffices to assume $P(z)$ has no repeated factors, which is to say $P(z)$\nand its derivative $P'(z)$ are relatively prime.\n\nIn particular, if we carry out the Euclidean algorithm on $P(z)$ and $P'(z)$\nwithout dividing, we get an integer $D$ (the discriminant of $P$) such that\nthe greatest common divisor of $P(n)$ and $P'(n)$ divides $D$ for any $n$.\nNow there exist infinitely many primes $p$ such that $p$ divides $P(n)$ for\nsome $n$: if there were only finitely many, say, $p_1, \\dots, p_k$, then\nfor any $n$ divisible by $m = P(0) p_1 p_2 \\cdots p_k$, we have $P(n)\n\\equiv P(0) \\pmod{m}$, that is, $P(n)/P(0)$ is not divisible by $p_1,\n\\dots, p_k$, so must be $\\pm 1$, but then $P$ takes some value infinitely\nmany times, contradiction. In particular, we can choose some such $p$ not\ndividing $D$, and choose $n$ such that $p$ divides $P(n)$. Then $P(n+kp)\n\\equiv P(n) + kp P'(n) (\\mathrm{mod}\\,p)$\n(write out the Taylor series of the left side);\nin particular, since $p$ does not divide $P'(n)$, we can find some $k$\nsuch that $P(n+kp)$ is divisible by $p$ but not by $p^2$, and so\nis not a perfect square.\n\\end{proof}\n\n\n\n\n\\end{document}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} -{"name": "Artin_exercise_2_2_9", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_2_9 {G : Type*} [Group G] {a b : G}\n (h : a * b = b * a) :\n ∀ x y : closure {x | x = a ∨ x = b}, x*y = y*x := sorry", "formal_proof": null, "informal_stmt": "Let $H$ be the subgroup generated by two elements $a, b$ of a group $G$. Prove that if $a b=b a$, then $H$ is an abelian group.\n\\begin{proof}\n Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_2_3_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_3_2 {G : Type*} [Group G] (a b : G) :\n ∃ g : G, b* a = g * a * b * g⁻¹ := sorry", "formal_proof": null, "informal_stmt": "Prove that the products $a b$ and $b a$ are conjugate elements in a group.\n\\begin{proof}\n We have that $(a^{-1})ab(a^{-1})^{-1} = ba$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_2_4_19", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_4_19 {G : Type*} [Group G] {x : G}\n (hx : orderOf x = 2) (hx1 : ∀ y, orderOf y = 2 → y = x) :\n x ∈ center G := sorry", "formal_proof": null, "informal_stmt": "Prove that if a group contains exactly one element of order 2 , then that element is in the center of the group.\n\\begin{proof}\n Let $x$ be the element of order two. Consider the element $z=y^{-1} x y$, we have: $z^2=\\left(y^{-1} x y\\right)^2=\\left(y^{-1} x y\\right)\\left(y^{-1} x y\\right)=e$. So: $z=x$, and $y^{-1} x y=x$. So: $x y=y x$. So: $x$ is in the center of $G$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_2_8_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "instance Artin_exercise_2_8_6 {G H : Type*} [Group G] [Group H] :\n center (G × H) ≃* (center G) × (center H) := sorry", "formal_proof": null, "informal_stmt": "Prove that the center of the product of two groups is the product of their centers.\n\\begin{proof}\n We have that $(g_1, g_2)\\cdot (h_1, h_2) = (h_1, h_2)\\cdot (g_1, g_2)$ if and only if $g_1h_1 = h_1g_1$ and $g_2h_2 = h_2g_2$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_2_11_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_2_11_3 {G : Type*} [Group G] [Fintype G]\n (hG : Even (card G)) : ∃ x : G, orderOf x = 2 := sorry", "formal_proof": null, "informal_stmt": "Prove that a group of even order contains an element of order $2 .$\n\\begin{proof}\n Pair up if possible each element of $G$ with its inverse, and observe that\n$$\ng^2 \\neq e \\Longleftrightarrow g \\neq g^{-1} \\Longleftrightarrow \\text { there exists the pair }\\left(g, g^{-1}\\right)\n$$\nNow, there is one element that has no pairing: the unit $e$ (since indeed $e=e^{-1} \\Longleftrightarrow e^2=e$ ), so since the number of elements of $G$ is even there must be at least one element more, say $e \\neq a \\in G$, without a pairing, and thus $a=a^{-1} \\Longleftrightarrow a^2=e$\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_3_2_7", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_2_7 {F : Type*} [Field F] {G : Type*} [Field G]\n (φ : F →+* G) : Injective φ := sorry", "formal_proof": null, "informal_stmt": "Prove that every homomorphism of fields is injective.\n\\begin{proof}\n Suppose $f(a)=f(b)$, then $f(a-b)=0=f(0)$. If $u=(a-b) \\neq 0$, then $f(u) f\\left(u^{-1}\\right)=f(1)=1$, but that means that $0 f\\left(u^{-1}\\right)=1$, which is impossible. Hence $a-b=0$ and $a=b$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_3_5_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_5_6 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {S : Set V} (hS : Set.Countable S)\n (hS1 : span K S = ⊤) {ι : Type*} (R : ι → V)\n (hR : LinearIndependent K R) : Countable ι := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space which is spanned by a countably infinite set. Prove that every linearly independent subset of $V$ is finite or countably infinite.\n\\begin{proof}\n Let $A$ be the countable generating set, and let $U$ be an uncountable linearly independent set. It can be extended to a basis $B$ of the whole space. Now consider the subset $C$ of elements of $B$ that appear in the $B$-decompositions of elements of $A$.\nSince only finitely many elements are involved in the decomposition of each element of $A$, the set $C$ is countable. But $C$ also clearly generates the vector space $V$. This contradicts the fact that it is a proper subset of the basis $B$ (since $B$ is uncountable).\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_3_7_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_3_7_2 {K V : Type*} [Field K] [AddCommGroup V]\n [Module K V] {ι : Type*} [Fintype ι] (γ : ι → Submodule K V)\n (h : ∀ i : ι, γ i ≠ ⊤) :\n (⋂ (i : ι), (γ i : Set V)) ≠ ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $V$ be a vector space over an infinite field $F$. Prove that $V$ is not the union of finitely many proper subspaces.\n\\begin{proof}\n If $V$ is the set-theoretic union of $n$ proper subspaces $W_i$ ( $1 \\leq i \\leq n$ ), then $|F| \\leq n-1$.\nProof. We may suppose no $W_i$ is contained in the union of the other subspaces. Let $u \\in W_i, \\quad u \\notin \\bigcup_{j \\neq i} W_j$ and $v \\notin W_i$.\nThen $(v+F u) \\cap W_i=\\varnothing$ and $(v+F u) \\cap W_j(j \\neq i)$ contains at most one vector since otherwise $W_j$ would contain $u$. Hence\n$$\n|v+F u|=|F| \\leq n-1 .\n$$\nCorollary: Avoidance lemma for vector spaces.\nLet $E$ be a vector space over an infinite field. If a subspace is contained in a finite union of subspaces, it is contained in one of them.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_6_1_14", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_1_14 (G : Type*) [Group G]\n (hG : IsCyclic $ G ⧸ (center G)) :\n center G = ⊤ := sorry", "formal_proof": null, "informal_stmt": "Let $Z$ be the center of a group $G$. Prove that if $G / Z$ is a cyclic group, then $G$ is abelian and hence $G=Z$.\n\\begin{proof}\n We have that $G / Z(G)$ is cyclic, and so there is an element $x \\in G$ such that $G / Z(G)=\\langle x Z(G)\\rangle$, where $x Z(G)$ is the coset with representative $x$. Now let $g \\in G$\nWe know that $g Z(G)=(x Z(G))^m$ for some $m$, and by definition $(x Z(G))^m=x^m Z(G)$.\nNow, in general, if $H \\leq G$, we have by definition too that $a H=b H$ if and only if $b^{-1} a \\in H$.\nIn our case, we have that $g Z(G)=x^m Z(G)$, and this happens if and only if $\\left(x^m\\right)^{-1} g \\in Z(G)$.\nThen, there's a $z \\in Z(G)$ such that $\\left(x^m\\right)^{-1} g=z$, and so $g=x^m z$.\n\n$g, h \\in G$ implies that $g=x^{a_1} z_1$ and $h=x^{a_2} z_2$, so\n$$\n\\begin{aligned}\ng h & =\\left(x^{a_1} z_1\\right)\\left(x^{a_2} z_2\\right) \\\\\n& =x^{a_1} x^{a_2} z_1 z_2 \\\\\n& =x^{a_1+a_2} z_2 z_1 \\\\\n& =\\ldots=\\left(x^{a_2} z_2\\right)\\left(x^{a_1} z_1\\right)=h g .\n\\end{aligned}\n$$\nTherefore, $G$ is abelian.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_6_4_2", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_2 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p*q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n If $|G|=n=p q$ then the only two Sylow subgroups are of order $p$ and $q$.\nFrom Sylow's third theorem we know that $n_p \\mid q$ which means that $n_p=1$ or $n_p=q$.\nIf $n_p=1$ then we are done (by a corollary of Sylow's theorem)\nIf $n_p=q$ then we have accounted for $q(p-1)=p q-q$ elements of $G$ and so there is only one group of order $q$ and again we are done.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_6_4_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_6_4_3 {G : Type*} [Group G] [Fintype G] {p q : ℕ}\n (hp : Prime p) (hq : Prime q) (hG : card G = p^2 *q) :\n IsSimpleGroup G → false := sorry", "formal_proof": null, "informal_stmt": "Prove that no group of order $p^2 q$, where $p$ and $q$ are prime, is simple.\n\\begin{proof}\n We may as well assume $p0$ and $b^2>0$, so $-a^2-b^2<0$. Furthermore, it is an integer. Thus, we have found a nonzero integer in $I$.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_10_4_6", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_4_6 {R : Type*} [CommRing R]\n [NoZeroDivisors R] (I J : Ideal R) (x : ↑(I ⊓ J)) :\n IsNilpotent ((Ideal.Quotient.mk (I*J)) x) := sorry", "formal_proof": null, "informal_stmt": "Let $I, J$ be ideals in a ring $R$. Prove that the residue of any element of $I \\cap J$ in $R / I J$ is nilpotent.\n\\begin{proof}\n If $x$ is in $I \\cap J, x \\in I$ and $x \\in J . R / I J=\\{r+a b: a \\in I, b \\in J, r \\in R\\}$. Then $x \\in I \\cap J \\Rightarrow x \\in I$ and $x \\in J$, and so $x^2 \\in I J$. Thus\n$$\n[x]^2=\\left[x^2\\right]=[0] \\text { in } R / I J\n$$\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_10_4_7a", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_4_7a {R : Type*} [CommRing R] [NoZeroDivisors R]\n (I J : Ideal R) (hIJ : I + J = ⊤) : I * J = I ⊓ J := sorry", "formal_proof": null, "informal_stmt": "Let $I, J$ be ideals of a ring $R$ such that $I+J=R$. Prove that $I J=I \\cap J$.\n\\begin{proof}\n We have seen that $IJ \\subset I \\cap J$, so it remains to show that $I \\cap J \\subset IJ$. Since $I+J = (1)$, there are elements $i \\in I$ and $j \\in J$ such that $i+j = 1$. Let $k \\in I \\cap J$, and multiply $i+j=1$ through by $k$ to get $ki+kj = k$. Write this more suggestively as\n\\[ k = ik+kj. \\]\nThe first term is in $IJ$ because $k \\in J$, and the second term is in $IJ$ because $k \\in I$, so $k \\in IJ$ as desired.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_10_7_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_10_7_10 {R : Type*} [Ring R]\n (M : Ideal R) (hM : ∀ (x : R), x ∉ M → IsUnit x)\n (hProper : ∃ x : R, x ∉ M) :\n IsMaximal M ∧ ∀ (N : Ideal R), IsMaximal N → N = M := sorry", "formal_proof": null, "informal_stmt": "Let $R$ be a ring, with $M$ an ideal of $R$. Suppose that every element of $R$ which is not in $M$ is a unit of $R$. Prove that $M$ is a maximal ideal and that moreover it is the only maximal ideal of $R$.\n\\begin{proof}\nSuppose there is an ideal $M\\subset I\\subset R$. If $I\\neq M$, then $I$ contains a unit, thus $I=R$. Therefore $M$ is a maximal ideal. \n\nSuppose we have an arbitrary maximal ideal $M^\\prime$ of $R$. The ideal $M^\\prime$ cannot contain a unit, otherwise $M^\\prime =R$. Therefore $M^\\prime \\subset M$. But we cannot have $M^\\prime \\subsetneq M \\subsetneq R$, therefore $M=M^\\prime$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_2_13", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_2_13 (a b : ℤ) :\n (ofInt a : GaussianInt) ∣ ofInt b → a ∣ b := sorry", "formal_proof": null, "informal_stmt": "If $a, b$ are integers and if $a$ divides $b$ in the ring of Gauss integers, then $a$ divides $b$ in $\\mathbb{Z}$.\n\\begin{proof}\n Suppose $a|b$ in $\\mathbb{Z}[i]$ and $a,b\\in\\mathbb{Z}$. Then $a(x+yi)=b$ for $x,y\\in\\mathbb{Z}$. Expanding this we get $ax+ayi=b$, and equating imaginary parts gives us $ay=0$, implying $y=0$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_4_1b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_1b {F : Type*} [Field F] [Fintype F] (hF : card F = 2) :\n Irreducible (12 + 6 * X + X ^ 3 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 + 6x + 12$ is irreducible in $\\mathbb{Q}$.\n\\begin{proof}\n Apply Eisenstein's criterion with $p=3$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_4_6a", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6a {F : Type*} [Field F] [Fintype F] (hF : card F = 7) :\n Irreducible (X ^ 2 + 1 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+x+1$ is irreducible in the field $\\mathbb{F}_2$.\n\\begin{proof}\n If $x^2+x+1$ were reducible in $\\mathbb{F}_2$, its factors must be linear. But we neither have that $0^2+0+1=$ nor $1^2+1+1=0$, therefore $x^2+x+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_4_6b", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6b {F : Type*} [Field F] [Fintype F] (hF : card F = 31) :\n Irreducible (X ^ 3 - 9 : Polynomial F) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^2+1$ is irreducible in $\\mathbb{F}_7$\n\\begin{proof}\n If $p(x)=x^2+1$ were reducible, its factors must be linear. But no $p(a)$ for $a\\in\\mathbb{F}_7$ evaluates to 0, therefore $x^2+1$ is irreducible. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_4_6c", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_6c : Irreducible (X^3 - 9 : Polynomial (ZMod 31)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $x^3 - 9$ is irreducible in $\\mathbb{F}_{31}$.\n\\begin{proof}\n If $p(x) = x^3-9$ were reducible, it would have a linear factor, since it either has a linear factor and a quadratic factor or three linear factors. We can then verify by brute force that $p(x)\\neq 0$ for $x \\in \\mathbb{F}_31$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_4_8", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_4_8 (p : ℕ) (hp : Prime p) (n : ℕ) :\n -- p ∈ ℕ can be written as p ∈ ℚ[X]\n Irreducible (X ^ n - (p : Polynomial ℚ) : Polynomial ℚ) := sorry", "formal_proof": null, "informal_stmt": "Let $p$ be a prime integer. Prove that the polynomial $x^n-p$ is irreducible in $\\mathbb{Q}[x]$.\n\\begin{proof}\n Straightforward application of Eisenstein's criterion with $p$. \n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_11_13_3", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_11_13_3 (N : ℕ):\n ∃ p ≥ N, Nat.Prime p ∧ p + 1 ≡ 0 [MOD 4] := sorry", "formal_proof": null, "informal_stmt": "Prove that there are infinitely many primes congruent to $-1$ (modulo $4$).\n\\begin{proof}\n First we show a lemma: if $a \\equiv 3(\\bmod 4)$ then there exists a prime $p$ such that $p \\mid a$ and $p \\equiv 3(\\bmod 4)$.\n\n Clearly, all primes dividing $a$ are odd. Suppose all of them would be $\\equiv 1(\\bmod 4)$. Then their product would also be $a \\equiv 1(\\bmod 4)$, which is a contradiction.\n\nTo prove the main claim, suppose that $p_1, \\ldots, p_n$ would be all such primes. (In particular, we have $p_1=3$.) Consider $a=4 p_2 \\cdots p_n+3$. (Or you can take $a=4 p_2 \\cdots p_n-1$.) Show that $p_i \\nmid a$ for $i=1, \\ldots, n$. (The case $3 \\nmid a$ is solved differently than the other primes - this is the reason for omitting $p_1$ in the definition of $a$.) Then use the above lemma to get a contradiction.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_13_4_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_4_10\n {p : ℕ} {hp : Nat.Prime p} (h : ∃ r : ℕ, p = 2 ^ r + 1) :\n ∃ (k : ℕ), p = 2 ^ (2 ^ k) + 1 := sorry", "formal_proof": null, "informal_stmt": "Prove that if a prime integer $p$ has the form $2^r+1$, then it actually has the form $2^{2^k}+1$.\n\\begin{proof}\n In particular, we have\n$$\n\\frac{x^a+1}{x+1}=\\frac{(-x)^a-1}{(-x)-1}=1-x+x^2-\\cdots+(-x)^{a-1}\n$$\nby the geometric sum formula. In this case, specialize to $x=2^{2^m}$ and we have a nontrivial divisor.\n\\end{proof}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} -{"name": "Artin_exercise_13_6_10", "source": "Artin.lean", "header": "import Mathlib\n\nopen Function Fintype Subgroup Ideal Polynomial Submodule Zsqrtd\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Artin_exercise_13_6_10 {K : Type*} [Field K] [Fintype Kˣ] :\n (∏ x : Kˣ, x) = -1 := sorry", "formal_proof": null, "informal_stmt": "Let $K$ be a finite field. Prove that the product of the nonzero elements of $K$ is $-1$.\n\\begin{proof}\n Since we are working with a finite field with $q$ elements, anyone of them is a root of the following polynomial\n$$\nx^q-x=0 .\n$$\nIn particular if we rule out the 0 element, any $a_i \\neq 0$ is a root of\n$$\nx^{q-1}-1=0 .\n$$\nThis polynomial splits completely in $\\mathbb{F}_q$ so we find\n$$\n\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)=0\n$$\nin particular\n$$\nx^{q-1}-1=\\left(x-a_1\\right) \\cdots\\left(x-a_{q-1}\\right)\n$$\nThus $a_1 \\cdots a_{q-1}=-1$.\n\\end{proof}\n\\end{document}", "informal_proof": "Since $a$ and $b$ commute, for any $g, h\\in H$ we can write $g=a^ib^j$ and $h = a^kb^l$. Then $gh = a^ib^ja^kb^l = a^kb^la^ib^j = hg$. Thus $H$ is abelian."} +{"name": "Herstein_exercise_2_1_18", "source": "Herstein.lean", "header": "import Mathlib\n\nopen Fintype Set Real Ideal Polynomial\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Herstein_exercise_2_1_18 {G : Type*} [Group G]\n [Fintype G] (hG2 : Even (card G)) :\n ∃ (a : G), a ≠ 1 ∧ a = a⁻¹ := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a finite group of even order, show that there must be an element $a \\neq e$ such that $a=a^{-1}$.\n\\begin{proof}\n First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$.\nEvery element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $nj$ (just reverse the roles of $i$ and $j$ otherwise). Then multiply both sides by $\\left(a^j\\right)^{-1}=a^{-j}$ to get\n$$\na^i * a^{-j}=a^{i-j}=e\n$$\nThus the $n=i-j$ is a positive integer such that $a^n=e$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 0$ such that $a^m = e$ for all $a \\in G$.\n\\begin{proof}\n Let $n_1, n_2, \\ldots, n_k$ be the orders of all $k$ elements of $G=$ $\\left\\{a_1, a_2, \\ldots, a_k\\right\\}$. Let $m=\\operatorname{lcm}\\left(n_1, n_2, \\ldots, n_k\\right)$. Then, for any $i=$ $1, \\ldots, k$, there exists an integer $c$ such that $m=n_i c$. Thus\n$$\na_i^m=a_i^{n_i c}=\\left(a_i^{n_i}\\right)^c=e^c=e\n$$\nHence $m$ is a positive integer such that $a^m=e$ for all $a \\in G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n ∀ a b : G, (a*b)^i = a^i * b^i}\n (hP1 : ∃ n : ℕ, P n ∧ P (n+1) ∧ P (n+2)) : CommGroup G := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group in which $(a b)^{i}=a^{i} b^{i}$ for three consecutive integers $i$, prove that $G$ is abelian.\n\\begin{proof}\n Let $G$ be a group, $a, b \\in G$ and $i$ be any integer. Then from given condition,\n$$\n\\begin{aligned}\n(a b)^i & =a^i b^i \\\\\n(a b)^{i+1} & =a^{i+1} b^{i+1} \\\\\n(a b)^{i+2} & =a^{i+2} b^{i+2}\n\\end{aligned}\n$$\nFrom first and second, we get\n$$\na^{i+1} b^{i+1}=(a b)^i(a b)=a^i b^i a b \\Longrightarrow b^i a=a b^i\n$$\nFrom first and third, we get\n$$\na^{i+2} b^{i+2}=(a b)^i(a b)^2=a^i b^i a b a b \\Longrightarrow a^2 b^{i+1}=b^i a b a\n$$\nThis gives\n$$\na^2 b^{i+1}=a\\left(a b^i\\right) b=a b^i a b=b^i a^2 b\n$$\nFinally, we get\n$$\nb^i a b a=b^i a^2 b \\Longrightarrow b a=a b\n$$\nThis shows that $G$ is Abelian.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1)\n (h : ∀ (a b : G), (a * b) ^ n = a ^ n * b ^ n) :\n ∀ (a b : G), (a * b * a⁻¹ * b⁻¹) ^ (n * (n - 1)) = 1 := sorry", "formal_proof": null, "informal_stmt": "Let $G$ be a group in which $(a b)^{n}=a^{n} b^{n}$ for some fixed integer $n>1$ for all $a, b \\in G$. For all $a, b \\in G$, prove that $\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e$. \n\\begin{proof}\n We start with the following two intermediate results.\n(1) $(a b)^{n-1}=b^{n-1} a^{n-1}$.\n(2) $a^n b^{n-1}=b^{n-1} a^n$.\nTo prove (1), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen,\n$(b a)^n=b^n a^n \\Longrightarrow b .(a b)(a b) \\ldots .(a b) . a=b\\left(b^{n-1} a^{n-1}\\right) a$, where $(a b)$ occurs $n-1$ times $\\Longrightarrow(a b)^{n-1}=b^{n-1} a^{n-1}$, by cancellation law.\nHence, for all $a, b \\in G$\n$$\n(a b)^{n-1}=b^{n-1} a^{n-1} .\n$$\nTo prove (2), notice by the given condition for all $a, b \\in G$\n$(b a)^n=b^n a^n$, for some fixed integers $n>1$.\nThen we have\n$$\n\\begin{aligned}\n& (b a)^n=b^n a^n \\\\\n\\Longrightarrow & b \\cdot(a b)(a b) \\ldots(a b) \\cdot a=b\\left(b^{n-1} a^{n-1}\\right) a, \\text { where }(a b) \\text { occurs } n-1 \\text { times } \\\\\n\\Longrightarrow & (a b)^{n-1}=b^{n-1} a^{n-1}, \\text { by cancellation law } \\\\\n\\Longrightarrow & (a b)^{n-1}(a b)=\\left(b^{n-1} a^{n-1}\\right)(a b) \\\\\n\\Longrightarrow & (a b)^n=b^{n-1} a^n b \\\\\n\\Longrightarrow & a^n b^n=b^{n-1} a^n b, \\text { given condition } \\\\\n\\Longrightarrow & a^n b^{n-1}=b^{n-1} a^n, \\text { by cancellation law. }\n\\end{aligned}\n$$\nTherefore for all $a, b \\in G$ we have\n$$\na^n b^{n-1}=b^{n-1} a^n\n$$\nIn order to show that\n$$\n\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { for all } a, b \\in G\n$$\nit is enough to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nStep 3\nThis is because of\n$$\n\\begin{aligned}\n(a b)^{n(n-1)}=(b a)^{n(n-1)} & \\left.\\Longrightarrow(b a)^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(a^{-1} b^{-1}\\right)^{n(n-1)}(a b)^{n(n-1)}=e \\\\\n& \\Longrightarrow\\left(\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}\\left((a b)^n\\right)(n-1)=e \\\\\n& \\Longrightarrow\\left((a b)^n\\left(a^{-1} b^{-1}\\right)^n\\right)^{n-1}=e, \\text { by }(1) \\\\\n& \\Longrightarrow\\left(a b a^{-1} b^{-1}\\right)^{n(n-1)}=e, \\text { ( given condition) }\n\\end{aligned}\n$$\nNow, it suffices to show that\n$$\n(a b)^{n(n-1)}=(b a)^{n(n-1)}, \\quad \\forall x, y \\in G .\n$$\nNow, we have\n$$\n\\begin{aligned}\n(a b)^{n(n-1)} & =\\left(a^n b^n\\right)^{n-1}, \\text { by the given condition } \\\\\n& =\\left(a^n b^{n-1} b\\right)^{n-1} \\\\\n& =\\left(b^{n-1} a^n b\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^n b\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =b^{n-1}\\left(a^n\\right)^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(1) \\\\\n& =\\left(b^{n-1}\\left(a^{n-1}\\right)^n\\right)\\left(b^{n-1}\\right)^{n-1} \\\\\n& =\\left(a^{n-1}\\right)^n b^{n-1}\\left(b^{n-1}\\right)^{n-1}, \\text { by }(2) \\\\\n& =\\left(a^{n-1}\\right)^n\\left(b^{n-1}\\right)^n \\\\\n& =\\left(a^{n-1} b^{n-1}\\right)^n, \\text { by }(1) \\\\\n& =(b a)^{n(n-1)}, \\text { by }(1) .\n\\end{aligned}\n$$\nThis completes our proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x⁻¹*g*x) '' (centralizer {a}) := sorry", "formal_proof": null, "informal_stmt": "If $G$ is a group and $a, x \\in G$, prove that $C\\left(x^{-1} a x\\right)=x^{-1} C(a) x$\n\\begin{proof}\n Note that\n$$\nC(a):=\\{x \\in G \\mid x a=a x\\} .\n$$\nLet us assume $p \\in C\\left(x^{-1} a x\\right)$. Then,\n$$\n\\begin{aligned}\n& p\\left(x^{-1} a x\\right)=\\left(x^{-1} a x\\right) p \\\\\n\\Longrightarrow & \\left(p x^{-1} a\\right) x=x^{-1}(a x p) \\\\\n\\Longrightarrow & x\\left(p x^{-1} a\\right)=(a x p) x^{-1} \\\\\n\\Longrightarrow & \\left(x p x^{-1}\\right) a=a\\left(x p x^{-1}\\right) \\\\\n\\Longrightarrow & x p x^{-1} \\in C(a) .\n\\end{aligned}\n$$\nTherefore,\n$$\np \\in C\\left(x^{-1} a x\\right) \\Longrightarrow x p x^{-1} \\in C(a) .\n$$\nThus,\n$$\nC\\left(x^{-1} a x\\right) \\subset x^{-1} C(a) x .\n$$\nLet us assume\n$$\nq \\in x^{-1} C(a) x .\n$$\nThen there exists an element $y$ in $C(a)$ such that\n$$\nq=x^{-1} y x\n$$\nNow,\n$$\ny \\in C(a) \\Longrightarrow y a=a y .\n$$\nAlso,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=x^{-1}(y a) x=x^{-1}(y a) x=\\left(x^{-1} y x\\right)\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q .\n$$\nTherefore,\n$$\nq\\left(x^{-1} a x\\right)=\\left(x^{-1} y x\\right) q\n$$\nSo,\n$$\nq \\in C\\left(x^{-1} a x\\right) .\n$$\nConsequently we have\n$$\nx^{-1} C(a) x \\subset C\\left(x^{-1} a x\\right) .\n$$\nIt follows from the aforesaid argument\n$$\nC\\left(x^{-1} a x\\right)=x^{-1} C(a) x .\n$$\nThis completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n 1) :\n n ∣ (a ^ n - 1).totient := sorry", "formal_proof": null, "informal_stmt": "If $a > 1$ is an integer, show that $n \\mid \\varphi(a^n - 1)$, where $\\phi$ is the Euler $\\varphi$-function.\n\\begin{proof}\n Proof: We have $a>1$. First we propose to prove that\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nIf possible, let us assume that\n$\\operatorname{Gcd}\\left(a, a^n-1\\right)=d$, where $d>1$.\nThen\n$d$ divides $a$ as well as $a^n-1$.\nNow,\n$d$ divides $a \\Longrightarrow d$ divides $a^n$.\nThis is an impossibility, since $d$ divides $a^n-1$ by our assumption. Consequently, $d$ divides 1 , which implies $d=1$. Hence we are contradict to the fact that $d>1$. Therefore\n$$\n\\operatorname{Gcd}\\left(a, a^n-1\\right)=1 .\n$$\nThen $a \\in U_{a^n-1}$, where $U_n$ is a group defined by\n$$\nU_n:=\\left\\{\\bar{a} \\in \\mathbb{Z}_n \\mid \\operatorname{Gcd}(a, n)=1\\right\\} .\n$$\nWe know that order of an element divides the order of the group. Here order of the group $U_{a^n-1}$ is $\\phi\\left(a^n-1\\right)$ and $a \\in U_{a^n-1}$. This follows that $\\mathrm{o}(a)$ divides $\\phi\\left(a^n-1\\right)$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $nn$. By lagrange's theorem then $p^{2 n-s}\\left|p^n m \\Longrightarrow p^{n-s}\\right| m \\Longrightarrow p \\mid m$-contradiction. So $\\phi(H)=H$, and $H$ is characteristic subgroup of $G$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n\\frac{|G|}{2}$, where\n$$\nb^{-1} A=\\left\\{b^{-1} a \\mid a \\in A\\right\\}\n$$\nFirst notice that if we consider a map $f: A \\rightarrow b^{-1} A$ defined by $f(a)=b^{-1} a$, for all $a \\in A$, then $f$ is a 1-1 map and so $\\left|b^{-1} A\\right| \\geq|A|>\\frac{3}{4}|G|$. Now using inclusion-exclusion principle we have\n$$\n\\left|A \\cap\\left(b^{-1} A\\right)\\right|=|A|+\\left|b^{-1} A\\right|-\\left|A \\cup\\left(b^{-1} A\\right)\\right|>\\frac{3}{4}|G|+\\frac{3}{4}|G|-|G|=\\frac{1}{2}|G|\n$$\n2. Argue that $A \\cap\\left(b^{-1} A\\right) \\subseteq C(b)$, where $C(b)$ is the centralizer of $b$ in $G$.\n\nSuppose $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in A$ and $x \\in b^{-1} A$. Thus there exist an element $a \\in A$ such that $x=$ $b^{-1} a$, which gives us $x b=a \\in A$. Now notice that $x, b \\in A$ and $x b \\in A$, therefore we get\n$$\n\\phi(x b)=(x b)^{-1} \\Longrightarrow \\phi(x) \\phi(b)=(x b)^{-1} \\Longrightarrow x^{-1} b^{-1}=b^{-1} x^{-1} \\Longrightarrow x b=b x\n$$\nTherefore, we get $x b=b x$, for any $x \\in A \\cap\\left(b^{-1} A\\right)$, that means, $x \\in C(b)$.\n\n3. Argue that $C(b)=G$.\nWe know that centralizer of an element in a group $G$ is a subgroup (See Page 53). Therefore $C(b)$ is a subgroup of $G$. From statements $\\mathbf{1}$ and $\\mathbf{2}$, we have\n$$\n|C(b)| \\geq\\left|A \\cap\\left(b^{-1} A\\right)\\right|>\\frac{|G|}{2}\n$$\nWe need to use the following remark to argue $C(b)=G$ from the above step.\nRemark. Let $G$ be a finite group and $H$ be a subgroup with more then $|G| / 2$ elements then $H=G$.\n\nProof of Remark. Suppose $|H|=p$ Then by Lagrange Theorem, there exist an $n \\in \\mathbb{N}$, such that $|G|=n p$, as $|H|$ divide $|G|$. Now by hypothesis $p>\\frac{G]}{2}$ gives us,\n$$\np>\\frac{|G|}{2} \\Longrightarrow n p>\\frac{n|G|}{2} \\Longrightarrow n<2 \\Longrightarrow n=1\n$$\nTherefore we get $H=G$.\n\nNow notice that $C(b)$ is a subgroup of $G$ with $C(b)$ having more than $|G| / 2$ elements. Therefore, $C(b)=G$.\n\n4. Show that $A \\in Z(G)$.\n\nWe know that $x \\in Z(G)$ if and only if $C(a)=G$. Now notice that, for any $b \\in A$ we have $C(b)=G$. Therefore, every element of $A$ is in the center of $G$, that means, $A \\subseteq Z(G)$.\n\n5. 5how that $Z(G)=G$.\n\nAs it is given that $|A|>\\frac{3|G|}{4}$ and $A \\leq|Z(G)|$, therefore we get\n$$\n|Z(G)|>\\frac{3}{4}|G|>\\frac{1}{2}|G| .\n$$\nAs $Z(G)$ is a subgroup of $G$, so by the above Remark we have $Z(G)=G$. Hence $G$ is abelian.\n\n6. Finally show that $A=G$.\n\nFirst notice that $A$ is a subgroup of $G$. To show this let $p, q \\in A$. Then we have\n$$\n\\phi(p q)=\\phi(p) \\phi(q)=p^{-1} q^{-1}=(q p)^{-1}=(p q)^{-1}, \\quad \\text { As } G \\text { is abelian. }\n$$\nTherefore, $p q \\in A$ and so we have $A$ is a subgroup of $G$. Again by applying the above remark. we get $A=G$. Therefore we have\n$$\n\\phi(y)=y^{-1}, \\quad \\text { for all } y \\in G\n$$\n\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n q) (h1 : q ∣ p - 1) (hG : card G = p*q) (hH : card G = p*q) :\n G ≃* H := sorry", "formal_proof": null, "informal_stmt": "Prove that if $p > q$ are two primes such that $q \\mid p - 1$, then any two nonabelian groups of order $pq$ are isomorphic.\n\\begin{proof}\n For a nonabelian group of order $p q$, the structure of the group $G$ is set by determining the relation $a b a^{-1}=b^{k^{\\frac{p-1}{q}}}$ for some generator $k$ of the cyclic group. Here we are using the fact that $k^{\\frac{p-1}{q}}$ is a generator for the unique subgroup of order $q$ in $U_p$ (a cyclic group of order $m$ has a unique subgroup of order $d$ for each divisor $d$ of $m$ ). The other possible generators of this subgroup are $k^{\\frac{l(p-1)}{q}}$ for each $1 \\leq l \\leq q-1$, so these give potentially new group structures. Let $G^{\\prime}$ be a group with an element $c$ of order $q$, an element $d$ of order $p$ with structure defined by the relation $c d c^{-1}=d^{k^{\\frac{l(p-1)}{q}}}$. We may then define\n$$\n\\begin{aligned}\n\\phi: G^{\\prime} & \\rightarrow G \\\\\nc & \\mapsto a^l \\\\\nd & \\mapsto b\n\\end{aligned}\n$$\nsince $c$ and $a^l$ have the same order and $b$ and $d$ have the same order this is a well defined function.\nSince\n$$\n\\begin{aligned}\n\\phi(c) \\phi(d) \\phi(c)^{-1} & =a^l b a^{-l} \\\\\n& =b^{\\left(k^{\\frac{p-1}{q}}\\right)^l} \\\\\n& =b^{k^{\\frac{l(p-1)}{q}}} \\\\\n& =\\phi(d)^{k^{\\frac{l(p-1)}{q}}}\n\\end{aligned}\n$$\n$\\phi\\left(c^i d^j\\right)=a^{l i} b^j=e$ only if $i=j=0$, so $\\phi$ is 1-to-l. Therefore $G$ and $G^{\\prime}$ are isomorphic and so up to isomorphism there is only one nonabelian group of order $p q$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n1$. Let $g^k$ be an element of $G$ and $h^j$ be an element of $H$. Since the lowest common multiple of $n$ and $m$ is lower than the product $n . m$, that is, $\\operatorname{lcm}(n, m)1$, then $Z(G)$, the center of $G$, has more than one element; that is, if $|G|=p^k$ with $k\\geq 1$, then $|Z(G)|>1$.\n\n\\textit{Proof of the lemma:} Consider the class equation\n$$\n|G|=|Z(G)|+\\sum_{a \\notin Z(G)}[G: C(a)],\n$$\nwhere $C(a)$ denotes the centralizer of $a$ in $G$. If $G=Z(G)$, then the lemma is immediate. Suppose $Z(G)$ is a proper subset of $G$ and consider an element $a\\in G$ such that $a\\notin Z(G)$. Then $C(a)$ is a proper subgroup of $G$. Since $C(a)$ is a subgroup of a $p$-group, $[G:C(a)]$ is divisible by $p$ for all $a\\notin Z(G)$. This implies that $p$ divides $|G|=|Z(G)|+\\sum_{a\\notin Z(G)} [G:C(a)]$.\n\nSince $p$ also divides $|G|$, it follows that $p$ divides $|Z(G)|$. Hence, $|Z(G)|>1$. $\\Box$\n\nThis proves our \\textbf{lemma}.\n\nWe will prove the result by induction on $n$.\nIf $n=1$, the $G$ is a cyclic group of prime order and hence every subgroup of $G$ is normal in $G$. Thus, the result is true for $n=1$.\nSuppose the result is true for all groups of order $p^m$, where $1 \\leq mp^{n-1}$. Thus, $|N(H)|=p^n$ and $N(H)=G$.\nIn this case $H$ is normal in $G$.\nLet $H=N(H)$. Then $Z(G)$, the center of $G$, is a subset of $H$ and $Z(G) \\neq$ $\\{e\\}$.\nBy Cauchy's theorem and the above Claim, there exists $a \\in Z(G)$ such that $o(a)=p$.\nLet $K=\\langle a\\rangle$, a cyclic group generated by $a$.\nThen $K$ is a normal subgroup of $G$ of order $p$. Now, $|H / K|=p^{n-2}$ and $|G / K|=p^{n-1}$.\nThus, by induction hypothesis, $H / K$ is a normal subgroup of $G / K$.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n3$.\nLet us take $p=3$. Then the sum\n$$\n\\frac{1}{1}+\\frac{1}{2}+\\ldots+\\frac{1}{(p-1)}\n$$\nbecomes\n$$\n1+\\frac{1}{3-1}=1+\\frac{1}{2}=\\frac{3}{2} .\n$$\nTherefore in this case $\\quad \\frac{a}{b}=\\frac{3}{2} \\quad$ implies $3 \\mid a$, i.e. $p \\mid a$.\nNow for odd prime $p>3$.\nLet us consider $f(x)=(x-1)(x-2) \\ldots(x-(p-1))$.\nNow, by Fermat, we know that the coefficients of $f(x)$ other than the $x^{p-1}$ and $x^0$ are divisible by $p$.\nSo if,\n$$\n\\begin{array}{r}\nf(x)=x^{p-1}+\\sum_{i=0}^{p-2} a_i x^i \\\\\n\\text { and } p>3 .\n\\end{array}\n$$\nThen $p \\mid a_2$, and\n$$\nf(p) \\equiv a_1 p+a_0 \\quad\\left(\\bmod p^3\\right)\n$$\nBut we see that\n$$\nf(x)=(-1)^{p-1} f(p-x) \\text { for any } x,\n$$\nso if $p$ is odd,\n$$\nf(p)=f(0)=a_0,\n$$\nSo it follows that:\n$$\n0=f(p)-a_0 \\equiv a_1 p \\quad\\left(\\bmod p^3\\right)\n$$\nTherefore,\n$$\n0 \\equiv a_1 \\quad\\left(\\bmod p^2\\right) .\n$$\nHence,\n$$\n0 \\equiv a_1 \\quad(\\bmod p) .\n$$\nNow our sum is just $\\frac{a_1}{(p-1) !}=\\frac{a}{b}$.\nIt follows that $p$ divides $a$. This completes the proof.\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n x^5 + sqrt 2 * x^3 + sqrt 5 * x^2 + sqrt 7 * x + 11)\n (ha : p a = 0) :\n ∃ p : Polynomial ℂ , p.degree < 80 ∧ a ∈ p.roots ∧\n ∀ n : p.support, ∃ a b : ℤ, p.coeff n = a / b := sorry", "formal_proof": null, "informal_stmt": "If $a \\in C$ is such that $p(a) = 0$, where $p(x) = x^5 + \\sqrt{2}x^3 + \\sqrt{5}x^2 + \\sqrt{7}x + \\sqrt{11}$, show that $a$ is algebraic over $\\mathbb{Q}$ of degree at most 80.\n\\begin{proof}\n Given $a \\in \\mathbb{C}$ such that $p(a)=0$, where\n$$\np(x)=x^5+\\sqrt{2} x^3+\\sqrt{5} x^2+\\sqrt{7} x+\\sqrt{11}\n$$\nHere, we note that $p(x) \\in \\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$ and\n$$\n\\begin{aligned}\n {[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): \\mathbb{Q}] } & =[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7})] \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}): \\mathbb{Q}(\\sqrt{2}, \\sqrt{5})] \\\\\n& \\cdot[\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}): \\mathbb{Q}(\\sqrt{2})] \\cdot[\\mathbb{Q}(\\sqrt{2}): \\mathbb{Q}] \\\\\n& =2 \\cdot 2 \\cdot 2 \\cdot 2 \\\\\n& =16\n\\end{aligned}\n$$\nHere, we note that $p(x)$ is of degree 5 over $\\mathbb{Q}(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. If $a$ is root of $p(x)$, then\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}]=[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\cdot 15\n$$\nand $[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}): Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})] \\leq 5$. We get equality if $p(x)$ is irreducible over $Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11})$. This gives\n$$\n[Q(\\sqrt{2}, \\sqrt{5}, \\sqrt{7}, \\sqrt{11}, a): \\mathbb{Q}] \\leq 16 \\cdot 5=80\n$$\n\\end{proof}", "informal_proof": "First note that $a=a^{-1}$ is the same as saying $a^2=e$, where $e$ is the identity. I.e. the statement is that there exists at least one element of order 2 in $G$. Every element $a$ of $G$ of order at least 3 has an inverse $a^{-1}$ that is not itself -- that is, $a \\neq a^{-1}$. So the subset of all such elements has an even cardinality (/size). There's exactly one element with order 1 : the identity $e^1=e$. So $G$ contains an even number of elements -call it $2 k$-- of which an even number are elements of order 3 or above -- call that $2 n$ where $n0$ there exists $\\delta>0$ such that\n$$\nd_Y(f(x), f(y))<\\epsilon \\text { whenever } d_X(x, y)<\\delta \\text { and } x, y \\in A\n$$\nSo for this $\\delta>0$ there exists $N \\in \\mathbb{N}$ such that\n$$\nd_X\\left(x_n, x\\right)<\\frac{\\delta}{2} \\text { and } d_X\\left(y_n, x\\right)<\\frac{\\delta}{2}, \\text { foe all } n \\geq N .\n$$\nTherefore, we have that for all $n \\geq N$,\n$$\nd_X\\left(x_n, y_n\\right)<\\delta\n$$\nThus the equation (1) yields us that\n$$\nd_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)<\\epsilon \\text { for all } n \\geq N .\n$$\nNow since $\\lim _{n \\rightarrow \\infty} f\\left(x_n\\right)=a$ and $b=\\lim _{n \\rightarrow \\infty} f\\left(y_n\\right)$, so for the above $\\epsilon>0$ we have a natural number $K \\geq N$ such that\n$$\n\\begin{gathered}\nd_Y\\left(f\\left(x_n\\right), a\\right)<\\epsilon \\text { for all } n \\geq K \\text { and } \\\\\nd_Y\\left(f\\left(y_n\\right), b\\right)<\\epsilon \\text { for all } n \\geq K .\n\\end{gathered}\n$$\nMoreover, since $K \\geq N$, from $(2)$ we get\n$$\nd_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)<\\epsilon \\text { for all } n \\geq K .\n$$\nNow we calculate the following, for $n \\geq K$,\n$$\n\\begin{array}{rlr}\nd_Y(a, b) & \\leq & d_Y\\left(a, f\\left(x_n\\right)\\right)+d_Y\\left(f\\left(x_n\\right), f\\left(y_n\\right)\\right)+d\\left(f\\left(y_n\\right), b\\right) \\\\\n& < & \\epsilon+\\epsilon+\\epsilon \\text { by }(3),(4) \\text { and }(5) \\\\\n& = & 3 \\epsilon\n\\end{array}\n$$\nwhere the first inequality holds because of triangular inequality. Since $\\epsilon>0$ is arbitrary the above calculation shows that $d_Y(a, b)=0$. Thus, the above definition is independent of the choice of the sequence $\\left\\{x_n\\right\\}$ and hence the map $g$ is well defined. Moreover, from the construction it follows that $g$ is continuous on $\\bar{A}$.\nMoreover, we observe that $g$ is unique extension of $f$ by the construction.\nSo it remains to show that $g$ is uniformly continuous. In order to that we take a Cauchy sequence $\\left\\{a_n\\right\\} \\subset \\bar{A}$. Then since $\\bar{A}$ is a closed set so the sequence $\\left\\{a_n\\right\\}$ is convergent and hence $\\left\\{g\\left(a_n\\right)\\right\\}$ is also a convergent sequence as $g$ is continuous on $\\bar{A}$. So $\\left\\{g\\left(a_n\\right)\\right\\}$ is a Cauchy sequence in $Y$. Since a function is uniformly continuous if and only if it sends Cauchy sequences to Cauchy sequences, we conclude that $g$ is uniformly continuous.\n\\end{proof}\n\\end{document}", "informal_proof": "Since, from the given hypothesis given any $x \\in A$ there exists an open set containing $x$ say, $U_x$ such that $U_x \\subset A$. Thus, we claim that $$ A=\\bigcup_{x \\in A} U_x $$ Observe that if we prove the above claim, then $A$ will be open, being a union of arbitrary open sets. Since, for each $x \\in A, U_x \\subset A \\Longrightarrow \\cup U_x \\subset A$. For the converse, observe that given any $x \\in A, x \\in U_x$ and hence in the union. Thus we proved our claim, and hence $A$ is an open set."} -{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_1E_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_1E_a : ∀ N : ℕ, ∃ n ≥ N, (3*n+1).Prime ∧ (3*n+1) ≥ N := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} -{"name": "Cambridge_Tripos_exercise_2022_IA_4_I_2D_a", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IA_4_I_2D_a : Irrational (2^((1:ℝ)/3) + 3^((1:ℝ)/3)) := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} -{"name": "Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i", "source": "Cambridge-Tripos.lean", "header": "import Mathlib\n\nopen Filter Set\n", "formal_statement": "theorem Cambridge_Tripos_exercise_2022_IB_3_II_13G_a_i (U : Set ℂ) (hU : IsOpen U)\n (hU1 : Nonempty U) (hU2 : IsConnected U) (f : ℕ → ℂ → ℂ) (f' : ℂ → ℂ)\n (hf : ∀ n : ℕ, DifferentiableOn ℂ (f n) U)\n (hf1 : ∀ X ⊂ U, CompactSpace X →\n (TendstoUniformly (λ n => restrict X (f n)) (restrict X f') atTop)) :\n DifferentiableOn ℂ f' U := sorry", "formal_proof": null, "informal_stmt": null, "informal_proof": "The general strategy is to find a (large) number $n$ that is relatively prime to each of the existing list of such primes, and is also congruent to 2 modulo 3 . The prime factorization of $n$ cannot consist only of primes congruent to 1 modulo 3 , since the product of any number of such is still 1 modulo 3 . Hence there must be some prime factor of $n$ that is congruent to 2 modulo 3 , which must be not on our list by the construction of $n$. Now, how to construct such an $n$ ? Suppose the finite list is $\\left\\{p_1, p_2, \\ldots, p_k\\right\\}$. If $k$ is even, then take $n=p_1 p_2 \\cdots p_k+1$. If $k$ is odd, then take $n=\\left(p_1 p_2 \\cdots p_k\\right) p_k+1$."} +{"name": "Pugh_exercise_2_12a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_12a (f : ℕ → ℕ) (p : ℕ → ℝ) (a : ℝ)\n (hf : Injective f) (hp : Tendsto p atTop (𝓝 a)) :\n Tendsto (λ n => p (f n)) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Let $(p_n)$ be a sequence and $f:\\mathbb{N}\\to\\mathbb{N}$. The sequence $(q_k)_{k\\in\\mathbb{N}}$ with $q_k=p_{f(k)}$ is called a rearrangement of $(p_n)$. Show that if $f$ is an injection, the limit of a sequence is unaffected by rearrangement.\n\\begin{proof}\n Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_26", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_26 {M : Type*} [TopologicalSpace M]\n (U : Set M) : IsOpen U ↔ ∀ x ∈ U, ¬ ClusterPt x (𝓟 Uᶜ) := sorry", "formal_proof": null, "informal_stmt": "Prove that a set $U \\subset M$ is open if and only if none of its points are limits of its complement.\n\\begin{proof}\n Assume that none of the points of $U$ are limits of its complement, and let us prove that $U$ is open. Assume by contradiction that $U$ is not open, so there exists $p \\in M$ so that $\\forall r>0$ there exists $q \\in M$ with $d(p, q)0$ such that $d(p, x)0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_29", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_29 (M : Type*) [MetricSpace M]\n (O C : Set (Set M))\n (hO : O = {s | IsOpen s})\n (hC : C = {s | IsClosed s}) :\n ∃ f : O → C, Bijective f := sorry", "formal_proof": null, "informal_stmt": "Let $\\mathcal{T}$ be the collection of open subsets of a metric space $\\mathrm{M}$, and $\\mathcal{K}$ the collection of closed subsets. Show that there is a bijection from $\\mathcal{T}$ onto $\\mathcal{K}$.\n\\begin{proof}\n The bijection given by $x\\mapsto X^C$ suffices. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_32a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_32a (A : Set ℕ) : IsClopen A := sorry", "formal_proof": null, "informal_stmt": "Show that every subset of $\\mathbb{N}$ is clopen.\n\\begin{proof}\n 32. The one-point set $\\{n\\} \\subset \\mathbb{N}$ is open, since it contains all $m \\in \\mathbb{N}$ that satisfy $d(m, n)<\\frac{1}{2}$. Every subset of $\\mathbb{N}$ is a union of one-point sets, hence is open. Then every set it closed, since its complement is necessarily open.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_41", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_41 (m : ℕ) {X : Type*} [NormedSpace ℝ ((Fin m) → ℝ)] :\n IsCompact (Metric.closedBall 0 1) := sorry", "formal_proof": null, "informal_stmt": "Let $\\|\\cdot\\|$ be any norm on $\\mathbb{R}^{m}$ and let $B=\\left\\{x \\in \\mathbb{R}^{m}:\\|x\\| \\leq 1\\right\\}$. Prove that $B$ is compact.\n\\begin{proof}\n Let us call $\\|\\cdot\\|_E$ the Euclidean norm in $\\mathbb{R}^m$. We start by claiming that there exist constants $C_1, C_2>0$ such that\n$$\nC_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E, \\forall x \\in \\mathbb{R}^m .\n$$\nAssuming (1) to be true, let us finish the problem. First let us show that $B$ is bounded w.r.t. $d_E$, which is how we call the Euclidean distance in $\\mathbb{R}^m$. Indeed, given $x \\in B,\\|x\\|_E \\leq \\frac{1}{C_1}\\|x\\| \\leq \\frac{1}{C_1}$. Hence $B \\subset\\left\\{x \\in \\mathbb{R}^m: d_E(x, 0)<\\frac{1}{C_1}+1\\right\\}$, which means $B$ is bounded w.r.t $d_E$.\nNow let us show that $B$ is closed w.r.t. $d_E$. Let $x_n \\rightarrow x$ w.r.t. $d_E$, where $x_n \\in B$. Notice that this implies that $x_n \\rightarrow x$ w.r.t. $d(x, y)=\\|x-y\\|$, the distance coming from $\\|\\cdot\\|$, since by (1) we have\n$$\nd\\left(x_n, x\\right)=\\left\\|x_n-x\\right\\| \\leq C_2\\left\\|x_n-x\\right\\|_E \\rightarrow 0 .\n$$\nAlso, notice that\n$$\n\\|x\\| \\leq\\left\\|x_n-x\\right\\|+\\left\\|x_n\\right\\| \\leq\\left\\|x_n-x\\right\\|+1,\n$$\nhence passing to the limit we obtain that $\\|x\\| \\leq 1$, therefore $x \\in B$ and so $B$ is closed w.r.t. $d_E$. Since $B$ is closed and bounded w.r.t. $d_E$, it must be compact. Now we claim that the identity function, $i d:\\left(\\mathbb{R}^m, d_E\\right) \\rightarrow\\left(\\mathbb{R}^m, d\\right)$ where $\\left(\\mathbb{R}^m, d_E\\right)$ means we are using the distance $d_E$ in $\\mathbb{R}^m$ and $\\left(\\mathbb{R}^m, d\\right)$ means we are using the distance $d$ in $\\mathbb{R}^m$, is a homeomorphism. This follows by (1), since $i d$ is always a bijection, and it is continuous and its inverse is continuous by (1) (if $x_n \\rightarrow x$ w.r.t. $d_E$, then $x_n \\rightarrow x$ w.r.t. $d$ and vice-versa, by (1)). By a result we saw in class, since $B$ is compact in $\\left(\\mathbb{R}^m, d_E\\right)$ and $i d$ is a homeomorphism, then $i d(B)=B$ is compact w.r.t. $d$.\n\nWe are left with proving (1). Notice that it suffices to prove that $C_1 \\leq\\|x\\| \\leq$ $C_2, \\forall x \\in \\mathbb{R}^m$ with $\\|x\\|_E=1$. Indeed, if this is true, given $x \\in \\mathbb{R}^m$, either $\\|x\\|_E=0$ (which implies $x=0$ and (1) holds in this case), or $x /\\|x\\|_E=y$ is such that $\\|y\\|_E=1$, so $C_1 \\leq\\|y\\| \\leq C_2$, which implies $C_1\\|x\\|_E \\leq\\|x\\| \\leq C_2\\|x\\|_E$.\nWe want to show now that $\\|\\cdot\\|$ is continuous w.r.t. $d_E$, that is, given $\\varepsilon>0$ and $x \\in \\mathbb{R}^m$, there exists $\\delta>0$ such that if $d_E(x, y)<\\delta$, then $\\|\\mid x\\|-\\|y\\| \\|<\\varepsilon$.\n\nBy the triangle inequality, $\\|x\\|-\\|y\\| \\leq\\|x-y\\|$, and $\\|y\\|-\\|x\\| \\leq\\|x-y\\|$, therefore\n$$\n|\\|x||-\\| y|\\|\\leq\\| x-y \\| .\n$$\nWriting now $x=\\sum_{i=1}^m a_i e_i, y=\\sum_{i=1}^m b_i e_i$, where $e_i=(0, \\ldots, 1,0, \\ldots, 0)$ (with 1 in the i-th component), we obtain by the triangle inequality,\n$$\n\\begin{aligned}\n\\|x-y\\| & =\\left\\|\\sum_{i=1}^m\\left(a_i-b_i\\right) e_i\\right\\| \\leq \\sum_{i=1}^m\\left|a_i-b_i\\left\\|\\left|\\left\\|e_i\\right\\| \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| \\sum_{i=1}^m\\right| a_i-b_i \\mid\\right.\\right. \\\\\n& =\\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| d_{s u m}(x, y) \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_{\\max }(x, y) \\\\\n& \\leq \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\| m d_E(x, y) .\n\\end{aligned}\n$$\nLet $\\delta=\\frac{\\varepsilon}{m \\max _{i=1, \\ldots, m}\\left\\|e_i\\right\\|}$. Then if $d_E(x, y)<\\delta,\\|x\\|-\\|y\\|||<\\varepsilon$.\nSince $\\|\\cdot\\|$ is continuous w.r.t. $d_E$ and $K=\\left\\{x \\in \\mathbb{R}^m:\\|x\\|_E=1\\right\\}$ is compact w.r.t. $d_E$, then the function $\\|\\cdot\\|$ achieves a maximum and a minimum value on $K$. Call $C_1=\\min _{x \\in K}\\|x\\|, C_2=\\max _{x \\in K}\\|x\\|$. Then\n$$\nC_1 \\leq\\|x\\| \\leq C_2, \\forall x \\in \\mathbb{R}^m \\text { such that }\\|x\\|_E=1,\n$$\nwhich is what we needed.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_46", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_46 {M : Type*} [MetricSpace M]\n {A B : Set M} (hA : IsCompact A) (hB : IsCompact B)\n (hAB : Disjoint A B) (hA₀ : A ≠ ∅) (hB₀ : B ≠ ∅) :\n ∃ a₀ b₀, a₀ ∈ A ∧ b₀ ∈ B ∧ ∀ (a : M) (b : M),\n a ∈ A → b ∈ B → dist a₀ b₀ ≤ dist a b := sorry", "formal_proof": null, "informal_stmt": "Assume that $A, B$ are compact, disjoint, nonempty subsets of $M$. Prove that there are $a_0 \\in A$ and $b_0 \\in B$ such that for all $a \\in A$ and $b \\in B$ we have $d(a_0, b_0) \\leq d(a, b)$.\n\\begin{proof}\nLet $A$ and $B$ be compact, disjoint and non-empty subsets of $M$. We want to show that there exist $a_0 \\in A, b_0 \\in B$ such that for all $a \\in A, b \\in B$,\n$$\nd\\left(a_0, b_0\\right) \\leq d(a, b) .\n$$\nWe saw in class that the distance function $d: M \\times M \\rightarrow \\mathbb{R}$ is continuous. We also saw in class that any continuous, real-valued function assumes maximum and minimum values on a compact set. Since $A$ and $B$ are compact, $A \\times B$ is (non-empty) compact in $M \\times M$. Therefore there exists $\\left(a_0, b_0\\right) \\in A \\times B$ such that $d\\left(a_0, b_0\\right) \\leq d(a, b), \\forall(a, b) \\in A \\times B$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_57", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_57 {X : Type*} [TopologicalSpace X]\n : ∃ (S : Set X), IsConnected S ∧ ¬ IsConnected (interior S) := sorry", "formal_proof": null, "informal_stmt": "Show that if $S$ is connected, it is not true in general that its interior is connected.\n\\begin{proof}\n Consider $X=\\mathbb{R}^2$ and\n$$\nA=([-2,0] \\times[-2,0]) \\cup([0,2] \\times[0,2])\n$$\nwhich is connected, while $\\operatorname{int}(A)$ is not connected.\nTo see this consider the continuous function $f: \\mathbb{R}^2 \\rightarrow \\mathbb{R}$ is defined by $f(x, y)=x+y$. Let $U=f^{-1}(0,+\\infty)$ which is open in $\\mathbb{R}^2$ and so $U \\cap \\operatorname{int}(A)$ is open in $\\operatorname{int}(A)$. Also, since $(0,0) \\notin \\operatorname{int}(A)$, so for all $(x, y) \\in \\operatorname{int}(A), f(x, y) \\neq 0$ and $U \\cap \\operatorname{int}(A)=f^{-1}[0,+\\infty) \\cap \\operatorname{int}(A)$ is closed in $\\operatorname{int}(A)$. Furthermore, $(1,1)=f^{-1}(2) \\in U \\cap \\operatorname{int}(A)$ shows that $U \\cap \\operatorname{int}(A) \\neq \\emptyset$ while $(-1,-1) \\in \\operatorname{int}(A)$ and $(-1,-1) \\notin U$ shows that $U \\cap \\operatorname{int}(A) \\neq \\operatorname{int}(A)$.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_92", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_92 {α : Type*} [TopologicalSpace α]\n {s : ℕ → Set α}\n (hs : ∀ i, IsCompact (s i))\n (hs : ∀ i, (s i).Nonempty)\n (hs : ∀ i, (s i) ⊃ (s (i + 1))) :\n (⋂ i, s i).Nonempty := sorry", "formal_proof": null, "informal_stmt": "Give a direct proof that the nested decreasing intersection of nonempty covering compact sets is nonempty.\n\\begin{proof}\n Let\n$$\nA_1 \\supset A_2 \\supset \\cdots \\supset A_n \\supset \\cdots\n$$\nbe a nested decreasing sequence of compacts. Suppose that $\\bigcap A_n=\\emptyset$. Take $U_n=A_n^c$, then\n$$\n\\bigcup U_n=\\bigcup A_n^c=\\left(\\bigcap A_n\\right)^c=A_1 .\n$$\nHere, I'm thinking of $A_1$ as the main metric space. Since $\\left\\{U_n\\right\\}$ is an open covering of $A_1$, we can extract a finite subcovering, that is,\n$$\nA_{\\alpha_1}^c \\cup A_{\\alpha_2}^c \\cup \\cdots \\cup A_{\\alpha_m}^c \\supset A_1\n$$\nor\n$$\n\\left(A_1 \\backslash A_{\\alpha_1}\\right) \\cup\\left(A_1 \\backslash A_{\\alpha_2}\\right) \\cup \\cdots \\cup\\left(A_1 \\backslash A_{\\alpha_m}\\right) \\supset A_1 .\n$$\nBut, this is true only if $A_{\\alpha_i}=\\emptyset$ for some $i$, a contradiction.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_2_126", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_2_126 {E : Set ℝ}\n (hE : ¬ Set.Countable E) : ∃ (p : ℝ), ClusterPt p (𝓟 E) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $E$ is an uncountable subset of $\\mathbb{R}$. Prove that there exists a point $p \\in \\mathbb{R}$ at which $E$ condenses.\n\\begin{proof}\n I think this is the proof by contrapositive that you were getting at.\nSuppose that $E$ has no limit points at all. Pick an arbitrary point $x \\in E$. Then $x$ cannot be a limit point, so there must be some $\\delta>0$ such that the ball of radius $\\delta$ around $x$ contains no other points of $E$ :\n$$\nB_\\delta(x) \\cap E=\\{x\\}\n$$\nCall this \"point 1 \". For the next point, take the closest element to $x$ and on its left; that is, choose the point\n$$\n\\max [E \\cap(-\\infty, x)]\n$$\nif it exists (that is important - if not, skip to the next step). Note that by the argument above, this supremum, should it exist, cannot equal $x$ and is therefore a new point in $E$.\n\nCall this \"point 2 \". Now take the first point to the right of $x$ for \"point 3 \". Take the first point to the left of point 2 for \"point 4 \". And so on, ad infinitum.\n\nThis gives a countable list of unique points; we must show that it exhausts the entire set $E$. Suppose not. Suppose there is some element $aa_1 \\in E$ such that $a_2$ is not in the list. Repeating, we generate an infinite monotone-increasing sequence $\\left\\{a_i\\right\\}$ of elements in $E$ and not in the list, which is clearly bounded above by $x$. By the Monotone\nConvergence Theorem this sequence has a limit. But that means the sequence $\\left\\{a_i\\right\\} \\subset E$ converges to a limit, and hence $E$ has a limit point, contradicting the assumption. Therefore our list exhausts $E$, and we have enumerated all its elements.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_1", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_1 {f : ℝ → ℝ}\n (hf : ∀ x y, |f x - f y| ≤ |x - y| ^ 2) :\n ∃ c, f = λ x => c := sorry", "formal_proof": null, "informal_stmt": "Assume that $f \\colon \\mathbb{R} \\rightarrow \\mathbb{R}$ satisfies $|f(t)-f(x)| \\leq|t-x|^{2}$ for all $t, x$. Prove that $f$ is constant.\n\\begin{proof}\n We have $|f(t)-f(x)| \\leq|t-x|^2, \\forall t, x \\in \\mathbb{R}$. Fix $x \\in \\mathbb{R}$ and let $t \\neq x$. Then\n$$\n\\left|\\frac{f(t)-f(x)}{t-x}\\right| \\leq|t-x| \\text {, hence } \\lim _{t \\rightarrow x}\\left|\\frac{f(t)-f(x)}{t-x}\\right|=0 \\text {, }\n$$\nso $f$ is differentiable in $\\mathbb{R}$ and $f^{\\prime}=0$. This implies that $f$ is constant, as seen in class.\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_4", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_4 (n : ℕ) :\n Tendsto (λ n => (sqrt (n + 1) - sqrt n)) atTop (𝓝 0) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sqrt{n+1}-\\sqrt{n} \\rightarrow 0$ as $n \\rightarrow \\infty$.\n\\begin{proof}\n $$\n\\sqrt{n+1}-\\sqrt{n}=\\frac{(\\sqrt{n+1}-\\sqrt{n})(\\sqrt{n+1}+\\sqrt{n})}{\\sqrt{n+1}+\\sqrt{n}}=\\frac{1}{\\sqrt{n+1}+\\sqrt{n}}<\\frac{1}{2 \\sqrt{n}}\n$$\n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_63a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63a (p : ℝ) (f : ℕ → ℝ) (hp : p > 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ converges when $p > 1$.\n\\begin{proof}\n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_3_63b", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_3_63b (p : ℝ) (f : ℕ → ℝ) (hp : p ≤ 1)\n (h : f = λ (k : ℕ) => (1 : ℝ) / (k * (log k) ^ p)) :\n ¬ ∃ l, Tendsto f atTop (𝓝 l) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\sum 1/k(\\log(k))^p$ diverges when $p \\leq 1$.\n\\begin{proof} \n Using the integral test, for a set $a$, we see\n$$\n\\lim _{b \\rightarrow \\infty} \\int_a^b \\frac{1}{x \\log (x)^c} d x=\\lim _{b \\rightarrow \\infty}\\left(\\frac{\\log (b)^{1-c}}{1-c}-\\frac{\\log (a)^{1-c}}{1-c}\\right)\n$$\nwhich goes to infinity if $c \\leq 1$ and converges if $c>1$. Thus,\n$$\n\\sum_{n=2}^{\\infty} \\frac{1}{n \\log (n)^c}\n$$\nconverges if and only if $c>1$. \n\\end{proof}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Pugh_exercise_4_15a", "source": "Pugh.lean", "header": "import Mathlib\n\nopen Filter Real Function\nopen scoped Topology\nnoncomputable section\n", "formal_statement": "theorem Pugh_exercise_4_15a {α : Type*}\n (a b : ℝ) (F : Set (ℝ → ℝ)) :\n (∀ x : ℝ, ∀ ε > 0, ∃ U ∈ (𝓝 x),\n (∀ y z : U, ∀ f : ℝ → ℝ, f ∈ F → (dist (f y) (f z) < ε)))\n ↔\n ∃ (μ : ℝ → ℝ), ∀ (x : ℝ), (0 : ℝ) ≤ μ x ∧ Tendsto μ (𝓝 0) (𝓝 0) ∧\n (∀ (s t : ℝ) (f : ℝ → ℝ), f ∈ F → |(f s) - (f t)| ≤ μ (|s - t|)) := sorry", "formal_proof": null, "informal_stmt": "A continuous, strictly increasing function $\\mu \\colon (0, \\infty) \\rightarrow (0, \\infty)$ is a modulus of continuity if $\\mu(s) \\rightarrow 0$ as $s \\rightarrow 0$. A function $f \\colon [a, b] \\rightarrow \\mathbb{R}$ has modulus of continuity $\\mu$ if $|f(s) - f(t)| \\leq \\mu(|s - t|)$ for all $s, t \\in [a, b]$. Prove that a function is uniformly continuous if and only if it has a modulus of continuity.\n\\begin{proof}\n Suppose there exists a modulus of continuity $w$ for $f$, then fix $\\varepsilon>0$, since $\\lim _{s \\rightarrow 0} w(s)=0$, there exists $\\delta>0$ such that for any $|s|<\\delta$, we have $w(s)<\\varepsilon$, then we have for any $x, z \\in X$ such that $d_X(x, z)<\\delta$, we have $d_Y(f(x), f(z)) \\leq w\\left(d_X(x, z)\\right)<\\varepsilon$, which means $f$ is uniformly continuous.\n\nSuppose $f:\\left(X, d_X\\right) \\rightarrow\\left(Y, d_Y\\right)$ is uniformly continuous.\nLet $\\delta_1>0$ be such that $d_X(a, b)<\\delta_1$ implies $d_Y(f(a), f(b))<1$.\nDefine $w:[0, \\infty) \\rightarrow[0, \\infty]$ by\n$$\nw(s)= \\begin{cases}\\left.\\sup \\left\\{d_Y(f(a), f(b))\\right\\} \\mid d_X(a, b) \\leq s\\right\\} & \\text { if } s \\leq \\delta_1 \\\\ \\infty & \\text { if } s>\\delta_1\\end{cases}\n$$\nWe'll show that $w$ is a modulus of continuity for $f \\ldots$\nBy definition of $w$, it's immediate that $w(0)=0$ and it's clear that\n$$\nd_Y(f(a), f(b)) \\leq w\\left(d_X(a, b)\\right)\n$$\nfor all $a, b \\in X$.\nIt remains to show $\\lim _{s \\rightarrow 0^{+}} w(s)=0$.\nIt's easily seen that $w$ is nonnegative and non-decreasing, hence $\\lim _{s \\rightarrow 0^{+}}=L$ for some $L \\geq 0$, where $L=\\inf w((0, \\infty))$\nLet $\\epsilon>0$.\nBy uniform continuity of $f$, there exists $\\delta>0$ such that $d_X(a, b)<\\delta$ implies $d_Y(f(a), f(b))<\\epsilon$, hence by definition of $w$, we get $w(\\delta) \\leq \\epsilon$.\nThus $L \\leq \\epsilon$ for all $\\epsilon>0$, hence $L=0$.\nThis completes the proof.\n\\end{proof}\n\\end{document}", "informal_proof": "Let $\\varepsilon>0$. Since $p_n \\rightarrow L$, we have that, for all $n$ except $n \\leq N$, $d\\left(p_n, L\\right)<\\epsilon$. Let $S=\\{n \\mid f(n) \\leq N\\}$, let $n_0$ be the largest $n \\in S$, we know there is such a largest $n$ because $f(n)$ is injective. Now we have that $\\forall n>n_0 f(n)>N$ which implies that $p_{f(n)} \\rightarrow L$, as required."} +{"name": "Putnam_exercise_1998_a3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_a3 (f : ℝ → ℝ) (hf : ContDiff ℝ 3 f) :\n ∃ a : ℝ, (f a) * (deriv f a) * (iteratedDeriv 2 f a) * (iteratedDeriv 3 f a) ≥ 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function on the real line with continuous third derivative. Prove that there exists a point $a$ such that\n$f(a) \\cdot f^{\\prime}(a) \\cdot f^{\\prime \\prime}(a) \\cdot f^{\\prime \\prime \\prime}(a) \\geq 0$. \n\\begin{proof}\n If at least one of $f(a)$, $f'(a)$, $f''(a)$, or $f'''(a)$ vanishes\nat some point $a$, then we are done. Hence we may assume each of\n$f(x)$, $f'(x)$, $f''(x)$, and $f'''(x)$ is either strictly positive\nor strictly negative on the real line. By replacing $f(x)$ by $-f(x)$\nif necessary, we may assume $f''(x)>0$; by replacing $f(x)$\nby $f(-x)$ if necessary, we may assume $f'''(x)>0$. (Notice that these\nsubstitutions do not change the sign of $f(x) f'(x) f''(x) f'''(x)$.)\nNow $f''(x)>0$ implies that $f'(x)$ is increasing, and $f'''(x)>0$\nimplies that $f'(x)$ is convex, so that $f'(x+a)>f'(x)+a f''(x)$\nfor all $x$ and $a$. By\nletting $a$ increase in the latter inequality, we see that $f'(x+a)$\nmust be positive for sufficiently large $a$; it follows that\n$f'(x)>0$\nfor all $x$. Similarly, $f'(x)>0$ and $f''(x)>0$ imply\nthat $f(x)>0$ for all $x$. Therefore $f(x) f'(x) f''(x) f'''(x)>0$ for\nall $x$, and we are done.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_1998_b6", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1998_b6 (a b c : ℤ) :\n ∃ n : ℤ, n > 0 ∧ ¬ ∃ m : ℤ, Real.sqrt (n^3 + a*n^2 + b*n + c) = m := sorry", "formal_proof": null, "informal_stmt": "Prove that, for any integers $a, b, c$, there exists a positive integer $n$ such that $\\sqrt{n^3+a n^2+b n+c}$ is not an integer.\n\\begin{proof}\n We prove more generally that for any polynomial $P(z)$ with integer\ncoefficients which is not a perfect square, there exists a positive\ninteger $n$ such that $P(n)$ is not a perfect square. Of course it\nsuffices to assume $P(z)$ has no repeated factors, which is to say $P(z)$\nand its derivative $P'(z)$ are relatively prime.\n\nIn particular, if we carry out the Euclidean algorithm on $P(z)$ and $P'(z)$\nwithout dividing, we get an integer $D$ (the discriminant of $P$) such that\nthe greatest common divisor of $P(n)$ and $P'(n)$ divides $D$ for any $n$.\nNow there exist infinitely many primes $p$ such that $p$ divides $P(n)$ for\nsome $n$: if there were only finitely many, say, $p_1, \\dots, p_k$, then\nfor any $n$ divisible by $m = P(0) p_1 p_2 \\cdots p_k$, we have $P(n)\n\\equiv P(0) \\pmod{m}$, that is, $P(n)/P(0)$ is not divisible by $p_1,\n\\dots, p_k$, so must be $\\pm 1$, but then $P$ takes some value infinitely\nmany times, contradiction. In particular, we can choose some such $p$ not\ndividing $D$, and choose $n$ such that $p$ divides $P(n)$. Then $P(n+kp)\n\\equiv P(n) + kp P'(n) (\\mathrm{mod}\\,p)$\n(write out the Taylor series of the left side);\nin particular, since $p$ does not divide $P'(n)$, we can find some $k$\nsuch that $P(n+kp)$ is divisible by $p$ but not by $p^2$, and so\nis not a perfect square.\n\\end{proof}\n\n\n\n\n\\end{document}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_1999_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_1999_b4 (f : ℝ → ℝ) (hf: ContDiff ℝ 3 f)\n (hf1 : ∀ n ≤ 3, ∀ x : ℝ, iteratedDeriv n f x > 0)\n (hf2 : ∀ x : ℝ, iteratedDeriv 3 f x ≤ f x) :\n ∀ x : ℝ, deriv f x < 2 * f x := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real function with a continuous third derivative such that $f(x), f^{\\prime}(x), f^{\\prime \\prime}(x), f^{\\prime \\prime \\prime}(x)$ are positive for all $x$. Suppose that $f^{\\prime \\prime \\prime}(x) \\leq f(x)$ for all $x$. Show that $f^{\\prime}(x)<2 f(x)$ for all $x$.\n\\begin{proof} \n\\setcounter{equation}{0}\nWe make repeated use of the following fact: if $f$ is a differentiable function on all of\n$\\mathbb{R}$, $\\lim_{x \\to -\\infty} f(x) \\geq 0$, and $f'(x) > 0$ for all $x \\in \\mathbb{R}$, then\n$f(x) > 0$ for all $x \\in \\mathbb{R}$. (Proof: if $f(y) < 0$ for some $x$, then $f(x)< f(y)$ for all\n$x0$, but then $\\lim_{x \\to -\\infty} f(x) \\leq f(y) < 0$.)\n\nFrom the inequality $f'''(x) \\leq f(x)$ we obtain\n\\[\nf'' f'''(x) \\leq f''(x) f(x) < f''(x) f(x) + f'(x)^2\n\\]\nsince $f'(x)$ is positive. Applying the fact to the difference between the right and left sides,\nwe get\n\\begin{equation}\n\\frac{1}{2} (f''(x))^2 < f(x) f'(x).\n\\end{equation}\n\nOn the other hand, since $f(x)$ and $f'''(x)$ are both positive for all $x$,\nwe have\n\\[\n2f'(x) f''(x) < 2f'(x)f''(x) + 2f(x) f'''(x).\n\\]\nApplying the fact to the difference between the sides yields\n\\begin{equation}\nf'(x)^2 \\leq 2f(x) f''(x).\n\\end{equation}\nCombining (1) and (2), we obtain\n\\begin{align*}\n\\frac{1}{2} \\left( \\frac{f'(x)^2}{2f(x)} \\right)^2\n&< \\frac{1}{2} (f''(x))^2 \\\\\n&< f(x) f'(x),\n\\end{align*}\nor $(f'(x))^3 < 8 f(x)^3$. We conclude $f'(x) < 2f(x)$, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2000_a2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2000_a2 :\n ∀ N : ℕ, ∃ n : ℕ, n > N ∧ ∃ i : Fin 6 → ℕ, n = (i 0)^2 + (i 1)^2 ∧\n n + 1 = (i 2)^2 + (i 3)^2 ∧ n + 2 = (i 4)^2 + (i 5)^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that there exist infinitely many integers $n$ such that $n, n+1, n+2$ are each the sum of the squares of two integers. \n\\begin{proof}\n It is well-known that the equation $x^2-2y^2=1$ has infinitely\nmany solutions (the so-called ``Pell'' equation). Thus setting\n$n=2y^2$ (so that $n=y^2+y^2$, $n+1=x^2+0^2$, $n+2=x^2+1^2$)\nyields infinitely many $n$ with the desired property.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2001_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2001_a5 :\n ∃! a : ℕ × ℕ, a.1 > 0 ∧ a.2 > 0 ∧ a.1^(a.2+1) - (a.1+1)^a.2 = 2001 := sorry", "formal_proof": null, "informal_stmt": "Prove that there are unique positive integers $a, n$ such that $a^{n+1}-(a+1)^n=2001$.\n\\begin{proof}\n Suppose $a^{n+1} - (a+1)^n = 2001$.\nNotice that $a^{n+1} + [(a+1)^n - 1]$ is a multiple of $a$; thus\n$a$ divides $2002 = 2 \\times 7 \\times 11 \\times 13$.\n\nSince $2001$ is divisible by 3, we must have $a \\equiv 1 \\pmod{3}$,\notherwise one of $a^{n+1}$ and $(a+1)^n$ is a multiple of 3 and the\nother is not, so their difference cannot be divisible by 3. Now\n$a^{n+1} \\equiv 1 \\pmod{3}$, so we must have $(a+1)^n \\equiv 1\n\\pmod{3}$, which forces $n$ to be even, and in particular at least 2.\n\nIf $a$ is even, then $a^{n+1} - (a+1)^n \\equiv -(a+1)^n \\pmod{4}$.\nSince $n$ is even, $-(a+1)^n \\equiv -1 \\pmod{4}$. Since $2001 \\equiv 1\n\\pmod{4}$, this is impossible. Thus $a$ is odd, and so must divide\n$1001 = 7 \\times 11 \\times 13$. Moreover, $a^{n+1} - (a+1)^n \\equiv a\n\\pmod{4}$, so $a \\equiv 1 \\pmod{4}$.\n\nOf the divisors of $7 \\times 11 \\times 13$, those congruent to 1 mod 3\nare precisely those not divisible by 11 (since 7 and 13 are both\ncongruent to 1 mod 3). Thus $a$ divides $7 \\times 13$. Now\n$a \\equiv 1 \\pmod{4}$ is only possible if $a$ divides $13$.\n\nWe cannot have $a=1$, since $1 - 2^n \\neq 2001$ for any $n$. Thus\nthe only possibility is $a = 13$. One easily checks that $a=13, n=2$ is a\nsolution; all that remains is to check that no other $n$ works. In fact,\nif $n > 2$, then $13^{n+1} \\equiv 2001 \\equiv 1 \\pmod{8}$.\nBut $13^{n+1} \\equiv 13 \\pmod{8}$ since $n$ is even, contradiction.\nThus $a=13, n=2$ is the unique solution.\n\nNote: once one has that $n$ is even, one can use that $2002\n=a^{n+1} + 1 - (a+1)^n$ is divisible by $a+1$ to rule out cases.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2010_a4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2010_a4 (n : ℕ) :\n ¬ Nat.Prime (10^10^10^n + 10^10^n + 10^n - 1) := sorry", "formal_proof": null, "informal_stmt": "Prove that for each positive integer $n$, the number $10^{10^{10^n}}+10^{10^n}+10^n-1$ is not prime.\n\\begin{proof}\n Put\n\\[\nN = 10^{10^{10^n}} + 10^{10^n} + 10^n - 1.\n\\]\nWrite $n = 2^m k$ with $m$ a nonnegative integer and $k$ a positive odd integer.\nFor any nonnegative integer $j$,\n\\[\n10^{2^m j} \\equiv (-1)^j \\pmod{10^{2^m} + 1}.\n\\]\nSince $10^n \\geq n \\geq 2^m \\geq m+1$, $10^n$ is divisible by $2^n$ and hence by $2^{m+1}$,\nand similarly $10^{10^n}$ is divisible by $2^{10^n}$ and hence by $2^{m+1}$. It follows that\n\\[\nN \\equiv 1 + 1 + (-1) + (-1) \\equiv 0 \\pmod{10^{2^m} + 1}.\n\\]\nSince $N \\geq 10^{10^n} > 10^n + 1 \\geq 10^{2^m} + 1$, it follows that $N$ is composite.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2014_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2014_a5 (P : ℕ → Polynomial ℤ)\n (hP : ∀ n, P n = ∑ i : Fin n, (n+1) * Polynomial.X ^ n) :\n ∀ (j k : ℕ), j ≠ k → IsCoprime (P j) (P k) := sorry", "formal_proof": null, "informal_stmt": "Let\n$P_n(x)=1+2 x+3 x^2+\\cdots+n x^{n-1} .$ Prove that the polynomials $P_j(x)$ and $P_k(x)$ are relatively prime for all positive integers $j$ and $k$ with $j \\neq k$.\n\\begin{proof}\n Suppose to the contrary that there exist positive integers $i \\neq j$ and a complex number $z$ such that $P_i(z) = P_j(z) = 0$. Note that $z$ cannot be a nonnegative real number or else $P_i(z), P_j(z) > 0$; we may put $w = z^{-1} \\neq 0,1$. For $n \\in \\{i+1,j+1\\}$ we compute that\n\\[\nw^n = n w - n + 1,\n\\qquad \\overline{w}^n = n \\overline{w} - n + 1;\n\\]\nnote crucially that these equations also hold for $n \\in \\{0,1\\}$.\nTherefore, the function $f: [0, +\\infty) \\to \\mathbb{R}$ given by\n\\[\nf(t) = \\left| w \\right|^{2t} - t^2 \\left| w \\right|^2 + 2t(t-1)\\mathrm{Re}(w) - (t-1)^2\n\\]\nsatisfies $f(t) = 0$ for $t \\in \\{0,1,i+1,j+1\\}$. On the other hand, for all $t \\geq 0$ we have\n\\[\nf'''(t) = (2 \\log \\left| w \\right|)^3 \\left| w \\right|^{2t} > 0,\n\\]\nso by Rolle's theorem, the equation $f^{(3-k)}(t) = 0$ has at most $k$ distinct solutions for $k=0,1,2,3$. This yields the desired contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2017_b3", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2017_b3 (f : ℝ → ℝ) (c : ℕ → ℝ)\n (hf : f = λ x => (∑' (i : ℕ), (c i) * x^i))\n (hc : ∀ n, c n = 0 ∨ c n = 1)\n (hf1 : f (2/3) = 3/2) :\n Irrational (f (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f(x)=\\sum_{i=0}^{\\infty} c_{i} x^{i}$ is a power series for which each coefficient $c_{i}$ is 0 or 1 . Show that if $f(2 / 3)=3 / 2$, then $f(1 / 2)$ must be irrational.\n\\begin{proof}\n Suppose by way of contradiction that $f(1/2)$ is rational. Then $\\sum_{i=0}^{\\infty} c_i 2^{-i}$ is the binary expansion of a rational number, and hence must be eventually periodic; that is, there exist some integers $m,n$ such that\n$c_i = c_{m+i}$ for all $i \\geq n$. We may then write\n\\[\nf(x) = \\sum_{i=0}^{n-1} c_i x^i + \\frac{x^n}{1-x^m} \\sum_{i=0}^{m-1} c_{n+i} x^i.\n\\]\nEvaluating at $x = 2/3$, we may equate $f(2/3) = 3/2$ with \n\\[\n\\frac{1}{3^{n-1}} \\sum_{i=0}^{n-1} c_i 2^i 3^{n-i-1} + \\frac{2^n 3^m}{3^{n+m-1}(3^m-2^m)} \\sum_{i=0}^{m-1} c_{n+i} 2^i 3^{m-1-i};\n\\]\nsince all terms on the right-hand side have odd denominator, the same must be true of the sum, a contradiction.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_a5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_a5 (f : ℝ → ℝ) (hf : ContDiff ℝ ⊤ f)\n (hf0 : f 0 = 0) (hf1 : f 1 = 1) (hf2 : ∀ x, f x ≥ 0) :\n ∃ (n : ℕ) (x : ℝ), iteratedDeriv n f x = 0 := sorry", "formal_proof": null, "informal_stmt": "Let $f: \\mathbb{R} \\rightarrow \\mathbb{R}$ be an infinitely differentiable function satisfying $f(0)=0, f(1)=1$, and $f(x) \\geq 0$ for all $x \\in$ $\\mathbb{R}$. Show that there exist a positive integer $n$ and a real number $x$ such that $f^{(n)}(x)<0$.\n\\begin{proof}\n Call a function $f\\colon \\mathbb{R} \\to \\mathbb{R}$ \\textit{ultraconvex} if $f$ is infinitely differentiable and $f^{(n)}(x) \\geq 0$ for all $n \\geq 0$ and all $x \\in \\mathbb{R}$, where $f^{(0)}(x) = f(x)$;\nnote that if $f$ is ultraconvex, then so is $f'$.\nDefine the set\n\\[\nS = \\{ f :\\thinspace \\mathbb{R} \\to \\mathbb{R} \\,|\\,f \\text{ ultraconvex and } f(0)=0\\}.\n\\]\nFor $f \\in S$, we must have $f(x) = 0$ for all $x < 0$: if $f(x_0) > 0$ for some $x_0 < 0$, then\nby the mean value theorem there exists $x \\in (0,x_0)$ for which $f'(x) = \\frac{f(x_0)}{x_0} < 0$.\nIn particular, $f'(0) = 0$, so $f' \\in S$ also.\n\nWe show by induction that for all $n \\geq 0$,\n\\[\nf(x) \\leq \\frac{f^{(n)}(1)}{n!} x^n \\qquad (f \\in S, x \\in [0,1]).\n\\]\nWe induct with base case $n=0$, which holds because any $f \\in S$ is nondecreasing. Given the claim for $n=m$,\nwe apply the induction hypothesis to $f' \\in S$ to see that\n\\[\nf'(t) \\leq \\frac{f^{(n+1)}(1)}{n!} t^n \\qquad (t \\in [0,1]),\n\\]\nthen integrate both sides from $0$ to $x$ to conclude.\n\nNow for $f \\in S$, we have $0 \\leq f(1) \\leq \\frac{f^{(n)}(1)}{n!}$ for all $n \\geq 0$. \nOn the other hand, by Taylor's theorem with remainder,\n\\[\nf(x) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}(x-1)^k \\qquad (x \\geq 1).\n\\]\nApplying this with $x=2$, we obtain $f(2) \\geq \\sum_{k=0}^n \\frac{f^{(k)}(1)}{k!}$ for all $n$;\nthis implies that $\\lim_{n\\to\\infty} \\frac{f^{(n)}(1)}{n!} = 0$.\nSince $f(1) \\leq \\frac{f^{(n)}(1)}{n!}$, we must have $f(1) = 0$.\n\nFor $f \\in S$, we proved earlier that $f(x) = 0$ for all $x\\leq 0$, as well as for $x=1$. Since\nthe function $g(x) = f(cx)$ is also ultraconvex for $c>0$, we also have $f(x) = 0$ for all $x>0$;\nhence $f$ is identically zero.\n\nTo sum up, if $f\\colon \\mathbb{R} \\to \\mathbb{R}$ is infinitely differentiable, $f(0)=0$, and $f(1) = 1$,\nthen $f$ cannot be ultraconvex. This implies the desired result.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_b2", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b2 (n : ℕ) (hn : n > 0) (f : ℕ → ℂ → ℂ)\n (hf : ∀ n : ℕ, f n = λ (z : ℂ) => (∑ i : Fin n, (n-i)* z^(i : ℕ))) :\n ¬ (∃ z : ℂ, ‖z‖ ≤ 1 ∧ f n z = 0) := sorry", "formal_proof": null, "informal_stmt": "Let $n$ be a positive integer, and let $f_{n}(z)=n+(n-1) z+$ $(n-2) z^{2}+\\cdots+z^{n-1}$. Prove that $f_{n}$ has no roots in the closed unit disk $\\{z \\in \\mathbb{C}:|z| \\leq 1\\}$.\n\\begin{proof}\n Note first that $f_n(1) > 0$, so $1$ is not a root of $f_n$.\nNext, note that\n\\[\n(z-1)f_n(z) = z^n + \\cdots + z - n;\n\\]\nhowever, for $\\left| z \\right| \\leq 1$, we have \n$\\left| z^n + \\cdots + z \\right| \\leq n$ by the triangle inequality;\nequality can only occur if $z,\\dots,z^n$ have norm 1 and the same argument, which only happens for $z=1$.\nThus there can be no root of $f_n$ with $|z| \\leq 1$.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2018_b4", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2018_b4 (a : ℝ) (x : ℕ → ℝ) (hx0 : x 0 = a)\n (hx1 : x 1 = a)\n (hxn : ∀ n : ℕ, n ≥ 2 → x (n+1) = 2*(x n)*(x (n-1)) - x (n-2))\n (h : ∃ n, x n = 0) :\n ∃ c, Function.Periodic x c := sorry", "formal_proof": null, "informal_stmt": "Given a real number $a$, we define a sequence by $x_{0}=1$, $x_{1}=x_{2}=a$, and $x_{n+1}=2 x_{n} x_{n-1}-x_{n-2}$ for $n \\geq 2$. Prove that if $x_{n}=0$ for some $n$, then the sequence is periodic.\n\\begin{proof}\n We first rule out the case $|a|>1$. In this case, we prove that $|x_{n+1}| \\geq |x_n|$ for all $n$, meaning that we cannot have $x_n = 0$. We proceed by induction; the claim is true for $n=0,1$ by hypothesis. To prove the claim for $n \\geq 2$, write\n\\begin{align*}\n|x_{n+1}| &= |2x_nx_{n-1}-x_{n-2}| \\\\\n&\\geq 2|x_n||x_{n-1}|-|x_{n-2}| \\\\\n&\\geq |x_n|(2|x_{n-1}|-1) \\geq |x_n|,\n\\end{align*} \nwhere the last step follows from $|x_{n-1}| \\geq |x_{n-2}| \\geq \\cdots \\geq |x_0| = 1$.\n\nWe may thus assume hereafter that $|a|\\leq 1$. We can then write $a = \\cos b$ for some $b \\in [0,\\pi]$. \nLet $\\{F_n\\}$ be the Fibonacci sequence, defined as usual by $F_1=F_2=1$ and $F_{n+1}=F_n+F_{n-1}$. We show by induction that\n\\[\nx_n = \\cos(F_n b) \\qquad (n \\geq 0).\n\\]\nIndeed, this is true for $n=0,1,2$; given that it is true for $n \\leq m$, then\n\\begin{align*}\n2x_mx_{m-1}&=2\\cos(F_mb)\\cos(F_{m-1}b) \\\\\n&= \\cos((F_m-F_{m-1})b)+\\cos((F_m+F_{m-1})b) \\\\\n&= \\cos(F_{m-2}b)+\\cos(F_{m+1}b)\n\\end{align*}\nand so \n$x_{m+1} = 2x_mx_{m-1}-x_{m-2} = \\cos(F_{m+1}b)$. This completes the induction.\n\n\nSince $x_n = \\cos(F_n b)$, if $x_n=0$ for some $n$ then $F_n b = \\frac{k}{2} \\pi$ for some odd integer $k$. In particular, we can write $b = \\frac{c}{d}(2\\pi)$ where $c = k$ and $d = 4F_n$ are integers.\n\n\nLet $x_n$ denote the pair $(F_n,F_{n+1})$, where each entry in this pair is viewed as an element of $\\mathbb{Z}/d\\mathbb{Z}$. Since there are only finitely many possibilities for $x_n$, there must be some $n_2>n_1$ such that $x_{n_1}=x_{n_2}$. Now $x_n$ uniquely determines both $x_{n+1}$ and $x_{n-1}$, and it follows that the sequence $\\{x_n\\}$ is periodic: for $\\ell = n_2-n_1$, $x_{n+\\ell} = x_n$ for all $n \\geq 0$. In particular, $F_{n+\\ell} \\equiv F_n \\pmod{d}$ for all $n$. But then $\\frac{F_{n+\\ell}c}{d}-\\frac{F_n c}{d}$ is an integer, and so\n\\begin{align*}\nx_{n+\\ell} &= \\cos\\left(\\frac{F_{n+\\ell}c}{d}(2\\pi)\\right)\\\\\n& = \\cos\\left(\\frac{F_n c}{d}(2\\pi)\\right) = x_n\n\\end{align*}\nfor all $n$. Thus the sequence $\\{x_n\\}$ is periodic, as desired.\n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Putnam_exercise_2020_b5", "source": "Putnam.lean", "header": "import Mathlib\n\nopen scoped BigOperators\n", "formal_statement": "theorem Putnam_exercise_2020_b5 (z : Fin 4 → ℂ) (hz0 : ∀ n, ‖z n‖ < 1)\n (hz1 : ∀ n : Fin 4, z n ≠ 1) :\n 3 - z 0 - z 1 - z 2 - z 3 + (z 0) * (z 1) * (z 2) * (z 3) ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "For $j \\in\\{1,2,3,4\\}$, let $z_{j}$ be a complex number with $\\left|z_{j}\\right|=1$ and $z_{j} \\neq 1$. Prove that $3-z_{1}-z_{2}-z_{3}-z_{4}+z_{1} z_{2} z_{3} z_{4} \\neq 0 .$\n\\begin{proof}\n It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1.\n\nTo this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \n\\[\nf(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2.\n\\]\n A routine calculation shows that \n\\begin{align*}\nf(\\alpha, \\beta, \\gamma)&=\n10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\\n&\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\\n&\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha).\n\\end{align*}\nSince the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \n\\begin{align*}\n\\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &=\n6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\\n&=\n24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right)\n\\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right).\n\\end{align*}\nHence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \n\\[\nf = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2;\n\\]\nsince $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$. \n\\end{proof}", "informal_proof": "It will suffice to show that for any $z_1, z_2, z_3, z_4 \\in \\mathbb{C}$ of modulus 1 such that $|3-z_1-z_2-z_3-z_4| = |z_1z_2z_3z_4|$, at least one of $z_1, z_2, z_3$ is equal to 1. To this end, let $z_1=e^{\\alpha i}, z_2=e^{\\beta i}, z_3=e^{\\gamma i}$ and \\[ f(\\alpha, \\beta, \\gamma)=|3-z_1-z_2-z_3|^2-|1-z_1z_2z_3|^2. \\] A routine calculation shows that \\begin{align*} f(\\alpha, \\beta, \\gamma)&= 10 - 6\\cos(\\alpha) - 6\\cos(\\beta) - 6\\cos(\\gamma) \\\\ &\\quad + 2\\cos(\\alpha + \\beta + \\gamma) + 2\\cos(\\alpha - \\beta) \\\\ &\\quad + 2\\cos(\\beta - \\gamma) + 2\\cos(\\gamma - \\alpha). \\end{align*} Since the function $f$ is continuously differentiable, and periodic in each variable, $f$ has a maximum and a minimum and it attains these values only at points where $\\nabla f=(0,0,0)$. A routine calculation now shows that \\begin{align*} \\frac{\\partial f}{\\partial \\alpha} + \\frac{\\partial f}{\\partial \\beta} + \\frac{\\partial f}{\\partial \\gamma} &= 6(\\sin(\\alpha) +\\sin(\\beta)+\\sin(\\gamma)- \\sin(\\alpha + \\beta + \\gamma)) \\\\ &= 24\\sin\\left(\\frac{\\alpha+\\beta}{2}\\right) \\sin\\left(\\frac{\\beta+\\gamma}{2}\\right) \\sin\\left(\\frac{\\gamma+\\alpha}{2}\\right). \\end{align*} Hence every critical point of $f$ must satisfy one of $z_1z_2=1$, $z_2z_3=1$, or $z_3z_1=1$. By symmetry, let us assume that $z_1z_2=1$. Then \\[ f = |3-2\\mathrm{Re}(z_1)-z_3|^2-|1-z_3|^2; \\] since $3-2\\mathrm{Re}(z_1)\\ge 1$, $f$ is nonnegative and can be zero only if the real part of $z_1$, and hence also $z_1$ itself, is equal to $1$."} +{"name": "Rudin_exercise_1_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_1a\n (x : ℝ) (y : ℚ) :\n ( Irrational x ) -> Irrational ( x + y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $r+x$ is irrational.\n\\begin{proof}\n If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_1b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_1b\n(x : ℝ)\n(y : ℚ)\n(h : y ≠ 0)\n: ( Irrational x ) -> Irrational ( x * y ) := sorry", "formal_proof": null, "informal_stmt": "If $r$ is rational $(r \\neq 0)$ and $x$ is irrational, prove that $rx$ is irrational.\n\\begin{proof}\n If $r x$ were rational, then $x=\\frac{r x}{r}$ would also be rational.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_2 : ¬ ∃ (x : ℚ), ( x ^ 2 = 12 ) := sorry", "formal_proof": null, "informal_stmt": "Prove that there is no rational number whose square is $12$.\n\\begin{proof}\n Suppose $m^2=12 n^2$, where $m$ and $n$ have no common factor. It follows that $m$ must be even, and therefore $n$ must be odd. Let $m=2 r$. Then we have $r^2=3 n^2$, so that $r$ is also odd. Let $r=2 s+1$ and $n=2 t+1$. Then\n$$\n4 s^2+4 s+1=3\\left(4 t^2+4 t+1\\right)=12 t^2+12 t+3,\n$$\nso that\n$$\n4\\left(s^2+s-3 t^2-3 t\\right)=2 .\n$$\nBut this is absurd, since 2 cannot be a multiple of 4 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_4\n(α : Type*) [PartialOrder α]\n(s : Set α)\n(x y : α)\n(h₀ : Set.Nonempty s)\n(h₁ : x ∈ lowerBounds s)\n(h₂ : y ∈ upperBounds s)\n: x ≤ y := sorry", "formal_proof": null, "informal_stmt": "Let $E$ be a nonempty subset of an ordered set; suppose $\\alpha$ is a lower bound of $E$ and $\\beta$ is an upper bound of $E$. Prove that $\\alpha \\leq \\beta$.\n\\begin{proof}\nSince $E$ is nonempty, there exists $x \\in E$. Then by definition of lower and upper bounds we have $\\alpha \\leq x \\leq \\beta$, and hence by property $i i$ in the definition of an ordering, we have $\\alpha<\\beta$ unless $\\alpha=x=\\beta$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_5 (A minus_A : Set ℝ) (hA : A.Nonempty)\n (hA_bdd_below : BddBelow A) (hminus_A : minus_A = {x | -x ∈ A}) :\n Min A = Max minus_A := sorry", "formal_proof": null, "informal_stmt": "Let $A$ be a nonempty set of real numbers which is bounded below. Let $-A$ be the set of all numbers $-x$, where $x \\in A$. Prove that $\\inf A=-\\sup (-A)$.\n\\begin{proof}\n We need to prove that $-\\sup (-A)$ is the greatest lower bound of $A$. For brevity, let $\\alpha=-\\sup (-A)$. We need to show that $\\alpha \\leq x$ for all $x \\in A$ and $\\alpha \\geq \\beta$ if $\\beta$ is any lower bound of $A$.\n\nSuppose $x \\in A$. Then, $-x \\in-A$, and, hence $-x \\leq \\sup (-A)$. It follows that $x \\geq-\\sup (-A)$, i.e., $\\alpha \\leq x$. Thus $\\alpha$ is a lower bound of $A$.\n\nNow let $\\beta$ be any lower bound of $A$. This means $\\beta \\leq x$ for all $x$ in $A$. Hence $-x \\leq-\\beta$ for all $x \\in A$, which says $y \\leq-\\beta$ for all $y \\in-A$. This means $-\\beta$ is an upper bound of $-A$. Hence $-\\beta \\geq \\sup (-A)$ by definition of sup, i.e., $\\beta \\leq-\\sup (-A)$, and so $-\\sup (-A)$ is the greatest lower bound of $A$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_8", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_8 : ¬ ∃ (r : ℂ → ℂ → Prop), IsLinearOrder ℂ r := sorry", "formal_proof": null, "informal_stmt": "Prove that no order can be defined in the complex field that turns it into an ordered field.\n\\begin{proof}\n By Part (a) of Proposition $1.18$, either $i$ or $-i$ must be positive. Hence $-1=i^2=(-i)^2$ must be positive. But then $1=(-1)^2$, must also be positive, and this contradicts Part $(a)$ of Proposition 1.18, since 1 and $-1$ cannot both be positive.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_11a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_11a (z : ℂ) :\n ∃ (r : ℝ) (w : ℂ), norm w = 1 ∧ z = r * w := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number, prove that there exists an $r\\geq 0$ and a complex number $w$ with $| w | = 1$ such that $z = rw$.\n\\begin{proof}\n If $z=0$, we take $r=0, w=1$. (In this case $w$ is not unique.) Otherwise we take $r=|z|$ and $w=z /|z|$, and these choices are unique, since if $z=r w$, we must have $r=r|w|=|r w|=|z|, z / r$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_12 (n : ℕ) (f : ℕ → ℂ) :\n norm (∑ i ∈ range n, f i) ≤ ∑ i ∈ range n, norm (f i) := sorry", "formal_proof": null, "informal_stmt": "If $z_1, \\ldots, z_n$ are complex, prove that $|z_1 + z_2 + \\ldots + z_n| \\leq |z_1| + |z_2| + \\cdots + |z_n|$.\n\\begin{proof}\n We can apply the case $n=2$ and induction on $n$ to get\n$$\n\\begin{aligned}\n\\left|z_1+z_2+\\cdots z_n\\right| &=\\left|\\left(z_1+z_2+\\cdots+z_{n-1}\\right)+z_n\\right| \\\\\n& \\leq\\left|z_1+z_2+\\cdots+z_{n-1}\\right|+\\left|z_n\\right| \\\\\n& \\leq\\left|z_1\\right|+\\left|z_2\\right|+\\cdots+\\left|z_{n-1}\\right|+\\left|z_n\\right|\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_13 (x y : ℂ) :\n |(norm x) - (norm y)| ≤ norm (x - y) := sorry", "formal_proof": null, "informal_stmt": "If $x, y$ are complex, prove that $||x|-|y|| \\leq |x-y|$.\n\\begin{proof}\n Since $x=x-y+y$, the triangle inequality gives\n$$\n|x| \\leq|x-y|+|y|\n$$\nso that $|x|-|y| \\leq|x-y|$. Similarly $|y|-|x| \\leq|x-y|$. Since $|x|-|y|$ is a real number we have either ||$x|-| y||=|x|-|y|$ or ||$x|-| y||=|y|-|x|$. In either case, we have shown that ||$x|-| y|| \\leq|x-y|$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_14", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_14\n (z : ℂ) (h : norm z = 1)\n : (norm (1 + z)) ^ 2 + (norm (1 - z)) ^ 2 = 4 := sorry", "formal_proof": null, "informal_stmt": "If $z$ is a complex number such that $|z|=1$, that is, such that $z \\bar{z}=1$, compute $|1+z|^{2}+|1-z|^{2}$.\n\\begin{proof}\n $|1+z|^2=(1+z)(1+\\bar{z})=1+\\bar{z}+z+z \\bar{z}=2+z+\\bar{z}$. Similarly $|1-z|^2=(1-z)(1-\\bar{z})=1-z-\\bar{z}+z \\bar{z}=2-z-\\bar{z}$. Hence\n$$\n|1+z|^2+|1-z|^2=4 \\text {. }\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_16a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_16a\n (n : ℕ)\n (d r : ℝ)\n (x y z : EuclideanSpace ℝ (Fin n)) -- R^n\n (h₁ : n ≥ 3)\n (h₂ : ‖x - y‖ = d)\n (h₃ : d > 0)\n (h₄ : r > 0)\n (h₅ : 2 * r > d)\n : Set.Infinite {z : EuclideanSpace ℝ (Fin n) | ‖z - x‖ = r ∧ ‖z - y‖ = r} := sorry", "formal_proof": null, "informal_stmt": "Suppose $k \\geq 3, x, y \\in \\mathbb{R}^k, |x - y| = d > 0$, and $r > 0$. Prove that if $2r > d$, there are infinitely many $z \\in \\mathbb{R}^k$ such that $|z-x|=|z-y|=r$.\n\\begin{proof}\n (a) Let w be any vector satisfying the following two equations:\n$$\n\\begin{aligned}\n\\mathbf{w} \\cdot(\\mathbf{x}-\\mathbf{y}) &=0, \\\\\n|\\mathbf{w}|^2 &=r^2-\\frac{d^2}{4} .\n\\end{aligned}\n$$\nFrom linear algebra it is known that all but one of the components of a solution $\\mathbf{w}$ of the first equation can be arbitrary. The remaining component is then uniquely determined. Also, if $w$ is any non-zero solution of the first equation, there is a unique positive number $t$ such that $t$ w satisfies both equations. (For example, if $x_1 \\neq y_1$, the first equation is satisfied whenever\n$$\nz_1=\\frac{z_2\\left(x_2-y_2\\right)+\\cdots+z_k\\left(x_k-y_k\\right)}{y_1-x_1} .\n$$\nIf $\\left(z_1, z_2, \\ldots, z_k\\right)$ satisfies this equation, so does $\\left(t z_1, t z_2, \\ldots, t z_k\\right)$ for any real number $t$.) Since at least two of these components can vary independently, we can find a solution with these components having any prescribed ratio. This ratio does not change when we multiply by the positive number $t$ to obtain a solution of both equations. Since there are infinitely many ratios, there are infinitely many distinct solutions. For each such solution $\\mathbf{w}$ the vector $\\mathbf{z}=$ $\\frac{1}{2} \\mathrm{x}+\\frac{1}{2} \\mathrm{y}+\\mathrm{w}$ is a solution of the required equation. For\n$$\n\\begin{aligned}\n|\\mathrm{z}-\\mathbf{x}|^2 &=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}+\\mathbf{w}\\right|^2 \\\\\n&=\\left|\\frac{\\mathbf{y}-\\mathbf{x}}{2}\\right|^2+2 \\mathbf{w} \\cdot \\frac{\\mathbf{x}-\\mathbf{y}}{2}+|\\mathbf{w}|^2 \\\\\n&=\\frac{d^2}{4}+0+r^2-\\frac{d^2}{4} \\\\\n&=r^2\n\\end{aligned}\n$$\nand a similar relation holds for $|z-y|^2$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_17\n (n : ℕ)\n (x y : EuclideanSpace ℝ (Fin n)) -- R^n\n : ‖x + y‖^2 + ‖x - y‖^2 = 2*‖x‖^2 + 2*‖y‖^2 := sorry", "formal_proof": null, "informal_stmt": "Prove that $|\\mathbf{x}+\\mathbf{y}|^{2}+|\\mathbf{x}-\\mathbf{y}|^{2}=2|\\mathbf{x}|^{2}+2|\\mathbf{y}|^{2}$ if $\\mathbf{x} \\in R^{k}$ and $\\mathbf{y} \\in R^{k}$.\n\\begin{proof}\n The proof is a routine computation, using the relation\n$$\n|x \\pm y|^2=(x \\pm y) \\cdot(x \\pm y)=|x|^2 \\pm 2 x \\cdot y+|y|^2 .\n$$\nIf $\\mathrm{x}$ and $\\mathrm{y}$ are the sides of a parallelogram, then $\\mathrm{x}+\\mathrm{y}$ and $\\mathbf{x}-\\mathrm{y}$ are its diagonals. Hence this result says that the sum of the squares on the diagonals of a parallelogram equals the sum of the squares on the sides.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_18a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18a\n (n : ℕ)\n (h : n > 1)\n (x : EuclideanSpace ℝ (Fin n)) -- R^n\n : ∃ (y : EuclideanSpace ℝ (Fin n)), y ≠ 0 ∧ (inner ℝ x y) = (0 : ℝ) := sorry", "formal_proof": null, "informal_stmt": "If $k \\geq 2$ and $\\mathbf{x} \\in R^{k}$, prove that there exists $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n If $\\mathbf{x}$ has any components equal to 0 , then $\\mathbf{y}$ can be taken to have the corresponding components equal to 1 and all others equal to 0 . If all the components of $\\mathbf{x}$ are nonzero, $\\mathbf{y}$ can be taken as $\\left(-x_2, x_1, 0, \\ldots, 0\\right)$. This is, of course, not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_18b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_18b\n : ¬ ∀ (x : ℝ), ∃ (y : ℝ), y ≠ 0 ∧ x * y = 0 := sorry", "formal_proof": null, "informal_stmt": "If $k = 1$ and $\\mathbf{x} \\in R^{k}$, prove that there does not exist $\\mathbf{y} \\in R^{k}$ such that $\\mathbf{y} \\neq 0$ but $\\mathbf{x} \\cdot \\mathbf{y}=0$\n\\begin{proof}\n Not true when $k=1$, since the product of two nonzero real numbers is nonzero.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_1_19", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_1_19\n (n : ℕ)\n (a b c x : EuclideanSpace ℝ (Fin n))\n (r : ℝ)\n (h₁ : r > 0)\n (h₂ : 3 • c = 4 • b - a)\n (h₃ : 3 * r = 2 * ‖x - b‖)\n : ‖x - a‖ = 2 * ‖x - b‖ ↔ ‖x - c‖ = r := sorry", "formal_proof": null, "informal_stmt": "Suppose $a, b \\in R^k$. Find $c \\in R^k$ and $r > 0$ such that $|x-a|=2|x-b|$ if and only if $| x - c | = r$. Prove that $3c = 4b - a$ and $3r = 2 |b - a|$.\n\\begin{proof}\n Since the solution is given to us, all we have to do is verify it, i.e., we need to show that the equation\n$$\n|\\mathrm{x}-\\mathrm{a}|=2|\\mathrm{x}-\\mathrm{b}|\n$$\nis equivalent to $|\\mathrm{x}-\\mathbf{c}|=r$, which says\n$$\n\\left|\\mathbf{x}-\\frac{4}{3} \\mathbf{b}+\\frac{1}{3} \\mathbf{a}\\right|=\\frac{2}{3}|\\mathbf{b}-\\mathbf{a}| .\n$$\nIf we square both sides of both equations, we an equivalent pair of equations, the first of which reduces to\n$$\n3|\\mathbf{x}|^2+2 \\mathbf{a} \\cdot \\mathbf{x}-8 \\mathbf{b} \\cdot \\mathbf{x}-|\\mathbf{a}|^2+4|\\mathbf{b}|^2=0,\n$$\nand the second of which reduces to this equation divided by 3 . Hence these equations are indeed equivalent.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_19a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_19a {X : Type*} [MetricSpace X]\n (A B : Set X) (hA : IsClosed A) (hB : IsClosed B) (hAB : Disjoint A B) :\n SeparatedNhds A B := sorry", "formal_proof": null, "informal_stmt": "If $A$ and $B$ are disjoint closed sets in some metric space $X$, prove that they are separated.\n\\begin{proof}\n We are given that $A \\cap B=\\varnothing$. Since $A$ and $B$ are closed, this means $A \\cap \\bar{B}=\\varnothing=\\bar{A} \\cap B$, which says that $A$ and $B$ are separated.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_24 {X : Type*} [MetricSpace X]\n (hX : ∀ (A : Set X), Infinite A → ∃ (x : X), x ∈ closure A) :\n SeparableSpace X := sorry", "formal_proof": null, "informal_stmt": "Let $X$ be a metric space in which every infinite subset has a limit point. Prove that $X$ is separable.\n\\begin{proof}\n We observe that if the process of constructing $x_j$ did not terminate, the result would be an infinite set of points $x_j, j=1,2, \\ldots$, such that $d\\left(x_i, x_j\\right) \\geq \\delta$ for $i \\neq j$. It would then follow that for any $x \\in X$, the open ball $B_{\\frac{\\delta}{2}}(x)$ contains at most one point of the infinite set, hence that no point could be a limit point of this set, contrary to hypothesis. Hence $X$ is totally bounded, i.e., for each $\\delta>0$ there is a finite set $x_1, \\ldots, x_{N\\delta}$such that $X=\\bigcup_{j / 1}^{N\\delta} B_\\delta\\left(x_j\\right)$\n\nLet $x_{n_1}, \\ldots, x_{n N_n}$ be such that $X=\\bigcup_{j / 1}^{N_n} B_{\\frac{1}{n}}\\left(x_{n j}\\right), n=1,2, \\ldots$ We claim that $\\left\\{x_{n j}: 1 \\leq j \\leq N_n ; n=1,2, \\ldots\\right\\}$ is a countable dense subset of $X$. Indeed\n25\nif $x \\in X$ and $\\delta>0$, then $x \\in B_{\\frac{1}{n}}\\left(x_{n j}\\right)$ for some $x_{n j}$ for some $n>\\frac{1}{\\delta}$, and hence $d\\left(x, x_{n j}\\right)<\\delta$. By definition, this means that $\\left\\{x_{n j}\\right\\}$ is dense in $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_25", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_25 {K : Type*} [MetricSpace K] [CompactSpace K] :\n ∃ (B : Set (Set K)), Set.Countable B ∧ IsTopologicalBasis B := sorry", "formal_proof": null, "informal_stmt": "Prove that every compact metric space $K$ has a countable base.\n\\begin{proof}\n $K$ can be covered by a finite union of neighborhoods of radius $1 / n$, and this shows that this implies that $K$ is separable.\n\nIt is not entirely obvious that a metric space with a countable base is separable. To prove this, let $\\left\\{V_n\\right\\}_{n=1}^{\\infty}$ be a countable base, and let $x_n \\in V_n$. The points $V_n$ must be dense in $X$. For if $G$ is any non-empty open set, then $G$ contains $V_n$ for some $n$, and hence $x_n \\in G$. (Thus for a metric space, having a countable base and being separable are equivalent.)\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_27a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27a (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, ¬ Set.Countable (P ∩ E)}) :\n IsClosed P ∧ P = {x | ClusterPt x (𝓟 P)} := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that $P$ is perfect.\n\\begin{proof}\n We see that $E \\cap W$ is at most countable, being a countable union of at-most-countable sets. It remains to show that $P=W^c$, and that $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_27b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_27b (k : ℕ) (E P : Set (EuclideanSpace ℝ (Fin k)))\n (hE : E.Nonempty ∧ ¬ Set.Countable E)\n (hP : P = {x | ∀ U ∈ 𝓝 x, (P ∩ E).Nonempty ∧ ¬ Set.Countable (P ∩ E)}) :\n Set.Countable (E \\ P) := sorry", "formal_proof": null, "informal_stmt": "Suppose $E\\subset\\mathbb{R}^k$ is uncountable, and let $P$ be the set of condensation points of $E$. Prove that at most countably many points of $E$ are not in $P$.\n\\begin{proof}\n If $x \\in W^c$, and $O$ is any neighborhood of $x$, then $x \\in V_n \\subseteq O$ for some n. Since $x \\notin W, V_n \\cap E$ is uncountable. Hence $O$ contains uncountably many points of $E$, and so $x$ is a condensation point of $E$. Thus $x \\in P$, i.e., $W^c \\subseteq P$.\nConversely if $x \\in W$, then $x \\in V_n$ for some $V_n$ such that $V_n \\cap E$ is countable. Hence $x$ has a neighborhood (any neighborhood contained in $V_n$ ) containing at most a countable set of points of $E$, and so $x \\notin P$, i.e., $W \\subseteq P^c$. Hence $P=W^c$.\nIt is clear that $P$ is closed (since its complement $W$ is open), so that we need only show that $P \\subseteq P^{\\prime}$. Hence suppose $x \\in P$, and $O$ is any neighborhood of $x$. (By definition of $P$ this means $O \\cap E$ is uncountable.) We need to show that there is a point $y \\in P \\cap(O \\backslash\\{x\\})$. If this is not the case, i.e., if every point $y$ in $O \\backslash\\{x\\}$ is in $P^c$, then for each such point $y$ there is a set $V_n$ containing $y$ such that $V_n \\cap E$ is at most countable. That would mean that $y \\in W$, i.e., that $O \\backslash\\{x\\}$ is contained in $W$. It would follow that $O \\cap E \\subseteq\\{x\\} \\cup(W \\cap E)$, and so $O \\cap E$ contains at most a countable set of points, contrary to the hypothesis that $x \\in P$. Hence $O$ contains a point of $P$ different from $x$, and so $P \\subseteq P^{\\prime}$. Thus $P$ is perfect.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_28", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_28 (X : Type*) [MetricSpace X] [SeparableSpace X]\n (A : Set X) (hA : IsClosed A) :\n ∃ P₁ P₂ : Set X, A = P₁ ∪ P₂ ∧\n IsClosed P₁ ∧ P₁ = {x | ClusterPt x (𝓟 P₁)} ∧\n Set.Countable P₂ := sorry", "formal_proof": null, "informal_stmt": "Prove that every closed set in a separable metric space is the union of a (possibly empty) perfect set and a set which is at most countable.\n\\begin{proof}\n If $E$ is closed, it contains all its limit points, and hence certainly all its condensation points. Thus $E=P \\cup(E \\backslash P)$, where $P$ is perfect (the set of all condensation points of $E$ ), and $E \\backslash P$ is at most countable.\n\nSince a perfect set in a separable metric space has the same cardinality as the real numbers, the set $P$ must be empty if $E$ is countable. The at-most countable set $E \\backslash P$ cannot be perfect, hence must have isolated points if it is nonempty.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_2_29", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_2_29 (U : Set ℝ) (hU : IsOpen U) :\n ∃ (f : ℕ → Set ℝ), (∀ n, ∃ a b : ℝ, f n = {x | a < x ∧ x < b}) ∧ (∀ n, f n ⊆ U) ∧\n (∀ n m, n ≠ m → f n ∩ f m = ∅) ∧\n U = ⋃ n, f n := sorry", "formal_proof": null, "informal_stmt": "Prove that every open set in $\\mathbb{R}$ is the union of an at most countable collection of disjoint segments.\n\\begin{proof}\n Let $O$ be open. For each pair of points $x \\in O, y \\in O$, we define an equivalence relation $x \\sim y$ by saying $x \\sim y$ if and only if $[\\min (x, y), \\max (x, y)] \\subset$ 0 . This is an equivalence relation, since $x \\sim x([x, x] \\subset O$ if $x \\in O)$; if $x \\sim y$, then $y \\sim x$ (since $\\min (x, y)=\\min (y, x)$ and $\\max (x, y)=\\max (y, x))$; and if $x \\sim y$ and $y \\sim z$, then $x \\sim z([\\min (x, z), \\max (x, z)] \\subseteq[\\min (x, y), \\max (x, y)] \\cup$ $[\\min (y, z), \\max (y, z)] \\subseteq O)$. In fact it is easy to prove that\n$$\n\\min (x, z) \\geq \\min (\\min (x, y), \\min (y, z))\n$$\nand\n$$\n\\max (x, z) \\leq \\max (\\max (x, y), \\max (y, z))\n$$\nIt follows that $O$ can be written as a disjoint union of pairwise disjoint equivalence classes. We claim that each equivalence class is an open interval.\n\nTo show this, for each $x \\in O$; let $A=\\{z:[z, x] \\subseteq O\\}$ and $B=\\{z:[x, z] \\subseteq$ $O\\}$, and let $a=\\inf A, b=\\sup B$. We claim that $(a, b) \\subset O$. Indeed if $az$. Then $z \\in[c, x] \\cup[x, d] \\subseteq O$. We now claim that $(a, b)$ is the equivalence class containing $x$. It is clear that each element of $(a, b)$ is equivalent to $x$ by the way in which $a$ and $b$ were chosen. We need to show that if $z \\notin(a, b)$, then $z$ is not equivalent to $x$. Suppose that $zb$ and $z \\sim x$, then $b$ could not be an upper bound for $B$.\n\nWe have now established that $O$ is a union of pairwise disjoint open intervals. Such a union must be at most countable, since each open interval contains a rational number not in any other interval.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_1a\n (f : ℕ → ℝ)\n (h : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => f n) atTop (𝓝 a))\n : ∃ (a : ℝ), Tendsto (λ (n : ℕ) => |f n|) atTop (𝓝 a) := sorry", "formal_proof": null, "informal_stmt": "Prove that convergence of $\\left\\{s_{n}\\right\\}$ implies convergence of $\\left\\{\\left|s_{n}\\right|\\right\\}$.\n\\begin{proof}\n Let $\\varepsilon>0$. Since the sequence $\\left\\{s_n\\right\\}$ is a Cauchy sequence, there exists $N$ such that $\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. We then have $\\left| |s_m| - |s_n| \\right| \\leq\\left|s_m-s_n\\right|<\\varepsilon$ for all $m>N$ and $n>N$. Hence the sequence $\\left\\{\\left|s_n\\right|\\right\\}$ is also a Cauchy sequence, and therefore must converge.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_2a\n : Tendsto (λ (n : ℝ) => (sqrt (n^2 + n) - n)) atTop (𝓝 (1/2)) := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty}\\sqrt{n^2 + n} -n = 1/2$.\n\\begin{proof}\n Multiplying and dividing by $\\sqrt{n^2+n}+n$ yields\n$$\n\\sqrt{n^2+n}-n=\\frac{n}{\\sqrt{n^2+n}+n}=\\frac{1}{\\sqrt{1+\\frac{1}{n}}+1} .\n$$\nIt follows that the limit is $\\frac{1}{2}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "noncomputable def f : ℕ → ℝ\n| 0 => sqrt 2\n| (n + 1) => sqrt (2 + sqrt (f n))\n\ntheorem Rudin_exercise_3_3\n : ∃ (x : ℝ), Tendsto f atTop (𝓝 x) ∧ ∀ n, f n < 2 := sorry", "formal_proof": null, "informal_stmt": "If $s_{1}=\\sqrt{2}$, and $s_{n+1}=\\sqrt{2+\\sqrt{s_{n}}} \\quad(n=1,2,3, \\ldots),$ prove that $\\left\\{s_{n}\\right\\}$ converges, and that $s_{n}<2$ for $n=1,2,3, \\ldots$.\n\\begin{proof}\n Since $\\sqrt{2}<2$, it is manifest that if $s_n<2$, then $s_{n+1}<\\sqrt{2+2}=2$. Hence it follows by induction that $\\sqrt{2}1$, i.e., $s_n>s_n^2-2=s_{n-1}$. Hence the sequence is an increasing sequence that is bounded above (by 2 ) and so converges. Since the limit $s$ satisfies $s^2-s-2=0$, it follows that the limit is 2.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_5\n (a b : ℕ → ℝ)\n (h : limsup a + limsup b ≠ 0) :\n limsup (λ n => a n + b n) ≤ limsup a + limsup b := sorry", "formal_proof": null, "informal_stmt": "For any two real sequences $\\left\\{a_{n}\\right\\},\\left\\{b_{n}\\right\\}$, prove that $\\limsup _{n \\rightarrow \\infty}\\left(a_{n}+b_{n}\\right) \\leq \\limsup _{n \\rightarrow \\infty} a_{n}+\\limsup _{n \\rightarrow \\infty} b_{n},$ provided the sum on the right is not of the form $\\infty-\\infty$.\n\\begin{proof}\n Since the case when $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$ and $\\limsup _{n \\rightarrow \\infty} b_n=-\\infty$ has been excluded from consideration, we note that the inequality is obvious if $\\limsup _{n \\rightarrow \\infty} a_n=+\\infty$. Hence we shall assume that $\\left\\{a_n\\right\\}$ is bounded above.\n\nLet $\\left\\{n_k\\right\\}$ be a subsequence of the positive integers such that $\\lim _{k \\rightarrow \\infty}\\left(a_{n_k}+\\right.$ $\\left.b_{n_k}\\right)=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Then choose a subsequence of the positive integers $\\left\\{k_m\\right\\}$ such that\n$$\n\\lim _{m \\rightarrow \\infty} a_{n_{k_m}}=\\limsup _{k \\rightarrow \\infty} a_{n_k} .\n$$\nThe subsequence $a_{n_{k_m}}+b_{n_{k_m}}$ still converges to the same limit as $a_{n_k}+b_{n_k}$, i.e., to $\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n\\right)$. Hence, since $a_{n_k}$ is bounded above (so that $\\limsup _{k \\rightarrow \\infty} a_{n_k}$ is finite), it follows that $b_{n_{k_m}}$ converges to the difference\n$$\n\\lim _{m \\rightarrow \\infty} b_{n_{k_m}}=\\lim _{m \\rightarrow \\infty}\\left(a_{n_{k_m}}+b_{n_{k_m}}\\right)-\\lim _{m \\rightarrow \\infty} a_{n_{k_m}} .\n$$\nThus we have proved that there exist subsequences $\\left\\{a_{n_{k_m}}\\right\\}$ and $\\left\\{b_{n_{k_m}}\\right\\}$ which converge to limits $a$ and $b$ respectively such that $a+b=\\limsup _{n \\rightarrow \\infty}\\left(a_n+b_n^*\\right)$. Since $a$ is the limit of a subsequence of $\\left\\{a_n\\right\\}$ and $b$ is the limit of a subsequence of $\\left\\{b_n\\right\\}$, it follows that $a \\leq \\limsup _{n \\rightarrow \\infty} a_n$ and $b \\leq \\limsup _{n \\rightarrow \\infty} b_n$, from which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_6a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "def g (n : ℕ) : ℝ := sqrt (n + 1) - sqrt n\n\ntheorem Rudin_exercise_3_6a\n: Tendsto (λ (n : ℕ) => (∑ i ∈ range n, g i)) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Prove that $\\lim_{n \\rightarrow \\infty} \\sum_{i (∑ i ∈ (range n), a i)) atTop (𝓝 y))) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), sqrt (a i) / n)) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the convergence of $\\Sigma a_{n}$ implies the convergence of $\\sum \\frac{\\sqrt{a_{n}}}{n}$ if $a_n\\geq 0$.\n\\begin{proof}\n Since $\\left(\\sqrt{a_n}-\\frac{1}{n}\\right)^2 \\geq 0$, it follows that\n$$\n\\frac{\\sqrt{a_n}}{n} \\leq \\frac{1}{2}\\left(a_n^2+\\frac{1}{n^2}\\right) .\n$$\nNow $\\Sigma a_n^2$ converges by comparison with $\\Sigma a_n$ (since $\\Sigma a_n$ converges, we have $a_n<1$ for large $n$, and hence $\\left.a_n^2 (∑ i ∈ (range n), a i)) atTop (𝓝 y)))\n (h2 : Monotone b)\n (h3 : Bornology.IsBounded (Set.range b)) :\n ∃ y, Tendsto (λ n => (∑ i ∈ (range n), (a i) * (b i))) atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "If $\\Sigma a_{n}$ converges, and if $\\left\\{b_{n}\\right\\}$ is monotonic and bounded, prove that $\\Sigma a_{n} b_{n}$ converges.\n\\begin{proof}\n We shall show that the partial sums of this series form a Cauchy sequence, i.e., given $\\varepsilon>0$ there exists $N$ such that $\\left|\\sum_{k=m+1}^n a_k b_k\\right|\\langle\\varepsilon$ if $n\\rangle$ $m \\geq N$. To do this, let $S_n=\\sum_{k=1}^n a_k\\left(S_0=0\\right)$, so that $a_k=S_k-S_{k-1}$ for $k=1,2, \\ldots$ Let $M$ be an upper bound for both $\\left|b_n\\right|$ and $\\left|S_n\\right|$, and let $S=\\sum a_n$ and $b=\\lim b_n$. Choose $N$ so large that the following three inequalities hold for all $m>N$ and $n>N$ :\n$$\n\\left|b_n S_n-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m S_m-b S\\right|<\\frac{\\varepsilon}{3} ; \\quad\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M} .\n$$\nThen if $n>m>N$, we have, from the formula for summation by parts,\n$$\n\\sum_{k=m+1}^n a_n b_n=b_n S_n-b_m S_m+\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\n$$\nOur assumptions yield immediately that $\\left|b_n S_n-b_m S_m\\right|<\\frac{2 \\varepsilon}{3}$, and\n$$\n\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right) S_k\\right| \\leq M \\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right| .\n$$\nSince the sequence $\\left\\{b_n\\right\\}$ is monotonic, we have\n$$\n\\sum_{k=m}^{n-1}\\left|b_k-b_{k+1}\\right|=\\left|\\sum_{k=m}^{n-1}\\left(b_k-b_{k+1}\\right)\\right|=\\left|b_m-b_n\\right|<\\frac{\\varepsilon}{3 M},\n$$\nfrom which the desired inequality follows.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_13", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_13\n (a b : ℕ → ℝ)\n (ha : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |a i|)) atTop (𝓝 y)))\n (hb : ∃ y, (Tendsto (λ n => (∑ i ∈ (range n), |b i|)) atTop (𝓝 y))) :\n ∃ y, (Tendsto (λ n => (∑ i ∈ (range n),\n λ i => (∑ j ∈ range (i + 1), a j * b (i - j)))) atTop (𝓝 y)) := sorry", "formal_proof": null, "informal_stmt": "Prove that the Cauchy product of two absolutely convergent series converges absolutely.\n\\begin{proof}\n Since both the hypothesis and conclusion refer to absolute convergence, we may assume both series consist of nonnegative terms. We let $S_n=\\sum_{k=0}^n a_n, T_n=\\sum_{k=0}^n b_n$, and $U_n=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l}$. We need to show that $U_n$ remains bounded, given that $S_n$ and $T_n$ are bounded. To do this we make the convention that $a_{-1}=T_{-1}=0$, in order to save ourselves from having to separate off the first and last terms when we sum by parts. We then have\n$$\n\\begin{aligned}\nU_n &=\\sum_{k=0}^n \\sum_{l=0}^k a_l b_{k-l} \\\\\n&=\\sum_{k=0}^n \\sum_{l=0}^k a_l\\left(T_{k-l}-T_{k-l-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k a_{k-j}\\left(T_j-T_{j-1}\\right) \\\\\n&=\\sum_{k=0}^n \\sum_{j=0}^k\\left(a_{k-j}-a_{k-j-1}\\right) T_j \\\\\n&=\\sum_{j=0}^n \\sum_{k=j}^n\\left(a_{k-j}-a_{k-j-1}\\right) T_j\n&=\\sum_{j=0}^n a_{n-j} T_j \\\\\n&\\leq T \\sum_{m=0}^n a_m \\\\\n&=T S_n \\\\\n&\\leq S T .\n\\end{aligned}\n$$\nThus $U_n$ is bounded, and hence approaches a finite limit.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_20", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_20 {X : Type*} [MetricSpace X]\n (p : ℕ → X) (l : ℕ) (r : X)\n (hp : CauchySeq p)\n (hpl : Tendsto (λ n => p (l * n)) atTop (𝓝 r)) :\n Tendsto p atTop (𝓝 r) := sorry", "formal_proof": null, "informal_stmt": "Suppose $\\left\\{p_{n}\\right\\}$ is a Cauchy sequence in a metric space $X$, and some sequence $\\left\\{p_{n l}\\right\\}$ converges to a point $p \\in X$. Prove that the full sequence $\\left\\{p_{n}\\right\\}$ converges to $p$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $N_1$ so large that $d\\left(p_m, p_n\\right)<\\frac{\\varepsilon}{2}$ if $m>N_1$ and $n>N_1$. Then choose $N \\geq N_1$ so large that $d\\left(p_{n_k}, p\\right)<\\frac{\\varepsilon}{2}$ if $k>N$. Then if $n>N$, we have\n$$\nd\\left(p_n, p\\right) \\leq d\\left(p_n, p_{n_{N+1}}\\right)+d\\left(p_{n_{N+1}}, p\\right)<\\varepsilon\n$$\nFor the first term on the right is less than $\\frac{\\varepsilon}{2}$ since $n>N_1$ and $n_{N+1}>N+1>$ $N_1$. The second term is less than $\\frac{\\varepsilon}{2}$ by the choice of $N$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_21", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_21\n {X : Type*} [MetricSpace X] [CompleteSpace X]\n (E : ℕ → Set X)\n (hE : ∀ n, E n ⊃ E (n + 1))\n (hE' : Tendsto (λ n => Metric.diam (E n)) atTop (𝓝 0)) :\n ∃ a, Set.iInter E = {a} := sorry", "formal_proof": null, "informal_stmt": "If $\\left\\{E_{n}\\right\\}$ is a sequence of closed nonempty and bounded sets in a complete metric space $X$, if $E_{n} \\supset E_{n+1}$, and if $\\lim _{n \\rightarrow \\infty} \\operatorname{diam} E_{n}=0,$ then $\\bigcap_{1}^{\\infty} E_{n}$ consists of exactly one point.\n\\begin{proof}\n Choose $x_n \\in E_n$. (We use the axiom of choice here.) The sequence $\\left\\{x_n\\right\\}$ is a Cauchy sequence, since the diameter of $E_n$ tends to zero as $n$ tends to infinity and $E_n$ contains $E_{n+1}$. Since the metric space $X$ is complete, the sequence $x_n$ converges to a point $x$, which must belong to $E_n$ for all $n$, since $E_n$ is closed and contains $x_m$ for all $m \\geq n$. There cannot be a second point $y$ in all of the $E_n$, since for any point $y \\neq x$ the diameter of $E_n$ is less $\\operatorname{than} d(x, y)$ for large $n$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_3_22", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_3_22 (X : Type*) [MetricSpace X] [CompleteSpace X]\n (G : ℕ → Set X) (hG : ∀ n, IsOpen (G n) ∧ Dense (G n)) :\n ∃ x, ∀ n, x ∈ G n := sorry", "formal_proof": null, "informal_stmt": "Suppose $X$ is a nonempty complete metric space, and $\\left\\{G_{n}\\right\\}$ is a sequence of dense open sets of $X$. Prove Baire's theorem, namely, that $\\bigcap_{1}^{\\infty} G_{n}$ is not empty.\n\\begin{proof}\n Let $F_n$ be the complement of $G_n$, so that $F_n$ is closed and contains no open sets. We shall prove that any nonempty open set $U$ contains a point not in any $F_n$, hence in all $G_n$. To this end, we note that $U$ is not contained in $F_1$, so that there is a point $x_1 \\in U \\backslash F_1$. Since $U \\backslash F_1$ is open, there exists $r_1>0$ such that $B_1$, defined as the open ball of radius $r_1$ about $x_1$, is contained in $U \\backslash F_1$. Let $E_1$ be the open ball of radius $\\frac{r_1}{2}$ about $x_1$, so that the closure of $E_1$ is contained in $B_1$. Now $F_2$ does not contain $E_1$, and so we can find a point $x_2 \\in E_1 \\backslash F_2$. Since $E_1 \\backslash F_2$ is an open set, there exists a positive number $r_2$ such that $B_2$, the open ball of radius $R_2$ about $x_2$, is contained in $E_1 \\backslash F_2$, which in turn is contained in $U \\backslash\\left(F_1 \\cup F_2\\right)$. We let $E_2$ be the open ball of radius $\\frac{r_2}{2}$ about $x_2$, so that $\\bar{E}_2 \\subseteq B_2$. Proceeding in this way, we construct a sequence of open balls $E_j$, such that $E_j \\supseteq \\bar{E}_{j+1}$, and the diameter of $E_j$ tends to zero. By the previous exercise, there is a point $x$ belonging to all the sets $\\bar{E}_j$, hence to all the sets $U \\backslash\\left(F_1 \\cup F_2 \\cup \\cdots \\cup F_n\\right)$. Thus the point $x$ belongs to $U \\cap\\left(\\cap_1^{\\infty} G_n\\right)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_1a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_1a\n : ∃ (f : ℝ → ℝ), (∀ (x : ℝ), Tendsto (λ y => f (x + y) - f (x - y)) (𝓝 0) (𝓝 0)) ∧ ¬ Continuous f := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real function defined on $\\mathbb{R}$ which satisfies $\\lim_{h \\rightarrow 0} f(x + h) - f(x - h) = 0$ for every $x \\in \\mathbb{R}$. Show that $f$ does not need to be continuous.\n\\begin{proof}\n $$\nf(x)= \\begin{cases}1 & \\text { if } x \\text { is an integer } \\\\ 0 & \\text { if } x \\text { is not an integer. }\\end{cases}\n$$\n(If $x$ is an integer, then $f(x+h)-f(x-h) \\equiv 0$ for all $h$; while if $x$ is not an integer, $f(x+h)-f(x-h)=0$ for $|h|<\\min (x-[x], 1+[x]-x)$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_2a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_2a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (h₁ : Continuous f)\n : ∀ (x : Set α), f '' (closure x) ⊆ closure (f '' x) := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a continuous mapping of a metric space $X$ into a metric space $Y$, prove that $f(\\overline{E}) \\subset \\overline{f(E)}$ for every set $E \\subset X$. ($\\overline{E}$ denotes the closure of $E$).\n\\begin{proof}\n Let $x \\in \\bar{E}$. We need to show that $f(x) \\in \\overline{f(E)}$. To this end, let $O$ be any neighborhood of $f(x)$. Since $f$ is continuous, $f^{-1}(O)$ contains (is) a neighborhood of $x$. Since $x \\in \\bar{E}$, there is a point $u$ of $E$ in $f^{-1}(O)$. Hence $\\frac{f(u)}{f(E)} \\in O \\cap f(E)$. Since $O$ was any neighborhood of $f(x)$, it follows that $f(x) \\in \\overline{f(E)}$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_3\n {α : Type} [MetricSpace α]\n (f : α → ℝ) (h : Continuous f) (z : Set α) (g : z = f⁻¹' {0})\n : IsClosed z := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a continuous real function on a metric space $X$. Let $Z(f)$ (the zero set of $f$ ) be the set of all $p \\in X$ at which $f(p)=0$. Prove that $Z(f)$ is closed.\n\\begin{proof}\n $Z(f)=f^{-1}(\\{0\\})$, which is the inverse image of a closed set. Hence $Z(f)$ is closed.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_4a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4a\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Dense s)\n : f '' Set.univ ⊆ closure (f '' s) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that $f(E)$ is dense in $f(X)$.\n\\begin{proof}\n To prove that $f(E)$ is dense in $f(X)$, simply use that $f(X)=f(\\bar{E}) \\subseteq \\overline{f(E)}$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_4b", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_4b\n {α : Type} [MetricSpace α]\n {β : Type} [MetricSpace β]\n (f g : α → β)\n (s : Set α)\n (h₁ : Continuous f)\n (h₂ : Continuous g)\n (h₃ : Dense s)\n (h₄ : ∀ x ∈ s, f x = g x)\n : f = g := sorry", "formal_proof": null, "informal_stmt": "Let $f$ and $g$ be continuous mappings of a metric space $X$ into a metric space $Y$, and let $E$ be a dense subset of $X$. Prove that if $g(p) = f(p)$ for all $p \\in P$ then $g(p) = f(p)$ for all $p \\in X$.\n\\begin{proof}\n The function $\\varphi: X \\rightarrow R^1$ given by\n$$\n\\varphi(p)=d_Y(f(p), g(p))\n$$\nis continuous, since\n$$\n\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right| \\leq d_Y(f(p), f(q))+d_Y(g(p), g(q))\n$$\n(This inequality follows from the triangle inequality, since\n$$\nd_Y(f(p), g(p)) \\leq d_Y(f(p), f(q))+d_Y(f(q), g(q))+d_Y(g(q), g(p)),\n$$\nand the same inequality holds with $p$ and $q$ interchanged. The absolute value $\\left|d_Y(f(p), g(p))-d_Y(f(q), g(q))\\right|$ must be either $d_Y(f(p), g(p))-d_Y(f(q), g(q))$ or $d_Y(f(q), g(q))-d_Y(f(p), g(p))$, and the triangle inequality shows that both of these numbers are at most $d_Y(f(p), f(q))+d_Y(g(p), g(q))$.)\nBy the previous problem, the zero set of $\\varphi$ is closed. But by definition\n$$\nZ(\\varphi)=\\{p: f(p)=g(p)\\} .\n$$\nHence the set of $p$ for which $f(p)=g(p)$ is closed. Since by hypothesis it is dense, it must be $X$.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_5a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_5a\n (f : ℝ → ℝ)\n (E : Set ℝ)\n (h₁ : IsClosed E)\n (h₂ : ContinuousOn f E)\n : ∃ (g : ℝ → ℝ), Continuous g ∧ ∀ x ∈ E, f x = g x := sorry", "formal_proof": null, "informal_stmt": "If $f$ is a real continuous function defined on a closed set $E \\subset \\mathbb{R}$, prove that there exist continuous real functions $g$ on $\\mathbb{R}$ such that $g(x)=f(x)$ for all $x \\in E$.\n\\begin{proof}\nFollowing the hint, let the complement of $E$ consist of a countable collection of finite open intervals $\\left(a_k, b_k\\right)$ together with possibly one or both of the the semi-infinite intervals $(b,+\\infty)$ and $(-\\infty, a)$. The function $f(x)$ is already defined at $a_k$ and $b_k$, as well as at $a$ and $b$ (if these last two points exist). Define $g(x)$ to be $f(b)$ for $x>b$ and $f(a)$ for $x0$. To choose $\\delta>0$ such that $|x-u|<\\delta$ implies $|g(x)-g(u)|<\\varepsilon$, we consider three cases.\ni. If $x>b$, let $\\delta=x-b$. Then if $|x-u|<\\delta$, it follows that $u>b$ also, so that $g(u)=f(b)=g(x)$, and $|g(u)-g(x)|=0<\\varepsilon$. Similarly if $xa_k+\\delta_1$. Let us consider the second of these cases and show how to get $|f(u)-f(x)|<\\varepsilon$ for $xx$ we have $a_k0$ be given. Choose $\\eta>0$ so that $d_Y(f(x), f(u))<\\frac{\\varepsilon}{2}$ if $d_E(x, y)<\\eta$. Then let $\\delta=\\min \\left(\\eta, \\frac{\\varepsilon}{2}\\right)$. It is easy to see that $\\rho(\\varphi(x), \\varphi(u))<\\varepsilon$ if $d_E(x, u)<\\delta$. Conversely if $\\varphi$ is continuous, it is obvious from the inequality $\\rho(\\varphi(x), \\varphi(u)) \\geq d_Y(f(x), f(u))$ that $f$ is continuous.\n\nFrom these facts we deduce immediately that the graph of a continuous function $f$ on a compact set $E$ is compact, being the image of $E$ under the continuous mapping $\\varphi$. Conversely, if $f$ is not continuous at some point $x$, there is a sequence of points $x_n$ converging to $x$ such that $f\\left(x_n\\right)$ does not converge to $f(x)$. If no subsequence of $f\\left(x_n\\right)$ converges, then the sequence $\\left\\{\\left(x_n, f\\left(x_n\\right)\\right\\}_{n=1}^{\\infty}\\right.$ has no convergent subsequence, and so the graph is not compact. If some subsequence of $f\\left(x_n\\right)$ converges, say $f\\left(x_{n_k}\\right) \\rightarrow z$, but $z \\neq f(x)$, then the graph of $f$ fails to contain the limit point $(x, z)$, and hence is not closed. A fortiori it is not compact.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_8a", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_8a\n (E : Set ℝ) (f : ℝ → ℝ) (hf : UniformContinuousOn f E)\n (hE : Bornology.IsBounded E) : Bornology.IsBounded (Set.image f E) := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be a real uniformly continuous function on the bounded set $E$ in $R^{1}$. Prove that $f$ is bounded on $E$.\n\\begin{proof}\n Let $a=\\inf E$ and $b=\\sup E$, and let $\\delta>0$ be such that $|f(x)-f(y)|<1$ if $x, y \\in E$ and $|x-y|<\\delta$. Now choose a positive integer $N$ larger than $(b-a) / \\delta$, and consider the $N$ intervals $I_k=\\left[a+\\frac{k-1}{b-a}, a+\\frac{k}{b-a}\\right], k=1,2, \\ldots, N$. For each $k$ such that $I_k \\cap E \\neq \\varnothing$ let $x_k \\in E \\cap I_k$. Then let $M=1+\\max \\left\\{\\left|f\\left(x_k\\right)\\right|\\right\\}$. If $x \\in E$, we have $\\left|x-x_k\\right|<\\delta$ for some $k$, and hence $|f(x)| f (x n)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a uniformly continuous mapping of a metric space $X$ into a metric space $Y$ and prove that $\\left\\{f\\left(x_{n}\\right)\\right\\}$ is a Cauchy sequence in $Y$ for every Cauchy sequence $\\{x_n\\}$ in $X$.\n\\begin{proof}\n Suppose $\\left\\{x_n\\right\\}$ is a Cauchy sequence in $X$. Let $\\varepsilon>0$ be given. Let $\\delta>0$ be such that $d_Y(f(x), f(u))<\\varepsilon$ if $d_X(x, u)<\\delta$. Then choose $N$ so that $d_X\\left(x_n, x_m\\right)<\\delta$ if $n, m>N$. Obviously $d_Y\\left(f\\left(x_n\\right), f\\left(x_m\\right)\\right)<\\varepsilon$ if $m, n>N$, showing that $\\left\\{f\\left(x_n\\right)\\right\\}$ is a Cauchy sequence.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_12", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_12\n {α β γ : Type*} [UniformSpace α] [UniformSpace β] [UniformSpace γ]\n {f : α → β} {g : β → γ}\n (hf : UniformContinuous f) (hg : UniformContinuous g) :\n UniformContinuous (g ∘ f) := sorry", "formal_proof": null, "informal_stmt": "A uniformly continuous function of a uniformly continuous function is uniformly continuous.\n\\begin{proof}\n Let $f: X \\rightarrow Y$ and $g: Y \\rightarrow Z$ be uniformly continuous. Then $g \\circ f: X \\rightarrow Z$ is uniformly continuous, where $g \\circ f(x)=g(f(x))$ for all $x \\in X$.\nTo prove this fact, let $\\varepsilon>0$ be given. Then, since $g$ is uniformly continuous, there exists $\\eta>0$ such that $d_Z(g(u), g(v))<\\varepsilon$ if $d_Y(u, v)<\\eta$. Since $f$ is uniformly continuous, there exists $\\delta>0$ such that $d_Y(f(x), f(y))<\\eta$ if $d_X(x, y)<\\delta$\n\nIt is then obvious that $d_Z(g(f(x)), g(f(y)))<\\varepsilon$ if $d_X(x, y)<\\delta$, so that $g \\circ f$ is uniformly continuous.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_15 {f : ℝ → ℝ}\n (hf : Continuous f) (hof : IsOpenMap f) :\n Monotone f := sorry", "formal_proof": null, "informal_stmt": "Prove that every continuous open mapping of $R^{1}$ into $R^{1}$ is monotonic.\n\\begin{proof}\n Suppose $f$ is continuous and not monotonic, say there exist points $a 0 ∧ ∀ (p q : X), p ∈ K → q ∈ F → dist p q ≥ δ := sorry", "formal_proof": null, "informal_stmt": "Suppose $K$ and $F$ are disjoint sets in a metric space $X, K$ is compact, $F$ is closed. Prove that there exists $\\delta>0$ such that $d(p, q)>\\delta$ if $p \\in K, q \\in F$.\n\\begin{proof}\nFollowing the hint, we observe that $\\rho_F(x)$ must attain its minimum value on $K$, i.e., there is some point $r \\in K$ such that\n$$\n\\rho_F(r)=\\min _{q \\in K} \\rho_F(q) .\n$$\nSince $F$ is closed and $r \\notin F$, it follows from Exercise $4.20$ that $\\rho_F(r)>0$. Let $\\delta$ be any positive number smaller than $\\rho_F(r)$. Then for any $p \\in F, q \\in K$, we have\n$$\nd(p, q) \\geq \\rho_F(q) \\geq \\rho_F(r)>\\delta .\n$$\nThis proves the positive assertion.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_4_24", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_4_24 {f : ℝ → ℝ}\n (hf : Continuous f) (a b : ℝ) (hab : a < b)\n (h : ∀ x y : ℝ, a < x → x < b → a < y → y < b → f ((x + y) / 2) ≤ (f x + f y) / 2) :\n ConvexOn ℝ (Set.Ioo a b) f := sorry", "formal_proof": null, "informal_stmt": "Assume that $f$ is a continuous real function defined in $(a, b)$ such that $f\\left(\\frac{x+y}{2}\\right) \\leq \\frac{f(x)+f(y)}{2}$ for all $x, y \\in(a, b)$. Prove that $f$ is convex.\n\\begin{proof}\n We shall prove that\n$$\nf(\\lambda x+(1-\\lambda) y) \\leq \\lambda f(x)+(1-\\lambda) f(y)\n$$\nfor all \"dyadic rational\" numbers, i.e., all numbers of the form $\\lambda=\\frac{k}{2^n}$, where $k$ is a nonnegative integer not larger than $2^n$. We do this by induction on $n$. The case $n=0$ is trivial (since $\\lambda=0$ or $\\lambda=1$ ). In the case $n=1$ we have $\\lambda=0$ or $\\lambda=1$ or $\\lambda=\\frac{1}{2}$. The first two cases are again trivial, and the third is precisely the hypothesis of the theorem. Suppose the result is proved for $n \\leq r$, and consider $\\lambda=\\frac{k}{2^{r+1}}$. If $k$ is even, say $k=2 l$, then $\\frac{k}{2^{r+1}}=\\frac{l}{2^r}$, and we can appeal to the induction hypothesis. Now suppose $k$ is odd. Then $1 \\leq k \\leq 2^{r+1}-1$, and so the numbers $l=\\frac{k-1}{2}$ and $m=\\frac{k+1}{2}$ are integers with $0 \\leq l c := sorry", "formal_proof": null, "informal_stmt": "Let $f$ be defined for all real $x$, and suppose that $|f(x)-f(y)| \\leq (x-y)^{2}$ for all real $x$ and $y$. Prove that $f$ is constant.\n\\begin{proof}\n Dividing by $x-y$, and letting $x \\rightarrow y$, we find that $f^{\\prime}(y)=0$ for all $y$. Hence $f$ is constant.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_2", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_2 {a b : ℝ}\n {f g : ℝ → ℝ} (hf : ∀ x ∈ Set.Ioo a b, deriv f x > 0)\n (hg : g = f⁻¹)\n (hg_diff : DifferentiableOn ℝ g (Set.Ioo a b)) :\n DifferentiableOn ℝ g (Set.Ioo a b) ∧\n ∀ x ∈ Set.Ioo a b, deriv g x = 1 / deriv f x := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x)>0$ in $(a, b)$. Prove that $f$ is strictly increasing in $(a, b)$, and let $g$ be its inverse function. Prove that $g$ is differentiable, and that $g^{\\prime}(f(x))=\\frac{1}{f^{\\prime}(x)} \\quad(a0$. Hence $f(c)0$ there exists $\\eta>0$ such that\n$$\n\\left|\\frac{1}{\\frac{f(x+h)-f(x)}{h}}-\\frac{1}{f^{\\prime}(x)}\\right|<\\varepsilon\n$$\nif $0<|h|<\\eta$. Since $h=g(y+k)-g(y)$, there exists $\\delta>0$ such that $0<|h|<\\eta$ if $0<|k|<\\delta$. The proof is now complete. \n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_3", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_3 {g : ℝ → ℝ} (hg : Continuous g)\n (hg' : ∃ M : ℝ, ∀ x : ℝ, |deriv g x| ≤ M) :\n ∃ N, ∀ ε > 0, ε < N → Function.Injective (λ x : ℝ => x + ε * g x) := sorry", "formal_proof": null, "informal_stmt": "Suppose $g$ is a real function on $R^{1}$, with bounded derivative (say $\\left|g^{\\prime}\\right| \\leq M$ ). Fix $\\varepsilon>0$, and define $f(x)=x+\\varepsilon g(x)$. Prove that $f$ is one-to-one if $\\varepsilon$ is small enough.\n\\begin{proof}\n If $0<\\varepsilon<\\frac{1}{M}$, we certainly have\n$$\nf^{\\prime}(x) \\geq 1-\\varepsilon M>0,\n$$\nand this implies that $f(x)$ is one-to-one, by the preceding problem.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_4", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_4 {n : ℕ}\n (C : ℕ → ℝ)\n (hC : ∑ i ∈ (range (n + 1)), (C i) / (i + 1) = 0) :\n ∃ x, x ∈ (Set.Icc (0 : ℝ) 1) ∧ ∑ i ∈ range (n + 1), (C i) * (x^i) = 0 := sorry", "formal_proof": null, "informal_stmt": "If $C_{0}+\\frac{C_{1}}{2}+\\cdots+\\frac{C_{n-1}}{n}+\\frac{C_{n}}{n+1}=0,$ where $C_{0}, \\ldots, C_{n}$ are real constants, prove that the equation $C_{0}+C_{1} x+\\cdots+C_{n-1} x^{n-1}+C_{n} x^{n}=0$ has at least one real root between 0 and 1.\n\\begin{proof}\n Consider the polynomial\n$$\np(x)=C_0 x+\\frac{C_1}{2} x^2+\\cdots+\\frac{C_{n-1}}{n} x^n+\\frac{C_n}{n+1} x^{n+1},\n$$\nwhose derivative is\n$$\np^{\\prime}(x)=C_0+C_1 x+\\cdots+C_{n-1} x^{n-1}+C_n x^n .\n$$\nIt is obvious that $p(0)=0$, and the hypothesis of the problem is that $p(1)=0$. Hence Rolle's theorem implies that $p^{\\prime}(x)=0$ for some $x$ between 0 and 1 .\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_5", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_5\n {f : ℝ → ℝ}\n (hfd : Differentiable ℝ f)\n (hf : Tendsto (deriv f) atTop (𝓝 0)) :\n Tendsto (λ x => f (x + 1) - f x) atTop atTop := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is defined and differentiable for every $x>0$, and $f^{\\prime}(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$. Put $g(x)=f(x+1)-f(x)$. Prove that $g(x) \\rightarrow 0$ as $x \\rightarrow+\\infty$.\n\\begin{proof}\n Let $\\varepsilon>0$. Choose $x_0$ such that $\\left|f^{\\prime}(x)\\right|<\\varepsilon$ if $x>x_0$. Then for any $x \\geq x_0$ there exists $x_1 \\in(x, x+1)$ such that\n$$\nf(x+1)-f(x)=f^{\\prime}\\left(x_1\\right) .\n$$\nSince $\\left|f^{\\prime}\\left(x_1\\right)\\right|<\\varepsilon$, it follows that $|f(x+1)-f(x)|<\\varepsilon$, as required.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_6", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_6\n {f : ℝ → ℝ}\n (hf1 : Continuous f)\n (hf2 : ∀ x, DifferentiableAt ℝ f x)\n (hf3 : f 0 = 0)\n (hf4 : Monotone (deriv f)) :\n MonotoneOn (λ x => f x / x) (Set.Ioi 0) := sorry", "formal_proof": null, "informal_stmt": "Suppose (a) $f$ is continuous for $x \\geq 0$, (b) $f^{\\prime}(x)$ exists for $x>0$, (c) $f(0)=0$, (d) $f^{\\prime}$ is monotonically increasing. Put $g(x)=\\frac{f(x)}{x} \\quad(x>0)$ and prove that $g$ is monotonically increasing.\n\\begin{proof}\n Put\n$$\ng(x)=\\frac{f(x)}{x} \\quad(x>0)\n$$\nand prove that $g$ is monotonically increasing.\nBy the mean-value theorem\n$$\nf(x)=f(x)-f(0)=f^{\\prime}(c) x\n$$\nfor some $c \\in(0, x)$. Since $f^{\\prime}$ is monotonically increasing, this result implies that $f(x)0,\n$$\nso that $g$ is also monotonically increasing.\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_7", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_7\n {f g : ℝ → ℝ} {x : ℝ}\n (hf' : DifferentiableAt ℝ f 0)\n (hg' : DifferentiableAt ℝ g 0)\n (hg'_ne_0 : deriv g 0 ≠ 0)\n (f0 : f 0 = 0) (g0 : g 0 = 0) :\n Tendsto (λ x => f x / g x) (𝓝 x) (𝓝 (deriv f x / deriv g x)) := sorry", "formal_proof": null, "informal_stmt": "Suppose $f^{\\prime}(x), g^{\\prime}(x)$ exist, $g^{\\prime}(x) \\neq 0$, and $f(x)=g(x)=0$. Prove that $\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)}=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}.$\n\\begin{proof}\n Since $f(x)=g(x)=0$, we have\n$$\n\\begin{aligned}\n\\lim _{t \\rightarrow x} \\frac{f(t)}{g(t)} &=\\lim _{t \\rightarrow x} \\frac{\\frac{f(t)-f(x)}{t-x}}{\\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{\\lim _{t \\rightarrow x} \\frac{f(t)-f(x)}{t-x}}{\\lim _{t \\rightarrow x} \\frac{g(t)-g(x)}{t-x}} \\\\\n&=\\frac{f^{\\prime}(x)}{g^{\\prime}(x)}\n\\end{aligned}\n$$\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_15", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_15 {f : ℝ → ℝ} (a M0 M1 M2 : ℝ)\n (hf' : DifferentiableOn ℝ f (Set.Ici a))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Ici a))\n (hM0 : M0 = sSup {(|f x|) | x ∈ (Set.Ici a)})\n (hM1 : M1 = sSup {(|deriv f x|) | x ∈ (Set.Ici a)})\n (hM2 : M2 = sSup {(|deriv (deriv f) x|) | x ∈ (Set.Ici a)}) :\n (M1 ^ 2) ≤ 4 * M0 * M2 := sorry", "formal_proof": null, "informal_stmt": "Suppose $a \\in R^{1}, f$ is a twice-differentiable real function on $(a, \\infty)$, and $M_{0}, M_{1}, M_{2}$ are the least upper bounds of $|f(x)|,\\left|f^{\\prime}(x)\\right|,\\left|f^{\\prime \\prime}(x)\\right|$, respectively, on $(a, \\infty)$. Prove that $M_{1}^{2} \\leq 4 M_{0} M_{2} .$\n\\begin{proof}\n The inequality is obvious if $M_0=+\\infty$ or $M_2=+\\infty$, so we shall assume that $M_0$ and $M_2$ are both finite. We need to show that\n$$\n\\left|f^{\\prime}(x)\\right| \\leq 2 \\sqrt{M_0 M_2}\n$$\nfor all $x>a$. We note that this is obvious if $M_2=0$, since in that case $f^{\\prime}(x)$ is constant, $f(x)$ is a linear function, and the only bounded linear function is a constant, whose derivative is zero. Hence we shall assume from now on that $0-1$. Now $f^{\\prime}(x)=\\frac{4 x}{\\left(x^2+1\\right)^2}$ for $x>0$ and $f^{\\prime}(x)=4 x$ for $x<0$. It thus follows from Exercise 9 above that $f^{\\prime}(0)=0$, and that $f^{\\prime}(x)$ is continuous. Likewise $f^{\\prime \\prime}(x)=4$ for $x<0$ and $f^{\\prime \\prime}(x)=\\frac{4-4 x^2}{\\left(x^2+1\\right)^3}=-4 \\frac{x^2-1}{\\left(x^2+1\\right)^3}$. This shows that $\\left|f^{\\prime \\prime}(x)\\right|<4$ for $x>0$ and also that $\\lim _{x \\rightarrow 0} f^{\\prime \\prime}(x)=4$. Hence Exercise 9 again implies that $f^{\\prime \\prime}(x)$ is continuous and $f^{\\prime \\prime}(0)=4$.\n\nOn $n$-dimensional space let $\\mathbf{f}(x)=\\left(f_1(x), \\ldots, f_n(x)\\right), M_0=\\sup |\\mathbf{f}(x)|$, $M_1=\\sup \\left|\\mathbf{f}^{\\prime}(x)\\right|$, and $M_2=\\sup \\left|\\mathbf{f}^{\\prime \\prime}(x)\\right|$. Just as in the numerical case, there is nothing to prove if $M_2=0$ or $M_0=+\\infty$ or $M_2=+\\infty$, and so we assume $0a$, and let $\\mathbf{u}=\\frac{1}{\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|} \\mathbf{f}^{\\prime}\\left(x_0\\right)$. Consider the real-valued function $\\varphi(x)=\\mathrm{u} \\cdot \\mathrm{f}(x)$. Let $N_0, N_1$, and $N_2$ be the suprema of $|\\varphi(x)|,\\left|\\varphi^{\\prime}(x)\\right|$, and $\\left|\\varphi^{\\prime \\prime}(x)\\right|$ respectively. By the Schwarz inequality we have (since $|\\mathbf{u}|=1) N_0 \\leq M_0$ and $N_2 \\leq M_2$, while $N_1 \\geq \\varphi\\left(x_0\\right)=\\left|\\mathbf{f}^{\\prime}\\left(x_0\\right)\\right|>a$. We therefore have $a^2<4 N_0 N_2 \\leq 4 M_0 M_2$. Since $a$ was any positive number less than $M_1$, we have $M_1^2 \\leq 4 M_0 M_2$, i.e., the result holds also for vector-valued functions.\n\nEquality can hold on any $R^n$, as we see by taking $\\mathbf{f}(x)=(f(x), 0, \\ldots, 0)$ or $\\mathbf{f}(x)=(f(x), f(x), \\ldots, f(x))$, where $f(x)$ is a real-valued function for which equality holds.\n\n\\end{proof}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Rudin_exercise_5_17", "source": "Rudin.lean", "header": "import Mathlib\n\nopen Topology Filter Real Complex TopologicalSpace Finset\nopen scoped BigOperators\nnoncomputable section\n", "formal_statement": "theorem Rudin_exercise_5_17\n {f : ℝ → ℝ}\n (hf' : DifferentiableOn ℝ f (Set.Icc (-1) 1))\n (hf'' : DifferentiableOn ℝ (deriv f) (Set.Icc 1 1))\n (hf''' : DifferentiableOn ℝ (deriv (deriv f)) (Set.Icc 1 1))\n (hf0 : f (-1) = 0)\n (hf1 : f 0 = 0)\n (hf2 : f 1 = 1)\n (hf3 : deriv f 0 = 0) :\n ∃ x, x ∈ Set.Ioo (-1 : ℝ) 1 ∧ deriv (deriv (deriv f)) x ≥ 3 := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is a real, three times differentiable function on $[-1,1]$, such that $f(-1)=0, \\quad f(0)=0, \\quad f(1)=1, \\quad f^{\\prime}(0)=0 .$ Prove that $f^{(3)}(x) \\geq 3$ for some $x \\in(-1,1)$.\n\\begin{proof}\n Following the hint, we observe that Theorem $5.15$ (Taylor's formula with remainder) implies that\n$$\n\\begin{aligned}\nf(1) &=f(0)+f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)+\\frac{1}{6} f^{(3)}(s) \\\\\nf(-1) &=f(0)-f^{\\prime}(0)+\\frac{1}{2} f^{\\prime \\prime}(0)-\\frac{1}{6} f^{(3)}(t)\n\\end{aligned}\n$$\nfor some $s \\in(0,1), t \\in(-1,0)$. By subtracting the second equation from the first and using the given values of $f(1), f(-1)$, and $f^{\\prime}(0)$, we obtain\n$$\n1=\\frac{1}{6}\\left(f^{(3)}(s)+f^{(3)}(t)\\right),\n$$\nwhich is the desired result. Note that we made no use of the hypothesis $f(0)=0$.\n\\end{proof}\n\n\n\n\\end{document}", "informal_proof": "If $r$ and $r+x$ were both rational, then $x=r+x-r$ would also be rational."} +{"name": "Shakarchi_exercise_1_13a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13a {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).re = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Re}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Re}(f)=$ constant,\n$$\n\\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 .\n$$\nThus, in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\n3\nThus $f(z)$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_13b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13b {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, (f z).im = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $\\text{Im}(f)$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nSince $\\operatorname{Im}(f)=$ constant,\n$$\n\\frac{\\partial v}{\\partial x}=0, \\frac{\\partial v}{\\partial y}=0 .\n$$\nBy the Cauchy-Riemann equations,\n$$\n\\frac{\\partial u}{\\partial x}=\\frac{\\partial v}{\\partial y}=0 .\n$$\nThus in $\\Omega$,\n$$\nf^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 .\n$$\nThus $f$ is constant.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_13c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_13c {f : ℂ → ℂ} (Ω : Set ℂ) (a b : Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (hc : ∃ (c : ℝ), ∀ z ∈ Ω, norm (f z) = c) :\n f a = f b := sorry", "formal_proof": null, "informal_stmt": "Suppose that $f$ is holomorphic in an open set $\\Omega$. Prove that if $|f|$ is constant, then $f$ is constant.\n\\begin{proof}\nLet $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$.\nWe first give a mostly correct argument; the reader should pay attention to find the difficulty. Since $|f|=\\sqrt{u^2+v^2}$ is constant,\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{gathered}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 \\\\\n(1.14) \\Rightarrow \\frac{\\partial v}{\\partial x}=\\frac{v}{u} \\frac{\\partial v}{\\partial y}\n\\end{gathered}\n$$\nPlug (1.15) into (1.13) and we get\n$$\n\\frac{u^2+v^2}{u} \\frac{\\partial v}{\\partial y}=0 .\n$$\nSo $u^2+v^2=0$ or $\\frac{\\partial v}{\\partial y}=0$.\n\nIf $u^2+v^2=0$, then, since $u, v$ are real, $u=v=0$, and thus $f=0$ which is constant.\n\nThus we may assume $u^2+v^2$ equals a non-zero constant, and we may divide by it. We multiply both sides by $u$ and find $\\frac{\\partial v}{\\partial y}=0$, then by (1.15), $\\frac{\\partial v}{\\partial x}=0$, and by Cauchy-Riemann, $\\frac{\\partial u}{\\partial x}=0$.\n$$\nf^{\\prime}=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0 .\n$$\nThus $f$ is constant.\nWhy is the above only mostly a proof? The problem is we have a division by $u$, and need to make sure everything is well-defined. Specifically, we need to know that $u$ is never zero. We do have $f^{\\prime}=0$ except at points where $u=0$, but we would need to investigate that a bit more.\nLet's return to\n$$\n\\left\\{\\begin{array}{l}\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial x}=2 u \\frac{\\partial u}{\\partial x}+2 v \\frac{\\partial v}{\\partial x} . \\\\\n0=\\frac{\\partial\\left(u^2+v^2\\right)}{\\partial y}=2 u \\frac{\\partial u}{\\partial y}+2 v \\frac{\\partial v}{\\partial y} .\n\\end{array}\\right.\n$$\nPlug in the Cauchy-Riemann equations and we get\n$$\n\\begin{array}{r}\nu \\frac{\\partial v}{\\partial y}+v \\frac{\\partial v}{\\partial x}=0 \\\\\n-u \\frac{\\partial v}{\\partial x}+v \\frac{\\partial v}{\\partial y}=0 .\n\\end{array}\n$$\nWe multiply the first equation $u$ and the second by $v$, and obtain\n$$\n\\begin{aligned}\nu^2 \\frac{\\partial v}{\\partial y}+u v \\frac{\\partial v}{\\partial x} & =0 \\\\\n-u v \\frac{\\partial v}{\\partial x}+v^2 \\frac{\\partial v}{\\partial y} & =0 .\n\\end{aligned}\n$$\nAdding the two yields\n$$\nu^2 \\frac{\\partial v}{\\partial y}+v^2 \\frac{\\partial v}{\\partial y}=0,\n$$\nor equivalently\n$$\n\\left(u^2+v^2\\right) \\frac{\\partial v}{\\partial y}=0 .\n$$\nWe now argue in a similar manner as before, except now we don't have the annoying $u$ in the denominator. If $u^2+v^2=0$ then $u=v=0$, else we can divide by $u^2+v^2$ and find $\\partial v / \\partial y=0$. Arguing along these lines finishes the proof.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19a", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19a (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z ^ i)) :\n ¬ ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum nz^n$ does not converge on any point of the unit circle.\n\\begin{proof}\n For $z \\in S:=\\{z \\in \\mathbb{C}:|z|=1\\}$ it also holds $z^n \\in S$ for all $n \\in \\mathbb{N}$ (since in this case $\\left.\\left|z^n\\right|=|z|^n=1^n=1\\right)$\nThus, the sequence $\\left(a_n\\right)_{n \\in \\mathbb{N}}$ with $a_n=n z^n$ does not converge to zero which is necessary for the corresponding sum $\\sum_{n \\in \\mathbb{N}} a_n$ to be convergent. Hence this sum does not converge.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19b", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19b (z : ℂ) (hz : norm z = 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i ^ 2)) :\n ∃ y, Tendsto s atTop (𝓝 y) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n^2$ converges at every point of the unit circle.\n\\begin{proof}\n Since $\\left|z^n / n^2\\right|=1 / n^2$ for all $|z|=1$, then $\\sum z^n / n^2$ converges at every point in the unit circle as $\\sum 1 / n^2$ does ( $p$-series $p=2$.)\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_19c", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_19c (z : ℂ) (hz : norm z = 1) (hz2 : z ≠ 1) (s : ℕ → ℂ)\n (h : s = (λ n => ∑ i ∈ (range n), i * z / i)) :\n ∃ z, Tendsto s atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that the power series $\\sum zn/n$ converges at every point of the unit circle except $z = 1$.\n\\begin{proof}\n If $z=1$ then $\\sum z^n / n=\\sum 1 / n$ is divergent (harmonic series). If $|z|=1$ and $z \\neq 1$, write $z=e^{2 \\pi i t}$ with $t \\in(0,1)$ and apply Dirichlet's test: if $\\left\\{a_n\\right\\}$ is a sequence of real numbers and $\\left\\{b_n\\right\\}$ a sequence of complex numbers satisfying\n- $a_{n+1} \\leq a_n$\n- $\\lim _{n \\rightarrow \\infty} a_n=0$\n- $\\left|\\sum_{n=1}^N b_n\\right| \\leq M$ for every positive integer $N$ and some $M>0$,\nthen $\\sum a_n b_n$ converges. Let $a_n=1 / n$, so $a_n$ satisfies $a_{n+1} \\leq a_n$ and $\\lim _{n \\rightarrow \\infty} a_n=0$. Let $b_n=e^{2 \\pi i n t}$, then\n$$\n\\left|\\sum_{n=1}^N b_n\\right|=\\left|\\sum_{n=1}^N e^{2 \\pi i n t}\\right|=\\left|\\frac{e^{2 \\pi i t}-e^{2 \\pi i(N+1) t}}{1-e^{2 \\pi i t}}\\right| \\leq \\frac{2}{\\left|1-e^{2 \\pi i t}\\right|}=M \\text { for all } N\n$$\nThus $\\sum a_n b_n=\\sum z^n / n$ converges for every point in the unit circle except $z=1$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_1_26", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_1_26\n (f F₁ F₂ : ℂ → ℂ) (Ω : Set ℂ) (h1 : IsOpen Ω) (h2 : IsConnected Ω)\n (hF₁ : DifferentiableOn ℂ F₁ Ω) (hF₂ : DifferentiableOn ℂ F₂ Ω)\n (hdF₁ : ∀ x ∈ Ω, deriv F₁ x = f x) (hdF₂ : ∀ x ∈ Ω, deriv F₂ x = f x)\n : ∃ c : ℂ, ∀ x, F₁ x = F₂ x + c := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is continuous in a region $\\Omega$. Prove that any two primitives of $f$ (if they exist) differ by a constant.\n\\begin{proof}\n Suppose $F_1$ and $F_2$ are primitives of $F$. Then $(F_1-F_2)^\\prime = f - f = 0$, therefore $F_1$ and $F_2$ differ by a constant. \n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_2", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_2 :\n Tendsto (λ y => ∫ x in (0 : ℝ)..y, Real.sin x / x) atTop (𝓝 (Real.pi / 2)) := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_{0}^{\\infty} \\frac{\\sin x}{x} d x=\\frac{\\pi}{2}$.\n\\begin{proof}\n We have $\\int_0^{\\infty} \\frac{\\sin x}{x} d x=\\frac{1}{2 * i} \\int_0^{\\infty} \\frac{e^{i * x}-e^{-i * x}}{x} d x=\\frac{1}{2 * i}\\left(\\int_0^{\\infty} \\frac{e^{i * x}-1}{x} d x-\\int_0^{\\infty} \\frac{e^{-i * x}-1}{x} d x=\\right.$ $\\frac{1}{2 * i} \\int_{-\\infty}^{\\infty} \\frac{e^{i * x}-1}{x} d x$. Now integrate along the big and small semicircles $C_0$ and $C_1$ shown below. For $C_0$ : we have that $\\int_{C_0} \\frac{1}{x} d x=\\pi * i$ and $\\left|\\int_{C_0} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $2 *\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right|+\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right|$ where $C_{00}$ and $C_{01}$ are shown below $\\left(C_{01}\\right.$ contains the part of $C_0$ that has points with imaginary parts more than $a$ and $C_{00}$ is one of the other 2 components). We have $\\left|\\int_{C_{00}} \\frac{e^{i * x}}{x} d x\\right| \\leq$ $\\sup _{x \\in C_{00}}\\left(e^{i * x}\\right) / R * \\int_{C_{00}}|d x| \\leq e^{-a} * \\pi$ and $\\left|\\int_{C_{01}} \\frac{e^{i * x}}{x} d x\\right| \\leq\\left|\\int_{C_{01}} \\frac{1}{x} d x\\right| \\leq$ $\\frac{1}{R} * C * a$ for some constant $C$ (the constant $C$ exists because the length of the curve approaches $a$ as $a / R \\rightarrow 0)$. Thus, the integral of $e^{i * x} / x$ over $C_0$ is bounded by $A * e^{-a}+B * a / R$ for some constants $A$ and $B$. Pick $R$ large and $a=\\sqrt{R}$ and note that the above tends to 0 . About the integral over $C_1$ : We have $e^{i * x}-1=1+O(x)$ for $x \\rightarrow 0$ (this is again from $\\sin (x) / x \\rightarrow 1$ ),\n4\nso $\\left|\\int_{C_1} \\frac{e^{i * x}-1}{x} d x\\right| \\leq O(1) *\\left|\\int_{C_1} d x\\right| \\rightarrow 0$ as $x \\rightarrow 0$. Thus, we only care about the integral over $C_{00}$ which is $-\\pi * i$. Using Cauchy's theorem we get that our integral equals $\\frac{1}{2 * i}(-(\\pi * i))=\\pi / 2$.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_9\n {f : ℂ → ℂ} (Ω : Set ℂ) (b : Bornology.IsBounded Ω) (h : IsOpen Ω)\n (hf : DifferentiableOn ℂ f Ω) (z : Ω) (hz : f z = z) (h'z : deriv f z = 1) :\n ∃ (f_lin : ℂ →L[ℂ] ℂ), ∀ x ∈ Ω, f x = f_lin x := sorry", "formal_proof": null, "informal_stmt": "Let $\\Omega$ be a bounded open subset of $\\mathbb{C}$, and $\\varphi: \\Omega \\rightarrow \\Omega$ a holomorphic function. Prove that if there exists a point $z_{0} \\in \\Omega$ such that $\\varphi\\left(z_{0}\\right)=z_{0} \\quad \\text { and } \\quad \\varphi^{\\prime}\\left(z_{0}\\right)=1$ then $\\varphi$ is linear.\n\\begin{proof}\n When $\\Omega$ is connected, if $\\varphi$ is not linear, then there exists $n \\geq 2$ and $a_n \\neq 0$, such that\n$$\n\\varphi(z)=z+a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nAs you have noticed, by induction, it follows that for every $k \\geq 1$,\n$$\n\\varphi^k(z)=z+k a_n\\left(z-z_0\\right)^n+O\\left(\\left(z-z_0\\right)^{n+1}\\right) .\n$$\nLet $r>0$ be such that when $\\left|z-z_0\\right| \\leq r$, then $z \\in \\Omega$. Then by (1),\n$$\nk a_n=\\frac{1}{2 \\pi i} \\int_{\\left|z-z_0\\right|=r} \\frac{\\varphi^k(z)}{\\left(z-z_0\\right)^{n+1}} d z .\n$$\nSince $\\varphi^k(\\Omega) \\subset \\Omega$ and since $\\Omega$ is bounded, there exists $M>0$, independent of $k$, such that $\\left|\\varphi^k\\right| \\leq M$ on $\\Omega$. Then by (2),\n$$\nk\\left|a_n\\right| \\leq M r^{-n} .\n$$\nSince $k$ is arbitrary, $a_n=0$, a contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_2_13", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_2_13 {f : ℂ → ℂ}\n (hf : ∀ z₀ : ℂ, ∃ (s : Set ℂ) (c : ℕ → ℂ), IsOpen s ∧ z₀ ∈ s ∧\n ∀ z ∈ s, Tendsto (λ n => ∑ i ∈ range n, (c i) * (z - z₀)^i) atTop (𝓝 (f z₀))\n ∧ ∃ i, c i = 0) :\n ∃ (c : ℕ → ℂ) (n : ℕ), f = λ z => ∑ i ∈ range n, (c i) * z ^ n := sorry", "formal_proof": null, "informal_stmt": "Suppose $f$ is an analytic function defined everywhere in $\\mathbb{C}$ and such that for each $z_0 \\in \\mathbb{C}$ at least one coefficient in the expansion $f(z) = \\sum_{n=0}^\\infty c_n(z - z_0)^n$ is equal to 0. Prove that $f$ is a polynomial.\n\\begin{proof}\nSay that at least one of the coefficients of the Taylor series vanishes is the same as saying that for every $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$.\nConsider $A_n:=\\left\\{z \\in \\mathbb{C}: f^{(n)}(z)=0\\right\\}$ for each $n \\in \\mathbb{N}$. Note that:\n$f$ is polynomial iff $A_n$ is not countable for some $n \\in \\mathbb{N}$.\nIndeed, if $f$ is polynomial of degree $n$, then $f^{(n+1)}(z)=0$ for all $z \\in \\mathbb{C}$, then $A_{n+1}=\\mathbb{C}$, so, $A_{n+1}$ is not countable. Conversely, if there is $n \\in \\mathbb{C}$ such that $A_n$ is not countable, then $A_n$ has a limit point, then by Identity principle we have $f^{(n)}(z)=0$ for all $z \\in \\mathbb{C}$, so, $f$ is a polynomial of degree at most $n-1$.\n\nTherefore, tt suffices to show that there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable. Indeed, consider $\\bigcup_{n \\in \\mathbb{N}} A_n$, by hypothesis for each $a \\in \\mathbb{C}$ there is $m \\in \\mathbb{N}$ such that $f^{(m)}(a)=0$, then $\\mathbb{C} \\subseteq \\bigcup_{n \\in \\mathbb{N}} A_n$. Therefore, $\\bigcup_{n \\in \\mathbb{N}} A_n$ is not countable, then there is $n \\in \\mathbb{N}$ such that $A_n$ is not countable.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_3", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_3 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, Real.cos x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a) / a))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{\\cos x}{x^2 + a^2} dx = \\pi \\frac{e^{-a}}{a}$ for $a > 0$.\n\\begin{proof}\n $\\cos x=\\frac{e^{i x}+e^{-i x}}{2}$. changing $x \\rightarrow-x$ we see that we can just integrate $e^{i x} /\\left(x^2+a^2\\right)$ and we'll get the same answer. Again, we use the same semicircle and part of the real line. The only pole is $x=i a$, it has order 1 and the residue at it is $\\lim _{x \\rightarrow i a} \\frac{e^{i x}}{x^2+a^2}(x-i a)=\\frac{e^{-a}}{2 i a}$, which multiplied by $2 \\pi i$ gives the answer.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_4", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_4 (a : ℝ) (ha : 0 < a) :\n Tendsto (λ y => ∫ x in -y..y, x * Real.sin x / (x ^ 2 + a ^ 2))\n atTop (𝓝 (Real.pi * (Real.exp (-a)))) := sorry", "formal_proof": null, "informal_stmt": "Show that $ \\int_{-\\infty}^{\\infty} \\frac{x \\sin x}{x^2 + a^2} dx = \\pi e^{-a}$ for $a > 0$.\n\\begin{proof}\n$$\nx /\\left(x^2+a^2\\right)=x / 2 i a(1 /(x-i a)-1 /(x+i a))=1 / 2 i a(i a /(x-i a)+i a /(x+\n$$\n$i a))=(1 /(x-i a)+1 /(x+i a)) / 2$. So we care about $\\sin (x)(1 /(x-i a)+$ $1 /(x+i a)) / 2$. Its residue at $x=i a$ is $\\sin (i a) / 2=\\left(e^{-a}-e^a\\right) / 4 i$.?\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_9", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_9 : ∫ x in (0 : ℝ)..(1 : ℝ), Real.log (Real.sin (Real.pi * x)) = - Real.log 2 := sorry", "formal_proof": null, "informal_stmt": "Show that $\\int_0^1 \\log(\\sin \\pi x) dx = - \\log 2$.\n\\begin{proof}\nConsider\n$$\n\\begin{gathered}\nf(z)=\\log \\left(1-e^{2 \\pi z i}\\right)=\\log \\left(e^{\\pi z i}\\left(e^{-\\pi z i}-e^{\\pi z i}\\right)\\right)=\\log (-2 i)+\\pi z i+\\log \\\\\n(\\sin (\\pi z))\n\\end{gathered}\n$$\nThen we have\n$$\n\\begin{aligned}\n\\int_0^1 f(z) d z & =\\log (-2 i)+\\frac{i \\pi}{2}+\\int_0^1 \\log (\\sin (\\pi z)) d z \\\\\n& =\\int_0^1 \\log (\\sin (\\pi z)) d z+\\log (-2 i)+\\log (i) \\\\\n& =\\log (2)+\\int_0^1 \\log (\\sin (\\pi z)) d z\n\\end{aligned}\n$$\nNow it suffices to show that $\\int_0^1 f(z) d z=0$. Consider the contour $C(\\epsilon, R)$ (which is the contour given in your question) given by the following.\n1. $C_1(\\epsilon, R)$ : The vertical line along the imaginary axis from $i R$ to $i \\epsilon$.\n2. $C_2(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 0 .\n3. $C_3(\\epsilon)$ : Along the real axis from $(\\epsilon, 1-\\epsilon)$.\n4. $C_4(\\epsilon)$ : The quarter turn of radius $\\epsilon$ about 1 .\n5. $C_5(\\epsilon, R)$ : The vertical line from $1+i \\epsilon$ to $1+i R$.\n6. $C_6(R)$ : The horizontal line from $1+i R$ to $i R$.\n$f(z)$ is analytic inside the contour $C$ and hence $\\oint_C f(z)=0$. This gives us\n$$\n\\begin{aligned}\n\\int_{C_1(\\epsilon, R)} f d z+\\int_{C_2(\\epsilon)} f d z+\\int_{C_3(\\epsilon)} f d z+\\int_{C_4(\\epsilon)} f d z+\\int_{C_5(\\epsilon, R)} f d z+\\int_{C_6(R)} f d z \\\\\n=0\n\\end{aligned}\n$$\nNow the integral along 1 cancels with the integral along 5 due to symmetry. Integrals along 2 and 4 scale as $\\epsilon \\log (\\epsilon)$. Integral along 6 goes to 0 as $R \\rightarrow \\infty$. This gives us\n$$\n\\lim _{\\epsilon \\rightarrow 0} \\int_{C_3(\\epsilon)} f d z=0\n$$\nwhich is what we need.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_14", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_14 {f : ℂ → ℂ} (hf : Differentiable ℂ f)\n (hf_inj : Function.Injective f) :\n ∃ (a b : ℂ), f = (λ z => a * z + b) ∧ a ≠ 0 := sorry", "formal_proof": null, "informal_stmt": "Prove that all entire functions that are also injective take the form $f(z) = az + b$, $a, b \\in \\mathbb{C}$ and $a \\neq 0$.\n\\begin{proof}\nLook at $f(1 / z)$. If it has an essential singularity at 0 , then pick any $z_0 \\neq 0$. Now we know that the range of $f$ is dense as $z \\rightarrow 0$. We also know that the image of $f$ in some small ball around $z_0$ contains a ball around $f\\left(z_0\\right)$. But this means that the image of $f$ around this ball intersects the image of $f$ in any arbitrarily small ball around 0 (because of the denseness). Thus, $f$ cannot be injective. So the singularity at 0 is not essential, so $f(1 / z)$ is some polynomial of $1 / z$, so $f$ is some polynomial of $z$. If its degree is more than 1 it is not injective (fundamental theorem of algebra), so the degree of $f$ is 1 .\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_3_22", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_3_22 (D : Set ℂ) (hD : D = ball 0 1) (f : ℂ → ℂ)\n (hf : DifferentiableOn ℂ f D) (hfc : ContinuousOn f (closure D)) :\n ¬ ∀ z ∈ (sphere (0 : ℂ) 1), f z = 1 / z := sorry", "formal_proof": null, "informal_stmt": "Show that there is no holomorphic function $f$ in the unit disc $D$ that extends continuously to $\\partial D$ such that $f(z) = 1/z$ for $z \\in \\partial D$.\n\\begin{proof}\n Consider $g(r)=\\int_{|z|=r} f(z) d z$. Cauchy theorem implies that $g(r)=0$ for all $r<1$. Now since $\\left.f\\right|_{\\partial D}=1 / z$ we have $\\lim _{r \\rightarrow 1} \\int_{|z|=r} f(z) d z=\\int_{|z|=1} \\frac{1}{z} d z=\\frac{2}{\\pi i} \\neq 0$. Contradiction.\n\\end{proof}", "informal_proof": "Let $f(z)=f(x, y)=u(x, y)+i v(x, y)$, where $z=x+i y$. Since $\\operatorname{Re}(f)=$ constant, $$ \\frac{\\partial u}{\\partial x}=0, \\frac{\\partial u}{\\partial y}=0 . $$ By the Cauchy-Riemann equations, $$ \\frac{\\partial v}{\\partial x}=-\\frac{\\partial u}{\\partial y}=0 . $$ Thus, in $\\Omega$, $$ f^{\\prime}(z)=\\frac{\\partial f}{\\partial x}=\\frac{\\partial u}{\\partial x}+i \\frac{\\partial v}{\\partial x}=0+0=0 . $$ 3 Thus $f(z)$ is constant."} +{"name": "Shakarchi_exercise_5_1", "source": "Shakarchi.lean", "header": "import Mathlib\n\nopen Complex Filter Function Metric Finset\nopen scoped BigOperators Topology\n", "formal_statement": "theorem Shakarchi_exercise_5_1 (f : ℂ → ℂ) (hf : DifferentiableOn ℂ f (ball 0 1))\n (hb : Bornology.IsBounded (Set.range f)) (h0 : f ≠ 0) (zeros : ℕ → ℂ) (hz : ∀ n, f (zeros n) = 0)\n (hzz : Set.range zeros = {z | f z = 0 ∧ z ∈ (ball (0 : ℂ) 1)}) :\n ∃ (z : ℂ), Tendsto (λ n => (∑ i ∈ range n, (1 - zeros i))) atTop (𝓝 z) := sorry", "formal_proof": null, "informal_stmt": "Prove that if $f$ is holomorphic in the unit disc, bounded and not identically zero, and $z_{1}, z_{2}, \\ldots, z_{n}, \\ldots$ are its zeros $\\left(\\left|z_{k}\\right|<1\\right)$, then $\\sum_{n}\\left(1-\\left|z_{n}\\right|\\right)<\\infty$.\n\\begin{proof}\n Fix $\\mathrm{N}$ and let $D(0, R)$ contains the first $\\mathrm{N}$ zeroes of f. Let $S_N=\\sum_{k=1}^N\\left(1-\\left|z_k\\right|\\right)=$ $\\sum_{k=1}^N \\int_{\\left|z_k\\right|}^1 1 d r$. Let $\\eta_k$ be the characteristic function of the interval $\\left.\\| z_k \\mid, 1\\right]$. We have $S_N=\\sum_{k=1}^N \\int_0^1 \\eta(r) d r=\\int_0^1\\left(\\sum_{k=1}^N \\eta_k(r)\\right) d r \\leq \\int_0^1 n(r) d r$, where $n(r)$ is the number of zeroes of $f$ at the disk $D(0, r)$. For $r \\leq 1$ we have $n(r) \\leq \\frac{n(r)}{r}$. This means that $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}$. If $f(0)=0$ then we have $f(z)=z^m g(z)$ for some integer $\\mathrm{m}$ and some holomorphic $g$ with $g(0) \\neq 0$. The other zeroes of $\\mathrm{f}$ are precisely the zeroes of $g$. Thus we have reduced the problem to $f(0) \\neq 0$. By the Corollary of the Jensen's equality we get $S_N \\leq \\int_0^1 n(r) \\frac{d r}{r}=\\frac{1}{2 \\pi} \\int_0^{2 \\pi} \\log \\left|f\\left(R e^{i \\pi}\\right)\\right| d \\phi-\\log |f(0)| Tuple: + """Create a sorting key that handles numeric parts correctly. + + For names like 'Artin_exercise_2_11_3', this will create a tuple with proper + numeric sorting. For mixed alphanumeric parts like '3a' or '16c', it will + split them into numeric and alphabetic components for proper sorting. + """ + parts = name.split('_') + sort_key = [] + + for i, part in enumerate(parts): + if part.isdigit(): + # Pure numeric part: (0, number, '') + sort_key.append((0, int(part), '')) + else: + # Check if this is a mixed alphanumeric part (like '3a', '16c') + match = re.match(r'^(\d+)([a-zA-Z]+)$', part) + if match: + # Mixed alphanumeric: (0, numeric_part, alpha_part) + # This ensures 2a comes before 11, but after 2 + numeric_part = int(match.group(1)) + alpha_part = match.group(2) + sort_key.append((0, numeric_part, alpha_part)) + else: + # Pure string part: (1, 0, string) + sort_key.append((1, 0, part)) + + return tuple(sort_key) + + def extract_local_bindings(declaration_text: str) -> Set[str]: """Extract local variable names from a declaration.""" local_vars = set() @@ -254,34 +284,40 @@ def main(): path = os.path.join(informal_dir, fname) informal_texts[key] = open(path, 'r', encoding='utf-8').read() - # build entries and write jsonl + # build entries first + all_records = [] + for f_name in os.listdir(formal_dir): + if not f_name.endswith('.lean'): continue + fpath = os.path.join(formal_dir, f_name) + # determine the key for informal tex lookup by file name without extension + file_key = os.path.splitext(f_name)[0] + header, source, entries = parse_formal_file(fpath) + for e in entries: + orig = e['orig_name'] + # lookup informal tex by the formal file base name + tex_text = informal_texts.get(file_key) + if tex_text: + inf_stmt, inf_proof = parse_informal_tex(tex_text, orig) + else: + inf_stmt = inf_proof = None + log_missing.append(e['name']) + record = { + 'name': e['name'], + 'source': source, + 'header': header, + 'formal_statement': e['formal_statement'], + 'formal_proof': e['formal_proof'], + 'informal_stmt': inf_stmt, + 'informal_proof': inf_proof + } + all_records.append(record) + + # sort records by name using numeric-aware sorting and write jsonl + all_records.sort(key=lambda x: create_sort_key(x['name'])) with open(output_file, 'w', encoding='utf-8') as outp: - for f_name in os.listdir(formal_dir): - if not f_name.endswith('.lean'): continue - fpath = os.path.join(formal_dir, f_name) - # determine the key for informal tex lookup by file name without extension - file_key = os.path.splitext(f_name)[0] - header, source, entries = parse_formal_file(fpath) - for e in entries: - orig = e['orig_name'] - # lookup informal tex by the formal file base name - tex_text = informal_texts.get(file_key) - if tex_text: - inf_stmt, inf_proof = parse_informal_tex(tex_text, orig) - else: - inf_stmt = inf_proof = None - log_missing.append(e['name']) - record = { - 'name': e['name'], - 'source': source, - 'header': header, - 'formal_statement': e['formal_statement'], - 'formal_proof': e['formal_proof'], - 'informal_stmt': inf_stmt, - 'informal_proof': inf_proof - } - json.dump(record, outp, ensure_ascii=False) - outp.write('\n') + for record in all_records: + json.dump(record, outp, ensure_ascii=False) + outp.write('\n') # log missing informal log_file = os.path.join(base, 'script', 'missing_informal.log')