File: | /home/sbrandt/cactus/Cactus/configs/sim2/bindings/Variables/HydroBase.c |
1 | :/*@@
|
2 | : @file HydroBase.c
|
3 | : @author Automatically generated by GridFuncStuff.pl
|
4 | : @desc
|
5 | : Creates the CCTK variables for thorn HydroBase
|
6 | : @enddesc
|
7 | : @@*/
|
8 | :
|
9 | :
|
10 | :
|
11 | :#include <stddef.h>
|
12 | :
|
13 | :#include "HydroBase/cctk.h"
|
14 | :#include "HydroBase/cctk_Arguments.h"
|
15 | :#include "cctk_Parameter.h"
|
16 | :#include "cctk_WarnLevel.h"
|
17 | :#include "cctki_Groups.h"
|
18 | :#include "cctki_FortranWrappers.h"
|
19 | :#include "HydroBase/cctk_ScheduleFunctions.h"
|
20 | :
|
21 | :int CactusBindingsVariables_HydroBase_Initialise(void);
|
22 | :static int CCTKi_BindingsFortranWrapperHydroBase(void *_GH, void *fpointer);
|
23 | :
|
24 | :static int CCTKi_BindingsFortranWrapperHydroBase(void *_GH, void *fpointer)
|
25 | :{
|
26 | : cGH const *const GH = _GH;
|
27 | : const int _cctk_zero = 0;
|
28 | : void (*function)(HYDROBASE_C2F_PROTO);
|
29 | : DECLARE_HYDROBASE_C2F
|
30 | : INITIALISE_HYDROBASE_C2F
|
31 | : (void) (_cctk_zero + 0);
|
32 | :
|
33 | : function = (void (*) (HYDROBASE_C2F_PROTO)) fpointer;
|
34 | : function (PASS_HYDROBASE_C2F (GH));
|
35 | :
|
36 | : return (0);
|
37 | :}
|
38 | :
|
39 | :int CactusBindingsVariables_HydroBase_Initialise(void)
|
40 | :{
|
41 | : const char * warn_mixeddim_gfs = "";
|
42 | : int warn_mixeddim = 0;
|
43 | : const CCTK_INT *allow_mixeddim_gfs;
|
44 | :
|
45 | :
|
46 | : allow_mixeddim_gfs = CCTK_ParameterGet ("allow_mixeddim_gfs", "Cactus", 0);
|
47 | :
|
48 | : if (CCTKi_CreateGroup ("RHO", "HYDROBASE", "HYDROBASE",
|
49 | : "GF", "REAL", "PUBLIC",
|
50 | : 3, 3,
|
51 | : "DEFAULT",
|
52 | : "", "",
|
53 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
54 | : NULL,
|
55 | : 1,
|
56 | : "rho") == 1)
|
57 | : {
|
58 | : warn_mixeddim_gfs = "rho";
|
59 | : warn_mixeddim = 3;
|
60 | : }
|
61 | : if (CCTKi_CreateGroup ("PRESS", "HYDROBASE", "HYDROBASE",
|
62 | : "GF", "REAL", "PUBLIC",
|
63 | : 3, 3,
|
64 | : "DEFAULT",
|
65 | : "", "",
|
66 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
67 | : NULL,
|
68 | : 1,
|
69 | : "press") == 1)
|
70 | : {
|
71 | : warn_mixeddim_gfs = "press";
|
72 | : warn_mixeddim = 3;
|
73 | : }
|
74 | : if (CCTKi_CreateGroup ("EPS", "HYDROBASE", "HYDROBASE",
|
75 | : "GF", "REAL", "PUBLIC",
|
76 | : 3, 3,
|
77 | : "DEFAULT",
|
78 | : "", "",
|
79 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
80 | : NULL,
|
81 | : 1,
|
82 | : "eps") == 1)
|
83 | : {
|
84 | : warn_mixeddim_gfs = "eps";
|
85 | : warn_mixeddim = 3;
|
86 | : }
|
87 | : if (CCTKi_CreateGroup ("VEL", "HYDROBASE", "HYDROBASE",
|
88 | : "GF", "REAL", "PUBLIC",
|
89 | : 3, 3,
|
90 | : "DEFAULT",
|
91 | : "", "",
|
92 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"U\" interpolator=\"matter\"",
|
93 | : "3",
|
94 | : 1,
|
95 | : "vel") == 1)
|
96 | : {
|
97 | : warn_mixeddim_gfs = "vel";
|
98 | : warn_mixeddim = 3;
|
99 | : }
|
100 | : if (CCTKi_CreateGroup ("W_LORENTZ", "HYDROBASE", "HYDROBASE",
|
101 | : "GF", "REAL", "PUBLIC",
|
102 | : 3, 3,
|
103 | : "DEFAULT",
|
104 | : "", "",
|
105 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
106 | : NULL,
|
107 | : 1,
|
108 | : "w_lorentz") == 1)
|
109 | : {
|
110 | : warn_mixeddim_gfs = "w_lorentz";
|
111 | : warn_mixeddim = 3;
|
112 | : }
|
113 | : if (CCTKi_CreateGroup ("Y_E", "HYDROBASE", "HYDROBASE",
|
114 | : "GF", "REAL", "PUBLIC",
|
115 | : 3, 3,
|
116 | : "DEFAULT",
|
117 | : "", "",
|
118 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
119 | : NULL,
|
120 | : 1,
|
121 | : "Y_e") == 1)
|
122 | : {
|
123 | : warn_mixeddim_gfs = "Y_e";
|
124 | : warn_mixeddim = 3;
|
125 | : }
|
126 | : if (CCTKi_CreateGroup ("TEMPERATURE", "HYDROBASE", "HYDROBASE",
|
127 | : "GF", "REAL", "PUBLIC",
|
128 | : 3, 3,
|
129 | : "DEFAULT",
|
130 | : "", "",
|
131 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
132 | : NULL,
|
133 | : 1,
|
134 | : "temperature") == 1)
|
135 | : {
|
136 | : warn_mixeddim_gfs = "temperature";
|
137 | : warn_mixeddim = 3;
|
138 | : }
|
139 | : if (CCTKi_CreateGroup ("ENTROPY", "HYDROBASE", "HYDROBASE",
|
140 | : "GF", "REAL", "PUBLIC",
|
141 | : 3, 3,
|
142 | : "DEFAULT",
|
143 | : "", "",
|
144 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" interpolator=\"matter\"",
|
145 | : NULL,
|
146 | : 1,
|
147 | : "entropy") == 1)
|
148 | : {
|
149 | : warn_mixeddim_gfs = "entropy";
|
150 | : warn_mixeddim = 3;
|
151 | : }
|
152 | : if (CCTKi_CreateGroup ("BVEC", "HYDROBASE", "HYDROBASE",
|
153 | : "GF", "REAL", "PUBLIC",
|
154 | : 3, 3,
|
155 | : "DEFAULT",
|
156 | : "", "",
|
157 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"U\" tensorparity=-1 interpolator=\"matter\"",
|
158 | : "3",
|
159 | : 1,
|
160 | : "Bvec") == 1)
|
161 | : {
|
162 | : warn_mixeddim_gfs = "Bvec";
|
163 | : warn_mixeddim = 3;
|
164 | : }
|
165 | : if (CCTKi_CreateGroup ("AVEC", "HYDROBASE", "HYDROBASE",
|
166 | : "GF", "REAL", "PUBLIC",
|
167 | : 3, 3,
|
168 | : "DEFAULT",
|
169 | : "", "",
|
170 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"D\" jacobian=\"jacobian\" interpolator=\"matter\"",
|
171 | : "3",
|
172 | : 1,
|
173 | : "Avec") == 1)
|
174 | : {
|
175 | : warn_mixeddim_gfs = "Avec";
|
176 | : warn_mixeddim = 3;
|
177 | : }
|
178 | : if (CCTKi_CreateGroup ("APHI", "HYDROBASE", "HYDROBASE",
|
179 | : "GF", "REAL", "PUBLIC",
|
180 | : 3, 3,
|
181 | : "DEFAULT",
|
182 | : "", "",
|
183 | : "ProlongationParameter=\"HydroBase::prolongation_type\" tensortypealias=\"Scalar\" jacobian=\"jacobian\" interpolator=\"matter\"",
|
184 | : NULL,
|
185 | : 1,
|
186 | : "Aphi") == 1)
|
187 | : {
|
188 | : warn_mixeddim_gfs = "Aphi";
|
189 | : warn_mixeddim = 3;
|
190 | : }
|
191 | : if (CCTKi_CreateGroup ("HYDRO_EXCISION_MASK", "HYDROBASE", "HYDROBASE",
|
192 | : "GF", "INT", "PUBLIC",
|
193 | : 3, 1,
|
194 | : "DEFAULT",
|
195 | : "", "",
|
196 | : "Prolongation=\"None\" checkpoint=\"no\"",
|
197 | : NULL,
|
198 | : 1,
|
199 | : "hydro_excision_mask") == 1)
|
200 | : {
|
201 | : warn_mixeddim_gfs = "hydro_excision_mask";
|
202 | : warn_mixeddim = 3;
|
203 | : }
|
204 | :
|
205 | : if (*warn_mixeddim_gfs)
|
206 | : {
|
207 | : if (allow_mixeddim_gfs && *allow_mixeddim_gfs)
|
208 | : {
|
209 | : CCTK_VWarn (2, __LINE__, __FILE__, "Cactus",
|
210 | : "CCTKi_CreateGroup: Working dimension already set, "
|
211 | : "creating GF group '%s' with different dimension %d",
|
212 | : warn_mixeddim_gfs, warn_mixeddim);
|
213 | : }
|
214 | : else
|
215 | : {
|
216 | : CCTK_VWarn (0, __LINE__, __FILE__, "Cactus",
|
217 | : "CCTKi_CreateGroup: Working dimension already set, "
|
218 | : "cannot create GF group '%s' with dimension %d",
|
219 | : warn_mixeddim_gfs, warn_mixeddim);
|
220 | : }
|
221 | : }
|
222 | :
|
223 | : CCTKi_RegisterFortranWrapper("HydroBase", CCTKi_BindingsFortranWrapperHydroBase);
|
224 | :
|
225 | : return 0;
|
226 | :}
|
227 | :
|