-
Notifications
You must be signed in to change notification settings - Fork 308
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
Create class to represent MHD normalizations #1029
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1029 +/- ##
==========================================
- Coverage 95.18% 94.96% -0.23%
==========================================
Files 103 104 +1
Lines 9412 9524 +112
Branches 2153 2182 +29
==========================================
+ Hits 8959 9044 +85
- Misses 276 300 +24
- Partials 177 180 +3 ☔ View full report in Codecov by Sentry. |
Thank you for contributing to PlasmaPy! The project's future depends deeply on contributors like you, so we deeply appreciate it! 🌱 The following checklist will be used by the code reviewer to help guide the code review process.
|
…nto mhd-normalizations-2
Apparently the setter should go outside @particle_input
This PR will add a class that represents a particular system of normalizations that is commonly used for the equations of MHD, in particular for simulations and theory where we can't be bothered to deal with units. I'm just getting started on this, but will probably use some commits that I had temporarily had in #859, though I ultimately decided to reduce the scope of that PR to an abstract base class. This partially addresses #808, but there are other common normalizations that will need to be added (hence the abstract base class).
At the moment I'm thinking that it would be good to allow the inputs to be
Quantity
instances with the value of the normalization coefficient,Unit
instances (for example if we want to normalize length to1 * u.mm
, or aParticleLike
object (since the choice of ion matters when going between mass density and number density). It'd also be good to be flexible in what inputs the user may provide. I usually setL
,n
, andB
, but others might normalize to different things. I'm also wondering if there would be a good way to allow users to specify that the function to normalize length to would be, e.g., the ion inertial length or gyroradius.