SpECTRE  v2026.04.01
Loading...
Searching...
No Matches
grmhd::AnalyticData::MagneticRotor Class Reference

Analytic initial data for a magnetic rotor. More...

#include <MagneticRotor.hpp>

Classes

struct  AdiabaticIndex
 The adiabatic index of the ideal fluid. More...
struct  AngularVelocity
 Angular velocity inside the rotor. More...
struct  BackgroundDensity
 Density outside the rotor. More...
struct  MagneticField
 The x,y,z components of the uniform magnetic field threading the matter. More...
struct  Pressure
 Uniform pressure inside and outside the rotor. More...
struct  RotorDensity
 Density inside the rotor. More...
struct  RotorRadius
 Radius of the rotor. More...

Public Types

using equation_of_state_type = EquationsOfState::IdealFluid<true>
using options
Public Types inherited from grmhd::AnalyticDataBase
template<typename DataType>
using tags

Public Member Functions

 MagneticRotor (const MagneticRotor &)=default
MagneticRotoroperator= (const MagneticRotor &)=default
 MagneticRotor (MagneticRotor &&)=default
MagneticRotoroperator= (MagneticRotor &&)=default
 MagneticRotor (double rotor_radius, double rotor_density, double background_density, double pressure, double angular_velocity, const std::array< double, 3 > &magnetic_field, double adiabatic_index, const Options::Context &context={})
auto get_clone () const -> std::unique_ptr< evolution::initial_data::InitialData > override
template<typename DataType, typename Tag1, typename Tag2, typename... Tags>
tuples::TaggedTuple< Tag1, Tag2, Tags... > variables (const tnsr::I< DataType, 3 > &x, tmpl::list< Tag1, Tag2, Tags... >) const
 Retrieve a collection of hydrodynamic variables at position x.
template<typename DataType, typename Tag, Requires< tmpl::list_contains_v< gr::analytic_solution_tags< 3, DataType >, Tag > > = nullptr>
tuples::TaggedTuple< Tag > variables (const tnsr::I< DataType, 3 > &x, tmpl::list< Tag >) const
 Retrieve the metric variables.
const EquationsOfState::IdealFluid< true > & equation_of_state () const
void pup (PUP::er &) override
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::RestMassDensity< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::RestMassDensity< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::ElectronFraction< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::ElectronFraction< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::SpecificInternalEnergy< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::SpecificInternalEnergy< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::Pressure< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::Pressure< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::SpatialVelocity< DataType, 3 > >) const -> tuples::TaggedTuple< hydro::Tags::SpatialVelocity< DataType, 3 > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::MagneticField< DataType, 3 > >) const -> tuples::TaggedTuple< hydro::Tags::MagneticField< DataType, 3 > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::DivergenceCleaningField< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::DivergenceCleaningField< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::LorentzFactor< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::LorentzFactor< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::SpecificEnthalpy< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::SpecificEnthalpy< DataType > >
 Retrieve the GRMHD variables at a given position.
template<typename DataType>
auto variables (const tnsr::I< DataType, 3 > &x, tmpl::list< hydro::Tags::Temperature< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::Temperature< DataType > >
 Retrieve the GRMHD variables at a given position.
Public Member Functions inherited from hydro::TemperatureInitialization< MagneticRotor >
auto variables (const tnsr::I< DataType, Dim > &x, tmpl::list< hydro::Tags::Temperature< DataType > >) const -> tuples::TaggedTuple< hydro::Tags::Temperature< DataType > >

Static Public Attributes

static constexpr Options::String help
Static Public Attributes inherited from grmhd::AnalyticDataBase
static constexpr size_t volume_dim = 3_st

Friends

bool operator== (const MagneticRotor &lhs, const MagneticRotor &rhs)
bool operator!= (const MagneticRotor &lhs, const MagneticRotor &rhs)

Detailed Description

Analytic initial data for a magnetic rotor.

This is a test first described in [8] for classical MHD and later generalised to relativistic MHD in [51]

This effectively 2D test initially consists of an infinitely long cylinder of radius RotorRadius rotating about the z-axis with the given AngularVelocity. The rest mass density of the fluid inside the rotor, RotorDensity, is higher than the BackgroundDensity outside of the rotor. The fluid is at a constant Pressure. The rotor is embedded in a constant MagneticField (usually taken to be along the x-axis). The fluid is an ideal fluid with the given AdiabaticIndex. Evolving the initial data, magnetic braking will slow down the rotor, while dragging the magnetic field lines.

The standard test setup is done on a unit cube \([-0.5,0.5]^3\) with the following values given for the options:

Note that [218] uses different parameters,

The magnetic field in the disk should rotate by about 90 degrees by t = 0.4.

Member Typedef Documentation

◆ options

using grmhd::AnalyticData::MagneticRotor::options
Initial value:
The -, -, and -velocity.
Definition ScalingAndZRotation.hpp:100
The adiabatic index of the ideal fluid.
Definition BlastWave.hpp:120
The x,y,z components of the uniform magnetic field threading the matter.
Definition BlastWave.hpp:114
The mass density outside of the strip.
Definition KhInstability.hpp:123
The initial (constant) pressure of the fluid.
Definition KhInstability.hpp:138
Density inside the rotor.
Definition MagneticRotor.hpp:82
Radius of the rotor.
Definition MagneticRotor.hpp:75

Member Function Documentation

◆ get_clone()

auto grmhd::AnalyticData::MagneticRotor::get_clone ( ) const -> std::unique_ptr< evolution::initial_data::InitialData >
overridevirtual

Member Data Documentation

◆ help

Options::String grmhd::AnalyticData::MagneticRotor::help
staticconstexpr
Initial value:
= {
"Magnetic rotor analytic initial data."}

The documentation for this class was generated from the following file:
  • src/PointwiseFunctions/AnalyticData/GrMhd/MagneticRotor.hpp