define.h 1.39 KB
Newer Older
Cassio Kirch's avatar
Cassio Kirch committed
1
2
3
4
5
6
7
8
9
#define X        0
#define Y        1
#define Z        2
#define PI       3.14159265359

//#define PLOT_EXIT_FILES
#define GAMMA_FILE

#define ENDOPROP               0.25
Cassio Kirch's avatar
Cassio Kirch committed
10
#define N                      3200
11
#define RANGE                  240.0
Cassio Kirch's avatar
Cassio Kirch committed
12
13
14
#define PROP                   0.35
#define SEED                   13049        /* Must be unsigned int. */
#define DIMENSIONS             2
Cassio Kirch's avatar
Cassio Kirch committed
15
16
#define BOXES                  32400
#define BOXES_IN_EDGE          180
Cassio Kirch's avatar
Cassio Kirch committed
17
#define NEIGHBOR_DISTANCE      1.32              /* r0 */
Cassio Kirch's avatar
Cassio Kirch committed
18
#define CORE_RADIUS            0.4               /* rc */
Cassio Kirch's avatar
Cassio Kirch committed
19
20
21
#define ELASTIC_DISTANCE       1.0               /* re */
#define INFINITE_FORCE         10000.0
#define ETA                    1.0
Cassio Kirch's avatar
Cassio Kirch committed
22
#define V0                     0.007
Cassio Kirch's avatar
Cassio Kirch committed
23
24
25
#define ALPHA11                0.01
#define ALPHA12                0.01
#define ALPHA22                0.01
Cassio Kirch's avatar
Cassio Kirch committed
26
27
28
#define BETA11                 0.3
#define BETA12                 0.16
#define BETA22                 0.15
Cassio Kirch's avatar
Cassio Kirch committed
29
#define DT                     1.0
30
#define DATE_SIZE              36           /* Size of string */
Cassio Kirch's avatar
Cassio Kirch committed
31
#define FILENAME_SIZE          128           /* Size of string */
Cassio Kirch's avatar
Cassio Kirch committed
32
#define STEPS                  250000000
Cassio Kirch's avatar
Cassio Kirch committed
33
34
35
36
37
38
39
#define EXIT_INTERVAL          1000
#define NUM_THREADS            8

#define RANDOM_0(max) (((double)rand()/RAND_MAX) * max)

#define absDistance(x1, y1, x2, y2) sqrt(pow ((x2) - (x1), 2) +       \
                                         pow ((y2) - (y1), 2))