LSST Applications g07dc498a13+8a3ff5e555,g1409bbee79+8a3ff5e555,g1a7e361dbc+8a3ff5e555,g1fd858c14a+cdfc45a1e6,g28da252d5a+05df2523c9,g33399d78f5+b7ce9b29cb,g35bb328faa+e55fef2c71,g3bd4b5ce2c+801aef9193,g43bc871e57+32b9ddb877,g53246c7159+e55fef2c71,g60b5630c4e+f284161bd5,g6992a3b7c1+89734069dd,g6e5c4a0e23+7c1dc9d5af,g78460c75b0+8427c4cc8f,g786e29fd12+307f82e6af,g8534526c7b+af2545e932,g85d8d04dbe+6bd817bf56,g89139ef638+8a3ff5e555,g8b49a6ea8e+f284161bd5,g9125e01d80+e55fef2c71,g989de1cb63+8a3ff5e555,g9a9baf55bd+a4ec829099,g9f33ca652e+eafd8913dc,gaaedd4e678+8a3ff5e555,gabe3b4be73+9c0c3c7524,gb092a606b0+b01f69f56e,gb58c049af0+28045f66fd,gc2fcbed0ba+f284161bd5,gca43fec769+e55fef2c71,gcf25f946ba+b7ce9b29cb,gd6cbbdb0b4+784e334a77,gde0f65d7ad+3bc0905521,ge278dab8ac+25667260f6,geab183fbe5+f284161bd5,gecb8035dfe+0fa5abcb94,gf1e97e5484+b700727375,gf58bf46354+e55fef2c71,gfe7187db8c+f9d6462591,w.2025.01
LSST Data Management Base Package
Loading...
Searching...
No Matches
Magnitude.h
Go to the documentation of this file.
1// -*- LSST-C++ -*-
2/*
3 * This file is part of utils.
4 *
5 * Developed for the LSST Data Management System.
6 * This product includes software developed by the LSST Project
7 * (https://www.lsst.org).
8 * See the COPYRIGHT file at the top-level directory of this distribution
9 * for details of code ownership.
10 *
11 * This program is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation, either version 3 of the License, or
14 * (at your option) any later version.
15 *
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
20 *
21 * You should have received a copy of the GNU General Public License
22 * along with this program. If not, see <https://www.gnu.org/licenses/>.
23 */
24
37#ifndef LSST_CPPUTILS_MAGNITUDE_H
38#define LSST_CPPUTILS_MAGNITUDE_H
39
40#include <cmath>
41
42namespace lsst {
43namespace cpputils {
44
46const double referenceFlux = 1e23 * pow(10, (48.6 / -2.5)) * 1e9;
47
49double nanojanskyToABMagnitude(double flux);
50
52double ABMagnitudeToNanojansky(double magnitude);
53
54} // namespace cpputils
55} // namespace lsst
56
57#endif // LSST_CPPUTILS_MAGNITUDE_H
const double referenceFlux
The Oke & Gunn (1983) AB magnitude reference flux, in nJy (often approximated as 3631....
Definition Magnitude.h:46
double ABMagnitudeToNanojansky(double magnitude)
Convert an AB magnitude to a flux in nanojansky.
Definition Magnitude.cc:32
double nanojanskyToABMagnitude(double flux)
Convert a flux in nanojansky to AB magnitude.
Definition Magnitude.cc:30