New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Merged by Bors] - feat(ring_theory/polynomial): define the probabilist's Hermite polynomials #18739
Conversation
define the Hermite polynomials
Can you add the result that |
Whoops - misclicked the "close" button. Sorry about that. |
I think this will be easier once @lukemantle has PRed
|
I left some comments at 7e00f85#comments, they seem not to be showing up here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I recommend you add an entry to https://github.com/leanprover-community/mathlib4/wiki/port-comments/_edit asking people not to port this file yet; I imagine you will want to add to it in a future PR, and having someone port it immediately will just be unhelpful.
Co-authored-by: jakelev <levinson.jake@gmail.com>
Ok, that sounds like a good idea. How can I add an entry to that file? |
Just merge master, that will solve the lint-style issue. |
/-- the nth probabilist's Hermite polynomial -/ | ||
noncomputable def hermite : ℕ → polynomial ℤ | ||
| 0 := 1 | ||
| (n+1) := X * (hermite n) - (hermite n).derivative | ||
|
||
@[simp] lemma hermite_succ {n : ℕ} : hermite (n+1) = X * (hermite n) - (hermite n).derivative := | ||
by rw hermite | ||
|
||
lemma hermite_eq_iter {n : ℕ} : hermite n = nat.iterate (λp, X*p - p.derivative) n 1 := | ||
begin | ||
induction n with n ih, | ||
{ refl }, | ||
{ rw [function.iterate_succ_apply', ← ih, hermite_succ] } | ||
end | ||
|
||
@[simp] lemma hermite_zero : hermite 0 = C 1 := rfl | ||
|
||
@[simp] lemma hermite_one : hermite 1 = X := | ||
begin | ||
rw [hermite_succ, hermite_zero], | ||
simp only [map_one, mul_one, derivative_one, sub_zero] | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should all be wrapped in namespace polynomial
| 0 := 1 | ||
| (n+1) := X * (hermite n) - (hermite n).derivative | ||
|
||
@[simp] lemma hermite_succ {n : ℕ} : hermite (n+1) = X * (hermite n) - (hermite n).derivative := |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
n
should be explicit (()
not {}
) here and below
@[simp] lemma hermite_succ {n : ℕ} : hermite (n+1) = X * (hermite n) - (hermite n).derivative := | ||
by rw hermite | ||
|
||
lemma hermite_eq_iter {n : ℕ} : hermite n = nat.iterate (λp, X*p - p.derivative) n 1 := |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lean has notation for nat.iterate
, I think it's
lemma hermite_eq_iter {n : ℕ} : hermite n = nat.iterate (λp, X*p - p.derivative) n 1 := | |
lemma hermite_eq_iterate {n : ℕ} : hermite n = (λ p, X*p - p.derivative)^[n] 1 := |
I also changed the name; we rarely abbreviate function names unless they're really really long.
bors d+ Please merge once CI passes! Make sure you've done this first
I've done it for you; maybe you don't have permission to edit the page? |
✌️ lukemantle can now approve this pull request. To approve and merge a pull request, simply reply with |
Huh, I don't see the edit icon on the wiki sidebar. Maybe I'm missing some permission? I see you've already added an entry about |
You probably need non-master write access to mathlib4. |
bors merge Thanks! |
…mials (#18739) Define the Hermite polynomials recursively, and show this is equivalent to the result of iterating the operation `x - d/dx` on the constant polynomial `1`. Future PRs will include several equivalent characterizations: - Recursive and explicit expressions for the coefficients - Definition based on the nth derivative of the Gaussian function Co-authored-by: Jake Levinson <levinson.jake@gmail.com> Co-authored-by: lukemantle <62187700+lukemantle@users.noreply.github.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com>
Pull request successfully merged into master. Build succeeded: |
Define the Hermite polynomials recursively, and show this is equivalent to the result of iterating the operation
x - d/dx
on the constant polynomial1
.Future PRs will include several equivalent characterizations:
Co-authored-by: Jake Levinson levinson.jake@gmail.com
Currently,
hermite n
is defined as a polynomial overℤ
. Would it better to generalize this to a polynomial overcomm_ring R
?