blob: fed0fddcaeb078fa6cee12117c40ad3a781ef632 (
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
|
/*@@
@file Check.c
@date 19 May 2003
@author David Rideout
@desc
Check that the dimension of any grid variables is not greater than
what the faces specification can handle (currently 15).
@enddesc
@history
@hdate
@hauthor
@hdesc
@endhistory
@version $Header$
@@*/
#include "cctk.h"
#include "cctk_Arguments.h"
/* the rcs ID and its dummy function to use it */
static const char *rcsid = "$Header$";
CCTK_FILEVERSION(CactusBase_Boundary_Check_c);
/* Maximum dimension for grid variables to be selected for BC.
Restriction is representation of set of faces in a 32 bit signed integer. */
#define MAX_DIM 15
/********************************************************************
******************** Prototypes *******************************
********************************************************************/
int Boundary_Check(CCTK_ARGUMENTS);
/********************************************************************
******************** Scheduled Routines ***********************
********************************************************************/
/*@@
@routine Boundary_Check
@date 19 May 2003
@author David Rideout
@desc
Check that the dimension of any grid variables is not greater than
what the faces specification can handle (currently 15).
@enddesc
@calls
@history
Note that in future versions of Cactus this will require the GH
passed through CCTK_ARGUMENTS.
@endhistory
@var CCTK_ARGUMENTS
@vdesc standard Cactus argument list
@vtype various
@vio in
@endvar
@returntype int
@returndesc
0 success
-1 cactus executable contains variable group with too many
dimensions
@endreturndesc
@@*/
int Boundary_Check(CCTK_ARGUMENTS)
{
DECLARE_CCTK_ARGUMENTS;
int retval;
retval = 0;
if (CCTK_MaxDim() > 15)
{
CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,
"Executable contains variable group with more than 15 "
"dimensions. Thorn Boundary will not function properly for "
"these variable groups.");
retval = -1;
}
return retval;
}
|