Vlasiator
ebf0dd394 on dev (v5.4.0 + 1054 commits)
Loading...
Searching...
No Matches
common.h
Go to the documentation of this file.
1
/*
2
This file is part of Vlasiator.
3
4
Copyright 2010, 2011, 2012, 2013 Finnish Meteorological Institute
5
6
*/
7
8
#ifndef COMMON_H
9
#define COMMON_H
10
# include <stdint.h>
11
12
typedef
uint32_t
uint
;
13
typedef
const
uint32_t
cuint
;
14
15
16
const
uint
WID
= 4;
17
const
uint
WID2
=
WID
*
WID
;
18
const
uint
WID3
=
WID2
*
WID
;
19
20
//set general floating point precision here. Default is single precision, use -DDP to set double precision
21
#ifdef DP
22
typedef
double
Real
;
23
typedef
const
double
creal
;
24
#else
25
typedef
float
Real
;
26
typedef
const
float
creal
;
27
#endif
28
29
30
#define MAX_BLOCKS_PER_DIM 1000
31
#ifdef ACC_SEMILAG_PLM
32
#define RECONSTRUCTION_ORDER 1
33
#endif
34
#ifdef ACC_SEMILAG_PPM
35
#define RECONSTRUCTION_ORDER 2
36
#endif
37
#ifdef ACC_SEMILAG_PQM
38
#define RECONSTRUCTION_ORDER 4
39
#endif
40
41
// Natural constants
42
namespace
physicalconstants
{
43
const
Real
MU_0
= 1.25663706e-6;
44
const
Real
K_B
= 1.3806503e-23;
45
const
Real
CHARGE
= 1.60217653e-19;
46
const
Real
MASS_PROTON
= 1.67262158e-27;
47
const
Real
R_E
= 6.3712e6;
48
}
49
50
51
#endif
52
53
WID
#define WID
Definition
common.h:514
WID3
const int WID3
Definition
common.h:517
WID2
const int WID2
Definition
common.h:516
cuint
const uint32_t cuint
Definition
definitions.h:50
Real
float Real
Definition
definitions.h:41
creal
const float creal
Definition
definitions.h:42
CHARGE
static const Real CHARGE
Definition
differentialFlux.cpp:15
arch::uint
uint32_t uint
Definition
arch_device_api.h:17
physicalconstants
Definition
common.h:568
physicalconstants::K_B
const Real K_B
Definition
common.h:571
physicalconstants::MU_0
const Real MU_0
Definition
common.h:570
MASS_PROTON
static const Real MASS_PROTON
Definition
sigmaProfiles.cpp:25
R_E
#define R_E
Definition
test1.cpp:15
mini-apps
acceleration-vlasiator
common.h
Generated on
for Vlasiator by
1.16.1