-
Notifications
You must be signed in to change notification settings - Fork 189
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
Make magnetic field configuration runtime choice #5548
Make magnetic field configuration runtime choice #5548
Conversation
src/PointwiseFunctions/AnalyticData/GrMhd/InitialMagneticFields/Poloidal.cpp
Show resolved
Hide resolved
src/PointwiseFunctions/AnalyticData/GrMhd/InitialMagneticFields/Poloidal.hpp
Show resolved
Hide resolved
src/PointwiseFunctions/AnalyticData/GrMhd/InitialMagneticFields/Toroidal.hpp
Show resolved
Hide resolved
@@ -194,32 +195,14 @@ class MagnetizedTovStar : public virtual evolution::initial_data::InitialData, | |||
using tov_star = RelativisticEuler::Solutions::TovStar; | |||
|
|||
public: | |||
struct PressureExponent { | |||
using type = size_t; | |||
struct MagneticFields { |
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.
update the class documentation to using arbitrary fields
2, 0.04, 2500.0, std::array{0.0, 0.0, 0.0}, 100.0), | ||
std::make_unique< | ||
grmhd::AnalyticData::InitialMagneticFields::Toroidal>( | ||
2, 0.04, 2500.0, std::array{0.0, 0.0, 0.0}, 100.0)))); |
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.
Add a test where you compare the created B field from two different solutions where the InitialMagneticField pointers are in order (Poloidal, Toroidal) vs (Toroidal, Poloidal)
src/PointwiseFunctions/AnalyticData/GrMhd/InitialMagneticFields/Poloidal.cpp
Outdated
Show resolved
Hide resolved
dc6c932
to
6b19603
Compare
Rebased and pushed fixups. Thanks for the review! |
tests/Unit/PointwiseFunctions/AnalyticData/GrMhd/Test_MagnetizedTovStar.cpp
Show resolved
Hide resolved
6b19603
to
4f054ef
Compare
Proposed changes
Closes #4562
We will also be able to add a mutator or something to add it to the numerical initial data. I haven't looked into that, but that'll allow us to superpose a B-field in BNS simulations quite easily.
Upgrade instructions
Code review checklist
make doc
to generate the documentation locally intoBUILD_DIR/docs/html
.Then open
index.html
.code review guide.
bugfix
ornew feature
if appropriate.Further comments