LinearizedBondiSachs.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 #include <limits>
9 #include <memory>
10 #include <vector>
11 
12 #include "DataStructures/SpinWeighted.hpp"
13 #include "Evolution/Systems/Cce/AnalyticSolutions/SphericalMetricData.hpp"
14 #include "Evolution/Systems/Cce/AnalyticSolutions/WorldtubeData.hpp"
15 #include "Evolution/Systems/Cce/Initialize/InitializeJ.hpp"
16 #include "Evolution/Systems/Cce/Tags.hpp"
17 #include "Options/Options.hpp"
18 #include "Options/StdComplex.hpp"
20 #include "Utilities/Gsl.hpp"
21 #include "Utilities/TMPL.hpp"
22 
23 /// \cond
24 class DataVector;
25 class ComplexDataVector;
26 /// \endcond
27 
28 namespace Cce::Solutions {
29 namespace LinearizedBondiSachs_detail {
30 namespace InitializeJ {
31 // First hypersurface Initialization for the
32 // `Cce::Solutions::LinearizedBondiSachs` analytic solution.
33 //
34 // This initialization procedure should not be used except when the
35 // `Cce::Solutions::LinearizedBondiSachs` analytic solution is used,
36 // as a consequence, this initial data generator is deliberately not
37 // option-creatable; it should only be obtained from the `get_initialize_j`
38 // function of `Cce::InitializeJ::LinearizedBondiSachs`.
39 struct LinearizedBondiSachs : ::Cce::InitializeJ::InitializeJ {
40  WRAPPED_PUPable_decl_template(LinearizedBondiSachs); // NOLINT
41  explicit LinearizedBondiSachs(CkMigrateMessage* /*unused*/) noexcept {}
42 
43  LinearizedBondiSachs() = default;
44 
45  LinearizedBondiSachs(double start_time, double frequency,
48  std::complex<double> c_3b) noexcept;
49 
50  std::unique_ptr<InitializeJ> get_clone() const noexcept override;
51 
52  void operator()(
53  gsl::not_null<Scalar<SpinWeighted<ComplexDataVector, 2>>*> j,
54  gsl::not_null<tnsr::i<DataVector, 3>*> cartesian_cauchy_coordinates,
55  gsl::not_null<
56  tnsr::i<DataVector, 2, ::Frame::Spherical<::Frame::Inertial>>*>
57  angular_cauchy_coordinates,
58  const Scalar<SpinWeighted<ComplexDataVector, 2>>& boundary_j,
59  const Scalar<SpinWeighted<ComplexDataVector, 2>>& boundary_dr_j,
60  const Scalar<SpinWeighted<ComplexDataVector, 0>>& r, size_t l_max,
61  size_t number_of_radial_points) const noexcept override;
62 
63  void pup(PUP::er& /*p*/) noexcept override;
64  private:
65  std::complex<double> c_2a_ = std::numeric_limits<double>::signaling_NaN();
66  std::complex<double> c_2b_ = std::numeric_limits<double>::signaling_NaN();
67  std::complex<double> c_3a_ = std::numeric_limits<double>::signaling_NaN();
68  std::complex<double> c_3b_ = std::numeric_limits<double>::signaling_NaN();
69  double frequency_ = std::numeric_limits<double>::signaling_NaN();
70  double time_ = std::numeric_limits<double>::signaling_NaN();
71 };
72 } // namespace InitializeJ
73 
74 // combine the (2,2) and (3,3) modes to collocation values for
75 // `bondi_quantity`
76 template <int Spin, typename FactorType>
77 void assign_components_from_l_factors(
78  gsl::not_null<SpinWeighted<ComplexDataVector, Spin>*> bondi_quantity,
79  const FactorType& l_2_factor, const FactorType& l_3_factor, size_t l_max,
80  double frequency, double time) noexcept;
81 
82 // combine the (2,2) and (3,3) modes to time derivative collocation values for
83 // `bondi_quantity`
84 template <int Spin>
85 void assign_du_components_from_l_factors(
86  gsl::not_null<SpinWeighted<ComplexDataVector, Spin>*> du_bondi_quantity,
87  const std::complex<double>& l_2_factor,
88  const std::complex<double>& l_3_factor, size_t l_max, double frequency,
89  double time) noexcept;
90 } // namespace LinearizedBondiSachs_detail
91 
92 /*!
93  * \brief Computes the analytic data for a Linearized solution to the
94  * Bondi-Sachs equations described in \cite Barkett2019uae.
95  *
96  * \details The solution represented by this function is generated with only
97  * \f$(2,\pm2)\f$ and \f$(3,\pm3)\f$ modes, and is constructed according to the
98  * linearized solution documented in Section VI of \cite Barkett2019uae. For
99  * this solution, we impose additional restrictions that the linearized solution
100  * be asymptotically flat so that it is compatible with the gauge
101  * transformations performed in the SpECTRE regularity-preserving CCE. Using the
102  * notation of \cite Barkett2019uae, we set:
103  *
104  * \f{align*}{
105  * B_2 &= B_3 = 0\\
106  * C_{2b} &= 3 C_{2a} / \nu^2\\
107  * C_{3b} &= -3 i C_{3a} / \nu^3
108  * \f}
109  *
110  * where \f$C_{2a}\f$ and \f$C_{3a}\f$ may be specified freely and are taken via
111  * input option `InitialModes`.
112  */
114  struct InitialModes {
116  static constexpr Options::String help{
117  "The initial modes of the Robinson-Trautman scalar"};
118  };
120  using type = double;
121  static constexpr Options::String help{
122  "The extraction radius of the spherical solution"};
123  static type lower_bound() noexcept { return 0.0; }
124  };
125  struct Frequency {
126  using type = double;
127  static constexpr Options::String help{
128  "The frequency of the linearized modes."};
129  static type lower_bound() noexcept { return 0.0; }
130  };
131 
132  static constexpr Options::String help{
133  "A linearized Bondi-Sachs analytic solution"};
134 
135  using options = tmpl::list<InitialModes, ExtractionRadius, Frequency>;
136 
138 
139  explicit LinearizedBondiSachs(CkMigrateMessage* msg) noexcept
140  : SphericalMetricData(msg) {}
141 
142  // clang doesn't manage to use = default correctly in this case
143  // NOLINTNEXTLINE(hicpp-use-equals-default,modernize-use-equals-default)
144  LinearizedBondiSachs() noexcept {}
145 
146  LinearizedBondiSachs(
147  const std::array<std::complex<double>, 2>& mode_constants,
148  double extraction_radius, double frequency) noexcept;
149 
150  std::unique_ptr<WorldtubeData> get_clone() const noexcept override;
151 
152  void pup(PUP::er& p) noexcept override;
153 
154  std::unique_ptr<Cce::InitializeJ::InitializeJ> get_initialize_j(
155  double start_time) const noexcept override;
156 
157  protected:
158  /// A no-op as the linearized solution does not have substantial shared
159  /// computation to prepare before the separate component calculations.
160  void prepare_solution(const size_t /*output_l_max*/,
161  const double /*time*/) const noexcept override {}
162 
163  /*!
164  * \brief Computes the linearized solution for \f$J\f$.
165  *
166  * \details The linearized solution for \f$J\f$ is given by
167  * \cite Barkett2019uae,
168  *
169  * \f[
170  * J = \sqrt{12} ({}_2 Y_{2\,2} + {}_2 Y_{2\, -2})
171  * \mathrm{Re}(J_2(r) e^{i \nu u})
172  * + \sqrt{60} ({}_2 Y_{3\,3} - {}_2 Y_{3\, -3})
173  * \mathrm{Re}(J_3(r) e^{i \nu u}),
174  * \f]
175  *
176  * where
177  *
178  * \f{align*}{
179  * J_2(r) &= \frac{C_{2a}}{4 r} - \frac{C_{2b}}{12 r^3}, \\
180  * J_3(r) &= \frac{C_{3a}}{10 r} - \frac{i \nu C_{3 b}}{6 r^3}
181  * - \frac{C_{3 b}}{4 r^4}.
182  * \f}
183  */
184  void linearized_bondi_j(
185  gsl::not_null<SpinWeighted<ComplexDataVector, 2>*> bondi_j, size_t l_max,
186  double time) const noexcept;
187 
188  /*!
189  * \brief Compute the linearized solution for \f$U\f$
190  *
191  * \details The linearized solution for \f$U\f$ is given by
192  * \cite Barkett2019uae,
193  *
194  * \f[
195  * U = \sqrt{3} ({}_1 Y_{2\,2} + {}_1 Y_{2\, -2})
196  * \mathrm{Re}(U_2(r) e^{i \nu u})
197  * + \sqrt{6} ({}_1 Y_{3\,3} - {}_1 Y_{3\, -3})
198  * \mathrm{Re}(U_3(r) e^{i \nu u}),
199  * \f]
200  *
201  * where
202  *
203  * \f{align*}{
204  * U_2(r) &= \frac{C_{2a}}{2 r^2} + \frac{i \nu C_{2 b}}{3 r^3}
205  * + \frac{C_{2b}}{4 r^4} \\
206  * U_3(r) &= \frac{C_{3a}}{2 r^2} - \frac{2 \nu^2 C_{3b}}{3 r^3}
207  * + \frac{5 i \nu C_{3b}}{4 r^4} + \frac{C_{3 b}}{r^5}
208  * \f}
209  */
210  void linearized_bondi_u(
211  gsl::not_null<SpinWeighted<ComplexDataVector, 1>*> bondi_u, size_t l_max,
212  double time) const noexcept;
213 
214  /*!
215  * \brief Computes the linearized solution for \f$W\f$.
216  *
217  * \details The linearized solution for \f$W\f$ is given by
218  * \cite Barkett2019uae,
219  *
220  * \f[
221  * W = \frac{1}{\sqrt{2}} ({}_0 Y_{2\,2} + {}_0 Y_{2\, -2})
222  * \mathrm{Re}(W_2(r) e^{i \nu u})
223  * + \frac{1}{\sqrt{2}} ({}_0 Y_{3\,3} - {}_0 Y_{3\, -3})
224  * \mathrm{Re}(W_3(r) e^{i \nu u}),
225  * \f]
226  *
227  * where
228  *
229  * \f{align*}{
230  * W_2(r) &= - \frac{\nu^2 C_{2b}}{r^2} + \frac{i \nu C_{2 b}}{r^3}
231  * + \frac{C_{2b}}{2 r^4}, \\
232  * W_3(r) &= -\frac{2 i \nu^3 C_{3b}}{r^2} - \frac{4 i \nu^2 C_{3b}}{r^3}
233  * + \frac{5 \nu C_{3b}}{2 r^4} + \frac{3 C_{3b}}{r^5}.
234  * \f}
235  */
236  void linearized_bondi_w(
237  gsl::not_null<SpinWeighted<ComplexDataVector, 0>*> bondi_w, size_t l_max,
238  double time) const noexcept;
239 
240  /*!
241  * \brief Computes the linearized solution for \f$\partial_r J\f$.
242  *
243  * \details The linearized solution for \f$\partial_r J\f$ is given by
244  * \cite Barkett2019uae,
245  *
246  * \f[
247  * \partial_r J = \sqrt{12} ({}_2 Y_{2\,2} + {}_2 Y_{2\, -2})
248  * \mathrm{Re}(\partial_r J_2(r) e^{i \nu u})
249  * + \sqrt{60} ({}_2 Y_{3\,3} - {}_2 Y_{3\, -3})
250  * \mathrm{Re}(\partial_r J_3(r) e^{i \nu u}),
251  * \f]
252  *
253  * where
254  *
255  * \f{align*}{
256  * \partial_r J_2(r) &= - \frac{C_{2a}}{4 r^2} + \frac{C_{2b}}{4 r^4}, \\
257  * \partial_r J_3(r) &= -\frac{C_{3a}}{10 r^2} + \frac{i \nu C_{3 b}}{2 r^4}
258  * + \frac{C_{3 b}}{r^5}.
259  * \f}
260  */
261  void linearized_dr_bondi_j(
263  size_t l_max, double time) const noexcept;
264 
265  /*!
266  * \brief Compute the linearized solution for \f$\partial_r U\f$
267  *
268  * \details The linearized solution for \f$\partial_r U\f$ is given by
269  * \cite Barkett2019uae,
270  *
271  * \f[
272  * \partial_r U = \sqrt{3} ({}_1 Y_{2\,2} + {}_1 Y_{2\, -2})
273  * \mathrm{Re}(\partial_r U_2(r) e^{i \nu u})
274  * + \sqrt{6} ({}_1 Y_{3\,3} - {}_1 Y_{3\, -3})
275  * \mathrm{Re}(\partial_r U_3(r) e^{i \nu u}),
276  * \f]
277  *
278  * where
279  *
280  * \f{align*}{
281  * \partial_r U_2(r) &= -\frac{C_{2a}}{r^3} - \frac{i \nu C_{2 b}}{r^4}
282  * - \frac{C_{2b}}{r^5} \\
283  * \partial_r U_3(r) &= -\frac{C_{3a}}{r^3} + \frac{2 \nu^2 C_{3b}}{r^4}
284  * - \frac{5 i \nu C_{3b}}{r^5} - \frac{5 C_{3 b}}{r^6}
285  * \f}
286  */
287  void linearized_dr_bondi_u(
289  size_t l_max, double time) const noexcept;
290 
291  /*!
292  * \brief Computes the linearized solution for \f$\partial_r W\f$.
293  *
294  * \details The linearized solution for \f$W\f$ is given by
295  * \cite Barkett2019uae,
296  *
297  * \f[
298  * \partial_r W = \frac{1}{\sqrt{2}} ({}_0 Y_{2\,2} + {}_0 Y_{2\, -2})
299  * \mathrm{Re}(\partial_r W_2(r) e^{i \nu u})
300  * + \frac{1}{\sqrt{2}} ({}_0 Y_{3\,3} - {}_0 Y_{3\, -3})
301  * \mathrm{Re}(\partial_r W_3(r) e^{i \nu u}),
302  * \f]
303  *
304  * where
305  *
306  * \f{align*}{
307  * \partial_r W_2(r) &= \frac{2 \nu^2 C_{2b}}{r^3}
308  * - \frac{3 i \nu C_{2 b}}{r^4} - \frac{2 C_{2b}}{r^5}, \\
309  * \partial_r W_3(r) &= \frac{4 i \nu^3 C_{3b}}{r^3}
310  * + \frac{12 i \nu^2 C_{3b}}{r^4} - \frac{10 \nu C_{3b}}{r^5}
311  * - \frac{15 C_{3b}}{r^6}.
312  * \f}
313  */
314  void linearized_dr_bondi_w(
316  size_t l_max, double time) const noexcept;
317 
318  /*!
319  * \brief Computes the linearized solution for \f$\partial_u J\f$.
320  *
321  * \details The linearized solution for \f$\partial_u J\f$ is given by
322  * \cite Barkett2019uae,
323  *
324  * \f[
325  * \partial_u J = \sqrt{12} ({}_2 Y_{2\,2} + {}_2 Y_{2\, -2})
326  * \mathrm{Re}(i \nu J_2(r) e^{i \nu u})
327  * + \sqrt{60} ({}_2 Y_{3\,3} - {}_2 Y_{3\, -3})
328  * \mathrm{Re}(i \nu J_3(r) e^{i \nu u}),
329  * \f]
330  *
331  * where
332  *
333  * \f{align*}{
334  * J_2(r) &= \frac{C_{2a}}{4 r} - \frac{C_{2b}}{12 r^3}, \\
335  * J_3(r) &= \frac{C_{3a}}{10 r} - \frac{i \nu C_{3 b}}{6 r^3}
336  * - \frac{C_{3 b}}{4 r^4}.
337  * \f}
338  */
339  void linearized_du_bondi_j(
341  size_t l_max, double time) const noexcept;
342 
343  /*!
344  * \brief Compute the linearized solution for \f$\partial_u U\f$
345  *
346  * \details The linearized solution for \f$U\f$ is given by
347  * \cite Barkett2019uae,
348  *
349  * \f[
350  * \partial_u U = \sqrt{3} ({}_2 Y_{2\,2} + {}_2 Y_{2\, -2})
351  * \mathrm{Re}(i \nu U_2(r) e^{i \nu u})
352  * + \sqrt{6} ({}_2 Y_{3\,3} - {}_2 Y_{3\, -3})
353  * \mathrm{Re}(i \nu U_3(r) e^{i \nu u}),
354  * \f]
355  *
356  * where
357  *
358  * \f{align*}{
359  * U_2(r) &= \frac{C_{2a}}{2 r^2} + \frac{i \nu C_{2 b}}{3 r^3}
360  * + \frac{C_{2b}}{4 r^4} \\
361  * U_3(r) &= \frac{C_{3a}}{2 r^2} - \frac{2 \nu^2 C_{3b}}{3 r^3}
362  * + \frac{5 i \nu C_{3b}}{4 r^4} + \frac{C_{3 b}}{r^5}
363  * \f}
364  */
365  void linearized_du_bondi_u(
367  size_t l_max, double time) const noexcept;
368 
369  /*!
370  * \brief Computes the linearized solution for \f$\partial_u W\f$.
371  *
372  * \details The linearized solution for \f$\partial_u W\f$ is given by
373  * \cite Barkett2019uae,
374  *
375  * \f[
376  * \partial_u W = \frac{1}{\sqrt{2}} ({}_1 Y_{2\,2} + {}_1 Y_{2\, -2})
377  * \mathrm{Re}(i \nu W_2(r) e^{i \nu u})
378  * + \frac{1}{\sqrt{2}} ({}_1 Y_{3\,3} - {}_1 Y_{3\, -3})
379  * \mathrm{Re}(i \nu W_3(r) e^{i \nu u}),
380  * \f]
381  *
382  * where
383  *
384  * \f{align*}{
385  * W_2(r) &= \frac{\nu^2 C_{2b}}{r^2} + \frac{i \nu C_{2 b}}{r^3}
386  * + \frac{C_{2b}}{2 r^4}, \\
387  * W_3(r) &= \frac{2 i \nu^3 C_{3b}}{r^2} - \frac{4 i \nu^2 C_{3b}}{r^3}
388  * + \frac{5 \nu C_{3b}}{2 r^4} + \frac{3 C_{3b}}{r^5}.
389  * \f}
390  */
391  void linearized_du_bondi_w(
393  size_t l_max, double time) const noexcept;
394 
395  /*!
396  * \brief Compute the spherical coordinate metric from the linearized
397  * Bondi-Sachs system.
398  *
399  * \details This function dispatches to the individual computations in this
400  * class to determine the Bondi-Sachs scalars for the linearized solution.
401  * Once the scalars are determined, the metric is assembled via (note
402  * \f$\beta = 0\f$ in this solution)
403  *
404  * \f{align*}{
405  * ds^2 =& - ((1 + r W) - r^2 h_{A B} U^A U^B) (dt - dr)^2
406  * - 2 (dt - dr) dr \\
407  * &- 2 r^2 h_{A B} U^B (dt - dr) dx^A + r^2 h_{A B} dx^A dx^B,
408  * \f}
409  *
410  * where indices with capital letters refer to angular coordinates and the
411  * angular tensors may be written in terms of spin-weighted scalars. Doing so
412  * gives the metric components,
413  *
414  * \f{align*}{
415  * g_{t t} &= -\left(1 + r W
416  * - r^2 \Re\left(\bar J U^2 + K U \bar U\right)\right)\\
417  * g_{t r} &= -1 - g_{t t}\\
418  * g_{r r} &= 2 + g_{t t}\\
419  * g_{t \theta} &= r^2 \Re\left(K U + J \bar U\right)\\
420  * g_{t \phi} &= r^2 \Im\left(K U + J \bar U\right)\\
421  * g_{r \theta} &= -g_{t \theta}\\
422  * g_{r \phi} &= -g_{t \phi}\\
423  * g_{\theta \theta} &= r^2 \Re\left(J + K\right)\\
424  * g_{\theta \phi} &= r^2 \Im\left(J\right)\\
425  * g_{\phi \phi} &= r^2 \Re\left(K - J\right),
426  * \f}
427  *
428  * and all other components are zero.
429  */
430  void spherical_metric(
433  spherical_metric,
434  size_t l_max, double time) const noexcept override;
435 
436  /*!
437  * \brief Compute the radial derivative of the spherical coordinate metric
438  * from the linearized Bondi-Sachs system.
439  *
440  * \details This function dispatches to the individual computations in this
441  * class to determine the Bondi-Sachs scalars for the linearized solution.
442  * Once the scalars are determined, the radial derivative of the metric is
443  * assembled via (note \f$\beta = 0\f$ in this solution)
444  *
445  * \f{align*}{
446  * \partial_r g_{a b} dx^a dx^b =& - (W + r \partial_r W
447  * - 2 r h_{A B} U^A U^B - r^2 (\partial_r h_{A B}) U^A U^B
448  * - 2 r^2 h_{A B} U^A \partial_r U^B) (dt - dr)^2 \\
449  * &- (4 r h_{A B} U^B + 2 r^2 ((\partial_r h_{A B}) U^B
450  * + h_{AB} \partial_r U^B) ) (dt - dr) dx^A
451  * + (2 r h_{A B} + r^2 \partial_r h_{A B}) dx^A dx^B,
452  * \f}
453  *
454  * where indices with capital letters refer to angular coordinates and the
455  * angular tensors may be written in terms of spin-weighted scalars. Doing so
456  * gives the metric components,
457  *
458  * \f{align*}{
459  * \partial_r g_{t t} &= -\left( W + r \partial_r W
460  * - 2 r \Re\left(\bar J U^2 + K U \bar U\right)
461  * - r^2 \partial_r \Re\left(\bar J U^2 + K U \bar U\right)\right) \\
462  * \partial_r g_{t r} &= -\partial_r g_{t t}\\
463  * \partial_r g_{t \theta} &= 2 r \Re\left(K U + J \bar U\right)
464  * + r^2 \partial_r \Re\left(K U + J \bar U\right) \\
465  * \partial_r g_{t \phi} &= 2r \Im\left(K U + J \bar U\right)
466  * + r^2 \partial_r \Im\left(K U + J \bar U\right) \\
467  * \partial_r g_{r r} &= \partial_r g_{t t}\\
468  * \partial_r g_{r \theta} &= -\partial_r g_{t \theta}\\
469  * \partial_r g_{r \phi} &= -\partial_r g_{t \phi}\\
470  * \partial_r g_{\theta \theta} &= 2 r \Re\left(J + K\right)
471  * + r^2 \Re\left(\partial_r J + \partial_r K\right) \\
472  * \partial_r g_{\theta \phi} &= 2 r \Im\left(J\right)
473  * + r^2 \Im\left(\partial_r J\right)\\
474  * \partial_r g_{\phi \phi} &= 2 r \Re\left(K - J\right)
475  * + r^2 \Re\left(\partial_r K - \partial_r J\right),
476  * \f}
477  *
478  * and all other components are zero.
479  */
480  void dr_spherical_metric(
483  dr_spherical_metric,
484  size_t l_max, double time) const noexcept override;
485 
486  /*!
487  * \brief Compute the time derivative of the spherical coordinate metric from
488  * the linearized Bondi-Sachs system.
489  *
490  * \details This function dispatches to the individual computations in this
491  * class to determine the Bondi-Sachs scalars for the linearized solution.
492  * Once the scalars are determined, the metric is assembled via (note
493  * \f$\beta = 0\f$ in this solution, and note that we take coordinate
494  * \f$t=u\f$ in converting to the Cartesian coordinates)
495  *
496  * \f{align*}{
497  * \partial_t g_{a b} dx^a dx^b =& - (r \partial_u W
498  * - r^2 \partial_u h_{A B} U^A U^B
499  * - 2 r^2 h_{A B} U^B \partial_u U^A) (dt - dr)^2 \\
500  * &- 2 r^2 (\partial_u h_{A B} U^B + h_{A B} \partial_u U^B) (dt - dr) dx^A
501  * + r^2 \partial_u h_{A B} dx^A dx^B,
502  * \f}
503  *
504  * where indices with capital letters refer to angular coordinates and the
505  * angular tensors may be written in terms of spin-weighted scalars. Doing so
506  * gives the metric components,
507  *
508  * \f{align*}{
509  * \partial_t g_{t t} &= -\left(r \partial_u W
510  * - r^2 \partial_u \Re\left(\bar J U^2 + K U \bar U\right)\right)\\
511  * \partial_t g_{t r} &= -\partial_t g_{t t}\\
512  * \partial_t g_{t \theta} &= r^2 \partial_u \Re\left(K U + J \bar U\right)\\
513  * \partial_t g_{t \phi} &= r^2 \partial_u \Im\left(K U + J \bar U\right)\\
514  * \partial_t g_{r r} &= \partial_t g_{t t}\\
515  * \partial_t g_{r \theta} &= -\partial_t g_{t \theta}\\
516  * \partial_t g_{r \phi} &= -\partial_t g_{t \phi}\\
517  * \partial_t g_{\theta \theta} &= r^2 \Re\left(\partial_u J
518  * + \partial_u K\right)\\
519  * \partial_t g_{\theta \phi} &= r^2 \Im\left(\partial_u J\right)\\
520  * \partial_t g_{\phi \phi} &= r^2 \Re\left(\partial_u K
521  * - \partial_u J\right),
522  * \f}
523  *
524  * and all other components are zero.
525  */
526  void dt_spherical_metric(
529  dt_spherical_metric,
530  size_t l_max, double time) const noexcept override;
531 
532  using WorldtubeData::variables_impl;
533 
535 
536  /*!
537  * \brief Determines the News function from the linearized solution
538  * parameters.
539  *
540  * \details The News is determined from the formula given in
541  * \cite Barkett2019uae,
542  *
543  * \f{align*}{
544  * N = \frac{1}{2 \sqrt{3}} ({}_{-2} Y_{2\, 2} + {}_{-2} Y_{2\,-2})
545  * \Re\left(i \nu^3 C_{2 b} e^{i \nu u}\right)
546  * + \frac{1}{\sqrt{15}} ({}_{-2} Y_{3\, 3} - {}_{-2} Y_{3\, -3})
547  * \Re\left(- \nu^4 C_{3 b} e^{i \nu u} \right)
548  * \f}
549  */
550  void variables_impl(
552  size_t l_max, double time, tmpl::type_<Tags::News> /*meta*/) const
553  noexcept override;
554 
559 
560  double frequency_ = 0.0;
561 };
562 } // namespace Cce::Solutions
CharmPupable.hpp
Cce::Solutions::LinearizedBondiSachs::Frequency
Definition: LinearizedBondiSachs.hpp:125
Options.hpp
Cce::dr_bondi_j
void dr_bondi_j(gsl::not_null< Scalar< SpinWeighted< ComplexDataVector, 2 >> * > dr_bondi_j, gsl::not_null< Scalar< SpinWeighted< ComplexDataVector, 0 >> * > denominator_buffer, const tnsr::aa< DataVector, 3, Frame::RadialNull > &dlambda_null_metric, const tnsr::a< DataVector, 3, Frame::RadialNull > &d_bondi_r, const Scalar< SpinWeighted< ComplexDataVector, 2 >> &bondi_j, const Scalar< SpinWeighted< ComplexDataVector, 0 >> &bondi_r, const tnsr::I< ComplexDataVector, 2, Frame::RadialNull > &dyad) noexcept
Compute the radial derivative of the angular metric spin-weighted scalar in the CCE Bondi-like metri...
vector
SpinWeighted
Make a spin-weighted type T with spin-weight Spin. Mathematical operators are restricted to addition,...
Definition: SpinWeighted.hpp:24
Cce::Solutions::SphericalMetricData
Abstract base class for analytic worldtube data most easily derived in spherical coordinate form.
Definition: SphericalMetricData.hpp:42
WRAPPED_PUPable_decl_template
#define WRAPPED_PUPable_decl_template(className)
Mark derived classes as serializable.
Definition: CharmPupable.hpp:22
cstddef
Cce::Solutions::SphericalMetricData::variables_impl
void variables_impl(gsl::not_null< tnsr::aa< DataVector, 3 > * > spacetime_metric, size_t l_max, double time, tmpl::type_< gr::Tags::SpacetimeMetric< 3, ::Frame::Inertial, DataVector >>) const noexcept override
Computes the Cartesian spacetime metric from the spherical solution provided by the derived classes.
Cce::Solutions::LinearizedBondiSachs
Computes the analytic data for a Linearized solution to the Bondi-Sachs equations described in .
Definition: LinearizedBondiSachs.hpp:113
Cce::Solutions::LinearizedBondiSachs::InitialModes
Definition: LinearizedBondiSachs.hpp:114
std::array
DataVector
Stores a collection of function values.
Definition: DataVector.hpp:46
std::numeric_limits::signaling_NaN
T signaling_NaN(T... args)
memory
Frame::Spherical
Represents a spherical-coordinate frame that is associated with a Cartesian frame,...
Definition: IndexType.hpp:54
tnsr
Type aliases to construct common Tensors.
Definition: TypeAliases.hpp:31
Cce::InitializeJ::InitializeJ
Abstract base class for an initial hypersurface data generator for Cce.
Definition: InitializeJ.hpp:104
Cce::Solutions::LinearizedBondiSachs::ExtractionRadius
Definition: LinearizedBondiSachs.hpp:119
Scalar
Tensor< T, Symmetry<>, index_list<> > Scalar
Definition: TypeAliases.hpp:21
Cce
The set of utilities for performing Cauchy characteristic evolution and Cauchy characteristic matchin...
Definition: CharacteristicExtractFwd.hpp:6
limits
Gsl.hpp
Options::String
const char *const String
The string used in option structs.
Definition: Options.hpp:32
Frame
Definition: IndexType.hpp:36
complex
ComplexDataVector
Stores a collection of complex function values.
Definition: ComplexDataVector.hpp:53
std::unique_ptr
Cce::Solutions
Analytic solutions for CCE worldtube data and corresponding waveform News.
Definition: BouncingBlackHole.hpp:25
gsl
Implementations from the Guideline Support Library.
Definition: ReadSpecPiecewisePolynomial.hpp:11
TMPL.hpp
gsl::not_null
Require a pointer to not be a nullptr
Definition: ReadSpecPiecewisePolynomial.hpp:13