ARTS 2.5.0 (git: 9ee3ac6c)
physics_funcs.h
Go to the documentation of this file.
1/* Copyright (C) 2002-2012
2 Patrick Eriksson <Patrick.Eriksson@chalmers.se>
3 Stefan Buehler <sbuehler@ltu.se>
4
5 This program is free software; you can redistribute it and/or modify it
6 under the terms of the GNU General Public License as published by the
7 Free Software Foundation; either version 2, or (at your option) any
8 later version.
9
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
18 USA. */
19
28#ifndef physics_h
29#define physics_h
30
31/*===========================================================================
32 === External declarations
33 ===========================================================================*/
34
35#include "arts.h"
36#include "constants.h"
37#include "matpackI.h"
38#include "matpack_complex.h"
39
40/*===========================================================================
41 === Functions in physics_funcs.h
42 ===========================================================================*/
43
45
46Numeric dinvplanckdI(const Numeric& i, const Numeric& f);
47
48void fresnel(Complex& Rv,
49 Complex& Rh,
50 const Complex& n1,
51 const Complex& n2,
52 const Numeric& theta);
53
54Numeric invplanck(const Numeric& i, const Numeric& f);
55
56Numeric invrayjean(const Numeric& i, const Numeric& f);
57
70constexpr Numeric number_density(Numeric p, Numeric t) noexcept {return p / (Constant::k * t);}
71
84constexpr Numeric dnumber_density_dt(Numeric p, Numeric t) noexcept {return - p / (Constant::k * Constant::pow2(t));}
85
86Numeric planck(const Numeric& f, const Numeric& t);
87
88void planck(VectorView b, const ConstVectorView& f, const Numeric& t);
89
90Vector planck(const ConstVectorView& f, const Numeric& t);
91
92Numeric dplanck_dt(const Numeric& f, const Numeric& t);
93
94void dplanck_dt(VectorView b, const ConstVectorView& f, const Numeric& t);
95
96Vector dplanck_dt(const ConstVectorView& f, const Numeric& t);
97
98Numeric dplanck_df(const Numeric& f, const Numeric& t);
99
100Vector dplanck_df(const ConstVectorView& f, const Numeric& t);
101
102Numeric rayjean(const Numeric& f, const Numeric& t);
103
104#ifdef ENABLE_REFICE
105extern "C" {
106#endif
138Complex refice_(const Numeric& wavlen, const Numeric& temp);
139#ifdef ENABLE_REFICE
140}
141#endif
142
143#endif // physics_h
The global header file for ARTS.
A constant view of a Vector.
Definition: matpackI.h:489
The VectorView class.
Definition: matpackI.h:626
The Vector class.
Definition: matpackI.h:876
Constants of physical expressions as constexpr.
#define temp
Implementation of Matrix, Vector, and such stuff.
NUMERIC Numeric
The type to use for all floating point numbers.
Definition: matpack.h:33
std::complex< Numeric > Complex
constexpr auto pow2(T x) -> decltype(x *x)
power of two
Definition: constants.h:65
Numeric dplanck_df(const Numeric &f, const Numeric &t)
dplanck_df
Numeric dinvplanckdI(const Numeric &i, const Numeric &f)
dinvplanckdI
constexpr Numeric dnumber_density_dt(Numeric p, Numeric t) noexcept
dnumber_density_dT
Definition: physics_funcs.h:84
constexpr Numeric number_density(Numeric p, Numeric t) noexcept
number_density
Definition: physics_funcs.h:70
Numeric planck(const Numeric &f, const Numeric &t)
planck
Numeric rayjean(const Numeric &f, const Numeric &t)
rayjean
Numeric barometric_heightformula(const Numeric &p, const Numeric &dh)
barometric_heightformula
Numeric invrayjean(const Numeric &i, const Numeric &f)
invrayjean
Complex refice_(const Numeric &wavlen, const Numeric &temp)
Calculates complex refractive index of Ice 1H.
Numeric invplanck(const Numeric &i, const Numeric &f)
invplanck
Numeric dplanck_dt(const Numeric &f, const Numeric &t)
dplanck_dt
void fresnel(Complex &Rv, Complex &Rh, const Complex &n1, const Complex &n2, const Numeric &theta)
fresnel
#define b