aboutsummaryrefslogtreecommitdiff
path: root/src/macro/DYYDG_declare.h
blob: 100441a0df830e76c0c50ce186e717fa5639c99b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
/*@@
  @header   DYYDG_declare.h
  @date     Jun 98
  @author   Gabrielle Allen
  @desc
  Declarations for macro to calculate the (first and) second derivatives 
  of the physical metric with respect to y

  The macro uses @seefile DYDG_guts.h and @seefile DYDG_declare.h
  @enddesc
@@*/

#ifndef DYYDG_DECLARE
#define DYYDG_DECLARE

#include "DYDG_declare.h"

#ifdef FCODE

/* Output variables */
#undef  DYYDG_DYYDGXX
#define DYYDG_DYYDGXX dyydgxx
#undef  DYYDG_DYYDGXY
#define DYYDG_DYYDGXY dyydgxy
#undef  DYYDG_DYYDGXZ
#define DYYDG_DYYDGXZ dyydgxz
#undef  DYYDG_DYYDGYY
#define DYYDG_DYYDGYY dyydgyy
#undef  DYYDG_DYYDGYZ
#define DYYDG_DYYDGYZ dyydgyz
#undef  DYYDG_DYYDGZZ
#define DYYDG_DYYDGZZ dyydgzz

/* Internal variables */
#undef  DYYDG_FAC
#define DYYDG_FAC dyydg_fac
#undef  DYYDG_OODY2
#define DYYDG_OODY2 dyydg_oody2
#undef  DYYDG_DYYDPSI_O_PSI
#define DYYDG_DYYDPSI_O_PSI psiyy(i,j,k)

/* Declare internal variables */
      CCTK_REAL DYYDG_FAC
      CCTK_REAL DYYDG_OODY2

/* Declare output variables */
      CCTK_REAL DYYDG_DYYDGXX
      CCTK_REAL DYYDG_DYYDGXY
      CCTK_REAL DYYDG_DYYDGXZ
      CCTK_REAL DYYDG_DYYDGYY
      CCTK_REAL DYYDG_DYYDGYZ
      CCTK_REAL DYYDG_DYYDGZZ

#endif

#ifdef CCODE

/* Output variables */
#undef  DYYDG_DYYDGXX
#define DYYDG_DYYDGXX deldelg2211
#undef  DYYDG_DYYDGXY
#define DYYDG_DYYDGXY deldelg2212
#undef  DYYDG_DYYDGXZ
#define DYYDG_DYYDGXZ deldelg2213
#undef  DYYDG_DYYDGYY
#define DYYDG_DYYDGYY deldelg2222
#undef  DYYDG_DYYDGYZ
#define DYYDG_DYYDGYZ deldelg2223
#undef  DYYDG_DYYDGZZ
#define DYYDG_DYYDGZZ deldelg2233

/* Internal variables */
#undef  DYYDG_FAC
#define DYYDG_FAC dyydg_fac
#undef  DYYDG_OODY2
#define DYYDG_OODY2 dyydg_oody2
#undef  DYYDG_DYYDPSI_O_PSI
#define DYYDG_DYYDPSI_O_PSI psiyy[ijk]

/* Declare internal variables */
CCTK_REAL DYYDG_FAC;
CCTK_REAL DYYDG_OODY2 = 1/(cctkGH->cctk_delta_space[1]*cctkGH->cctk_delta_space[1]);

/* Declare output variables */
CCTK_REAL DYYDG_DYYDGXX;
CCTK_REAL DYYDG_DYYDGXY;
CCTK_REAL DYYDG_DYYDGXZ;
CCTK_REAL DYYDG_DYYDGYY;
CCTK_REAL DYYDG_DYYDGYZ;
CCTK_REAL DYYDG_DYYDGZZ;

#endif

#endif