cloudy
trunk
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
source
dense_fabden.cpp
Go to the documentation of this file.
1
/* This file is part of Cloudy and is copyright (C)1978-2017 by Gary J. Ferland and
2
* others. For conditions of distribution and use see copyright notice in license.txt */
3
/*dense_fabden called by dlaw command, returns density for any density law */
4
#include "
cddefines.h
"
5
#include "
rfield.h
"
6
#include "
dense.h
"
7
8
/*dense_fabden implements the dlaw command, returns density using
9
* current position and up to ten parameters on dlaw command line */
10
double
dense_fabden
(
double
radius
,
11
double
depth)
12
{
13
double
fabden_v =
exp10
(
dense
.
DensityLaw
[0]);
14
if
(
rfield
.
lgUSphON
)
15
fabden_v *=
pow
(radius/
rfield
.
rstrom
,
dense
.
DensityLaw
[1]);
16
else
17
fabden_v *=
pow
(depth/
rfield
.
rstrom
,
dense
.
DensityLaw
[1]);
18
19
return
fabden_v;
20
}
exp10
double exp10(double x)
Definition:
cddefines.h:1383
dense.h
dense
t_dense dense
Definition:
global.cpp:15
rfield
t_rfield rfield
Definition:
rfield.cpp:9
t_rfield::rstrom
realnum rstrom
Definition:
rfield.h:355
radius
t_radius radius
Definition:
radius.cpp:5
cddefines.h
dense_fabden
double dense_fabden(double radius, double depth)
Definition:
dense_fabden.cpp:10
pow
double pow(double x, int i)
Definition:
cddefines.h:782
t_dense::DensityLaw
double DensityLaw[10]
Definition:
dense.h:191
rfield.h
t_rfield::lgUSphON
bool lgUSphON
Definition:
rfield.h:353
Generated by
1.8.5