Qucs-core  0.0.18
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
constants.h
Go to the documentation of this file.
1 /*
2  * constants.h - global natural constant header file
3  *
4  * Copyright (C) 2004, 2005 Stefan Jahn <stefan@lkcc.org>
5  *
6  * This is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 2, or (at your option)
9  * any later version.
10  *
11  * This software is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with this package; see the file COPYING. If not, write to
18  * the Free Software Foundation, Inc., 51 Franklin Street - Fifth Floor,
19  * Boston, MA 02110-1301, USA.
20  *
21  * $Id$
22  *
23  */
24 
32 #ifndef __CONSTANTS_H__
33 #define __CONSTANTS_H__
34 
35 #include "consts.h"
36 #include "precision.h"
37 
38 namespace qucs {
39 
47 #define C0 299792458.0
48 
49 #define MU0 12.566370614e-7
50 
51 #define E0 8.854187817e-12
52 
53 #define Z0 376.73031346958504364963
54 
57 #define Hp 6.626069311e-34
58 
59 #define K -273.15
60 
61 #define T0 290
62 
64 #define kB 1.380650524e-23
65 
66 #define Q_e 1.6021765314e-19
67 
68 #define kBoverQ 0.86173433260414314916e-4
69 
70 #define QoverkB 1.16045045690360379713e+4
71 
73 #define ESiO2 3.9
74 
75 #define ESi 11.7
76 
77 #define EGe 15.8
78 
79 #define EGaAs 13.1
80 
81 #define NiSi 1.45e16
82 
83 #define NiGe 2.40e19
84 
85 #define NiGaAs 9.00e12
86 
87 #define EgSi 1.11
88 
91 #define EgSchottky 0.69
92 
93 #define EgGe 0.67
94 
95 #define EgGaAs 1.43
96 
97 #define Eg0Si 1.16
98 
100 
104 #define GMin NR_TINY
105 
106 #define cubic(x) ((x) * (x) * (x))
107 
108 #define kelvin(x) ((x) - K)
109 
113 #define degree(x) (K + (x))
114 
118 #define rad(x) (M_PI * (x) / 180.0)
119 
123 #define deg(x) (180.0 * (x) / M_PI)
124 
125 #ifndef MAX
126 
127 # define MAX(x,y) (((x) > (y)) ? (x) : (y))
128 #endif
129 
130 #ifndef MIN
131 
132 # define MIN(x,y) (((x) < (y)) ? (x) : (y))
133 #endif
134 
139 } // namespace qucs
140 
141 #endif /* __CONSTANTS_H__ */
Global math constants header file.