Todo #6YB2U: the force corresponding to the harmonic oscillator potential#604
Conversation
|
Thank you for your PR! The following checklist can be used to ensure that the PR is as helpful as possible and to help maintain the quality of the project. This checklist is experimental and can be ignored if you wish. Documentation
Lemmas and theorems
Layout
Usage of AI Please tick one that applies to this PR:
|
| simp only [mul_smul] | ||
| have h4 : (2 : ℕ) • (2⁻¹ : ℝ) • S.k • x = (2 : ℝ) • (2⁻¹ : ℝ) • S.k • x := by | ||
| norm_cast | ||
| rw [h4] |
There was a problem hiding this comment.
you could do rw [show (2 : ℕ) • (2⁻¹ : ℝ) • S.k • x = (2 : ℝ) • (2⁻¹ : ℝ) • S.k • x by norm_cast] here instead of the have, but yeah I don't think there is a simpler way.
There was a problem hiding this comment.
shouldn't the grad_inner have (2:ℝ) in the definition which avoids this?
There was a problem hiding this comment.
Yeah, I think that would be an option.
There was a problem hiding this comment.
Would probably make things easier in the long run aswell
|
Concerning the linters, let me point out that they can be run locally using |
Thanks, I was actually looking for a way to run them locally but couldn't find it. I will do this shortly. |
|
This took me a lot of time and effort but everything should be sorry free. I highly suspect a lot of the results can be golfed still, but I will mark this PR as ready for review now. |
jstoobysmith
left a comment
There was a problem hiding this comment.
Great! This looks really great to me! Thank you for putting in the effort to do this! I don't see any needed changes so have approved this PR - feel free to merge (let me know if you can't).
Once again thanks for this!
This PR derives the force that is the consequence of the harmonic oscillator potential, alongside some useful API lemmas.
Suggestions on improvements are appreciated, especially on some of the
havestatements that derive really basic stuff.