AnalyticDataHelpers.hpp
1 // Distributed under the MIT License.
2 // See LICENSE.txt for details.
3 
4 #pragma once
5 
6 #include <complex>
7 #include <cstddef>
8 
9 #include "DataStructures/ComplexDataVector.hpp"
10 #include "DataStructures/DataVector.hpp"
11 #include "DataStructures/SpinWeighted.hpp"
13 #include "Evolution/Systems/Cce/AnalyticSolutions/SphericalMetricData.hpp"
14 #include "Evolution/Systems/Cce/Tags.hpp"
15 #include "Utilities/TaggedTuple.hpp"
16 
17 namespace Cce {
18 namespace Solutions {
19 namespace TestHelpers {
20 
21 // This function determines the Bondi-Sachs scalars from a Cartesian spacetime
22 // metric, assuming that the metric is already in null form, so the spatial
23 // coordinates are related to standard Bondi-Sachs coordinates by just the
24 // standard Cartesian to spherical Jacobian.
26 extract_bondi_scalars_from_cartesian_metric(
27  const tnsr::aa<DataVector, 3>& spacetime_metric,
28  const CartesianiSphericalJ& inverse_jacobian,
29  double extraction_radius) noexcept;
30 
31 // This function determines the time derivative of the Bondi-Sachs scalars
32 // from the time derivative of a Cartesian spacetime metric, the Cartesian
33 // metric, and Jacobian factors. This procedure assumes that the metric is
34 // already in null form, so the spatial coordinates are related to standard
35 // Bondi-Sachs coordinates by just the standard cartesian to spherical Jacobian.
38 extract_dt_bondi_scalars_from_cartesian_metric(
39  const tnsr::aa<DataVector, 3>& dt_spacetime_metric,
40  const tnsr::aa<DataVector, 3>& spacetime_metric,
41  const CartesianiSphericalJ& inverse_jacobian,
42  double extraction_radius) noexcept;
43 
44 // This function determines the radial derivative of the Bondi-Sachs scalars
45 // from the radial derivative of a Cartesian spacetime metric, the Cartesian
46 // metric, and Jacobian factors. This procedure assumes that the metric is
47 // already in null form, so the spatial coordinates are related to standard
48 // Bondi-Sachs coordinates by just the standard cartesian to spherical Jacobian.
49 tuples::TaggedTuple<Tags::Dr<Tags::BondiBeta>, Tags::Dr<Tags::BondiU>,
50  Tags::Dr<Tags::BondiW>, Tags::Dr<Tags::BondiJ>>
51 extract_dr_bondi_scalars_from_cartesian_metric(
52  const tnsr::aa<DataVector, 3>& dr_spacetime_metric,
53  const tnsr::aa<DataVector, 3>& spacetime_metric,
54  const CartesianiSphericalJ& inverse_jacobian,
55  const CartesianiSphericalJ& dr_inverse_jacobian,
56  double extraction_radius) noexcept;
57 } // namespace TestHelpers
58 } // namespace Solutions
59 } // namespace Cce
cstddef
tuples::TaggedTuple
An associative container that is indexed by structs.
Definition: TaggedTuple.hpp:272
Tags::dt
Prefix indicating a time derivative.
Definition: Prefixes.hpp:32
Cce
The set of utilities for performing Cauchy characteristic evolution and Cauchy characteristic matchin...
Definition: BoundaryComputeAndSendToEvolution.hpp:28
gr::spacetime_metric
void spacetime_metric(gsl::not_null< tnsr::aa< DataType, Dim, Frame > * > spacetime_metric, const Scalar< DataType > &lapse, const tnsr::I< DataType, Dim, Frame > &shift, const tnsr::ii< DataType, Dim, Frame > &spatial_metric) noexcept
Computes the spacetime metric from the spatial metric, lapse, and shift.
Tensor.hpp
complex