42 ndarray::Array<T, 1>
abMagFromFlux(ndarray::Array<T const, 1>
const& flux) {
43 ndarray::Array<T, 1> out = ndarray::allocate(flux.getShape());
44 for (
std::size_t ii = 0; ii < flux.getNumElements(); ++ii) {
53 ndarray::Array<T const, 1>
const& flux) {
54 if (flux.getNumElements() != fluxErr.getNumElements()) {
56 flux.getNumElements() % fluxErr.getNumElements())
59 ndarray::Array<T, 1> out = ndarray::allocate(flux.getShape());
60 for (
std::size_t ii = 0; ii < flux.getNumElements(); ++ii) {
68 ndarray::Array<T, 1>
fluxFromABMag(ndarray::Array<T const, 1>
const& mag) {
69 ndarray::Array<T, 1> out = ndarray::allocate(mag.getShape());
70 for (
std::size_t ii = 0; ii < mag.getNumElements(); ++ii) {
79 ndarray::Array<T const, 1>
const& mag) {
80 if (mag.getNumElements() != magErr.getNumElements()) {
82 mag.getNumElements() % magErr.getNumElements())
85 ndarray::Array<T, 1> out = ndarray::allocate(mag.getShape());
86 for (
std::size_t ii = 0; ii < mag.getNumElements(); ++ii) {
93 #define INSTANTIATE(TYPE) \
94 template ndarray::Array<TYPE, 1> abMagFromFlux(ndarray::Array<TYPE const, 1> const& flux); \
95 template ndarray::Array<TYPE, 1> abMagErrFromFluxErr(ndarray::Array<TYPE const, 1> const& fluxErr, \
96 ndarray::Array<TYPE const, 1> const& flux); \
97 template ndarray::Array<TYPE, 1> fluxFromABMag(ndarray::Array<TYPE const, 1> const& mag); \
98 template ndarray::Array<TYPE, 1> fluxErrFromABMagErr(ndarray::Array<TYPE const, 1> const& magErr, \
99 ndarray::Array<TYPE const, 1> const& mag);