SpECTRE  v2024.02.05
domain::creators::bco::TimeDependentMapOptions< IsCylindrical > Struct Template Reference

This holds all options related to the time dependent maps of the binary compact object domains. More...

#include <BinaryCompactObjectHelpers.hpp>

Classes

struct  ExpansionMapOptions
 Options for the expansion map. The outer boundary radius of the map is always set to the outer boundary of the Domain, so there is no option here to set the outer boundary radius. More...
 
struct  InitialTime
 The initial time of the functions of time. More...
 
struct  RotationMapOptions
 

Public Types

using maps_list = tmpl::append< tmpl::list< detail::di_map< Identity > >, detail::produce_all_maps< Frame::Grid, Frame::Inertial, Shape, Expansion, Rotation >, detail::produce_all_maps< Frame::Grid, Frame::Distorted, Shape >, detail::produce_all_maps< Frame::Distorted, Frame::Inertial, Expansion, Rotation > >
 
template<domain::ObjectLabel Object>
using ShapeMapOptions = domain::creators::bco::ShapeMapOptions< IsCylindrical, Object >
 
using options = tmpl::list< InitialTime, ExpansionMapOptions, RotationMapOptions, ShapeMapOptions< domain::ObjectLabel::A >, ShapeMapOptions< domain::ObjectLabel::B > >
 
using IncludeDistortedMapType = tmpl::conditional_t< IsCylindrical, bool, std::optional< size_t > >
 Type to pass to grid_to_distorted_map() and grid_to_inertial_map(). More...
 

Public Member Functions

 TimeDependentMapOptions (double initial_time, std::optional< ExpansionMapOptions > expansion_map_options, std::optional< RotationMapOptions > rotation_options, std::optional< ShapeMapOptions< domain::ObjectLabel::A > > shape_options_A, std::optional< ShapeMapOptions< domain::ObjectLabel::B > > shape_options_B, const Options::Context &context={})
 
std::unordered_map< std::string, std::unique_ptr< domain::FunctionsOfTime::FunctionOfTime > > create_functions_of_time (const std::unordered_map< std::string, double > &initial_expiration_times) const
 Create the function of time map using the options that were provided to this class. More...
 
void build_maps (const std::array< std::array< double, 3 >, 2 > &centers, const std::optional< std::array< double, IsCylindrical ? 2 :3 > > &object_A_radii, const std::optional< std::array< double, IsCylindrical ? 2 :3 > > &object_B_radii, double domain_outer_radius)
 Construct the actual maps that will be used. More...
 
bool has_distorted_frame_options (domain::ObjectLabel object) const
 Check whether options were specified in the constructor for the shape map of this object.
 
template<domain::ObjectLabel Object>
MapType< Frame::Distorted, Frame::Inertialdistorted_to_inertial_map (const IncludeDistortedMapType &include_distorted_map) const
 This will construct the map from Frame::Distorted to Frame::Inertial More...
 
template<domain::ObjectLabel Object>
MapType< Frame::Grid, Frame::Distortedgrid_to_distorted_map (const IncludeDistortedMapType &include_distorted_map) const
 This will construct the maps from the Frame::Grid to the Frame::Distorted. More...
 
template<domain::ObjectLabel Object>
MapType< Frame::Grid, Frame::Inertialgrid_to_inertial_map (const IncludeDistortedMapType &include_distorted_map) const
 This will construct the entire map from the Frame::Grid to the Frame::Inertial. More...
 

Static Public Attributes

static constexpr Options::String help
 
static const std::string expansion_name {"Expansion"}
 
static const std::string expansion_outer_boundary_name
 
static const std::string rotation_name {"Rotation"}
 
static const std::array< std::string, 2 > size_names {{"SizeA", "SizeB"}}
 
static const std::array< std::string, 2 > shape_names
 

Detailed Description

template<bool IsCylindrical>
struct domain::creators::bco::TimeDependentMapOptions< IsCylindrical >

This holds all options related to the time dependent maps of the binary compact object domains.

Details

Since both domains will have the same (overall) time dependent maps, their options are going to be the same as well. The options won't be exactly the same though, so there is a IsCylindrical template parameter to distinguish.

This class will create the FunctionsOfTime needed for the binary compact object domains as well as the actual CoordinateMaps themselves

Note
This struct contains no information about what blocks the time dependent maps will go in.

Member Typedef Documentation

◆ IncludeDistortedMapType

