-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #229 from ocfnash/main
Fix a few minor Lean misformalisations
- Loading branch information
Showing
5 changed files
with
21 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
import Mathlib | ||
|
||
open Topology MvPolynomial Filter Set Metric | ||
open intervalIntegral MvPolynomial Real | ||
|
||
abbrev putnam_2009_b4_solution : ℕ := sorry | ||
-- 2020050 | ||
/-- | ||
Say that a polynomial with real coefficients in two variables, $x,y$, is \emph{balanced} if the average value of the polynomial on each circle centered at the origin is $0$. The balanced polynomials of degree at most $2009$ form a vector space $V$ over $\mathbb{R}$. Find the dimension of $V$. | ||
-/ | ||
theorem putnam_2009_b4 | ||
(balanced : MvPolynomial (Fin 2) ℝ → Prop) | ||
(hbalanced : balanced = fun P ↦ ∀ r > 0, (∫ x in Metric.sphere (0 : EuclideanSpace ℝ (Fin 2)) r, MvPolynomial.eval x P) / (2 * Real.pi * r) = 0) | ||
(V : Set (MvPolynomial (Fin 2) ℝ)) [AddCommGroup V] [Module ℝ V] | ||
(hV : ∀ P : MvPolynomial (Fin 2) ℝ, P ∈ V ↔ balanced P ∧ P.totalDegree ≤ 2009) | ||
: (Module.rank V = putnam_2009_b4_solution) := | ||
sorry | ||
(IsBalanced : MvPolynomial (Fin 2) ℝ → Prop) | ||
(IsBalanced_def : ∀ P, IsBalanced P ↔ ∀ r > 0, | ||
(∫ t in (0 : ℝ)..(2 * π), eval ![r * cos t, r * sin t] P) / (2 * π * r) = 0) | ||
(V : Submodule ℝ (MvPolynomial (Fin 2) ℝ)) | ||
(V_def : ∀ P, P ∈ V ↔ IsBalanced P ∧ P.totalDegree ≤ 2009) : | ||
Module.rank ℝ V = putnam_2009_b4_solution := | ||
sorry |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,14 @@ | ||
import Mathlib | ||
|
||
open Polynomial | ||
|
||
/-- | ||
Let $Q_0(x)=1$, $Q_1(x)=x$, and $Q_n(x)=\frac{(Q_{n-1}(x))^2-1}{Q_{n-2}(x)}$ for all $n \geq 2$. Show that, whenever $n$ is a positive integer, $Q_n(x)$ is equal to a polynomial with integer coefficients. | ||
-/ | ||
theorem putnam_2017_a2 | ||
(Q : ℕ → ℝ → ℝ) | ||
(hQbase : ∀ x : ℝ, Q 0 x = 1 ∧ Q 1 x = x) | ||
(hQn : ∀ n ≥ 2, ∀ x : ℝ, Q n x = ((Q (n - 1) x) ^ 2 - 1) / Q (n - 2) x) | ||
: ∀ n > 0, ∃ P : Polynomial ℝ, (∀ i : ℕ, P.coeff i = round (P.coeff i)) ∧ Q n = P.eval := | ||
sorry | ||
(Q : ℕ → RatFunc ℚ) | ||
(hQbase : Q 0 = 1 ∧ Q 1 = (X : ℚ[X])) | ||
(hQn : ∀ n, Q (n + 2) = (Q (n + 1) ^ 2 - 1) / Q n) | ||
(n : ℕ) (hn : 0 < n) : | ||
∃ P : ℤ[X], Q n = P.map (Int.castRingHom ℚ) := | ||
sorry |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters