Cloudy
Spectral Synthesis Code for Astrophysics
Loading...
Searching...
No Matches
atmdat_gaunt.h
Go to the documentation of this file.
1/* This file is part of Cloudy and is copyright (C)1978-2025 by Gary J. Ferland and
2 * others. For conditions of distribution and use see copyright notice in license.txt */
3
4#ifndef ATMDAT_GAUNT_H
5#define ATMDAT_GAUNT_H
6
7#include "container_classes.h"
8#include "vectorize.h"
9
10struct t_gff
11{
12 double Te_used;
15 t_gff() : Te_used(-1.), nflux_used(0) {}
16};
17
19{
20 double Te_used;
21 long nlo;
22 long nhi;
23 double brems_sum;
24 t_brems_sum() : Te_used(-1.), nlo(0), nhi(0), brems_sum(0.) {}
25};
26
28{
29 double Te_used;
30 long nhi;
31 vector<double> brems_vec;
32 t_brems_vec() : Te_used(-1.), nhi(0) {}
33};
34
36{
37 double den_Hm;
38 double den_Hp;
39 double den_Hep;
40 double den_Hepp;
41 // this will exclude hydrogen and helium
42 double den_ion[LIMELM+1];
43};
44
45class t_gaunt : public Singleton<t_gaunt>
46{
47 friend class Singleton<t_gaunt>;
48
49 size_t p_np_gam2;
50 size_t p_np_u;
51
54 double p_lg_u_min;
55 double p_lg_u_max;
56 double p_step;
57
58 vector<double> p_lg_gam2;
59 vector<double> p_lg_u;
62
68
69 void p_read_table(const char* fnam, long nelem);
70 void p_gauntff_vec_sub(long Z, double Te, const double anulog10[], long nmin, long nmax);
71 void p_gauntff_vec(long Z, double Te, const double anulog10[], long nflux);
72 void p_setup_brems(long ion, double Te);
73protected:
75public:
76 double gauntff(long Z, double Te, double anu);
77 double brems_cool(long ion, double Te);
78 void brems_rt(long ion, double Te, double abun, vector<double>& arr);
79 void brems_opac(long ion, double Te, double abun, vector<double>& arr);
80 void brems_sum_ions(t_brems_den& sum) const;
81};
82
83#endif
const int LIMELM
Definition cddefines.h:318
Definition cddefines.h:214
Definition container_classes.h:916
void brems_rt(long ion, double Te, double abun, vector< double > &arr)
Definition atmdat_gaunt.cpp:366
double p_lg_gam2_min
Definition atmdat_gaunt.h:52
double p_step
Definition atmdat_gaunt.h:56
t_brems_sum p_cache[LIMELM+1]
Definition atmdat_gaunt.h:64
t_brems_vec p_hminus_vec
Definition atmdat_gaunt.h:67
vector_avx< realnum > p_vexp_arg
Definition atmdat_gaunt.h:61
double brems_cool(long ion, double Te)
Definition atmdat_gaunt.cpp:312
void brems_sum_ions(t_brems_den &sum) const
Definition atmdat_gaunt.cpp:418
double p_lg_u_max
Definition atmdat_gaunt.h:55
void p_gauntff_vec(long Z, double Te, const double anulog10[], long nflux)
Definition atmdat_gaunt.cpp:166
size_t p_np_gam2
Definition atmdat_gaunt.h:49
void brems_opac(long ion, double Te, double abun, vector< double > &arr)
Definition atmdat_gaunt.cpp:394
vector< double > p_lg_u
Definition atmdat_gaunt.h:59
void p_gauntff_vec_sub(long Z, double Te, const double anulog10[], long nmin, long nmax)
Definition atmdat_gaunt.cpp:194
double p_lg_u_min
Definition atmdat_gaunt.h:54
double gauntff(long Z, double Te, double anu)
Definition atmdat_gaunt.cpp:135
void p_setup_brems(long ion, double Te)
Definition atmdat_gaunt.cpp:261
multi_arr< double, 4 > p_gff
Definition atmdat_gaunt.h:60
t_brems_sum p_hminus
Definition atmdat_gaunt.h:65
t_gff p_gff_ion[LIMELM+1]
Definition atmdat_gaunt.h:63
void p_read_table(const char *fnam, long nelem)
Definition atmdat_gaunt.cpp:21
t_brems_vec p_cache_vec[LIMELM+1]
Definition atmdat_gaunt.h:66
size_t p_np_u
Definition atmdat_gaunt.h:50
double p_lg_gam2_max
Definition atmdat_gaunt.h:53
vector< double > p_lg_gam2
Definition atmdat_gaunt.h:58
t_gaunt()
Definition atmdat_gaunt.h:74
Definition atmdat_gaunt.h:36
double den_Hm
Definition atmdat_gaunt.h:37
double den_Hp
Definition atmdat_gaunt.h:38
double den_ion[LIMELM+1]
Definition atmdat_gaunt.h:42
double den_Hepp
Definition atmdat_gaunt.h:40
double den_Hep
Definition atmdat_gaunt.h:39
Definition atmdat_gaunt.h:19
double Te_used
Definition atmdat_gaunt.h:20
long nlo
Definition atmdat_gaunt.h:21
t_brems_sum()
Definition atmdat_gaunt.h:24
long nhi
Definition atmdat_gaunt.h:22
double brems_sum
Definition atmdat_gaunt.h:23
Definition atmdat_gaunt.h:28
t_brems_vec()
Definition atmdat_gaunt.h:32
double Te_used
Definition atmdat_gaunt.h:29
vector< double > brems_vec
Definition atmdat_gaunt.h:31
long nhi
Definition atmdat_gaunt.h:30
Definition atmdat_gaunt.h:11
double Te_used
Definition atmdat_gaunt.h:12
t_gff()
Definition atmdat_gaunt.h:15
long nflux_used
Definition atmdat_gaunt.h:13
vector_avx< realnum > gff
Definition atmdat_gaunt.h:14
typename std::vector< T, allocator_avx< T > > vector_avx
Definition vectorize.h:331