template<bool IsCylindrical>
using domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::IncludeDistortedMapType = tmpl::conditional_t<IsCylindrical, bool, std::optional<size_t> >

Type to pass to grid_to_distorted_map() and grid_to_inertial_map().

Details

If IsCylindrical is true, pass a bool for whether to include a shape map or not. If it's false, pass a std::optional<size_t>. If this has a value, then it includes a shape map. The size_t represents the relative block number around each object in the BinaryCompactObject domain. It should go from 0 to 11 for the 12 blocks surrounding each object.

Member Function Documentation

◆ build_maps()

template<bool IsCylindrical>
void domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::build_maps ( const std::array< std::array< double, 3 >, 2 > &  centers,
const std::optional< std::array< double, IsCylindrical ? 2 :3 > > &  object_A_radii,
const std::optional< std::array< double, IsCylindrical ? 2 :3 > > &  object_B_radii,
double  domain_outer_radius 
)

Construct the actual maps that will be used.

Currently, this constructs a:

  • Expansion: CubicScale<3>
  • Rotation: Rotation<3>
  • ShapeA/B: Shape (with size FunctionOfTime)

If the radii for an object are std::nullopt, this means that a Shape map is not constructed for that object. An identity map will be used instead. If IsCylindrical is true, only pass two radii for the inner/outer radius of the object sphere. If it is false, pass three radii corresponding to the excision radius, the outer radius of the inner sphere, and the radius of the surrounding cube.

◆ create_functions_of_time()

template<bool IsCylindrical>
std::unordered_map< std::string, std::unique_ptr< domain::FunctionsOfTime::FunctionOfTime > > domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::create_functions_of_time ( const std::unordered_map< std::string, double > &  initial_expiration_times) const

Create the function of time map using the options that were provided to this class.

Currently, this will add:

  • Expansion: PiecewisePolynomial<2>
  • ExpansionOuterBoundary: FixedSpeedCubic
  • Rotation: QuaternionFunctionOfTime<3>
  • SizeA/B: PiecewisePolynomial<3>
  • ShapeA/B: PiecewisePolynomial<2>

◆ distorted_to_inertial_map()

template<bool IsCylindrical>
template<domain::ObjectLabel Object>
MapType< Frame::Distorted, Frame::Inertial > domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::distorted_to_inertial_map ( const IncludeDistortedMapType include_distorted_map) const

This will construct the map from Frame::Distorted to Frame::Inertial

If we are including a shape map, then this will be a composition of an CubicScale and Rotation map. If we aren't, this returns a nullptr.

See also
IncludeDistortedMapType

◆ grid_to_distorted_map()

template<bool IsCylindrical>
template<domain::ObjectLabel Object>
MapType< Frame::Grid, Frame::Distorted > domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::grid_to_distorted_map ( const IncludeDistortedMapType include_distorted_map) const

This will construct the maps from the Frame::Grid to the Frame::Distorted.

If we are including a shape map, then this will be a Shape map (with size FunctionOfTime) for the templated Object. If we aren't, then this returns a nullptr.

See also
IncludeDistortedMapType

◆ grid_to_inertial_map()

template<bool IsCylindrical>
template<domain::ObjectLabel Object>
MapType< Frame::Grid, Frame::Inertial > domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::grid_to_inertial_map ( const IncludeDistortedMapType include_distorted_map) const

This will construct the entire map from the Frame::Grid to the Frame::Inertial.

If we are including a shape map, then this map will have a composition of a Shape (with size FunctionOfTime), CubicScale, and Rotation map. If not, there will only be CubicScale and Rotation maps.

See also
IncludeDistortedMapType

Member Data Documentation

◆ expansion_outer_boundary_name

template<bool IsCylindrical>
const std::string domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::expansion_outer_boundary_name
inlinestatic
Initial value:
{
"ExpansionOuterBoundary"}

◆ help

template<bool IsCylindrical>
constexpr Options::String domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::help
staticconstexpr
Initial value:
{
"The options for all time dependent maps in a binary compact object "
"domain. Specify 'None' to not use any time dependent maps."}

◆ shape_names

template<bool IsCylindrical>
const std::array<std::string, 2> domain::creators::bco::TimeDependentMapOptions< IsCylindrical >::shape_names
inlinestatic
Initial value:
{
{"ShapeA", "ShapeB"}}

The documentation for this struct was generated from the following file: