Line data Source code
1 0 : // Distributed under the MIT License.
2 : // See LICENSE.txt for details.
3 :
4 : #pragma once
5 :
6 : #include <cstddef>
7 : #include <string>
8 : #include <vector>
9 :
10 : #include "NumericalAlgorithms/Strahlkorper/Strahlkorper.hpp"
11 : #include "Utilities/Gsl.hpp"
12 :
13 : namespace ylm {
14 : /*!
15 : * \brief Fills the legend and row of spherical harmonic data to write to disk
16 : *
17 : * The number of coefficients to write is based on `max_l`, the maximum value
18 : * that the input `strahlkorper` could possibly have. When
19 : * `strahlkorper.l_max() < max_l`, coefficients with \f$l\f$ higher than
20 : * `strahlkorper.l_max()` will simply be zero. Assuming the same `max_l` is
21 : * always used for a given surface, we will always write the same number of
22 : * columns for each row, as `max_l` sets the number of columns to write
23 : */
24 : template <typename Frame>
25 1 : void fill_ylm_legend_and_data(gsl::not_null<std::vector<std::string>*> legend,
26 : gsl::not_null<std::vector<double>*> data,
27 : const ylm::Strahlkorper<Frame>& strahlkorper,
28 : double time, size_t max_l);
29 : } // namespace ylm
|