| { |
| "thorn_name": "CactusBase/CartGrid3D", |
| "url": "https://bitbucket.org/cactuscode/cactusbase.git", |
| "configuration": "# Configuration definitions for thorn CartGrid2D\n# $Header$\n\n# This will disappear once no-one calls anything from this thorn\nPROVIDES CartGrid3D\n{\n SCRIPT\n LANG\n}\n\n# This will disappear once the aliasing has a requires\n\nREQUIRES CoordBase\n", |
| "interface": "# Interface definition for thorn CartGrid3D\n# $Header$\n\nimplements: grid\ninherits: coordbase\n\nINCLUDE HEADER: Symmetry.h in Symmetry.h\nuses include header: CoordBase.h\n\n# The overall size of the domain\nCCTK_INT FUNCTION GetDomainSpecification \\\n (CCTK_INT IN size, \\\n CCTK_REAL OUT ARRAY physical_min, \\\n CCTK_REAL OUT ARRAY physical_max, \\\n CCTK_REAL OUT ARRAY interior_min, \\\n CCTK_REAL OUT ARRAY interior_max, \\\n CCTK_REAL OUT ARRAY exterior_min, \\\n CCTK_REAL OUT ARRAY exterior_max, \\\n CCTK_REAL OUT ARRAY spacing)\nUSES FUNCTION GetDomainSpecification\n\nCCTK_INT FUNCTION ConvertFromPhysicalBoundary \\\n (CCTK_INT IN size, \\\n CCTK_REAL IN ARRAY physical_min, \\\n CCTK_REAL IN ARRAY physical_max, \\\n CCTK_REAL OUT ARRAY interior_min, \\\n CCTK_REAL OUT ARRAY interior_max, \\\n CCTK_REAL OUT ARRAY exterior_min, \\\n CCTK_REAL OUT ARRAY exterior_max, \\\n CCTK_REAL IN ARRAY spacing)\nUSES FUNCTION ConvertFromPhysicalBoundary\n\n\n\nCCTK_INT FUNCTION \\\n MultiPatch_GetMap \\\n (CCTK_POINTER_TO_CONST IN cctkGH)\nUSES FUNCTION MultiPatch_GetMap\n\nCCTK_INT FUNCTION \\\n MultiPatch_GetDomainSpecification \\\n (CCTK_INT IN map, \\\n CCTK_INT IN size, \\\n CCTK_REAL OUT ARRAY physical_min, \\\n CCTK_REAL OUT ARRAY physical_max, \\\n CCTK_REAL OUT ARRAY interior_min, \\\n CCTK_REAL OUT ARRAY interior_max, \\\n CCTK_REAL OUT ARRAY exterior_min, \\\n CCTK_REAL OUT ARRAY exterior_max, \\\n CCTK_REAL OUT ARRAY spacing)\nUSES FUNCTION MultiPatch_GetDomainSpecification\n\nCCTK_INT FUNCTION \\\n MultiPatch_ConvertFromPhysicalBoundary \\\n (CCTK_INT IN map, \\\n CCTK_INT IN size, \\\n CCTK_REAL IN ARRAY physical_min, \\\n CCTK_REAL IN ARRAY physical_max, \\\n CCTK_REAL OUT ARRAY interior_min, \\\n CCTK_REAL OUT ARRAY interior_max, \\\n CCTK_REAL OUT ARRAY exterior_min, \\\n CCTK_REAL OUT ARRAY exterior_max, \\\n CCTK_REAL IN ARRAY spacing)\nUSES FUNCTION MultiPatch_ConvertFromPhysicalBoundary\n\n\n\n# Register the symmetry boundaries\nCCTK_INT FUNCTION SymmetryRegister (CCTK_STRING IN sym_name)\nUSES FUNCTION SymmetryRegister\n\nCCTK_INT FUNCTION \\\n SymmetryRegisterGrid \\\n (CCTK_POINTER IN cctkGH, \\\n CCTK_INT IN sym_handle, \\\n CCTK_INT IN ARRAY which_faces, \\\n CCTK_INT IN ARRAY symmetry_zone_width) \nUSES FUNCTION SymmetryRegisterGrid\n\n\n\n# Apply the symmetry boundary conditions\nCCTK_INT FUNCTION Boundary_SelectedGVs \\\n (CCTK_POINTER_TO_CONST IN GH, \\\n CCTK_INT IN array_size, \\\n CCTK_INT ARRAY OUT var_indicies, \\\n CCTK_INT ARRAY OUT faces, \\\n CCTK_INT ARRAY OUT boundary_widths, \\\n CCTK_INT ARRAY OUT table_handles, \\\n CCTK_STRING IN bc_name)\nUSES FUNCTION Boundary_SelectedGVs\n\npublic:\n\nREAL gridspacings type=SCALAR tags='Checkpoint=\"no\"'\n{\n coarse_dx, coarse_dy, coarse_dz\n} \"3D Cartesian grid spacings\"\n\nREAL coordinates type=GF tags='Prolongation=\"None\" Checkpoint=\"no\"'\n{\n x, y, z, r\n# will become:\n# coord_x, coord_y, coord_z\n} \"3D Cartesian grid coordinates\"\n", |
| "param": "# Parameter definitions for thorn CartGrid3D\n# $Header$\n\nshares: driver\n\nUSES BOOLEAN periodic\nUSES BOOLEAN periodic_x\nUSES BOOLEAN periodic_y\nUSES BOOLEAN periodic_z\n\n\nprivate:\n\nBOOLEAN no_origin \"DEPRECATED: Don't place grid points on the coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN no_originx \"DEPRECATED: Don't place grid points on the x-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN no_originy \"DEPRECATED: Don't place grid points on the y-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN no_originz \"DEPRECATED: Don't place grid points on the z-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN avoid_originx \"Don't place grid points on the x-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN avoid_originy \"Don't place grid points on the y-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN avoid_originz \"Don't place grid points on the z-coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN avoid_origin \"Don't place grid points on the coordinate origin/axes\"\n{\n : :: \"\"\n} \"yes\"\n\nBOOLEAN register_default_coordinate_systems \"register cartnd as the default coordinate systems\"\n{\n} \"yes\"\n\nrestricted:\n\nREAL dx \"Coarse grid spacing in x-direction\"\n{\n 0:* :: \"Positive\"\n} 0.3\nREAL dy \"Coarse grid spacing in y-direction\"\n{\n 0:* :: \"Positive\"\n} 0.3\nREAL dz \"Coarse grid spacing in z-direction\"\n{\n 0:* :: \"Positive\"\n} 0.3\nREAL dxyz \"Coarse grid spacing in x,y,z-directions\"\n{\n 0:* :: \"Positive\"\n} 0.0\n\n\nREAL xmin \"Coordinate minimum in x-direction\"\n{\n : :: \"Anything\"\n} -1.0\nREAL ymin \"Coordinate minimum in y-direction\"\n{\n : :: \"Anything\"\n} -1.0\nREAL zmin \"Coordinate minimum in z-direction\"\n{\n : :: \"Anything\"\n} -1.0\nREAL xyzmin \"Coordinate minimum in x,y,z-directions\"\n{\n : :: \"Anything\"\n} -424242\n\n\nREAL xmax \"Coordinate maximum in x-direction\"\n{\n : :: \"Anything\"\n} 1.0\nREAL ymax \"Coordinate maximum in y-direction\"\n{\n : :: \"Anything\"\n} 1.0\nREAL zmax \"Coordinate maximum in z-direction\"\n{\n : :: \"Anything\"\n} 1.0\nREAL xyzmax \"Coordinate maximum in xyz-directions\"\n{\n : :: \"Anything\"\n} -424242\n\n\nKEYWORD type \"Grid type\"\n{\n \"box\" :: \"Box grid from -0.5 to 0.5\"\n \"byrange\" :: \"Specify min and max values\"\n \"byspacing\" :: \"Specify grid spacings\"\n \"coordbase\" :: \"Get specification from CoordBase\"\n \"multipatch\" :: \"Get specification from MultiPatch\"\n} \"box\"\n\nKEYWORD domain \"Domain type\"\n{\n \"octant\" :: \"Use an octant about the origin\"\n \"quadrant\" :: \"Use a quadrant in x-y plane\"\n \"quadrant_reflect_rotate\" :: \"Use a quadrant with rotation symmetry about an axis\"\n \"bitant\" :: \"Use a bitant about the x-y plane\"\n \"bitant_rotate\" :: \"Use a bitant with rotation symmetry about an axis\"\n \"full\" :: \"Use the full domain\"\n} \"full\"\n\nKEYWORD bitant_plane \"Plane defining bitant domain\"\n{\n \"xy\" :: \"xy-plane\"\n \"xz\" :: \"xz-plane\"\n \"yz\" :: \"yz-plane\"\n} \"xy\"\n\nKEYWORD quadrant_direction \"Direction defining quadrant domain\"\n{\n \"x\" :: \"x-direction\"\n \"y\" :: \"y-direction\"\n \"z\" :: \"z-direction\"\n} \"z\"\n\nKEYWORD rotation_axis \"Axis about which the rotation symmetry is to be applied\"\n{\n \"x\" :: \"x-axis\"\n \"y\" :: \"y-axis\"\n \"z\" :: \"z-axis\"\n} \"z\"\n\n\nBOOLEAN symmetry_xmin \"Symmetry boundary condition on lower x boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nBOOLEAN symmetry_ymin \"Symmetry boundary condition on lower y boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nBOOLEAN symmetry_zmin \"Symmetry boundary condition on lower z boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nBOOLEAN symmetry_xmax \"Symmetry boundary condition on upper x boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nBOOLEAN symmetry_ymax \"Symmetry boundary condition on upper y boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nBOOLEAN symmetry_zmax \"Symmetry boundary condition on upper z boundary\"\n{\n : :: \"Logical\"\n} \"no\"\n\nprivate:\n\nKEYWORD set_coordinate_ranges_on \"On which grids to set the coordinate ranges\"\n{\n \"all grids\" :: \"set ranges in local mode, on the coarsest level\"\n \"all maps\" :: \"set ranges in singlemap mode, on the coarsest level\"\n \"first level\" :: \"set ranges in level mode, on the first level\"\n} \"all grids\"\n", |
| "schedule": "# Schedule definitions for thorn CartGrid3D\n# $Header$\n\nSTORAGE: coordinates gridspacings\n\nschedule SymmetryStartup at CCTK_STARTUP\n{\n LANG: C\n} \"Register GH Extension for GridSymmetry\"\n\nschedule RegisterCartGrid3DCoords at CCTK_WRAGH\n{\n LANG:C\n OPTIONS: meta\n} \"Register coordinates for the Cartesian grid\"\n\nschedule CartGrid3D_RegisterSymmetryBoundaries in SymmetryRegister\n{\n LANG:C\n OPTIONS: meta\n} \"Register symmetry boundaries\"\n\nschedule ParamCheck_CartGrid3D at CCTK_PARAMCHECK\n{\n LANG:C\n} \"Check coordinates for CartGrid3D\"\n\nif (CCTK_EQUALS (set_coordinate_ranges_on, \"all grids\"))\n{\n schedule CartGrid3D_SetRanges at CCTK_BASEGRID as SpatialSpacings before SpatialCoordinates\n {\n LANG:C\n WRITES: GRID::gridspacings(everywhere) \n } \"Set up ranges for spatial 3D Cartesian coordinates (on all grids)\"\n}\nelse if (CCTK_EQUALS (set_coordinate_ranges_on, \"all maps\"))\n{\n schedule CartGrid3D_SetRanges at CCTK_BASEGRID as SpatialSpacings before SpatialCoordinates\n {\n LANG:C\n WRITES: GRID::gridspacings(everywhere)\n OPTIONS: singlemap\n } \"Set up ranges for spatial 3D Cartesian coordinates (on all maps)\"\n}\nelse if (CCTK_EQUALS (set_coordinate_ranges_on, \"first level\"))\n{\n schedule CartGrid3D_SetRanges at CCTK_BASEGRID as SpatialSpacings before SpatialCoordinates\n {\n LANG:C\n READS: GRID::gridspacings(everywhere)\n OPTIONS: level\n } \"Set up ranges for spatial 3D Cartesian coordinates (on first level)\"\n}\n\nschedule CartGrid3D_SetCoordinates as SpatialCoordinates at CCTK_BASEGRID\n{\n LANG:C\n WRITES: GRID::coordinates(everywhere)\n} \"Set up spatial 3D Cartesian coordinates on the GH\"\n\nschedule CartGrid3D_SetCoordinates as SpatialCoordinates at CCTK_POSTREGRIDINITIAL\n{\n LANG: C\n WRITES: GRID::coordinates(everywhere)\n} \"Set Coordinates after regridding\"\n\nschedule CartGrid3D_SetCoordinates as SpatialCoordinates at CCTK_POSTREGRID\n{\n LANG: C\n WRITES: GRID::coordinates(Everywhere)\n} \"Set Coordinates after regridding\"\n\nschedule CartGrid3D_ApplyBC in BoundaryConditions\n{\n LANG: C\n} \"Apply symmetry boundary conditions\"\n", |
| "src": { |
| "make.code.defn": "# Main make.code.defn file for thorn CartGrid3D\n# $Header$\n\n# Source files in this directory\nSRCS = Startup.c ParamCheck.c DecodeSymParameters.c CartGrid3D.c \\\n GetSymmetry.c SetSymmetry.c Symmetry.c RegisterSymmetries.c\n\n", |
| "RegisterSymmetries.c": "/* $Header$ */\n\n#include <stdlib.h>\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n\n#include \"Symmetry.h\"\n\nvoid DecodeSymParameters3D(int sym[6]);\n\nvoid CartGrid3D_RegisterSymmetryBoundaries(CCTK_ARGUMENTS) {\n DECLARE_CCTK_ARGUMENTS_CartGrid3D_RegisterSymmetryBoundaries;\n DECLARE_CCTK_PARAMETERS;\n\n int sym[6];\n int n;\n CCTK_INT faces[6];\n CCTK_INT width[6];\n CCTK_INT handle;\n\n DecodeSymParameters3D(sym);\n\n for (n = 0; n < 6; ++n) {\n faces[n] = sym[n];\n width[n] = cctk_nghostzones[n / 2];\n }\n\n handle = SymmetryRegister(\"CartGrid3D\");\n if (handle < 0) {\n CCTK_WARN(0, \"Could not register symmetry boundary condition\");\n }\n\n if (SymmetryRegisterGrid(cctkGH, handle, faces, width) < 0) {\n CCTK_WARN(0, \"Could not register the symmetry boundaries -- probably some \"\n \"other thorn has already registered the same boundary faces \"\n \"for a different symmetry\");\n }\n}\n", |
| "Symmetry.h": "/*@@\n @header Symmetry.h\n @date Sun 7th Mar 1999\n @author Gerd Lanfermann\n @desc\n The extensions to the GH structure for 3D grid symmetry treatment.\n\n We'll have six int array for every GF, which holds a flag\n for which symmetry or (physical) bnd-condition to apply\n at the grid faces.\n\n * These tables are set by SetSymmetry(GF,int,int,int)\n during initialization.\n * Default values ?\n * The information is used during evolution\n by Einstein_DoBound(GF), Einstein_DoSym(GF).\n @enddesc\n @version $Header$\n @@*/\n\n#ifndef _SYMMETRY_H_\n#define _SYMMETRY_H_ 1\n\n#include \"cctk.h\"\n\n#define GFSYM_UNKNOWN 0\n#define GFSYM_UNSET -41\n#define GFSYM_NOSYM -42\n\n#define GFSYM_REFLECTION 1\n#define GFSYM_ROTATION_X 2\n#define GFSYM_ROTATION_Y 3\n#define GFSYM_ROTATION_Z 4\n\n#define MAX_DIM 3\n#define MAX_FACE 6\n\ntypedef struct Symmetry {\n /* Symmetry[0..GF-1][0..dim-1] */\n /* in each direction [0,..dim-1], this will hold the symmetry\n operation across that plane, iff the grid layout requires this.\n this compares to the {sx,sy,sz} of Cactus3.2 */\n int **GFSym;\n} SymmetryGHex;\n\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n\nvoid CartGrid3D_ApplyBC(CCTK_ARGUMENTS);\n\nint GetCartSymVI(const cGH *GH, int *sym, int varindexi);\nint GetCartSymVN(const cGH *GH, int *sym, const char *varname);\n\nint SetCartSymVI(const cGH *GH, const int *sym, int varindex);\nint SetCartSymGI(const cGH *GH, const int *sym, int groupindex);\nint SetCartSymVN(const cGH *GH, const int *sym, const char *varname);\nint SetCartSymGN(const cGH *GH, const int *sym, const char *groupname);\n\nint CartSymVI(const cGH *GH, int varindex);\nint CartSymGI(const cGH *GH, int groupindexi);\nint CartSymVN(const cGH *GH, const char *varname);\nint CartSymGN(const cGH *GH, const char *groupname);\n\n#ifdef __cplusplus\n}\n#endif\n\n#endif /* _SYMMETRY_H_ */\n", |
| "Symmetry.c": "/*@@\n @file SymmetryWrappers.c\n @date April 2000\n @author Gerd Lanfermann\n @desc\n Routines to apply the 1/2/3D Symmetries for\n all symmetry domains (octant/bitant/quadrant).\n @enddesc\n @history\n @hdate Sat 02 Nov 2002\n @hauthor Thomas Radke\n @hdesc routines generalized for applying to arbitrary CCTK data types\n @endhistory\n @version $Id$\n@@*/\n\n#include <stdlib.h>\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n\n#include \"Symmetry.h\"\n\n/* the rcs ID and its dummy function to use it */\nstatic const char *rcsid = \"$Header$\";\nCCTK_FILEVERSION(CactusBase_CartGrid3D_Symmetry_c)\n\n/********************************************************************\n ********************* Local Routine Prototypes *********************\n ********************************************************************/\nstatic int ApplySymmetry(const cGH *GH, int gindex, int first_vindex,\n int numvars);\n\n/********************************************************************\n ******************* Fortran Wrapper Prototypes *********************\n ********************************************************************/\nvoid CCTK_FCALL CCTK_FNAME(CartSymGI)(int *ierr, const cGH **GH, int *gindex);\nvoid CCTK_FCALL\n CCTK_FNAME(CartSymGN)(int *ierr, const cGH **GH, ONE_FORTSTRING_ARG);\nvoid CCTK_FCALL CCTK_FNAME(CartSymVI)(int *ierr, const cGH **GH, int *vindex);\nvoid CCTK_FCALL\n CCTK_FNAME(CartSymVN)(int *ierr, const cGH **GH, ONE_FORTSTRING_ARG);\n\n/********************************************************************\n ****************** External Routine Prototypes *********************\n ********************************************************************/\nvoid DecodeSymParameters3D(int sym[6]);\n\n/*@@\n @routine CartSymGI\n @date April 2000\n @author Gerd Lanfermann\n @desc\n Apply symmetry boundary routines by group index\n @enddesc\n @calls ApplySymmetry\n\n @var GH\n @vdesc Pointer to CCTK grid hierarchy\n @vtype const cGH *\n @vio in\n @endvar\n @var gindex\n @vdesc index of group to apply symmetry BC\n @vtype int\n @vio in\n @endvar\n\n @returntype int\n @returndesc\n return code of @seeroutine ApplySymmetry <BR>\n -1 if invalid group index was given\n @endreturndesc\n@@*/\nint CartSymGI(const cGH *GH, int gindex) {\n int numvars, first_vindex, retval;\n\n numvars = CCTK_NumVarsInGroupI(gindex);\n first_vindex = CCTK_FirstVarIndexI(gindex);\n if (numvars > 0 && first_vindex >= 0) {\n char *groupname = CCTK_GroupName(gindex);\n if (!groupname)\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error returned from function CCTK_GroupName\");\n CCTK_VWarn(3, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"You should not call the symmetry boundary condition routines \"\n \"for the group \\\"%s\\\" through the CartSym* routines any more. \"\n \"The symmetry boundary conditions are now applied automatically \"\n \"when a physical boundary condition is applied.\",\n groupname);\n free(groupname);\n retval = ApplySymmetry(GH, gindex, first_vindex, numvars);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid group index %d in CartSymGI\", gindex);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(CartSymGI)(int *ierr, const cGH **GH, int *gindex) {\n *ierr = CartSymGI(*GH, *gindex);\n}\n\n/*@@\n @routine CartSymGN\n @date April 2000\n @author Gerd Lanfermann\n @desc\n Apply symmetry boundary routines by group name\n @enddesc\n @calls ApplySymmetry\n\n @var GH\n @vdesc Pointer to CCTK grid hierarchy\n @vtype const cGH *\n @vio in\n @endvar\n @var gname\n @vdesc name of group to apply symmetry BC\n @vtype const char *\n @vio in\n @endvar\n\n @returntype int\n @returndesc\n return code of @seeroutine ApplySymmetry <BR>\n -1 if invalid group name was given\n @endreturndesc\n@@*/\nint CartSymGN(const cGH *GH, const char *gname) {\n int gindex, retval;\n\n gindex = CCTK_GroupIndex(gname);\n if (gindex >= 0) {\n retval = CartSymGI(GH, gindex);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid group name '%s' in CartSymGN\", gname);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL\n CCTK_FNAME(CartSymGN)(int *ierr, const cGH **GH, ONE_FORTSTRING_ARG) {\n ONE_FORTSTRING_CREATE(gname)\n *ierr = CartSymGN(*GH, gname);\n free(gname);\n}\n\n/*@@\n @routine CartSymVI\n @date April 2000\n @author Gerd Lanfermann\n @desc\n Apply symmetry boundary routines by variable index\n @enddesc\n @calls ApplySymmetry\n\n @var GH\n @vdesc Pointer to CCTK grid hierarchy\n @vtype const cGH *\n @vio in\n @endvar\n @var gindex\n @vdesc index of variable to apply symmetry BC\n @vtype int\n @vio in\n @endvar\n\n @returntype int\n @returndesc\n return code of @seeroutine ApplySymmetry <BR>\n -1 if invalid variable index was given\n @endreturndesc\n@@*/\nint CartSymVI(const cGH *GH, int vindex) {\n int retval, gindex;\n\n gindex = CCTK_GroupIndexFromVarI(vindex);\n if (gindex >= 0) {\n char *fullname = CCTK_FullName(vindex);\n if (!fullname)\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error returned from function CCTK_FullName\");\n CCTK_VWarn(3, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"You should not call the symmetry boundary condition routines \"\n \"for the variable \\\"%s\\\" through the CartSym* routines any \"\n \"more. The symmetry boundary conditions are now applied \"\n \"automatically when a physical boundary condition is applied.\",\n fullname);\n free(fullname);\n retval = ApplySymmetry(GH, gindex, vindex, 1);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid variable index %d in CartSymVI\", vindex);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(CartSymVI)(int *ierr, const cGH **GH, int *vindex) {\n *ierr = CartSymVI(*GH, *vindex);\n}\n\n/*@@\n @routine CartSymVN\n @date April 2000\n @author Gerd Lanfermann\n @desc\n Apply symmetry boundary routines by variable name\n @enddesc\n @calls ApplySymmetry\n\n @var GH\n @vdesc Pointer to CCTK grid hierarchy\n @vtype const cGH *\n @vio in\n @endvar\n @var gname\n @vdesc name of variable to apply symmetry BC\n @vtype const char *\n @vio in\n @endvar\n\n @returntype int\n @returndesc\n return code of @seeroutine ApplySymmetry <BR>\n -1 if invalid variable name was given\n @endreturndesc\n@@*/\nint CartSymVN(const cGH *GH, const char *vname) {\n int vindex, retval;\n\n vindex = CCTK_VarIndex(vname);\n if (vindex >= 0) {\n retval = CartSymVI(GH, vindex);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid variable name '%s' in CartSymVN\", vname);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL\n CCTK_FNAME(CartSymVN)(int *ierr, const cGH **GH, ONE_FORTSTRING_ARG) {\n ONE_FORTSTRING_CREATE(vname)\n *ierr = CartSymVN(*GH, vname);\n free(vname);\n}\n\n/********************************************************************\n ********************* Local Routines *************************\n ********************************************************************/\n/* macro to compute the linear index of a 3D point */\n#define INDEX_3D(ash, i, j, k) ((i) + (ash)[0] * ((j) + (ash)[1] * (k)))\n\n/*@@\n @routine SYMMETRY_BOUNDARY\n @date Sat 02 Nov 2002\n @author Thomas Radke\n @desc\n Macro to apply symmetry boundary conditions to a variable\n of given datatype\n Currently it is limited up to 3D variables only.\n @enddesc\n\n @var cctk_type\n @vdesc CCTK datatype of the variable\n @vtype <cctk_type>\n @vio in\n @endvar\n @var itype\n @vdesc integral CCTK datatype of the variable (used for typecasting)\n @vtype <cctk_type>\n @vio in\n @endvar\n@@*/\n#define APPLY_LOWER(dir, ii, jj, kk, jjend, kkend, iii, jjj, kkk, itype) \\\n { \\\n for (kk = 0; kk < kkend; kk++) { \\\n for (jj = 0; jj < jjend; jj++) { \\\n for (ii = 0; ii < gdata.nghostzones[dir / 2]; ii++) { \\\n _var[INDEX_3D(ash, i, j, k)] = (itype)( \\\n GFSym[vindex][dir] * _var[INDEX_3D(ash, iii, jjj, kkk)]); \\\n } \\\n } \\\n } \\\n }\n\n#define APPLY_UPPER(dir, ii, jj, kk, jjend, kkend, iii, jjj, kkk, itype) \\\n { \\\n for (kk = 0; kk < kkend; kk++) { \\\n for (jj = 0; jj < jjend; jj++) { \\\n for (ii = lsh[dir / 2] - gdata.nghostzones[dir / 2]; \\\n ii < lsh[dir / 2]; ii++) { \\\n _var[INDEX_3D(ash, i, j, k)] = (itype)( \\\n GFSym[vindex][dir] * _var[INDEX_3D(ash, iii, jjj, kkk)]); \\\n } \\\n } \\\n } \\\n }\n\n#define SYMMETRY_BOUNDARY(cctk_type, itype) \\\n { \\\n cctk_type *_var = GH->data[vindex][0]; \\\n \\\n switch (group_static_data.dim) { \\\n case 3: \\\n /* apply symmetry to the z faces */ \\\n if (doSym[4] == GFSYM_REFLECTION) { \\\n APPLY_LOWER(4, k, j, i, lsh[1], lsh[0], i, j, offset[4] - k, itype); \\\n } \\\n if (doSym[5] == GFSYM_REFLECTION) { \\\n APPLY_UPPER(5, k, j, i, lsh[1], lsh[0], i, j, offset[5] - k, itype); \\\n } \\\n if (doSym[4] == GFSYM_ROTATION_X) { \\\n APPLY_LOWER(4, k, j, i, lsh[1], lsh[0], i, lsh[1] - j - 1, \\\n offset[4] - k, itype); \\\n } \\\n if (doSym[5] == GFSYM_ROTATION_X) { \\\n APPLY_UPPER(5, k, j, i, lsh[1], lsh[0], i, lsh[1] - j - 1, \\\n offset[5] - k, itype); \\\n } \\\n if (doSym[4] == GFSYM_ROTATION_Y) { \\\n APPLY_LOWER(4, k, j, i, lsh[1], lsh[0], lsh[0] - i - 1, j, \\\n offset[4] - k, itype); \\\n } \\\n if (doSym[5] == GFSYM_ROTATION_Y) { \\\n APPLY_UPPER(5, k, j, i, lsh[1], lsh[0], lsh[0] - i - 1, j, \\\n offset[5] - k, itype); \\\n } \\\n /* FALL THROUGH */ \\\n case 2: \\\n /* apply symmetry to the y faces */ \\\n if (doSym[2] == GFSYM_REFLECTION) { \\\n APPLY_LOWER(2, j, k, i, lsh[2], lsh[0], i, offset[2] - j, k, itype); \\\n } \\\n if (doSym[3] == GFSYM_REFLECTION) { \\\n APPLY_UPPER(3, j, k, i, lsh[2], lsh[0], i, offset[3] - j, k, itype); \\\n } \\\n if (doSym[2] == GFSYM_ROTATION_Z) { \\\n APPLY_LOWER(2, j, k, i, lsh[2], lsh[0], lsh[0] - i - 1, offset[2] - j, \\\n k, itype); \\\n } \\\n if (doSym[3] == GFSYM_ROTATION_Z) { \\\n APPLY_UPPER(3, j, k, i, lsh[2], lsh[0], lsh[0] - i - 1, offset[3] - j, \\\n k, itype); \\\n } \\\n if (group_static_data.dim > 2) { \\\n if (doSym[2] == GFSYM_ROTATION_X) { \\\n APPLY_LOWER(2, j, k, i, lsh[2], lsh[0], i, offset[2] - j, \\\n lsh[2] - k - 1, itype); \\\n } \\\n if (doSym[3] == GFSYM_ROTATION_X) { \\\n APPLY_UPPER(3, j, k, i, lsh[2], lsh[0], i, offset[3] - j, \\\n lsh[2] - k - 1, itype); \\\n } \\\n } \\\n /* FALL THROUGH */ \\\n case 1: \\\n /* apply symmetry to the x faces */ \\\n if (doSym[0] == GFSYM_REFLECTION) { \\\n APPLY_LOWER(0, i, j, k, lsh[1], lsh[2], offset[0] - i, j, k, itype); \\\n } \\\n if (doSym[1] == GFSYM_REFLECTION) { \\\n APPLY_UPPER(1, i, j, k, lsh[1], lsh[2], offset[1] - i, j, k, itype); \\\n } \\\n if (group_static_data.dim > 1) { \\\n if (doSym[0] == GFSYM_ROTATION_Z) { \\\n APPLY_LOWER(0, i, j, k, lsh[1], lsh[2], offset[0] - i, \\\n lsh[1] - j - 1, k, itype); \\\n } \\\n if (doSym[1] == GFSYM_ROTATION_Z) { \\\n APPLY_UPPER(1, i, j, k, lsh[1], lsh[2], offset[1] - i, \\\n lsh[1] - j - 1, k, itype); \\\n } \\\n } \\\n if (group_static_data.dim > 2) { \\\n if (doSym[0] == GFSYM_ROTATION_Y) { \\\n APPLY_LOWER(0, i, j, k, lsh[1], lsh[2], offset[0] - i, j, \\\n lsh[2] - k - 1, itype); \\\n } \\\n if (doSym[1] == GFSYM_ROTATION_Y) { \\\n APPLY_UPPER(1, i, j, k, lsh[1], lsh[2], offset[1] - i, j, \\\n lsh[2] - k - 1, itype); \\\n } \\\n } \\\n /* FALL THROUGH */ \\\n default: \\\n ; \\\n } \\\n }\n\n/* Function to apply above macros. */\n#define SYMMETRY_FUNCTION(cctk_type, integral_type) \\\n static void cctk_type##_SymBC( \\\n const cGH *GH, const int vindex, const int *doSym, const int *offset, \\\n const int *lsh, const int *ash, const cGroup group_static_data, \\\n const cGroupDynamicData gdata, int **GFSym) { \\\n int i, j, k; \\\n SYMMETRY_BOUNDARY(cctk_type, integral_type); \\\n }\n\n/* Create functions to apply macros.\n * This is much easier for the optiser to deal with.\n * E.g. on some machines we can't compile this file if we use the macros\n * directly in the switch statement in ApplySymmetry.\n */\n\nSYMMETRY_FUNCTION(CCTK_COMPLEX, CCTK_REAL)\n#ifdef HAVE_CCTK_COMPLEX8\nSYMMETRY_FUNCTION(CCTK_COMPLEX8, CCTK_REAL4)\n#endif\n#ifdef HAVE_CCTK_COMPLEX16\nSYMMETRY_FUNCTION(CCTK_COMPLEX16, CCTK_REAL8)\n#endif\n#ifdef HAVE_CCTK_COMPLEX32\nSYMMETRY_FUNCTION(CCTK_COMPLEX32, CCTK_REAL16)\n#endif\n\nSYMMETRY_FUNCTION(CCTK_BYTE, CCTK_BYTE)\nSYMMETRY_FUNCTION(CCTK_INT, CCTK_INT)\n#ifdef HAVE_CCTK_INT1\nSYMMETRY_FUNCTION(CCTK_INT1, CCTK_INT1)\n#endif\n#ifdef HAVE_CCTK_INT2\nSYMMETRY_FUNCTION(CCTK_INT2, CCTK_INT2)\n#endif\n#ifdef HAVE_CCTK_INT4\nSYMMETRY_FUNCTION(CCTK_INT4, CCTK_INT4)\n#endif\n#ifdef HAVE_CCTK_INT8\nSYMMETRY_FUNCTION(CCTK_INT8, CCTK_INT8)\n#endif\n#ifdef HAVE_CCTK_INT16\nSYMMETRY_FUNCTION(CCTK_INT16, CCTK_INT16)\n#endif\nSYMMETRY_FUNCTION(CCTK_REAL, CCTK_REAL)\n#ifdef HAVE_CCTK_REAL4\nSYMMETRY_FUNCTION(CCTK_REAL4, CCTK_REAL4)\n#endif\n#ifdef HAVE_CCTK_REAL8\nSYMMETRY_FUNCTION(CCTK_REAL8, CCTK_REAL8)\n#endif\n#ifdef HAVE_CCTK_REAL16\nSYMMETRY_FUNCTION(CCTK_REAL16, CCTK_REAL16)\n#endif\n\n#define CALL_SYMBC(cctk_type) \\\n cctk_type##_SymBC(GH, vindex, doSym, offset, lsh, ash, group_static_data, \\\n gdata, GFSym)\n\n/*@@\n @routine ApplySymmetry\n @date Thu Mar 2 11:02:10 2000\n @author Gerd Lanfermann\n @desc\n Apply symmetry boundary conditions to a group of grid variables\n This routine is called by the various CartSymXXX wrappers.\n @enddesc\n\n @var GH\n @vdesc Pointer to CCTK grid hierarchy\n @vtype const cGH *\n @vio in\n @endvar\n @var gindex\n @vdesc group index of the variables to apply symmetry BCs\n @vtype int\n @vio in\n @endvar\n @var first_var\n @vdesc index of first variable to apply symmetry BCs\n @vtype int\n @vio in\n @endvar\n @var num_vars\n @vdesc number of variables\n @vtype int\n @vio in\n @endvar\n\n @calls CCTK_GroupData\n CCTK_GroupDynamicData\n SYMMETRY_BOUNDARY\n @history\n @hdate Sat 02 Nov 2002\n @hauthor Thomas Radke\n @hdesc Merged separate routines for 1D, 2D, and 3D\n into a single generic routine\n @endhistory\n\n @returntype int\n @returndesc\n 0 for success, or<BR>\n -1 if group dimension is not supported<BR>\n -2 if group datatype is not supported\n @endreturndesc\n@@*/\nstatic int ApplySymmetry(const cGH *GH, int gindex, int first_vindex,\n int numvars) {\n int i, dim, vindex, retval;\n int **GFSym;\n int domainsym[2 * MAX_DIM], doSym[2 * MAX_DIM], offset[2 * MAX_DIM];\n int lsh[MAX_DIM], ash[MAX_DIM], cntstag[MAX_DIM];\n cGroup group_static_data;\n cGroupDynamicData gdata;\n DECLARE_CCTK_PARAMETERS\n\n DecodeSymParameters3D(domainsym);\n\n /* check if any symmetries are to be applied */\n for (i = 0; i < 2 * MAX_DIM; i++) {\n if (domainsym[i]) {\n break;\n }\n }\n if (i == 2 * MAX_DIM) {\n return (0);\n }\n\n /* get the group's static and dynamic data structure */\n CCTK_GroupData(gindex, &group_static_data);\n CCTK_GroupDynamicData(GH, gindex, &gdata);\n if (group_static_data.dim <= 0 || group_static_data.dim > MAX_DIM) {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"ApplySymmetry: group dimension must 1, 2, or 3\");\n return (-1);\n }\n\n /* Avoid origin? Default is yes */\n cntstag[0] = no_origin && no_originx && avoid_origin && avoid_originx;\n cntstag[1] = no_origin && no_originy && avoid_origin && avoid_originy;\n cntstag[2] = no_origin && no_originz && avoid_origin && avoid_originz;\n\n /* initialize array for variables with less dimensions than MAX_DIM\n so that we can use the INDEX_3D macro later on */\n for (i = 0; i < MAX_DIM; i++) {\n if (i < group_static_data.dim) {\n lsh[i] = gdata.lsh[i];\n ash[i] = gdata.ash[i];\n } else {\n lsh[i] = 1;\n ash[i] = 1;\n }\n offset[2 * i + 0] = 2 * gdata.nghostzones[i] - cntstag[i];\n offset[2 * i + 1] = 2 * (lsh[i] - 1) - offset[2 * i + 0];\n }\n\n GFSym = ((SymmetryGHex *)CCTK_GHExtension(GH, \"Symmetry\"))->GFSym;\n\n /* Apply Symmetries if:\n + the Symmetry is activated (== NOT NOSYM)\n + the Symmetry is set (== NOT UNSET)\n + the length in the direction is more than 1 grid point\n + the processor has a lower/upper physical boundary.\n Whether a grid allows a symmetry along a direction (e.g. octant=all)\n is part if the Symmetry Setup process.\n */\n retval = 0;\n for (vindex = first_vindex; vindex < first_vindex + numvars; vindex++) {\n for (dim = 0; dim < 2 * group_static_data.dim; dim++) {\n if (GFSym[vindex][dim] == GFSYM_UNSET) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Symmetries unspecified for '%s'\", CCTK_VarName(vindex));\n }\n\n doSym[dim] = (GFSym[vindex][dim] != GFSYM_NOSYM &&\n GFSym[vindex][dim] != GFSYM_UNSET && lsh[dim / 2] > 1 &&\n GH->cctk_bbox[dim])\n ? domainsym[dim]\n : 0;\n }\n\n switch (group_static_data.vartype) {\n case CCTK_VARIABLE_BYTE:\n CALL_SYMBC(CCTK_BYTE);\n break;\n\n case CCTK_VARIABLE_INT:\n CALL_SYMBC(CCTK_INT);\n break;\n\n case CCTK_VARIABLE_REAL:\n CALL_SYMBC(CCTK_REAL);\n break;\n\n case CCTK_VARIABLE_COMPLEX:\n CALL_SYMBC(CCTK_COMPLEX);\n break;\n\n#ifdef HAVE_CCTK_INT1\n case CCTK_VARIABLE_INT1:\n CALL_SYMBC(CCTK_INT1);\n break;\n#endif\n\n#ifdef HAVE_CCTK_INT2\n case CCTK_VARIABLE_INT2:\n CALL_SYMBC(CCTK_INT2);\n break;\n#endif\n\n#ifdef HAVE_CCTK_INT4\n case CCTK_VARIABLE_INT4:\n CALL_SYMBC(CCTK_INT4);\n break;\n#endif\n\n#ifdef HAVE_CCTK_INT8\n case CCTK_VARIABLE_INT8:\n CALL_SYMBC(CCTK_INT8);\n break;\n#endif\n\n#ifdef HAVE_CCTK_INT16\n case CCTK_VARIABLE_INT16:\n CALL_SYMBC(CCTK_INT16);\n break;\n#endif\n\n#ifdef HAVE_CCTK_REAL4\n case CCTK_VARIABLE_REAL4:\n CALL_SYMBC(CCTK_REAL4);\n break;\n\n case CCTK_VARIABLE_COMPLEX8:\n CALL_SYMBC(CCTK_COMPLEX8);\n break;\n#endif\n\n#ifdef HAVE_CCTK_REAL8\n case CCTK_VARIABLE_REAL8:\n CALL_SYMBC(CCTK_REAL8);\n break;\n\n case CCTK_VARIABLE_COMPLEX16:\n CALL_SYMBC(CCTK_COMPLEX16);\n break;\n#endif\n\n#ifdef HAVE_CCTK_REAL16\n case CCTK_VARIABLE_REAL16:\n CALL_SYMBC(CCTK_REAL16);\n break;\n\n case CCTK_VARIABLE_COMPLEX32:\n CALL_SYMBC(CCTK_COMPLEX32);\n break;\n#endif\n\n default:\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Unsupported variable type %d for variable '%s'\",\n CCTK_VarTypeI(vindex), CCTK_VarName(vindex));\n retval = -2;\n }\n }\n\n return (retval);\n}\n\n/*@@\n @routine CartGrid3D_ApplyBC\n @date Sat Feb 07\n @author Erik Schnetter\n @desc Apply the symmetry boundary conditions\n @enddesc\n@@*/\n\nvoid CartGrid3D_ApplyBC(CCTK_ARGUMENTS) {\n DECLARE_CCTK_ARGUMENTS;\n DECLARE_CCTK_PARAMETERS;\n\n int nvars;\n CCTK_INT *restrict indices;\n CCTK_INT *restrict faces;\n CCTK_INT *restrict widths;\n CCTK_INT *restrict tables;\n int i;\n\n nvars = Boundary_SelectedGVs(cctkGH, 0, 0, 0, 0, 0, 0);\n if (nvars < 0)\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error returned from function Boundary_selectedGVs\");\n\n indices = malloc(nvars * sizeof *indices);\n if (!(nvars == 0 || indices))\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error in function CartGrid3D_ApplyBC\");\n faces = malloc(nvars * sizeof *faces);\n if (!(nvars == 0 || faces))\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error in function CartGrid3D_ApplyBC\");\n widths = malloc(nvars * sizeof *widths);\n if (!(nvars == 0 || widths))\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error in function CartGrid3D_ApplyBC\");\n tables = malloc(nvars * sizeof *tables);\n if (!(nvars == 0 || tables))\n CCTK_VWarn(0, __LINE__, __FILE__, \"CartGrid3D\",\n \"error in function CartGrid3D_ApplyBC\");\n\n int ierr = Boundary_SelectedGVs(cctkGH, nvars, indices, faces, widths, tables, 0);\n if (!(ierr == nvars))\n CCTK_VERROR(\"Error in function CartGrid3D_ApplyBC, Boudary_Selection returned %d instead of %d\",\n ierr, nvars);\n\n for (i = 0; i < nvars; ++i) {\n int vi = indices[i];\n if (!(vi >= 0 && vi < CCTK_NumVars()))\n CCTK_VERROR(\"Error in function CartGrid3D_ApplyBC. variable_index=%d\",vi);\n\n int gi = CCTK_GroupIndexFromVarI(vi);\n if ((gi < 0))\n CCTK_VERROR(\"Error in function CartGrid3D_ApplyBC. group_index=%d\", gi);\n\n ierr = ApplySymmetry(cctkGH, gi, vi, 1);\n if (ierr)\n CCTK_VERROR(\"Error in function CartGrid3D_ApplyBC. ApplySymmetry returned %d\",ierr);\n }\n\n free(indices);\n free(faces);\n free(widths);\n free(tables);\n}\n", |
| "ParamCheck.c": "/*@@\n @file ParamCheck.c\n @date Thu Oct 7 17:11:44 1999\n @author Tom Goodale\n @desc\n C version of Gab's paramcheck stuff\n @enddesc\n@@*/\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n\nstatic const char *rcsid = \"$Header$\";\n\nCCTK_FILEVERSION(CactusBase_CartGrid3D_ParamCheck_c)\n\nvoid ParamCheck_CartGrid3D(CCTK_ARGUMENTS);\n\n/*@@\n @routine ParamCheckCartGrid3D\n @date Tue Feb 23 1999\n @author Gabrielle Allen\n @desc\n Check parameters for CartGrid3D\n @enddesc\n @calls\n @calledby\n @history\n @hdate Thu Oct 7 17:23:15 1999 @hauthor Tom Goodale\n @hdesc Converted to C\n @endhistory\n\n@@*/\nvoid ParamCheck_CartGrid3D(CCTK_ARGUMENTS) {\n DECLARE_CCTK_ARGUMENTS_ParamCheck_CartGrid3D;\n DECLARE_CCTK_PARAMETERS\n\n int iflag;\n\n iflag = 0;\n\n if (CCTK_Equals(type, \"byrange\")) {\n if (CCTK_Equals(domain, \"octant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant_reflect_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"bitant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"bitant_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"full\")) {\n iflag++;\n }\n\n } else if (CCTK_Equals(type, \"byspacing\")) {\n if (CCTK_Equals(domain, \"bitant\")) {\n iflag++;\n }\n if (CCTK_Equals(domain, \"bitant_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant_reflect_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"octant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"full\")) {\n iflag++;\n }\n\n } else if (CCTK_Equals(type, \"coordbase\") ||\n CCTK_Equals(type, \"multipatch\")) {\n if (CCTK_IsFunctionAliased(\"GetDomainSpecification\")) {\n if (CCTK_Equals(domain, \"bitant\")) {\n iflag++;\n }\n if (CCTK_Equals(domain, \"bitant_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"quadrant_reflect_rotate\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"octant\")) {\n iflag++;\n } else if (CCTK_Equals(domain, \"full\")) {\n iflag++;\n }\n }\n } else if (CCTK_Equals(type, \"box\")) {\n iflag++;\n\n if (!CCTK_Equals(domain, \"full\"))\n CCTK_PARAMWARN(\"No symmetries can be used with box grid\");\n }\n\n /* No grid was set up */\n\n if (iflag != 1) {\n CCTK_PARAMWARN(\"No grid set up in CartGrid3D\");\n }\n\n if (CCTK_Equals(domain, \"bitant_rotate\")) {\n if (CCTK_nProcs(cctkGH) != 1)\n CCTK_PARAMWARN(\"domain 'bitant_rotate' only works on a single processor\");\n\n if (CCTK_Equals(bitant_plane, \"xy\") && CCTK_Equals(rotation_axis, \"z\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"z\\\" is incompatible with bitant_plane=\\\"xy\\\"\");\n\n if (CCTK_Equals(bitant_plane, \"xz\") && CCTK_Equals(rotation_axis, \"y\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"y\\\" is incompatible with bitant_plane=\\\"xz\\\"\");\n\n if (CCTK_Equals(bitant_plane, \"yz\") && CCTK_Equals(rotation_axis, \"x\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"x\\\" is incompatible with bitant_plane=\\\"yz\\\"\");\n }\n\n if (CCTK_Equals(domain, \"quadrant_reflect_rotate\")) {\n if (CCTK_nProcs(cctkGH) != 1)\n CCTK_PARAMWARN(\n \"domain 'quadrant_reflect_rotate' only works on a single processor\");\n\n if (CCTK_Equals(quadrant_direction, \"x\") && CCTK_Equals(rotation_axis, \"x\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"x\\\" is incompatible with quadrant_direction=\\\"x\\\"\");\n\n if (CCTK_Equals(quadrant_direction, \"y\") && CCTK_Equals(rotation_axis, \"y\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"y\\\" is incompatible with quadrant_direction=\\\"y\\\"\");\n\n if (CCTK_Equals(quadrant_direction, \"z\") && CCTK_Equals(rotation_axis, \"z\"))\n CCTK_PARAMWARN(\n \"rotation_axis=\\\"z\\\" is incompatible with quadrant_direction=\\\"z\\\"\");\n }\n\n return;\n}\n", |
| "CartGrid3D.c": "/*@@\n @file CartGrid3D.c\n @date Thu Oct 7 13:20:06 1999\n @author Tom Goodale\n @desc\n Set up coordinates for a 3D Cartesian grid.\n C Conversion of Fortran routine written by Gab.\n @version $Id$\n @enddesc\n@@*/\n\n#include <stdio.h>\n#include <math.h>\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n#include \"util_Table.h\"\n\n#include \"Symmetry.h\"\n#include \"CoordBase.h\"\n\nstatic const char *rcsid = \"$Header$\";\n\nCCTK_FILEVERSION(CactusBase_CartGrid3D_CartGrid3D_c);\n\n/********************************************************************\n ********************* Macro Definitions **************************\n ********************************************************************/\n#define max(a, b) ((a) > (b) ? (a) : (b))\n#define SQR(a) ((a) * (a))\n\n/********************************************************************\n ********************* Scheduled Routine Prototypes ***************\n ********************************************************************/\nvoid CartGrid3D_SetRanges(CCTK_ARGUMENTS);\nvoid CartGrid3D_SetCoordinates(CCTK_ARGUMENTS);\n\n/********************************************************************\n ********************* External Routine Prototypes ****************\n ********************************************************************/\nvoid DecodeSymParameters3D(int sym[6]);\n\n/********************************************************************\n ********************* Local Routine Prototypes *******************\n ********************************************************************/\n\n/********************************************************************\n ********************* Scheduled Routines *************************\n ********************************************************************/\n/*@@\n @routine CartGrid3D_SetRanges\n @date Oct 1999?\n @author Tom Goodale? Gabrielle Allen? Thomas Radke\n @date Mon 3 Jan 2005\n @author Thomas Radke\n @desc\n Sets up ranges for Cartesian coordinates.\n @enddesc\n @calls DecodeSymParameters3D, CCTK_Equals, CCTK_WARN,\n CCTK_CoordRegisterRange, CCTK_CoordRegisterRangePhysIndex,\n CCTK_INFO, Coord_CoordHandle, Util_TableSetReal,\n Util_TableSetString, Util_TableSetInt\n\n @var CCTK_ARGUMENTS\n @vdesc Cactus argument list\n @vtype\n @vio in/out\n @endvar\n@@*/\nvoid CartGrid3D_SetRanges(CCTK_ARGUMENTS) {\n int i;\n int coord_handle, ierr;\n CCTK_REAL this_delta[3], origin[3], min1[3], max1[3];\n CCTK_REAL *coarse_delta[3];\n double lower[3], upper[3];\n int domainsym[6], cntstag[3], loweri[3], upperi[3], do_periodic[3];\n char coord_name[16];\n DECLARE_CCTK_ARGUMENTS_CartGrid3D_SetRanges;\n DECLARE_CCTK_PARAMETERS;\n\n if (CCTK_EQUALS(set_coordinate_ranges_on, \"first level\")) {\n /* Ranges must be set up only once, and this must happen on the\n coarse grid. However, the coarse grid itself may not actually\n exist; in this case, use the coarsest existing grid. We assume\n that this is the first grid for which this routine is\n called. */\n static int is_coarsest_refinement_level = 1;\n if (!is_coarsest_refinement_level) {\n return;\n }\n is_coarsest_refinement_level = 0;\n } else {\n /* Ranges need to be set up only once (or once per map), on the\n coarsest refinement level */\n int const is_coarsest_refinement_level =\n cctk_levfac[0] == 1 && cctk_levfac[1] == 1 && cctk_levfac[2] == 1;\n if (!is_coarsest_refinement_level) {\n return;\n }\n }\n\n coarse_delta[0] = coarse_dx;\n coarse_delta[1] = coarse_dy;\n coarse_delta[2] = coarse_dz;\n\n /* Calculate the coordinate ranges only for the coarsest level */\n /* Avoid origin? Default is yes */\n cntstag[0] = no_origin && no_originx && avoid_origin && avoid_originx;\n cntstag[1] = no_origin && no_originy && avoid_origin && avoid_originy;\n cntstag[2] = no_origin && no_originz && avoid_origin && avoid_originz;\n\n /* Determine symmetries of domain */\n DecodeSymParameters3D(domainsym);\n\n do_periodic[0] = periodic && periodic_x;\n do_periodic[1] = periodic && periodic_y;\n do_periodic[2] = periodic && periodic_z;\n\n /* Calculate physical indices, using symmetries and periodicity */\n for (i = 0; i < 3; i++) {\n loweri[i] = 0;\n upperi[i] = cctk_gsh[i] - 1;\n\n if (domainsym[2 * i + 0] || do_periodic[i]) {\n loweri[i] += cctk_nghostzones[i];\n }\n if (domainsym[2 * i + 1] || do_periodic[i]) {\n upperi[i] -= cctk_nghostzones[i];\n }\n }\n\n /****************************************************************\n *\n * BYRANGE\n *\n * User gives: minimum and maximum values of coordinates and\n * the number of gridpoints on the coarse grid\n *\n ***************************************************************/\n /**************************************************************\n *\n * BOX (-0.5 to 0.5)\n *\n * User gives: number of gridpoints on the coarse grid\n *\n **************************************************************/\n\n if (CCTK_Equals(type, \"byrange\") || CCTK_Equals(type, \"box\")) {\n if (CCTK_Equals(type, \"box\")) {\n /* Coordinates are all -0.5 to 0.5 */\n min1[0] = min1[1] = min1[2] = -0.5;\n max1[0] = max1[1] = max1[2] = 0.5;\n } else {\n if (xyzmin != -424242) {\n min1[0] = min1[1] = min1[2] = xyzmin;\n } else {\n min1[0] = xmin;\n min1[1] = ymin;\n min1[2] = zmin;\n }\n\n if (xyzmax != -424242) {\n max1[0] = max1[1] = max1[2] = xyzmax;\n } else {\n max1[0] = xmax;\n max1[1] = ymax;\n max1[2] = zmax;\n }\n }\n\n /* Grid spacing on coarsest grid */\n for (i = 0; i < 3; i++) {\n if (domainsym[2 * i + 0]) {\n if (cntstag[i]) {\n *coarse_delta[i] =\n max1[i] / (cctk_gsh[i] - cctk_nghostzones[i] - 0.5);\n origin[i] = -(cctk_nghostzones[i] - 0.5) * *coarse_delta[i];\n } else {\n *coarse_delta[i] = max1[i] / (cctk_gsh[i] - cctk_nghostzones[i] - 1);\n origin[i] = -cctk_nghostzones[i] * *coarse_delta[i];\n }\n } else if (domainsym[2 * i + 1]) {\n if (cntstag[i]) {\n *coarse_delta[i] =\n fabs(min1[i]) / (cctk_gsh[i] - cctk_nghostzones[i] - 0.5);\n } else {\n *coarse_delta[i] =\n fabs(min1[i]) / (cctk_gsh[i] - cctk_nghostzones[i] - 1);\n }\n origin[i] = min1[i];\n } else {\n if (cntstag[i]) {\n CCTK_VWarn(4, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Ignoring request to avoid origin in %c-direction, \"\n \"it is not relevant for this grid type\",\n 'x' + i);\n }\n *coarse_delta[i] = (max1[i] - min1[i]) / max(cctk_gsh[i] - 1, 1);\n origin[i] = min1[i];\n }\n\n this_delta[i] = *coarse_delta[i];\n }\n }\n\n /**************************************************************\n * BYSPACING\n *\n * User gives: grid spacing on the coarsest GH and\n * the number of gridpoints on the coarsest GH\n *\n **************************************************************/\n else if (CCTK_Equals(type, \"byspacing\")) {\n /* Dx, Dy, Dx on the coarsest grid */\n if (dxyz > 0) {\n *coarse_delta[0] = *coarse_delta[1] = *coarse_delta[2] = dxyz;\n } else {\n *coarse_delta[0] = dx;\n *coarse_delta[1] = dy;\n *coarse_delta[2] = dz;\n }\n\n for (i = 0; i < 3; i++) {\n this_delta[i] = *coarse_delta[i];\n\n /* Set minimum values of coordinates */\n if (domainsym[2 * i + 0]) {\n origin[i] = -(cctk_nghostzones[i] - cntstag[i] * 0.5);\n } else if (domainsym[2 * i + 1]) {\n origin[i] = -(cctk_gsh[i] - 1 - cctk_nghostzones[i] + cntstag[i] * 0.5);\n } else {\n origin[i] = -0.5 * (cctk_gsh[i] - 1 - cntstag[i] * cctk_gsh[i] % 2);\n }\n origin[i] *= this_delta[i];\n }\n }\n\n /**************************************************************\n * COORDBASE\n *\n * CoordBase gives: grid spacing on the coarsest GH and\n * minimum and maximum values of coordinates and\n * the number of gridpoints on the coarsest GH\n *\n **************************************************************/\n else if (CCTK_Equals(type, \"coordbase\")) {\n CCTK_REAL physical_min[3];\n CCTK_REAL physical_max[3];\n CCTK_REAL interior_min[3];\n CCTK_REAL interior_max[3];\n CCTK_REAL exterior_min[3];\n CCTK_REAL exterior_max[3];\n CCTK_REAL spacing[3];\n int d;\n\n ierr = GetDomainSpecification(3, physical_min, physical_max, interior_min,\n interior_max, exterior_min, exterior_max,\n spacing);\n if (ierr)\n CCTK_WARN(0, \"error returned from function GetDomainSpecification\");\n\n /* Adapt to convergence level */\n for (d = 0; d < 3; ++d) {\n spacing[d] *= pow(cctkGH->cctk_convfac, cctkGH->cctk_convlevel);\n }\n\n ierr = ConvertFromPhysicalBoundary(3, physical_min, physical_max,\n interior_min, interior_max, exterior_min,\n exterior_max, spacing);\n if (ierr)\n CCTK_WARN(0, \"error returned from function ConvertFromPhysicalBoundary\");\n\n for (d = 0; d < 3; ++d) {\n origin[d] = exterior_min[d];\n this_delta[d] = spacing[d];\n *coarse_delta[d] = this_delta[d];\n }\n }\n /**************************************************************\n * MULTIPATCH\n *\n * MultiPatch gives: grid spacing on the coarsest GH and\n * minimum and maximum values of coordinates and\n * the number of gridpoints on the coarsest GH\n *\n **************************************************************/\n else if (CCTK_Equals(type, \"multipatch\")) {\n CCTK_REAL physical_min[3];\n CCTK_REAL physical_max[3];\n CCTK_REAL interior_min[3];\n CCTK_REAL interior_max[3];\n CCTK_REAL exterior_min[3];\n CCTK_REAL exterior_max[3];\n CCTK_REAL spacing[3];\n CCTK_INT map;\n int d;\n\n map = MultiPatch_GetMap(cctkGH);\n if (map < 0)\n CCTK_WARN(0, \"error returned from function MultiPatch_GetMap\");\n\n ierr = MultiPatch_GetDomainSpecification(\n map, 3, physical_min, physical_max, interior_min, interior_max,\n exterior_min, exterior_max, spacing);\n if (ierr)\n CCTK_WARN(\n 0, \"error returned from function MultiPatch_GetDomainSpecification\");\n\n /* Adapt to convergence level */\n for (d = 0; d < 3; ++d) {\n spacing[d] *= pow(cctkGH->cctk_convfac, cctkGH->cctk_convlevel);\n }\n\n if (CCTK_IsFunctionAliased(\"MultiPatch_ConvertFromPhysicalBoundary\")) {\n ierr = MultiPatch_ConvertFromPhysicalBoundary(\n map, 3, physical_min, physical_max, interior_min, interior_max,\n exterior_min, exterior_max, spacing);\n if (ierr)\n CCTK_WARN(0, \"error returned from function \"\n \"MultiPatch_ConvertFromPhysicalBoundary\");\n } else {\n ierr = ConvertFromPhysicalBoundary(3, physical_min, physical_max,\n interior_min, interior_max,\n exterior_min, exterior_max, spacing);\n if (ierr)\n CCTK_WARN(0,\n \"error returned from function ConvertFromPhysicalBoundary\");\n }\n\n for (d = 0; d < 3; ++d) {\n origin[d] = exterior_min[d];\n this_delta[d] = spacing[d];\n *coarse_delta[d] = this_delta[d];\n }\n }\n\n else {\n if (0)\n CCTK_WARN(0, \"type is out of bounds\");\n }\n\n /* Register the coordinate ranges */\n for (i = 0; i < 3; i++) {\n cctkGH->cctk_delta_space[i] = this_delta[i];\n cctkGH->cctk_origin_space[i] = origin[i];\n\n lower[i] = origin[i];\n upper[i] = origin[i] + this_delta[i] * (cctk_gsh[i] - 1);\n if (CCTK_CoordRegisterRange(cctkGH, lower[i], upper[i], i + 1, NULL,\n \"cart3d\") < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Failed to register %c-coordinate computational range\",\n 'x' + i);\n }\n if (CCTK_CoordRegisterRangePhysIndex(cctkGH, loweri[i], upperi[i], i + 1,\n NULL, \"cart3d\") < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Failed to register %c-coordinate physical range\", 'x' + i);\n }\n }\n\n CCTK_INFO(\"Grid Spacings:\");\n CCTK_VInfo(CCTK_THORNSTRING, \"dx=>%12.7e dy=>%12.7e dz=>%12.7e\",\n (double)cctk_delta_space[0], (double)cctk_delta_space[1],\n (double)cctk_delta_space[2]);\n CCTK_INFO(\"Computational Coordinates:\");\n CCTK_VInfo(CCTK_THORNSTRING,\n \"x=>[%6.3f,%6.3f] y=>[%6.3f,%6.3f] z=>[%6.3f,%6.3f]\", lower[0],\n upper[0], lower[1], upper[1], lower[2], upper[2]);\n CCTK_INFO(\"Indices of Physical Coordinates:\");\n CCTK_VInfo(CCTK_THORNSTRING, \"x=>[%d,%d] y=>[%d,%d] z=>[%d,%d]\", loweri[0],\n upperi[0], loweri[1], upperi[1], loweri[2], upperi[2]);\n\n if ((domainsym[0] == GFSYM_ROTATION_Y || domainsym[2] == GFSYM_ROTATION_X) &&\n (lower[2] + upper[2] > 1e-12)) {\n CCTK_WARN(0, \"minimum z must equal maximum z for rotation symmetry\");\n }\n\n if ((domainsym[0] == GFSYM_ROTATION_Z || domainsym[4] == GFSYM_ROTATION_X) &&\n (lower[1] + upper[1] > 1e-12)) {\n CCTK_WARN(0, \"minimum y must equal maximum y for rotation symmetry\");\n }\n\n if ((domainsym[2] == GFSYM_ROTATION_Z || domainsym[4] == GFSYM_ROTATION_Y) &&\n (lower[0] - upper[0] > 1e-12)) {\n CCTK_WARN(0, \"minimum x must equal maximum x for rotation symmetry\");\n }\n\n /* cart3d */\n for (i = 0; i < 3; i++) {\n sprintf(coord_name, \"%c\", 'x' + i);\n\n coord_handle = Coord_CoordHandle(cctkGH, coord_name, \"cart3d\");\n if (coord_handle < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Error retreiving coordinate handle for '%s' of cart3d\",\n coord_name);\n }\n sprintf(coord_name, \"grid::%c\", 'x' + i);\n ierr = Util_TableSetInt(coord_handle, loweri[i], \"PHYSICALMIN\");\n ierr += Util_TableSetReal(coord_handle, lower[i], \"COMPMIN\");\n ierr += Util_TableSetInt(coord_handle, upperi[i], \"PHYSICALMAX\");\n ierr += Util_TableSetReal(coord_handle, upper[i], \"COMPMAX\");\n ierr += Util_TableSetString(coord_handle, \"uniform\", \"TYPE\");\n ierr += Util_TableSetString(coord_handle, \"no\", \"TIMEDEPENDENT\");\n ierr += Util_TableSetString(coord_handle, \"CCTK_REAL\", \"DATATYPE\");\n ierr +=\n Util_TableSetInt(coord_handle, CCTK_VarIndex(coord_name), \"GAINDEX\");\n ierr += Util_TableSetReal(coord_handle, cctk_delta_space[i], \"DELTA\");\n }\n\n /* cart2d */\n for (i = 0; i < 2; i++) {\n sprintf(coord_name, \"%c\", 'x' + i);\n coord_handle = Coord_CoordHandle(cctkGH, coord_name, \"cart2d\");\n if (coord_handle < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Error retreiving coordinate handle for '%s' of cart2d\",\n coord_name);\n }\n sprintf(coord_name, \"grid::%c\", 'x' + i);\n ierr = Util_TableSetReal(coord_handle, lower[i], \"PHYSICALMIN\"); /*??*/\n ierr += Util_TableSetReal(coord_handle, lower[i], \"COMPMIN\");\n ierr += Util_TableSetReal(coord_handle, upper[i], \"PHYSICALMAX\"); /*??*/\n ierr += Util_TableSetReal(coord_handle, upper[i], \"COMPMAX\");\n ierr += Util_TableSetString(coord_handle, \"uniform\", \"TYPE\");\n ierr += Util_TableSetString(coord_handle, \"no\", \"TIMEDEPENDENT\");\n ierr += Util_TableSetString(coord_handle, \"CCTK_REAL\", \"DATATYPE\");\n ierr +=\n Util_TableSetInt(coord_handle, CCTK_VarIndex(coord_name), \"GAINDEX\");\n ierr += Util_TableSetReal(coord_handle, cctk_delta_space[i], \"DELTA\");\n }\n\n /* cart1d */\n coord_handle = Coord_CoordHandle(cctkGH, \"x\", \"cart1d\");\n if (coord_handle < 0) {\n CCTK_WARN(0, \"Error retreiving coordinate handle for x of cart1d\");\n }\n ierr = Util_TableSetReal(coord_handle, lower[0], \"PHYSICALMIN\"); /*??*/\n ierr += Util_TableSetReal(coord_handle, lower[0], \"COMPMIN\");\n ierr += Util_TableSetReal(coord_handle, upper[0], \"PHYSICALMAX\"); /*??*/\n ierr += Util_TableSetReal(coord_handle, upper[0], \"COMPMAX\");\n ierr += Util_TableSetString(coord_handle, \"uniform\", \"TYPE\");\n ierr += Util_TableSetString(coord_handle, \"no\", \"TIMEDEPENDENT\");\n ierr += Util_TableSetString(coord_handle, \"CCTK_REAL\", \"DATATYPE\");\n ierr += Util_TableSetInt(coord_handle, CCTK_VarIndex(\"grid::x\"), \"GAINDEX\");\n ierr += Util_TableSetReal(coord_handle, cctk_delta_space[0], \"DELTA\");\n\n /* Set up coordinate tables */\n /* Should this be done in a function?\n WriteCoordinateTable(cctkGH, \"cart3d\"); */\n}\n\n/*@@\n @routine CartGrid3D_SetCoordinates\n @date 2004-06-17\n @author Christian Ott\n @desc\n Sets up Cartesian coordinates.\n @enddesc\n @var CCTK_ARGUMENTS\n @vdesc Cactus argument list\n @vtype\n @vio in/out\n @endvar\n@@*/\nvoid CartGrid3D_SetCoordinates(CCTK_ARGUMENTS) {\n DECLARE_CCTK_ARGUMENTS_CartGrid3D_SetCoordinates;\n\n /* CCTK_VInfo(CCTK_THORNSTRING,\"Resetting coordinates after regridding.\"); */\n\n for (int k = 0; k < cctk_lsh[2]; k++) {\n for (int j = 0; j < cctk_lsh[1]; j++) {\n for (int i = 0; i < cctk_lsh[0]; i++) {\n int idx = CCTK_GFINDEX3D(cctkGH, i, j, k);\n x[idx] =\n CCTK_DELTA_SPACE(0) * (i + cctk_lbnd[0]) + CCTK_ORIGIN_SPACE(0);\n y[idx] =\n CCTK_DELTA_SPACE(1) * (j + cctk_lbnd[1]) + CCTK_ORIGIN_SPACE(1);\n z[idx] =\n CCTK_DELTA_SPACE(2) * (k + cctk_lbnd[2]) + CCTK_ORIGIN_SPACE(2);\n r[idx] = sqrt(SQR(x[idx]) + SQR(y[idx]) + SQR(z[idx]));\n }\n }\n }\n}\n", |
| "GetSymmetry.c": "/*@@\n @file GetSymmetry.c\n @date April 12 2002\n @author Frank Herrmann\n @desc\n This file contains the routines for getting symmetry information\n code stolen from SetSymmetry.c\n @enddesc\n @version $Id$\n@@*/\n\n#include <stdlib.h>\n\n#include \"cctk.h\"\n#include \"cctk_Parameters.h\"\n#include \"cctk_FortranString.h\"\n#include \"Symmetry.h\"\n\nstatic const char *rcsid = \"$Header$\";\n\nCCTK_FILEVERSION(CactusBase_CartGrid3D_GetSymmetry_c)\n\n/********************************************************************\n ********************* Local Defines ***********************\n ********************************************************************/\n#define MAX_DIM 3\n#define MAX_FACE 6\n\n/********************************************************************\n ********************* Local Routine Prototypes *********************\n ********************************************************************/\nvoid DecodeSymParameters3D(int sym[6]);\n\nvoid CCTK_FCALL CCTK_FNAME(GetCartSymVI)(int *ierr, const cGH **GH, int *sym,\n const int *vi);\nvoid CCTK_FCALL CCTK_FNAME(GetCartSymVN)(int *ierr, const cGH **GH, int *sym,\n ONE_FORTSTRING_ARG);\n\n/********************************************************************\n ********************* External Routines **********************\n ********************************************************************/\n\n/*@@\n @routine GetCartSymVI\n @date Mon Mar 15 15:10:58 1999\n @author Frank Herrmann\n @desc\n This routine returns symmetry for variable index.\n @enddesc\n@@*/\nint GetCartSymVI(const cGH *GH, int *sym, int vi) {\n int domainsym[MAX_FACE];\n SymmetryGHex *sGHex;\n int dir;\n DECLARE_CCTK_PARAMETERS\n\n if (vi < 0 || vi >= CCTK_NumVars()) {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid variable index %d in GetCartSymVI\", vi);\n return (-1);\n }\n\n /* Pointer to the SymmetryGHextension */\n sGHex = (SymmetryGHex *)CCTK_GHExtension(GH, \"Symmetry\");\n\n/* Reference the hash table in the GHex and get the kind of\n * symmetry being applied\n */\n\n#ifdef SYM_DEBUG\n printf(\"GetSymmetry: %s [%d,%d,%d]\\n\", CCTK_VarName(vi), sym[0], sym[1],\n sym[2]);\n#endif\n\n DecodeSymParameters3D(domainsym);\n\n for (dir = 0; dir < MAX_FACE; ++dir) {\n sym[dir / 2] = GFSYM_UNKNOWN;\n if (domainsym[dir])\n sym[dir / 2] = sGHex->GFSym[vi][dir];\n }\n\n return 0;\n}\n\nvoid CCTK_FCALL CCTK_FNAME(GetCartSymVI)(int *ierr, const cGH **GH, int *sym,\n const int *vi) {\n *ierr = GetCartSymVI(*GH, sym, *vi);\n}\n\n/*@@\n @routine GetCartSymVN\n @date April 12 2002\n @author Frank Herrmann\n @desc\n Gets symmetry boundary conditions from variable name\n @enddesc\n@@*/\nint GetCartSymVN(const cGH *GH, int *sym, const char *vn) {\n int vi;\n vi = CCTK_VarIndex(vn);\n\n if (vi > -1) {\n return (GetCartSymVI(GH, sym, vi));\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Cannot find variable %s in GetCartSymVN\", vn);\n return (-1);\n }\n}\n\nvoid CCTK_FCALL CCTK_FNAME(GetCartSymVN)(int *ierr, const cGH **GH, int *sym,\n ONE_FORTSTRING_ARG) {\n ONE_FORTSTRING_CREATE(vn)\n *ierr = GetCartSymVN(*GH, sym, vn);\n free(vn);\n}\n", |
| "SetSymmetry.c": "\n/*@@\n @file Symmetry.c\n @date Mon Mar 15 15:09:00 1999\n @author Gerd Lanfermann\n @desc\n This file contains the routines for registering and applying symmetry\n boundary conditions\n @enddesc\n @@*/\n\n#include <stdlib.h>\n\n#include \"cctk.h\"\n#include \"cctk_Parameters.h\"\n#include \"cctk_FortranString.h\"\n#include \"Symmetry.h\"\n\nstatic const char *rcsid = \"$Header$\";\n\nCCTK_FILEVERSION(CactusBase_CartGrid3D_SetSymmetry_c)\n\n/********************************************************************\n ********************* External Routines **********************\n ********************************************************************/\nvoid DecodeSymParameters3D(int sym[6]);\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymVI)(int *ierr, const cGH **GH,\n const int *sym, const int *vi);\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymVN)(int *ierr, const cGH **GH,\n const int *sym, ONE_FORTSTRING_ARG);\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymGI)(int *ierr, const cGH **GH,\n const int *sym, const int *gi);\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymGN)(int *ierr, const cGH **GH,\n const int *sym, ONE_FORTSTRING_ARG);\n\n/*@@\n @routine SetCartSymmetry\n @date Mon Mar 15 15:10:58 1999\n @author Gerd Lanfermann\n @desc\n This routine sets the GH extension (EinsteinBoundGHex *bGHex),\n which describes the symmetry boundary type of each GF. Takes\n the name of the GF (\"implementation::gfname\") and the\n symmetry operators sx,sy,sz and inserts them in the array bGHex.\n These values will looked up by the application routines\n SymmetryWrappers\n @enddesc\n @history\n enhanced by E.Schnetter\n @endhistory\n@@*/\nint SetCartSymVI(const cGH *GH, const int *sym, int vi) {\n int domainsym[MAX_FACE];\n SymmetryGHex *sGHex;\n int dir;\n DECLARE_CCTK_PARAMETERS\n\n if (vi < 0 || vi >= CCTK_NumVars()) {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Invalid variable index %d in SetCartSymVI\", vi);\n return (-1);\n }\n\n /* Pointer to the SymmetryGHextension */\n sGHex = (SymmetryGHex *)CCTK_GHExtension(GH, \"Symmetry\");\n\n/* Reference the hash table in the GHex and tell it what kind of\n symmetry is being applied\n (depending on sym and the grid layout)\n If there is no symmetry necessary,set ESYM_NOSYM\n When we apply a symmetry and find ESYM_UNSET, something went wrong!\n */\n\n#ifdef SYM_DEBUG\n printf(\"SetSymmetry: %s [%d,%d,%d]\\n\", CCTK_VarName(vi), sym[0], sym[1],\n sym[2]);\n#endif\n\n DecodeSymParameters3D(domainsym);\n for (dir = 0; dir < MAX_FACE; ++dir) {\n if (domainsym[dir] == GFSYM_REFLECTION) {\n sGHex->GFSym[vi][dir] = sym[dir / 2];\n } else if (domainsym[dir] == GFSYM_ROTATION_X) {\n sGHex->GFSym[vi][dir] = sym[1] * sym[2];\n } else if (domainsym[dir] == GFSYM_ROTATION_Y) {\n sGHex->GFSym[vi][dir] = sym[0] * sym[2];\n } else if (domainsym[dir] == GFSYM_ROTATION_Z) {\n sGHex->GFSym[vi][dir] = sym[0] * sym[1];\n } else {\n sGHex->GFSym[vi][dir] = GFSYM_NOSYM;\n }\n }\n\n#ifdef SYM_DEBUG\n printf(\"SetSymmetry: %s [%d,%d,%d]\\n\\n\", CCTK_VarName(vi),\n sGHex->GFSym[vi][0], sGHex->GFSym[vi][2], sGHex->GFSym[vi][4]);\n#endif\n\n return (0);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymVI)(int *ierr, const cGH **GH,\n const int *sym, const int *vi) {\n *ierr = SetCartSymVI(*GH, sym, *vi);\n}\n\n/*@@\n @routine SetCartSymVN\n @date Thu May 11 13:32:55 2000\n @author Gerd Lanfermann\n @desc\n Applies symmetry boundary conditions from\n variable index\n @enddesc\n@@*/\nint SetCartSymVN(const cGH *GH, const int *sym, const char *vn) {\n int vi, retval;\n\n vi = CCTK_VarIndex(vn);\n if (vi >= 0) {\n retval = SetCartSymVI(GH, sym, vi);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Unknown variable '%s' in SetCartSymVN\", vn);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymVN)(int *ierr, const cGH **GH,\n const int *sym, ONE_FORTSTRING_ARG) {\n ONE_FORTSTRING_CREATE(vn)\n *ierr = SetCartSymVN(*GH, sym, vn);\n free(vn);\n}\n\n/*@@\n @routine SetCartSymGI\n @date\n @author Gerd Lanfermann\n @desc\n Applies symmetry boundary conditions from\n Group index\n @enddesc\n@@*/\nint SetCartSymGI(const cGH *GH, const int *sym, int gi) {\n int domainsym[MAX_FACE];\n SymmetryGHex *sGHex;\n int first_vari, numvars, vi;\n int dir;\n DECLARE_CCTK_PARAMETERS\n\n sGHex = (SymmetryGHex *)CCTK_GHExtension(GH, \"Symmetry\");\n\n first_vari = CCTK_FirstVarIndexI(gi);\n numvars = CCTK_NumVarsInGroupI(gi);\n\n if (first_vari < 0) {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Cannot find group %s (grp.index: %d) in SetCartSymGI\",\n CCTK_GroupName(gi), first_vari);\n return (-1);\n }\n\n /* Reference the hash table in the GHex and tell it what kind of\n symmetry is being applied\n (depending on sym and the grid layout)\n If there is no symmetry necessary,set ESYM_NOSYM\n When we apply a symmetry and find ESYM_UNSET, something went wrong!\n */\n for (vi = first_vari; vi < first_vari + numvars; vi++) {\n\n#ifdef SYM_DEBUG\n printf(\"SetSymmetry: %s [%d,%d,%d]\\n\", CCTK_VarName(vi), sym[0], sym[1],\n sym[2]);\n#endif\n\n DecodeSymParameters3D(domainsym);\n for (dir = 0; dir < MAX_FACE; dir++) {\n if (domainsym[dir] == GFSYM_REFLECTION) {\n sGHex->GFSym[vi][dir] = sym[dir / 2];\n } else if (domainsym[dir] == GFSYM_ROTATION_X) {\n sGHex->GFSym[vi][dir] = sym[1] * sym[2];\n } else if (domainsym[dir] == GFSYM_ROTATION_Y) {\n sGHex->GFSym[vi][dir] = sym[0] * sym[2];\n } else if (domainsym[dir] == GFSYM_ROTATION_Z) {\n sGHex->GFSym[vi][dir] = sym[0] * sym[1];\n } else {\n sGHex->GFSym[vi][dir] = GFSYM_NOSYM;\n }\n }\n\n#ifdef SYM_DEBUG\n printf(\"SetSymmetry: %s [%d,%d,%d]\\n\\n\", CCTK_VarName(vi),\n sGHex->GFSym[vi][0], sGHex->GFSym[vi][2], sGHex->GFSym[vi][4]);\n#endif\n }\n return (0);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymGI)(int *ierr, const cGH **GH,\n const int *sym, const int *gi) {\n *ierr = SetCartSymGI(*GH, sym, *gi);\n}\n\n/*@@\n @routine\n @date\n @author\n @desc\n Applies symmetry boundary conditions from\n \"Implementation::Groupname\"\n @enddesc\n@@*/\nint SetCartSymGN(const cGH *GH, const int *sym, const char *gn) {\n int gi, retval;\n\n gi = CCTK_GroupIndex(gn);\n if (gi >= 0) {\n retval = SetCartSymGI(GH, sym, gi);\n } else {\n CCTK_VWarn(1, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Unknown group '%s' in SetCartSymGN\", gn);\n retval = -1;\n }\n\n return (retval);\n}\n\nvoid CCTK_FCALL CCTK_FNAME(SetCartSymGN)(int *ierr, const cGH **GH,\n const int *sym, ONE_FORTSTRING_ARG) {\n ONE_FORTSTRING_CREATE(gn)\n *ierr = SetCartSymGN(*GH, sym, gn);\n free(gn);\n}\n", |
| "Startup.c": "/*@@\n @file Startup.c\n @date Mon Mar 15 15:48:42 1999\n @author Gerd Lanfermann\n @desc\n Startup file to register the GHextension and coordinates\n @enddesc\n @version $Id$\n@@*/\n\n#include <stdlib.h>\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n#include \"util_Table.h\"\n\n#include \"CoordBase.h\"\n#include \"Symmetry.h\"\n\n/* the rcs ID and its dummy function to use it */\nstatic const char *rcsid = \"$Header$\";\nCCTK_FILEVERSION(CactusBase_CartGrid3D_Startup_c);\n\n/********************************************************************\n ******************** External Prototypes **********************\n ********************************************************************/\nint SymmetryStartup(void);\nvoid RegisterCartGrid3DCoords(CCTK_ARGUMENTS);\n\n/********************************************************************\n ******************** Internal Prototypes **********************\n ********************************************************************/\nstatic void *SetupGH(tFleshConfig *config, int convlevel, cGH *GH);\n\n/********************************************************************\n ******************** External Routines ************************\n ********************************************************************/\n/*@@\n @routine SymmetryStartup\n @date Mon Mar 15 15:49:16 1999\n @author Gerd Lanfermann\n @desc\n Routine registers the GH extension for CartGrid3D\n along with its setup routine.\n @enddesc\n @calls CCTK_RegisterGHExtension\n CCTK_RegisterGHExtensionSetupGH\n @history\n @endhistory\n\n @returntype void\n@@*/\nint SymmetryStartup(void) {\n CCTK_RegisterGHExtensionSetupGH(CCTK_RegisterGHExtension(\"Symmetry\"),\n SetupGH);\n return 0;\n}\n\n/*@@\n @routine RegisterCartGrid3DCoords\n @date\n @author Gabrielle Allen\n @desc\n Routine registers the coordinates provided by\n CartGrid3D, using both the new and old APIs. The old\n CCTK_ API is deprecated.\n @enddesc\n @calls CCTK_CoordRegisterSystem\n CCTK_CoordRegisterData\n\n @returntype int\n @returndesc\n 0 for success, or negative in case of errors\n @endreturndesc\n@@*/\nvoid RegisterCartGrid3DCoords(CCTK_ARGUMENTS) {\n DECLARE_CCTK_ARGUMENTS_RegisterCartGrid3DCoords;\n DECLARE_CCTK_PARAMETERS;\n\n int ierr, coord_system_handle;\n\n /* Register coordinate systems */\n ierr = Coord_SystemRegister(cctkGH, 3, \"cart3d\");\n ierr += Coord_SystemRegister(cctkGH, 2, \"cart2d\");\n ierr += Coord_SystemRegister(cctkGH, 1, \"cart1d\");\n if (ierr < 0) {\n CCTK_WARN(0, \"Error registering cartnd coordinate systems\");\n } else {\n\n /* Register coordinates for cart3d */\n coord_system_handle = Coord_SystemHandle(cctkGH, \"cart3d\");\n if (coord_system_handle < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Error obtaining system handle for cart3d\");\n }\n ierr = Coord_CoordRegister(cctkGH, coord_system_handle, 1, \"x\");\n ierr += Coord_CoordRegister(cctkGH, coord_system_handle, 2, \"y\");\n ierr += Coord_CoordRegister(cctkGH, coord_system_handle, 3, \"z\");\n if (ierr < 0) {\n CCTK_WARN(0, \"Error registering cart3d coordinates\");\n }\n\n /* Fill out rest of coordinate system table for cart3d */\n ierr = Util_TableSetString(coord_system_handle, \"uniform\", \"TYPE\");\n if (ierr < 0) {\n CCTK_WARN(1, \"Error registering cart3d type\");\n }\n\n /* Register coordinates for cart2d */\n coord_system_handle = Coord_SystemHandle(cctkGH, \"cart2d\");\n if (coord_system_handle < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Error obtaining system handle for cart2d\");\n }\n ierr = Coord_CoordRegister(cctkGH, coord_system_handle, 1, \"x\");\n ierr += Coord_CoordRegister(cctkGH, coord_system_handle, 2, \"y\");\n if (ierr < 0) {\n CCTK_WARN(0, \"Error registering cart2d coordinates\");\n }\n\n /* Fill out rest of coordinate system table for cart2d */\n ierr = Util_TableSetString(coord_system_handle, \"uniform\", \"TYPE\");\n if (ierr < 0) {\n CCTK_WARN(1, \"Error registering cart2d type\");\n }\n\n /* Register coordinate for cart1d */\n coord_system_handle = Coord_SystemHandle(cctkGH, \"cart1d\");\n if (coord_system_handle < 0) {\n CCTK_VWarn(0, __LINE__, __FILE__, CCTK_THORNSTRING,\n \"Error obtaining system handle for cart1d\");\n }\n ierr = Coord_CoordRegister(cctkGH, coord_system_handle, 1, \"x\");\n if (ierr < 0) {\n CCTK_WARN(0, \"Error registering cart1d coordinate\");\n }\n\n /* Fill out rest of coordinate system table for cart1d */\n ierr = Util_TableSetString(coord_system_handle, \"uniform\", \"TYPE\");\n if (ierr < 0) {\n CCTK_WARN(1, \"Error registering cart1d type\");\n }\n\n /* Register cartnd as the default coordinate systems */\n if (register_default_coordinate_systems) {\n ierr = Coord_SetDefaultSystem(cctkGH, \"cart3d\");\n ierr += Coord_SetDefaultSystem(cctkGH, \"cart2d\");\n ierr += Coord_SetDefaultSystem(cctkGH, \"cart1d\");\n if (ierr < 0) {\n CCTK_WARN(1, \"Error registering cartnd as default coordinate systems\");\n }\n }\n }\n\n /* Register coordinates under the old API */\n CCTK_CoordRegisterSystem(3, \"cart3d\");\n CCTK_CoordRegisterSystem(3, \"spher3d\");\n\n if (CCTK_CoordRegisterData(1, \"grid::x\", \"x\", \"cart3d\") < 0) {\n CCTK_WARN(1, \"Problem with registering coordinate x\");\n }\n if (CCTK_CoordRegisterData(2, \"grid::y\", \"y\", \"cart3d\") < 0) {\n CCTK_WARN(1, \"Problem with registering coordinate y\");\n }\n if (CCTK_CoordRegisterData(3, \"grid::z\", \"z\", \"cart3d\") < 0) {\n CCTK_WARN(1, \"Problem with registering coordinate z\");\n }\n if (CCTK_CoordRegisterData(1, \"grid::r\", \"r\", \"spher3d\") < 0) {\n CCTK_WARN(1, \"Problem with registering coordinate r\");\n }\n}\n\n/********************************************************************\n ******************** Internal Routines ************************\n ********************************************************************/\nstatic void *SetupGH(tFleshConfig *config, int convlevel, cGH *GH) {\n int i, j, maxdim, numvars;\n SymmetryGHex *myGH;\n\n /* avoid compiler warnings about unused arguments */\n (void)(config + 0);\n (void)(convlevel + 0);\n (void)(GH + 0);\n\n maxdim = CCTK_MaxDim();\n numvars = CCTK_NumVars();\n\n /* allocate the GH extension */\n myGH = (SymmetryGHex *)malloc(sizeof(SymmetryGHex));\n if (myGH) {\n /* allocation for the number of grid functions */\n myGH->GFSym = (int **)malloc(numvars * sizeof(int *));\n\n /* allocation for the number of dimensions*/\n for (i = 0; i < numvars; i++) {\n myGH->GFSym[i] = (int *)malloc(2 * maxdim * sizeof(int));\n\n for (j = 0; j < 2 * maxdim; j++) {\n myGH->GFSym[i][j] = GFSYM_UNSET; /* not set */\n }\n }\n }\n\n return (myGH);\n}\n", |
| "DecodeSymParameters.c": "\n/*@@\n @file DecodeSymParameters.c\n @date Wed May 10 18:58:00 EST 2000\n @author Erik Schnetter\n @desc\n Decode the symmetry parameters.\n @enddesc\n @version $Id$\n@@*/\n\n#include \"cctk.h\"\n#include \"cctk_Arguments.h\"\n#include \"cctk_Parameters.h\"\n#include \"Symmetry.h\"\n\nstatic const char *rcsid = \"$Header$\";\n\nCCTK_FILEVERSION(CactusBase_CartGrid3D_DecodeSymParameters_c)\n\nvoid DecodeSymParameters3D(int sym[6]);\nvoid CCTK_FCALL CCTK_FNAME(DecodeSymParameters3D)(int sym[6]);\n\n/*@@\n @routine DecodeSymParameters3D\n @date Thu May 11 11:49:08 2000\n @author Erik Schnetter\n @desc\n Decode the Symmetry parameters.\n returns the symmetry flags (yes/no=1/0)\n in the array sym\n @enddesc\n@@*/\n\nvoid DecodeSymParameters3D(int sym[6]) {\n DECLARE_CCTK_PARAMETERS\n\n /* The default is as set by the explicit symmetry parameters */\n /* lower faces */\n sym[0] = symmetry_xmin;\n sym[2] = symmetry_ymin;\n sym[4] = symmetry_zmin;\n\n /* upper faces */\n sym[1] = symmetry_xmax;\n sym[3] = symmetry_ymax;\n sym[5] = symmetry_zmax;\n\n /* The default can be overridden by bitant, quadrant, and octant mode */\n if (CCTK_Equals(domain, \"bitant\")) {\n if (CCTK_Equals(bitant_plane, \"xy\")) {\n sym[4] = GFSYM_REFLECTION;\n } else if (CCTK_Equals(bitant_plane, \"xz\")) {\n sym[2] = GFSYM_REFLECTION;\n } else if (CCTK_Equals(bitant_plane, \"yz\")) {\n sym[0] = GFSYM_REFLECTION;\n }\n } else if (CCTK_Equals(domain, \"bitant_rotate\")) {\n if (CCTK_Equals(bitant_plane, \"xy\")) {\n if (CCTK_Equals(rotation_axis, \"y\"))\n sym[4] = GFSYM_ROTATION_Y;\n else if (CCTK_Equals(rotation_axis, \"x\"))\n sym[4] = GFSYM_ROTATION_X;\n } else if (CCTK_Equals(bitant_plane, \"xz\")) {\n if (CCTK_Equals(rotation_axis, \"x\"))\n sym[2] = GFSYM_ROTATION_X;\n else if (CCTK_Equals(rotation_axis, \"z\"))\n sym[2] = GFSYM_ROTATION_Z;\n } else if (CCTK_Equals(bitant_plane, \"yz\")) {\n if (CCTK_Equals(rotation_axis, \"y\"))\n sym[0] = GFSYM_ROTATION_Y;\n else if (CCTK_Equals(rotation_axis, \"z\"))\n sym[0] = GFSYM_ROTATION_Z;\n }\n } else if (CCTK_Equals(domain, \"quadrant\")) {\n if (CCTK_Equals(quadrant_direction, \"x\")) {\n sym[2] = GFSYM_REFLECTION;\n sym[4] = GFSYM_REFLECTION;\n } else if (CCTK_Equals(quadrant_direction, \"y\")) {\n sym[0] = GFSYM_REFLECTION;\n sym[4] = GFSYM_REFLECTION;\n } else if (CCTK_Equals(quadrant_direction, \"z\")) {\n sym[0] = GFSYM_REFLECTION;\n sym[2] = GFSYM_REFLECTION;\n }\n } else if (CCTK_Equals(domain, \"quadrant_reflect_rotate\")) {\n if (CCTK_Equals(quadrant_direction, \"x\")) {\n if (CCTK_Equals(rotation_axis, \"y\")) {\n sym[2] = GFSYM_REFLECTION;\n sym[4] = GFSYM_ROTATION_Y;\n } else if (CCTK_Equals(rotation_axis, \"z\")) {\n sym[2] = GFSYM_ROTATION_Z;\n sym[4] = GFSYM_REFLECTION;\n }\n } else if (CCTK_Equals(quadrant_direction, \"y\")) {\n if (CCTK_Equals(rotation_axis, \"x\")) {\n sym[0] = GFSYM_REFLECTION;\n sym[4] = GFSYM_ROTATION_X;\n }\n if (CCTK_Equals(rotation_axis, \"z\")) {\n sym[0] = GFSYM_ROTATION_Z;\n sym[4] = GFSYM_REFLECTION;\n }\n } else if (CCTK_Equals(quadrant_direction, \"z\")) {\n if (CCTK_Equals(rotation_axis, \"x\")) {\n sym[0] = GFSYM_REFLECTION;\n sym[2] = GFSYM_ROTATION_X;\n }\n if (CCTK_Equals(rotation_axis, \"y\")) {\n sym[0] = GFSYM_ROTATION_Y;\n sym[2] = GFSYM_REFLECTION;\n }\n }\n } else if (CCTK_Equals(domain, \"octant\")) {\n sym[0] = GFSYM_REFLECTION;\n sym[2] = GFSYM_REFLECTION;\n sym[4] = GFSYM_REFLECTION;\n }\n}\n\nvoid CCTK_FCALL CCTK_FNAME(DecodeSymParameters3D)(int sym[6]) {\n DecodeSymParameters3D(sym);\n}\n" |
| }, |
| "test": {}, |
| "doc": { |
| "rotating_sym.tex": "% /*@@\n% @file rotating_sym.tex\n% @date 6 June 2002\n% @author Denis Pollney\n% @desc \n% Description of the implementation of `rotating'\n% symmetry conditions in CartGrid3D.\n% @enddesc \n% @version $Header$\n% @@*/\n\n\\documentclass{article}\n\n\\newif\\ifpdf\n\\ifx\\pdfoutput\\undefined\n\\pdffalse % we are not running PDFLaTeX\n\\else\n\\pdfoutput=1 % we are running PDFLaTeX\n\\pdftrue\n\\fi\n\n\\ifpdf\n\\usepackage[pdftex]{graphicx}\n\\else\n\\usepackage{graphicx}\n\\fi\n\n\\parskip = 0 pt\n\\parindent = 0pt\n\\oddsidemargin = 0 cm\n\\textwidth = 16 cm\n\\topmargin = -1 cm\n\\textheight = 24 cm\n\n\\begin{document}\n\n\\title{Rotating symmetry conditions}\n\\author{Denis Pollney}\n\\date{June 2002}\n\n\\maketitle\n\n\\begin{abstract}\nThese notes describe the implentation of rotating symmetry conditions\nfor \\emph{bitant} and \\emph{quadrant} domains in \\texttt{CartGrid3D}.\nFor these particular domain types, the condition that fields on the\ngrid have a rotational symmetry in a plane along one of the\ncoordinate axes can be simply implemented with minor extensions to the\nalready existing symmetry mechanism, which copies the components of\na given field to the required ghost-zones with a possible plus-minus\ninversion.\n\\end{abstract}\n\n%------------------------------------------------------------------------------\n\\section{Introduction}\n\\label{sec:rs_intro}\n%------------------------------------------------------------------------------\n\nA number of useful physical models involve situations where a\nrotational symmetry is present in all of the relevant fields. By\n`rotational symmetry' we mean that there exists a pair of half-planes\nextending from one of the coordinate axes and separated by an angle\n$\\theta$ which have the property that on $A$ and near to $A$ can be\nmapped onto $B$ and corresponding points near to $B$ (see Figure\n\\ref{fig:rs_rotation_examples}).\n%\n\\begin{figure}\n\\centering\n\\begin{tabular}{ccc}\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_general.eps}\n\\fi\n&\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_bitant.eps}\n\\fi\n&\n\\ifpdf\n\\else\n\\includegraphics[height=25mm]{fig/rotate_octant.eps}\n\\fi\n\\\\\n(a) & (b) & (c)\n\\end{tabular}\n\\caption{Rotational symmetries, looking down the $z$-axis. In the\ngeneral case (a), the half-planes $A$ and $B$ are separated by an\nangle $\\theta$. Data at $A$ can be mapped on to points of $B$ via a\nrotation through $\\theta$. Particular cases of importance are the\nrotation through $\\theta=\\pi$, so that data on the positive $y$-axis\nis mapped onto the negative $y$, and vice versa; and the rotation\nthrough $\\theta=3\\pi/2$ so that data need be specified only in a\nsingle quarter-plane.}\n\\label{fig:rs_rotation_examples}\n\\end{figure}\n%\nIn particular, situations for which such conditions can be useful\ninclude\n\\begin{itemize}\n \\item rotating axisymmetric bodies -- satisfies the rotational \n symmetry for arbitrary $\\theta$.\n \\item pairs of massive bodies separated by distances $\\pm\n \\mathbf{d}$ from the origin and with identical oppositely directed\n momenta $\\pm \\mathbf{p}$ (Figure \\ref{fig:rs_bbh}) -- satisfies\n the half-plane rotational symmetry ($\\theta=\\pi$) or, if\n $\\mathbf{p}=0$ then also the quarter plane symmetry\n ($\\theta=3\\pi/2$).\n\\end{itemize}\n\\begin{figure}\n\\centering\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_bbh.eps}\n\\fi\n\\caption{A physical system consisting of a pair of identical bodies\n separated equal distance along a line through the origin, and moving\n with equal but opposite momenta, can be modelled using only the\n positive half-plane if the rotating symmetry condition is applied to\n the $x=0$ plane.}\n\\label{fig:rs_bbh}\n\\end{figure}\n\nIn order to apply the boundary condition exactly on a numerical grid,\nit is necessary that grid points to each side of the mapping planes\n$A$ and $B$ can be mapped onto each other exactly. In particular, this\nmeans that the rotating symmetry conditions can be applied exactly if\nthe half-planes are each aligned with one of the coordinate axes. For\ngeneral planes $A$ and $B$, however, interpolation would be required\nto put data in the neighbourhood of $A$ onto grid points near\n$B$. Only the particular cases described by Figures\n\\ref{fig:rs_rotation_examples} (b) and (c) will be\nconsidered here.\n\n%------------------------------------------------------------------------------\n\\section{Symmetry conditions}\n\\label{sec:rs_application}\n%------------------------------------------------------------------------------\n\nFor a given field, the boundary condition is applied as follows. For\neach ghost-zone point along the symmetry plane, the corresponding\npoint on the physical grid (under the rotational $\\theta$) is\ndetermined. To determine the value of the ghost-zone point, the\nvalue on the physical grid is simply transformed under the given\nrotation.\\\\\n\nThe first of these issues is not difficult to resolve. As an example,\nconsider the half-plane rotational symmetry about the $z$-axis applied\nin the $x=0$ plane, as depicted in Figure \\ref{fig:rs_grid}. The\nFigure has\n$j=0\\ldots m$ in the $y$ direction, an arbitrary number of points in the\n$x$ and $z$ directions, and some ghostzones whose $j$ coordinates are\nlabelled $j=-1,-2,\\ldots$. Then for the ghost-zone point $(n-i, -j,\nk)$, the corresponding physical point under rotation is (1) $(i,j-1,k)$\nif the $x=0$ plane is on the grid, or (2) $(i,j,k)$ if the $x=0$ plane\nis staggered between a grid point and the first ghost-zone\npoint. There is an implicit assumption here that the grid extends\nexactly the same distance to each side of the rotation axis. \\\\\n\n\\begin{figure}\n\\centering\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_grid.eps}\n\\fi\n\\caption{The mapping of physical points onto ghost-zone points for a\n half-plane rotation about the $z$-axis, where the $x=0$ plane is\n staggered between gridpoints, and two ghost zones have been\n allocated.}\n\\label{fig:rs_grid}\n\\end{figure}\n\nThe remaining issue is to determine how the fields at a point\n$(i,j,k)$ are modified under a rotation of a given angle. A set of\nbasis vectors $(\\mathbf{\\hat{x}},\\mathbf{\\hat{y}},\\mathbf{\\hat{z}})$\ncan be rotated to an arbitrary direction by applying the rotation\nmatrix\n\\begin{equation}\n \\mathbf{P} = \n \\left[\n \\begin{array}{ccc}\n \\eta_1(\\cos\\theta_1\\cos\\theta_3 - \\sin\\theta_1\\cos\\theta_2\\sin\\theta_3) &\n \\sin\\theta_1\\cos\\theta_3 + \\cos\\theta_1\\cos\\theta_2\\sin\\theta_3 &\n \\sin\\theta_2\\sin\\theta_3 \\\\\n -(\\cos\\theta_1\\sin\\theta_3 + \\sin\\theta_1\\cos\\theta_2\\cos\\theta3) &\n \\eta_2(\\sin\\theta_1\\sin\\theta_3 + \\cos\\theta_1\\cos\\theta_2\\cos\\theta_3) &\n \\sin\\theta_2\\cos\\theta_3 \\\\\n \\sin\\theta_1\\sin\\theta_2 &\n -\\cos\\theta_1\\sin\\theta_2 &\n \\eta_3\\cos\\theta_2\n \\end{array}\n \\right],\n\\end{equation}\nwhich preserves the orthogonality of the basis. The matrix\n$\\mathbf{P}$ has been written in terms of the Euler angles\n$0\\leq\\theta_1<2\\pi$, $0\\leq\\theta_2<2\\pi$, and $0\\leq\\theta_3<\\pi$,\nand the factors $\\eta_1=\\pm 1$, $\\eta_2=\\pm 1$, $\\eta_3=\\pm 1$ are\nintroduced to allow for reflections of individual axes (ie. changes of\nhandedness of the basis).\nThe basis is transformed under $\\mathbf{P}$ via the matrix multiplication\n\\begin{equation}\n \\left[\n \\begin{array}{c}\n \\mathbf{\\hat{x}^\\prime} \\\\\n \\mathbf{\\hat{y}^\\prime} \\\\\n \\mathbf{\\hat{z}^\\prime}\n \\end{array}\n \\right]\n =\n \\mathbf{P} \n \\left[\n \\begin{array}{c}\n \\mathbf{\\hat{x}} \\\\\n \\mathbf{\\hat{y}} \\\\\n \\mathbf{\\hat{z}} \n \\end{array}\n \\right].\n\\end{equation}\n\nVectors and tensor components are transformed under the given rotation\nby applying the $\\mathbf{P}$ matrix:\n\\begin{eqnarray}\n \\mathbf{v} & \\rightarrow & \\mathbf{P}^T \\mathbf{v}, \\\\\n \\mathbf{G} & \\rightarrow & \\mathbf{P}^T \\mathbf{G} \\mathbf{P},\n\\end{eqnarray}\nwhere $\\mathbf{v}$ is a 3-vector,\n\\begin{equation}\n \\mathbf{v} = [v_x, v_y, v_z]^T,\n\\end{equation}\nand $\\mathbf{G}$ is a two-index tensor treated as a matrix,\n\\begin{equation}\n \\mathbf{G} =\n \\left[\n \\begin{array}{ccc}\n\tg_{xx} & g_{xy} & g_{xz} \\\\\n\tg_{yx} & g_{yy} & g_{yz} \\\\\n\tg_{zx} & g_{zy} & g_{zz}\n \\end{array}\n \\right].\n\\end{equation}\n\n\\emph{Example 1.} The special case of a reflection in the $x=0$ plane\ncorresponds to an inversion of the $x$-axis, so that\n$\\theta_1=\\theta_2=\\theta_3=0$ and $\\eta_1=-1$,\n\\begin{equation}\n \\mathbf{P}_{x-\\mathrm{reflect}} = \\left[\n \\begin{array}{ccc}\n -1 & 0 & 0 \\\\\n 0 & 1 & 0 \\\\\n 0 & 0 & 1\n \\end{array}\n \\right].\n\\end{equation}\n\n\\emph{Example 2.} For a rotation about the $z$ axis by an angle of\n$\\theta=\\pi$ (corresponding to Figure \\ref{fig:rs_grid}), the only\nnon-zero rotation angle is $\\theta_1=\\pi$, so that\n\\begin{equation}\n \\mathbf{P}_{z-\\mathrm{rotate}} = \\left[\n \\begin{array}{ccc}\n -1 & 0 & 0 \\\\\n 0 & -1 & 0 \\\\\n 0 & 0 & 1\n \\end{array}\n \\right].\n\\end{equation}\n\n\\emph{Example 3.} A quarter-plane grid with positive $y$-axis values\nmapped onto the positive $x$-axis (as in Figure\\nobreak~\n\\ref{fig:rs_rotation_examples}) corresponds non-zero angle\n$\\theta_1=3\\pi/2$, with the resulting rotation matrix\n\\begin{equation}\n \\mathbf{P}_{z-\\mathrm{rotate(3/2)}} = \\left[\n \\begin{array}{ccc}\n 0 & -1 & 0 \\\\\n 1 & 0 & 0 \\\\\n 0 & 0 & 1\n \\end{array}\n \\right].\n\\end{equation}\n\n%------------------------------------------------------------------------------\n\\section{Implementation}\n\\label{sec:rs_implementation}\n%------------------------------------------------------------------------------\n\nIn order to implement the bitant, quadrant and octant\n\\emph{reflection} symmetries which already exist in\n\\texttt{CartGrid3D}, it was necessary to attach to each grid function\ninformation corresponding to how the field transforms under\nreflections in each of the $x$, $y$, and $z$ axes. These are\nspecified as an array of three integers, each taking the value $+1$ or\n$-1$, which is passed to the symmetry registration function. For\nexample,\n\\begin{verbatim}\n static int one=1;\n int sym[3];\n sym[0] = -one;\n sym[1] = -one;\n sym[2] = one;\n SetCartSymVN(cctkGH, sym,\"einstein::gxy\");\n\\end{verbatim}\nspecifies that the grid function \\texttt{einstein::gxy} should be\nnegated under reflections in $x=0$ and $y=0$, but keeps the same value\nunder reflections in the $z=0$ plane.\\\\\n\nThis is the only information required for the reflection symmetry\nsince the value of the field at the new (reflected) point does not\nrequire information from any other fields. For example, for a vector\n$v = (v_x, v_y, v_z)^T$ reflected in $x=0$, we have\n\\begin{equation}\n v_x \\rightarrow -v_x, \\qquad v_y \\rightarrow v_y, \\qquad\n v_z \\rightarrow v_z.\n\\end{equation}\nThat is, the transformation of $v_x$ only needs to know the values of\n$v_x$, and does not need to know anything about the values of $v_y$ or\n$v_z$. On the other hand, for the $3\\pi/2$-rotation corresponding to\nExample 3, above, the vector would transform as:\n\\begin{equation}\n v_x \\rightarrow -v_y, \\qquad v_y \\rightarrow v_x, \\qquad\n v_z \\rightarrow v_z.\n\\end{equation}\nIn this case, to determine the rotated $v_x$ component it is necessary\nto know the value of $v_y$. However, there is no concept of vector or\ntensor within Cactus, so that given a grid function corresponding to\n$v_x$, it is not generally possible to know which grid function\ncorresponds to $v_y$ which should be used to determine the rotated\nvalues.\\\\\n\nAs a result, the only symmetries which can easily be implemented\nwithin the current mechanism are those which require only the grid\nfunction itself in order to determine the ghost zone points. This\nincludes the $\\pi$-rotation symmetries (`half-plane', Figure\n\\ref{fig:rs_rotation_examples} (b)) but not the $3\\pi/2$-rotation\nsymmetries (`quarter-plane', Figure \\ref{fig:rs_rotation_examples}\n(c)).\\\\\n\nTable \\ref{tbl:rs_xform} lists the transformations of the components\nof an arbitrary scalar, vector and two-index tensor under reflections\nin each plane, and rotations about each axis.\n\\begin{table}\n\\centering\n\\begin{tabular}{r|rrr|rrr}\\hline\\hline\n & \\multicolumn{3}{c|}{reflection in} \n & \\multicolumn{3}{c}{rotation about} \\\\\n & $x$ & $y$ & $z$ & $x$ & $y$ & $z$ \\\\ \\hline\n$\\phi$ & 1 & 1 & 1 & 1 & 1 & 1 \\\\ \\hline\n$v_x$ & -1 & 1 & 1 & 1 & -1 & -1 \\\\\n$v_y$ & 1 & -1 & 1 & -1 & 1 & -1 \\\\\n$v_z$ & 1 & 1 & -1 & -1 & -1 & 1 \\\\ \\hline\n$g_{xx}$ & 1 & 1 & 1 & 1 & 1 & 1 \\\\ \n$g_{xy}$ & -1 & -1 & 1 & -1 & -1 & 1 \\\\ \n$g_{xz}$ & -1 & 1 & -1 & -1 & 1 & -1 \\\\ \n$g_{yy}$ & 1 & 1 & 1 & 1 & 1 & 1 \\\\ \n$g_{yz}$ & 1 & -1 & -1 & 1 & -1 & -1 \\\\ \n$g_{zz}$ & 1 & 1 & 1 & 1 & 1 & 1 \\\\ \\hline\\hline\n\\end{tabular}\n\\caption{Transformation factors for reflection and half-plane rotation\nsymmetries.}\n\\label{tbl:rs_xform}\n\\end{table}\nWe note the following useful fact: The transformation factor $s_i$ for\na rotation about the axis $i$ is given by $s_j \\times s_k$ where\n$i\\neq j\\neq k$. For example, for a rotation about the $z$-axis, the\ntransformation factor is given by\n\\begin{equation}\n s_x \\times s_y = -1 \\times -1 = 1.\n\\end{equation}\nIntuitively, this is clear since the rotation of the axes by $\\pi$\nradians about $z$ is equivalent to a reflection in $y$ followed by\na reflection in $x$ (Figure \\ref{fig:rs_rotate_reflect}).\\\\\n\n\\begin{figure}\n\\centering\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_reflect.eps}\n\\fi\n\\caption{A rotation by $\\pi$ radians about the $z$-axis is equivalent\n to successive reflections about the $y$- and $x$-axes.}\n\\label{fig:rs_rotate_reflect}\n\\end{figure}\n\nSince the transformation values for reflection symmetries are\nalready specified for each Cactus grid function, we can use this\ninformation to unambiguously determine the $\\pi$-rotation\ntransformation coefficients, without requiring that any new\ninformation be added if the reflection symmetries have already\nbeen defined (as is the case for any Cactus GFs which are able to\nuse the current \\texttt{bitant}, \\texttt{quadrant} and \\texttt{octant}\ndomains).\n\n%------------------------------------------------------------------------------\n\\section{\\texttt{CartGrid3D} Notes}\n\\label{sec:rs_cartgrid3d}\n%------------------------------------------------------------------------------\n\nTwo types of rotating symmetry conditions have been implemented in\n\\texttt{CartGrid3D} as extensions to the \\texttt{grid::domain}\nparameter.\\\\\n\nThe first, \\texttt{bitant\\_rotate}, defines a grid which is half-sized\nalong one axis, and assumes a field that is rotating about a\nperpendicular axis. The half-axis is chosen using the\n\\texttt{bitant\\_plane} parameter, which specifies the plane at which\nthe grid is to be cut as either ``\\texttt{xy}'', ``\\texttt{xz}'' or\n``\\texttt{yz}''. The rotation axis is chosen using the\n\\texttt{rotation\\_axis} parameter, which takes values of\n``\\texttt{x}'', ``\\texttt{y}'' or ``\\texttt{z}''. For example, to\nspecify a bitant domain along the positive $y$-axis, on which fields\nare rotating about the $z$-axis, the following parameters would do the\njob:\n\\begin{verbatim}\n grid::domain = \"bitant_rotate\"\n grid::bitant_plane = \"xz\"\n grid::rotation_axis = \"z\"\n\\end{verbatim}\nThis setup is illustrated in Figure \\ref{fig:rs_bitant_example} (a).\\\\\n\n\\begin{figure}\n\\centering\n\\begin{tabular}{cc}\n\\ifpdf\n\\else\n\\includegraphics[height=40mm]{fig/rotate_bitant_example.eps}\n\\fi\n&\n\\ifpdf\n\\else\n\\includegraphics[height=30mm]{fig/rotate_quadrant_example.eps}\n\\fi\n\\\\\n(a) & (b)\n\\end{tabular}\n\\caption{Active grids for the \\texttt{bitant\\_rotate} and\n \\texttt{quadrant\\_reflect\\_rotate} domains for the examples given in\n the text. (a) The given \\texttt{bitant\\_rotate} domain corresponds\n to the $y>0$ half-grid, with fields rotating about the $z$-axis. (b)\n The \\texttt{quadrant\\_reflect\\_rotate} example is similar, except\n the active grid is only along the positive $z$-axis and a reflection\n symmetry is assumed in the $z=0$ plane.}\n\\label{fig:rs_bitant_example}\n\\end{figure}\n\nThe \\texttt{quadrant\\_reflect\\_rotate} symmetry cuts two of the axes\nin half so that only a quadrant of the full domain is active. A\nstandard reflection symmetry is applied to one of the half-planes,\nwhile the physical fields are assumed to rotate in the other plane. To\nset up such a grid which rotates about the $z$-axis and which is\nreflection symmetric in the $z=0$ plane, the following parameters\nwould be used:\n\\begin{verbatim}\n grid::domain = \"quadrant_reflect_rotate\"\n grid::quadrant_direction = \"x\"\n grid::rotation_axis = \"z\"\n\\end{verbatim}\nNote that the \\texttt{quadrant\\_direction} parameter follows the\ncurrent \\texttt{CartGrid3D} standard, which defines the domain on the\n\\emph{positive} quadrant with the long edge aligned with the specified\naxis. It is currently not possible to choose the negative quadrant.\\\\\n\nOctant rotation symmetries, or the alternate quadrant symmetry (for\nwhich the data on one half-plane is rotated onto the other), are more\ndifficult to implement without some generalisation of the existing\n\\texttt{CartGrid3D} specification of symmetry boundaries for the\nreasons mentioned in the previous section.\n\n%------------------------------------------------------------------------------\n\\end{document}\n", |
| "documentation.tex": "\\documentclass{article}\n\n% Use the Cactus ThornGuide style file\n% (Automatically used from Cactus distribution, if you have a \n% thorn without the Cactus Flesh download this from the Cactus\n% homepage at www.cactuscode.org)\n\\usepackage{../../../../doc/latex/cactus}\n\n\\begin{document}\n\n\\title{CartGrid3D}\n\\author{Gabrielle Allen \\\\ Gerd Lanfermann \\\\ Joan Masso \\\\ Jonathan Thornburg}\n\\date{$ $Date$ $}\n\n\\maketitle\n\n% Do not delete next line\n% START CACTUS THORNGUIDE\n\n\\begin{abstract}\n{\\tt CartGrid3D} allows you to set up coordinates on a 3D Cartesian\ngrid in a flexible manner. You can choose different grid domains\n({\\it eg} octant) to allow you to exploit any symmetry in your problem.\n{\\tt CartGrid3D} also provides routines for registering symmetries\nof grid functions and applying symmetry conditions across the\ncoordinate axes. \n\\end{abstract}\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\section{Specifying the Grid Symmetry}\n\nCartGrid3D allows you to specify the grid symmetry (or lack thereof) with the\n\\verb|grid::domain| parameter:\n\\begin{description}\n\\item[{\\tt grid::domain = \"full\"}]\\mbox{}\\\\\n\tThere are no symmetries.\n\\item[{\\tt grid::domain = \"bitant\"}]\\mbox{}\\\\\n\tThe grid includes only the $z \\ge 0$ half-space\n\t(plus symmetry zones); there is a reflection symmetry\n\tacross the $z=0$ plane.\n\\item[{\\tt grid::domain = \"quadrant\"}]\\mbox{}\\\\\n\tThe grid includes only the $\\{x \\ge 0, y \\ge 0\\}$ quadrant\n\t(plus symmetry zones); there is a reflection symmetry\n\tacross both the $x=0$ plane and the $y=0$ plane.\n\\item[{\\tt grid::domain = \"octant\"}]\\mbox{}\\\\\n\tThe grid includes only the $\\{x \\ge 0, y \\ge 0, z \\ge 0\\}$\n\toctant (plus symmetry zones); there is a reflection symmetry\n\tacross each of the $x=0$ plane, the $y=0$ plane, and the $z=0$\n\tplane.\n\\end{description}\n\nNote that the implementation of symmetries in CartGrid3D is\ndeprecated, and the SymBase infrastructure should be used instead.\nThe above symmetries can be implemented using SymBase and the\nReflectionSymmetry thorn. Additionally, there are rotational\nsymmetries provided by the RotatingSymmetry180 and RotatingSymmetry90\nthorns.\n\nIn each case except \\verb|grid::domain = \"full\"|, symmetry zones are\nintroduced just on the ``other side'' of each symmetry grid boundary.\nEach symmetry zone has a width (perpendicular to the boundary) of\n\\verb|driver::ghost_size| extra grid points. For centered 2nd~order\nfinite differencing, a width of \\verb|driver::ghost_size = 1| should be\nsufficient, but for (centered) 4th~order finite differencing, or for\nupwinded 2nd~order, a width of \\verb|driver::ghost_size = 2| is needed.\nMaking \\verb|driver::ghost_size|\ntoo large is fairly harmless (it just slightly reduces performance),\nbut making it too small will almost certainly result in horribly wrong\nfinite differencing near the symmetry boundaries, and may also result\nin core dumps from out-of-range array accessing.\n\nNote that the symmetry zones must be explicitly included in\n\\verb|driver::global_nx|, \\verb|driver::global_ny|, and\n\\verb|driver::global_nz|, but should {\\em not\\/} be included in any\nof the \\verb|grid::type = \"byrange\"| parameters \\verb|grid::xmin|,\n\\verb|grid::xmax|, \\verb|grid::ymin|, \\verb|grid::ymax|, \\verb|grid::zmin|,\n\\verb|grid::zmax|, \\verb|grid::xyzmin|, and/or \\verb|grid::xyzmax|\ndescribed in the next section.\n\nNote also that \\verb|driver::global_nx|, \\verb|driver::global_ny|,\nand \\verb|driver::global_nz| do {\\em not\\/} include any ghost zones\nintroduced for multiprocessor synchronization. (For more information\non ghost zones, see the section ``Ghost Size'' in the ``Cactus Variables''\nchapter of the Cactus Users' Guide.)\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\section{Specifying the Grid Size, Range, and Spacing}\n\n\\verb|CartGrid3D| provides several different methods for setting\nup the integer {\\em grid size\\/} ({\\it eg} 128), floating-point\n{\\em grid spacing\\/} ({\\it eg} 0.1), and floating-point {\\em grid range\\/}\n({\\it eg} 12.8).%%%\n\\footnote{%%%\n\t If you're AMR-ing, this all refers to the\n\t coarsest or base grid.%%%\n\t }%%%\n{} You specify which method to use, with the \\verb|grid::type| parameter:\n\\begin{description}\n\\item[{\\tt grid::type = \"byrange\"}]\\mbox{}\\\\\n\tYou specify the $x$, $y$, and $z$ grid ranges, either with\n\tseparate \\verb|grid::xmin|, \\verb|grid::xmax|, \\verb|grid::ymin|,\n\t\\verb|grid::ymax|, \\verb|grid::zmin|, and \\verb|grid::zmax|\n\tparameters, or with the \\verb|grid::xyzmin| and\n\t\\verb|grid::xyzmax| parameters. The grid spacings are then\n\tdetermined automagically from this information and the\n\t\\verb|driver::global_nx|, \\verb|driver::global_ny|, and\n\t\\verb|driver::global_nz| grid-size parameters. You should\n\talso choose the \\verb|grid::domain| parameter consistent with\n\tall these other parameters. (It's not clear whether or not\n\tthe code ever explicitly checks this.)\n\\item[{\\tt grid::type = \"box\"}]\\mbox{}\\\\\n\tThis is a special case of \\verb|grid::type = \"byrange\"|\n\twith the grid ranges hard-wired to\n\t\\verb|grid::xyzmin = -0.5| and \\verb|grid::xyzmax = +0.5|.\n\\item[{\\tt grid::type = \"byspacing\"}]\\mbox{}\\\\\n\tYou specify the $x$, $y$, and $z$ grid spacings, either with\n\tseparate \\verb|grid::dx|, \\verb|grid::dy|, and \\verb|grid::dz|\n\tparameters, or with the \\verb|grid::dxyz| parameter. You also\n\tspecify the grid symmetry with the \\verb|grid::domain| parameter.\n\tThe $x$, $y$, and $z$ grid ranges are then determined automagically\n\tfrom this information and the \\verb|driver::global_nx|,\n\t\\verb|driver::global_ny|, and \\verb|driver::global_nz|\n\tgrid-size parameters: Each coordinate's range is chosen\n\tto be either symmetric about zero, or to extend from 0 up\n\tto a maximum value.\n\\end{description}\n\nThere are also a number of optional parameters which can be used\nto specify whether or not it's ok to have a grid point with an $x$,\n$y$, and/or $z$ coordinate exactly equal to 0:\n\\begin{description}\n\\item[{\\tt grid::no\\_originx}, {\\tt grid::no\\_originy}, {\\tt\ngrid::no\\_originz}, {\\tt grid::no\\_origin}]\\mbox{}\\\\\n\tThese parameters are all deprecated --- don't use them!\n\\item[{\\tt grid::avoid\\_originx}]\\mbox{}\\\\\n\tThis is a Boolean parameter; if set to true\n\t(\\verb|grid::avoid_originx = \"true\"| or\n\t\\verb|grid::avoid_originx = \"yes\"| or\n\t\\verb|grid::avoid_originx = 1|) then the grid will be\n\t``half-centered'' across $x=0$, {\\it ie} there will be\n\tgrid points at\n\t\\dots,\n\t$x = - \\frac{3}{2} \\Delta x$,\n\t$x = - \\frac{1}{2} \\Delta x$,\n\t$x = + \\frac{1}{2} \\Delta x$,\n\t$x = + \\frac{3}{2} \\Delta x$,\n\t\\dots,\n\tbut not at $x=0$.\n\\item[{\\tt grid::avoid\\_originy}]\\mbox{}\\\\\n\tSame thing for $y$.\n\\item[{\\tt grid::avoid\\_originz}]\\mbox{}\\\\\n\tSame thing for $z$.\n\\item[{\\tt grid::avoid\\_origin}]\\mbox{}\\\\\n\tSame thing for all 3 axes $x$ and $y$ and $z$, {\\it ie}\n\tno grid point will have $x=0$ or $y=0$ or $z=0$.\n\\end{description}\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\section{An Example}\n\nHere is an example of setting up a grid using the {\\tt PUGH} unigrid\ndriver. The relevant parts of the parameter file are as follows:\n\\begin{verbatim}\n# PUGH\ndriver::ghost_size = 2\ndriver::global_nx = 61\ndriver::global_ny = 61\ndriver::global_nz = 33\n\n# CartGrid3D\ngrid::avoid_origin = \"no\"\ngrid::domain = \"bitant\"\ngrid::type = \"byrange\"\ngrid::xmin = -3.0\ngrid::xmax = +3.0\ngrid::ymin = -3.0\ngrid::ymax = +3.0\ngrid::zmin = 0.0\ngrid::zmax = +3.0\n\\end{verbatim}\n\nThe resulting Cactus output (describing the grid) is as follows:\n\\begin{verbatim}\nINFO (CartGrid3D): Grid Spacings:\nINFO (CartGrid3D): dx=>1.0000000e-01 dy=>1.0000000e-01 dz=>1.0000000e-01 \nINFO (CartGrid3D): Computational Coordinates:\nINFO (CartGrid3D): x=>[-3.000, 3.000] y=>[-3.000, 3.000] z=>[-0.200, 3.000] \nINFO (CartGrid3D): Indices of Physical Coordinates:\nINFO (CartGrid3D): x=>[0,60] y=>[0,60] z=>[2,32] \nINFO (PUGH): Single processor evolution\nINFO (PUGH): 3-dimensional grid functions\nINFO (PUGH): Size: 61 61 33\n\\end{verbatim}\n\nSince there's no symmetry in the $x$ and $y$ directions, the grid\nis set up just as specified, with floating-point coordinates running\nfrom $-3.0$ to $3.0$ inclusive, and 61~grid points with integer grid\nindices $[0,60]$ (C) or $[1,61]$ (Fortran).\n\nHowever, in the $z$ direction there's a reflection symmetry across the\n$z=0$ plane, so the specified range of the grid, $z \\in [0.0,3.0]$,\nis automagically widened to include the symmetry zone of\n\\verb|driver::ghost_size = 2| grid points. The grid thus actually\nincludes the range of floating-point coordinates $z \\in [-0.2,3.0]$.\nThe original specification of 33~grid points is left alone, however,\nso the grid points have integer array indices $[0,32]$ (C) or\n$[1,33]$ (Fortran).\nThe ``physical'' ({\\it ie} non-symmetry-zone) part of the grid is\nprecisely the originally-specified range, $z \\in [0.0,3.0]$, and\nhas the integer array indices $[2,32]$ (C) or $[3,33]$ (Fortran).\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\section{Coordinates}\n\n\\verb|CartGrid3D| defines (registers) four coordinate systems:\n\\verb|cart3d|, \\verb|cart2d|, \\verb|cart1d|, and \\verb|spher3d|.\n\nThe Cartesian coordinates supplied by this thorn are grid functions\nwith the standard names \\verb|x|, \\verb|y|, and \\verb|z|. To use\nthese coordinates you need to inherit from \\verb|grid|, {\\it ie} you\nneed to have an\n\\begin{verbatim}\ninherits: grid\n\\end{verbatim}\nline in your \\verb|interface.ccl| file.\nIn addition a grid function \\verb|r| is provided, containing the\nradial coordinate from the origin where\n$$\nr = \\sqrt{x^2+y^2+z^2}\n$$\n\n\\verb|CartGrid3D| registers the lower and upper range of each coordinate\nwith the flesh.\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\section{Symmetries for Grid Functions}\n\nIf your problem and initial data allow it, \\verb|CartGrid3D|\nallows you to enforce even or odd parity for any grid function%%%\n{} at (across) each coordinate axis. For a function $\\phi(x,y,z)$,\neven parity symmetry on the $x$-axis means\n$$\n\\phi(-x,y,z) = \\phi(x,y,z)\n$$\nwhile odd parity symmetry means\n$$\n\\phi(-x,y,z) = -\\phi(x,y,z)\n$$\n\nNote that the symmetries will only be enforced if a symmetry domain\nis chosen (that is, if \\verb|grid::domain| is set to something other than\n\\verb|grid::domain = \"full\"|.\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\subsection{Registering Symmetry Behaviour}\n\nEach grid function can register how it behaves under a coordinate\nchange using function calls in {\\tt CartGrid3D}. These symmetry\nproperties can then be used by other thorns, for example\n{\\tt CactusBase/Boundary} uses them to enforce symmetry boundary\nconditions across coordinate axes. Symmetries should obviously be\nregistered before they are used, but since they can be different\nfor different grids, they must be registered {\\it after} the\n{\\tt CCTK\\_STARTUP} timebin. The usual place to register symmetries\nis in the {\\tt CCTK\\_BASEGRID} timebin.\n\nFor example, to register the symmetries of the {\\it xy} component of the\nmetric tensor from C, you first need to get access to the include file\nby putting the line\n\\begin{verbatim}\nuses include: Symmetry.h\n\\end{verbatim}\nin your \\verb|interface.ccl| file. Then in your thorn you can write (C)\n\\begin{verbatim}\n#include \"Symmetry.h\"\nstatic int one=1;\nint sym[3];\nsym[0] = -one;\nsym[1] = -one;\nsym[2] = one;\nSetCartSymVN(cctkGH, sym,\"ADMBase::gxy\");\n\\end{verbatim}\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n\\subsection{Calling Symmetry Boundary Conditions}\n\n\\verb|CartGrid3D| provides the following two routines to apply symmetry\nboundary conditions to a variable group:\n\n\\begin{verbatim}\nCartSymGI(cGH *GH, int *gi)\nCartSymGN(cGH *GH, const char *gn)\n\\end{verbatim}\n\nand for a specific variable it provides:\n\n\\begin{verbatim}\nCartSymVI(cGH *GH, int *vi)\nCartSymVN(cGH *GH, const char *gn)\n\\end{verbatim}\n\nA group or variable can\nbe specified by its index value or name (use the 'I' or 'N' version\nrespectively). The Fortran versions of these functions take an\nadditional first argument, which is an integer which will hold the\nreturn value.\n\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n% Do not delete next line\n% END CACTUS THORNGUIDE\n\n\\end{document}\n", |
| "fig/rotate_bbh.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_bbh.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Thu Jun 6 19:51:10 2002\n%%For: dp@nbdell15 (Denis Pollney,,,)\n%%BoundingBox: 0 0 203 204\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 204 moveto 0 0 lineto 203 0 lineto 203 204 lineto closepath clip newpath\n-78.6 264.4 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n /DrawEllipse {\n\t/endangle exch def\n\t/startangle exch def\n\t/yrad exch def\n\t/xrad exch def\n\t/y exch def\n\t/x exch def\n\t/savematrix mtrx currentmatrix def\n\tx y tr xrad yrad sc 0 0 1 startangle endangle arc\n\tclosepath\n\tsavematrix setmatrix\n\t} def\n\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n0 slj 0 slc\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Polyline\n7.500 slw\nn 2700 1350 m 4050 1350 l 4050 4050 l 2700 4050 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Ellipse\nn 3375 2250 64 64 0 360 DrawEllipse gs 0.00 setgray ef gr gs col0 s gr\n\n% Ellipse\nn 2025 3375 64 64 0 360 DrawEllipse gs 0.00 setgray ef gr gs col0 s gr\n\n% Polyline\nn 1350 1350 m 4050 1350 l 4050 4050 l 1350 4050 l\n cp gs col0 s gr \n% Polyline\ngs clippath\n2421 3767 m 2460 3721 l 2346 3623 l 2418 3724 l 2307 3668 l cp\neoclip\nn 2115 3465 m\n 2430 3735 l gs col0 s gr gr\n\n% arrowhead\nn 2307 3668 m 2418 3724 l 2346 3623 l 2307 3668 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n2978 1857 m 2939 1903 l 3053 2001 l 2982 1901 l 3092 1956 l cp\neoclip\nn 3285 2160 m\n 2970 1890 l gs col0 s gr gr\n\n% arrowhead\nn 3092 1956 m 2982 1901 l 3053 2001 l 3092 1956 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n4290 2730 m 4290 2670 l 4139 2670 l 4259 2700 l 4139 2730 l cp\neoclip\nn 1260 2700 m\n 4275 2700 l gs col0 s gr gr\n\n% arrowhead\nn 4139 2730 m 4259 2700 l 4139 2670 l 4139 2730 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n2730 1110 m 2670 1110 l 2670 1261 l 2700 1141 l 2730 1261 l cp\neoclip\nn 2700 4185 m\n 2700 1125 l gs col0 s gr gr\n\n% arrowhead\nn 2730 1261 m 2700 1141 l 2670 1261 l 2730 1261 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n2655 1080 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n4365 2745 m\ngs 1 -1 sc (x) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_general.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n5 1 0 1 0 7 50 0 -1 0.000 0 1 1 1 1761.000 2475.000 2025 2160 1350 2475 2025 2790\n\t1 1 1.00 60.00 120.00\n\t1 1 1.00 60.00 120.00\n1 3 0 1 0 0 50 0 20 0.000 1 0.0000 1800 2475 45 45 1800 2475 1845 2475\n2 1 0 1 0 6 50 0 20 0.000 0 0 -1 0 0 4\n\t 1800 2475 3600 1350 3600 3825 1800 2475\n4 0 0 50 0 32 12 0.0000 4 135 105 1170 2475 q\\001\n4 0 0 50 0 16 12 0.0000 4 135 135 2340 1980 A\\001\n4 0 0 50 0 16 12 0.0000 4 135 120 2340 3240 B\\001\n4 0 0 50 0 16 12 0.0000 4 135 345 2925 2610 Grid\\001\n", |
| "fig/rotate_bitant_example.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n1 1 0 1 0 7 50 0 -1 0.000 1 0.0000 2700 1350 315 135 2700 1350 3015 1350\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1800 3465 1170 3825\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 3375 1350 3375 3825\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 3375 3825 4950 3825\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 3375 3825 1800 4725\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 2700 1755 2700 4725\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 1805 3474 4145 2124\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 4140 2970 1575 2970\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4140 2970 5670 2970\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2700 4725 2700 4995\n2 2 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 1800 2250 3375 2250 3375 4725 1800 4725 1800 2250\n2 3 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 3375 1350 1800 2250 3375 2250 4950 1350 3375 1350\n2 3 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 3375 2250 4950 1350 4950 3825 3375 4725 3375 2250\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 1800 2970 1575 2970\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2700 1710 2700 900\n4 0 0 50 0 16 12 0.0000 4 105 90 1035 3960 x\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 2655 855 z\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 5715 3015 y\\001\n4 0 0 50 0 16 12 0.0000 4 135 615 1710 1305 rotation\\001\n4 0 0 50 0 16 12 0.0000 4 135 330 1845 1485 axis\\001\n", |
| "fig/rotate_reflect.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n6 630 1395 1980 2835\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1125 2250 1800 2250\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1125 2250 675 2700\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1125 2250 1125 1575\n4 0 0 50 0 16 12 0.0000 4 105 90 630 2835 x\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 1845 2340 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 1080 1530 z\\001\n-6\n6 6525 1395 7875 2340\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 7335 2250 7335 1575\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 7335 2250 6660 2250\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 7335 2250 7785 1800\n4 0 0 50 0 16 12 0.0000 4 105 90 7290 1530 z\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 6525 2295 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 7785 1800 x\\001\n-6\n6 3780 1395 4635 2835\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4590 2250 4590 1575\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4590 2250 4140 2700\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4545 2250 3870 2250\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4590 2250 3915 2250\n4 0 0 50 0 16 12 0.0000 4 105 90 4050 2835 x\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 3780 2295 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 4545 1530 z\\001\n-6\n6 5400 3645 6750 4590\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 6210 4500 6210 3825\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 6210 4500 5535 4500\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 6210 4500 6660 4050\n4 0 0 50 0 16 12 0.0000 4 105 90 6165 3780 z\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 5400 4545 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 6660 4050 x\\001\n-6\n6 2070 3645 3420 5085\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2565 4500 3240 4500\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2565 4500 2115 4950\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2565 4500 2565 3825\n4 0 0 50 0 16 12 0.0000 4 105 90 2070 5085 x\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 3285 4590 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 2520 3780 z\\001\n-6\n2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5\n\t 180 1035 8460 1035 8460 3150 180 3150 180 1035\n2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5\n\t 180 3285 8460 3285 8460 5400 180 5400 180 3285\n2 1 0 30 6 7 60 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 750.00 120.00\n\t 2385 2205 3285 2205\n2 1 0 30 6 7 60 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 750.00 120.00\n\t 5310 2205 6210 2205\n2 1 0 30 6 7 60 0 20 0.000 0 0 -1 1 0 2\n\t1 1 1.00 750.00 120.00\n\t 3800 4455 4950 4455\n4 0 0 50 0 16 12 0.0000 4 150 105 2745 2340 y\\001\n4 0 0 50 0 16 12 0.0000 4 135 510 2565 2160 reflect\\001\n4 0 0 50 0 16 12 0.0000 4 135 990 3825 4410 rotate about\\001\n4 0 0 50 0 16 12 0.0000 4 135 510 5490 2205 reflect\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 5670 2385 x\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 4230 4590 z\\001\n", |
| "fig/rotate_quadrant_example.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n1 1 0 1 0 7 50 0 -1 0.000 1 0.0000 2700 1350 315 135 2700 1350 3015 1350\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1800 3465 1170 3825\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 1805 3474 4145 2124\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 4140 2970 1575 2970\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 4140 2970 5670 2970\n2 3 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 6\n\t 3375 1350 1800 2250 3375 2250 4950 1350 3375 1350 3375 1350\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 1800 2970 1575 2970\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2700 1710 2700 900\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 3375 1350 3375 2250\n2 2 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 1800 2250 3375 2250 3375 3465 1800 3465 1800 2250\n2 3 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 6\n\t 3375 2250 3375 3465 4950 2520 4950 1350 3375 2250 3375 2250\n2 1 1 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 2700 1755 2700 3465\n2 1 0 1 0 7 50 0 -1 4.000 0 0 -1 0 0 2\n\t 2700 3465 2700 3825\n2 1 0 1 0 7 50 0 -1 4.000 0 0 -1 1 1 2\n\t1 1 1.00 60.00 120.00\n\t1 1 1.00 60.00 120.00\n\t 3105 3240 3105 3645\n4 0 0 50 0 16 12 0.0000 4 105 90 1035 3960 x\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 2655 855 z\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 5715 3015 y\\001\n4 0 0 50 0 16 12 0.0000 4 180 1290 3240 3690 reflection plane\\001\n4 0 0 50 0 16 12 0.0000 4 135 615 1755 1395 rotation\\001\n4 0 0 50 0 16 12 0.0000 4 135 330 1890 1575 axis\\001\n", |
| "fig/rotate_bitant.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_bitant.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sun Jun 9 11:06:24 2002\n%%For: pollney@xeon20.aei-potsdam.mpg.de (Denis Pollney,0.21,1.21,none)\n%%BoundingBox: 0 0 165 202\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 202 moveto 0 0 lineto 165 0 lineto 165 202 lineto closepath clip newpath\n-56.7 261.5 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Arc\n7.500 slw\ngs clippath\n1765 3181 m 1774 3122 l 1624 3100 l 1739 3148 l 1615 3159 l cp\n1774 2277 m 1765 2218 l 1615 2240 l 1739 2252 l 1624 2299 l cp\neoclip\nn 1755.0 2700.0 450.0 -90.0 90.0 arcn\ngs col0 s gr\n gr\n\n% arrowhead\nn 1615 3159 m 1739 3148 l 1624 3100 l 1615 3159 l cp gs 0.00 setgray ef gr col0 s\n% arrowhead\nn 1624 2299 m 1739 2252 l 1615 2240 l 1624 2299 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\nn 1800 1350 m 3150 1350 l 3150 4050 l 1800 4050 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\ngs clippath\n3390 2730 m 3390 2670 l 3239 2670 l 3359 2700 l 3239 2730 l cp\neoclip\nn 1710 2700 m\n 3375 2700 l gs col0 s gr gr\n\n% arrowhead\nn 3239 2730 m 3359 2700 l 3239 2670 l 3239 2730 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n1830 1110 m 1770 1110 l 1770 1261 l 1800 1141 l 1830 1261 l cp\neoclip\nn 1800 4140 m\n 1800 1125 l gs col0 s gr gr\n\n% arrowhead\nn 1830 1261 m 1800 1141 l 1770 1261 l 1830 1261 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n1755 1080 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3420 2790 m\ngs 1 -1 sc (x) col0 sh gr\n/Symbol ff 180.00 scf sf\n900 2745 m\ngs 1 -1 sc (q=p) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1575 2025 m\ngs 1 -1 sc (A) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1575 3600 m\ngs 1 -1 sc (B) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_general.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_general.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sun Jun 9 11:03:43 2002\n%%For: pollney@xeon20.aei-potsdam.mpg.de (Denis Pollney,0.21,1.21,none)\n%%BoundingBox: 0 0 154 158\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 158 moveto 0 0 lineto 154 0 lineto 154 158 lineto closepath clip newpath\n-73.7 241.7 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n /DrawEllipse {\n\t/endangle exch def\n\t/startangle exch def\n\t/yrad exch def\n\t/xrad exch def\n\t/y exch def\n\t/x exch def\n\t/savematrix mtrx currentmatrix def\n\tx y tr xrad yrad sc 0 0 1 startangle endangle arc\n\tclosepath\n\tsavematrix setmatrix\n\t} def\n\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Arc\n7.500 slw\ngs clippath\n2053 2808 m 2022 2756 l 1892 2833 l 2011 2798 l 1923 2885 l cp\n2022 2193 m 2053 2141 l 1923 2064 l 2011 2152 l 1892 2116 l cp\neoclip\nn 1761.0 2475.0 411.0 -50.0 50.0 arcn\ngs col0 s gr\n gr\n\n% arrowhead\nn 1923 2885 m 2011 2798 l 1892 2833 l 1923 2885 l cp gs 0.00 setgray ef gr col0 s\n% arrowhead\nn 1892 2116 m 2011 2152 l 1923 2064 l 1892 2116 l cp gs 0.00 setgray ef gr col0 s\n% Ellipse\nn 1800 2475 45 45 0 360 DrawEllipse gs 0.00 setgray ef gr gs col0 s gr\n\n% Polyline\nn 1800 2475 m 3600 1350 l 3600 3825 l\n 1800 2475 l cp gs col6 1.00 shd ef gr gs col0 s gr \n/Symbol ff 180.00 scf sf\n1170 2475 m\ngs 1 -1 sc (q) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2340 1980 m\ngs 1 -1 sc (A) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2340 3240 m\ngs 1 -1 sc (B) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2925 2610 m\ngs 1 -1 sc (Grid) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_bitant.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n5 1 0 1 0 7 50 0 -1 0.000 0 1 1 1 1755.000 2700.000 1755 2250 1305 2700 1755 3150\n\t1 1 1.00 60.00 120.00\n\t1 1 1.00 60.00 120.00\n2 2 0 1 0 6 50 0 20 0.000 0 0 -1 0 0 5\n\t 1800 1350 3150 1350 3150 4050 1800 4050 1800 1350\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1710 2700 3375 2700\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1800 4140 1800 1125\n4 0 0 50 0 16 12 0.0000 4 150 105 1755 1080 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 3420 2790 x\\001\n4 0 0 50 0 32 12 0.0000 4 135 315 900 2745 q=p\\001\n4 0 0 50 0 16 12 0.0000 4 135 135 1575 2025 A\\001\n4 0 0 50 0 16 12 0.0000 4 135 120 1575 3600 B\\001\n", |
| "fig/rotate_reflect.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_reflect.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sat Jun 8 18:20:30 2002\n%%For: dp@nbdell15 (Denis Pollney,,,)\n%%BoundingBox: 0 0 524 277\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 277 moveto 0 0 lineto 524 0 lineto 524 277 lineto closepath clip newpath\n-10.6 340.9 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n0 slj 0 slc\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Polyline\n435.000 slw\ngs clippath\n3300 2580 m 3300 1830 l 3161 1830 l 3281 2205 l 3161 2580 l cp\neoclip\nn 2385 2205 m\n 3285 2205 l gs col6 s gr gr\n\n% arrowhead\n7.500 slw\nn 3161 2580 m 3281 2205 l 3161 1830 l 3161 2580 l cp gs col6 1.00 shd ef gr col6 s\n% Polyline\n435.000 slw\ngs clippath\n6225 2580 m 6225 1830 l 6086 1830 l 6206 2205 l 6086 2580 l cp\neoclip\nn 5310 2205 m\n 6210 2205 l gs col6 s gr gr\n\n% arrowhead\n7.500 slw\nn 6086 2580 m 6206 2205 l 6086 1830 l 6086 2580 l cp gs col6 1.00 shd ef gr col6 s\n% Polyline\n435.000 slw\ngs clippath\n4965 4830 m 4965 4080 l 4826 4080 l 4946 4455 l 4826 4830 l cp\neoclip\nn 3800 4455 m\n 4950 4455 l gs col7 1.00 shd ef gr gs col6 s gr gr\n\n% arrowhead\n7.500 slw\nn 4826 4830 m 4946 4455 l 4826 4080 l 4826 4830 l cp gs col6 1.00 shd ef gr col6 s\n% Polyline\ngs clippath\n1815 2280 m 1815 2220 l 1664 2220 l 1784 2250 l 1664 2280 l cp\neoclip\nn 1125 2250 m\n 1800 2250 l gs col0 s gr gr\n\n% arrowhead\nn 1664 2280 m 1784 2250 l 1664 2220 l 1664 2280 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n643 2689 m 685 2731 l 792 2625 l 686 2689 l 749 2582 l cp\neoclip\nn 1125 2250 m\n 675 2700 l gs col0 s gr gr\n\n% arrowhead\nn 749 2582 m 686 2689 l 792 2625 l 749 2582 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n1155 1560 m 1095 1560 l 1095 1711 l 1125 1591 l 1155 1711 l cp\neoclip\nn 1125 2250 m\n 1125 1575 l gs col0 s gr gr\n\n% arrowhead\nn 1155 1711 m 1125 1591 l 1095 1711 l 1155 1711 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n630 2835 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1845 2340 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1080 1530 m\ngs 1 -1 sc (z) col0 sh gr\n% Polyline\ngs clippath\n7365 1560 m 7305 1560 l 7305 1711 l 7335 1591 l 7365 1711 l cp\neoclip\nn 7335 2250 m\n 7335 1575 l gs col0 s gr gr\n\n% arrowhead\nn 7365 1711 m 7335 1591 l 7305 1711 l 7365 1711 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n6645 2220 m 6645 2280 l 6796 2280 l 6676 2250 l 6796 2220 l cp\neoclip\nn 7335 2250 m\n 6660 2250 l gs col0 s gr gr\n\n% arrowhead\nn 6796 2220 m 6676 2250 l 6796 2280 l 6796 2220 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n7816 1810 m 7774 1768 l 7667 1874 l 7774 1811 l 7710 1917 l cp\neoclip\nn 7335 2250 m\n 7785 1800 l gs col0 s gr gr\n\n% arrowhead\nn 7710 1917 m 7774 1811 l 7667 1874 l 7710 1917 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n7290 1530 m\ngs 1 -1 sc (z) col0 sh gr\n/Helvetica ff 180.00 scf sf\n6525 2295 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n7785 1800 m\ngs 1 -1 sc (x) col0 sh gr\n% Polyline\ngs clippath\n4620 1560 m 4560 1560 l 4560 1711 l 4590 1591 l 4620 1711 l cp\neoclip\nn 4590 2250 m\n 4590 1575 l gs col0 s gr gr\n\n% arrowhead\nn 4620 1711 m 4590 1591 l 4560 1711 l 4620 1711 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n4108 2689 m 4150 2731 l 4257 2625 l 4151 2689 l 4214 2582 l cp\neoclip\nn 4590 2250 m\n 4140 2700 l gs col0 s gr gr\n\n% arrowhead\nn 4214 2582 m 4151 2689 l 4257 2625 l 4214 2582 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n3855 2220 m 3855 2280 l 4006 2280 l 3886 2250 l 4006 2220 l cp\neoclip\nn 4545 2250 m\n 3870 2250 l gs col0 s gr gr\n\n% arrowhead\nn 4006 2220 m 3886 2250 l 4006 2280 l 4006 2220 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n3900 2220 m 3900 2280 l 4051 2280 l 3931 2250 l 4051 2220 l cp\neoclip\nn 4590 2250 m\n 3915 2250 l gs col0 s gr gr\n\n% arrowhead\nn 4051 2220 m 3931 2250 l 4051 2280 l 4051 2220 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n4050 2835 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3780 2295 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n4545 1530 m\ngs 1 -1 sc (z) col0 sh gr\n% Polyline\ngs clippath\n6240 3810 m 6180 3810 l 6180 3961 l 6210 3841 l 6240 3961 l cp\neoclip\nn 6210 4500 m\n 6210 3825 l gs col0 s gr gr\n\n% arrowhead\nn 6240 3961 m 6210 3841 l 6180 3961 l 6240 3961 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n5520 4470 m 5520 4530 l 5671 4530 l 5551 4500 l 5671 4470 l cp\neoclip\nn 6210 4500 m\n 5535 4500 l gs col0 s gr gr\n\n% arrowhead\nn 5671 4470 m 5551 4500 l 5671 4530 l 5671 4470 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n6691 4060 m 6649 4018 l 6542 4124 l 6649 4061 l 6585 4167 l cp\neoclip\nn 6210 4500 m\n 6660 4050 l gs col0 s gr gr\n\n% arrowhead\nn 6585 4167 m 6649 4061 l 6542 4124 l 6585 4167 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n6165 3780 m\ngs 1 -1 sc (z) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5400 4545 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n6660 4050 m\ngs 1 -1 sc (x) col0 sh gr\n% Polyline\ngs clippath\n3255 4530 m 3255 4470 l 3104 4470 l 3224 4500 l 3104 4530 l cp\neoclip\nn 2565 4500 m\n 3240 4500 l gs col0 s gr gr\n\n% arrowhead\nn 3104 4530 m 3224 4500 l 3104 4470 l 3104 4530 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n2083 4939 m 2125 4981 l 2232 4875 l 2126 4939 l 2189 4832 l cp\neoclip\nn 2565 4500 m\n 2115 4950 l gs col0 s gr gr\n\n% arrowhead\nn 2189 4832 m 2126 4939 l 2232 4875 l 2189 4832 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n2595 3810 m 2535 3810 l 2535 3961 l 2565 3841 l 2595 3961 l cp\neoclip\nn 2565 4500 m\n 2565 3825 l gs col0 s gr gr\n\n% arrowhead\nn 2595 3961 m 2565 3841 l 2535 3961 l 2595 3961 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n2070 5085 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3285 4590 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2520 3780 m\ngs 1 -1 sc (z) col0 sh gr\n% Polyline\nn 180 1035 m 8460 1035 l 8460 3150 l 180 3150 l\n cp gs col0 s gr \n% Polyline\nn 180 3285 m 8460 3285 l 8460 5400 l 180 5400 l\n cp gs col0 s gr \n/Helvetica ff 180.00 scf sf\n2745 2340 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2565 2160 m\ngs 1 -1 sc (reflect) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3825 4410 m\ngs 1 -1 sc (rotate about) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5490 2205 m\ngs 1 -1 sc (reflect) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5670 2385 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n4230 4590 m\ngs 1 -1 sc (z) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_grid.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_grid.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sat Jun 8 18:10:26 2002\n%%For: dp@nbdell15 (Denis Pollney,,,)\n%%BoundingBox: 0 0 290 261\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 261 moveto 0 0 lineto 290 0 lineto 290 261 lineto closepath clip newpath\n-59.5 346.6 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n0 slj 0 slc\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Polyline\n7.500 slw\nn 1800 1800 m 5175 1800 l 5175 5400 l 1800 5400 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\nn 2070 1800 m\n 2070 2565 l gs col0 s gr \n% Polyline\nn 2430 2070 m\n 1800 2070 l gs col0 s gr \n% Polyline\nn 2430 2295 m\n 1800 2295 l gs col0 s gr \n% Polyline\nn 1530 4635 m\n 1530 5400 l gs col0 s gr \n% Polyline\nn 1800 5400 m 1260 5400 l 1260 1800 l 1800 1800 l\n cp gs col0 s gr \n% Polyline\nn 2430 2520 m\n 1800 2520 l gs col0 s gr \n% Polyline\nn 2340 1800 m\n 2340 2565 l gs col0 s gr \n% Polyline\nn 1260 5175 m\n 1800 5175 l gs col0 s gr \n% Polyline\nn 1260 4950 m\n 1800 4950 l gs col0 s gr \n% Polyline\nn 1260 4725 m\n 1800 4725 l gs col0 s gr \n% Polyline\ngs clippath\n1830 1560 m 1770 1560 l 1770 1711 l 1800 1591 l 1830 1711 l cp\neoclip\nn 1800 5490 m\n 1800 1575 l gs col0 s gr gr\n\n% arrowhead\nn 1830 1711 m 1800 1591 l 1770 1711 l 1830 1711 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n5415 3630 m 5415 3570 l 5264 3570 l 5384 3600 l 5264 3630 l cp\neoclip\nn 1125 3600 m\n 5400 3600 l gs col0 s gr gr\n\n% arrowhead\nn 5264 3630 m 5384 3600 l 5264 3570 l 5264 3630 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n1845 2025 m\ngs 1 -1 sc (00 01) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1845 2250 m\ngs 1 -1 sc (10 11) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1845 2475 m\ngs 1 -1 sc (20 21) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1305 5130 m\ngs 1 -1 sc (11 10) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1305 5355 m\ngs 1 -1 sc (01 00) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1305 4905 m\ngs 1 -1 sc (21 20) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3105 2880 m\ngs 1 -1 sc (physical grid) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1575 4095 m\ngs 1 -1 sc 90.0 rot (ghost zones) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1800 1485 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5445 3690 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1935 1755 m\ngs 1 -1 sc (0) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2160 1755 m\ngs 1 -1 sc (1) col0 sh gr\n/Helvetica ff 180.00 scf sf\n4995 1755 m\ngs 1 -1 sc (n) col0 sh gr\n/Helvetica ff 180.00 scf sf\n945 1980 m\ngs 1 -1 sc (0) col0 sh gr\n/Helvetica ff 180.00 scf sf\n945 2205 m\ngs 1 -1 sc (1) col0 sh gr\n/Helvetica ff 180.00 scf sf\n945 5400 m\ngs 1 -1 sc (m) col0 sh gr\n/Times-Roman ff 180.00 scf sf\n945 2430 m\ngs 1 -1 sc (2) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_octant.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n5 1 0 1 0 7 50 0 -1 0.000 0 1 1 1 1357.558 2923.697 1305 2475 1035 3240 1800 3015\n\t1 1 1.00 60.00 120.00\n\t1 1 1.00 60.00 120.00\n2 2 0 1 0 6 50 0 20 0.000 0 0 -1 0 0 5\n\t 1350 1800 2475 1800 2475 2925 1350 2925 1350 1800\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1260 2925 2700 2925\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1350 3015 1350 1575\n4 0 0 50 0 32 12 0.0000 4 135 540 495 3420 q=3p/2\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 1305 1530 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 2745 3015 x\\001\n4 0 0 50 0 16 12 0.0000 4 135 135 1125 2250 A\\001\n4 0 0 50 0 16 12 0.0000 4 135 120 1935 3150 B\\001\n", |
| "fig/rotate_octant.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_octant.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sun Jun 9 11:05:54 2002\n%%For: pollney@xeon20.aei-potsdam.mpg.de (Denis Pollney,0.21,1.21,none)\n%%BoundingBox: 0 0 148 130\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 130 moveto 0 0 lineto 148 0 lineto 148 130 lineto closepath clip newpath\n-31.2 218.0 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Arc\n7.500 slw\ngs clippath\n1833 3011 m 1777 2990 l 1724 3132 l 1794 3030 l 1780 3152 l cp\n1327 2499 m 1311 2442 l 1165 2482 l 1289 2479 l 1181 2539 l cp\neoclip\nn 1357.6 2923.7 451.8 -96.7 11.7 arcn\ngs col0 s gr\n gr\n\n% arrowhead\nn 1780 3152 m 1794 3030 l 1724 3132 l 1780 3152 l cp gs 0.00 setgray ef gr col0 s\n% arrowhead\nn 1181 2539 m 1289 2479 l 1165 2482 l 1181 2539 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\nn 1350 1800 m 2475 1800 l 2475 2925 l 1350 2925 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\ngs clippath\n2715 2955 m 2715 2895 l 2564 2895 l 2684 2925 l 2564 2955 l cp\neoclip\nn 1260 2925 m\n 2700 2925 l gs col0 s gr gr\n\n% arrowhead\nn 2564 2955 m 2684 2925 l 2564 2895 l 2564 2955 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\ngs clippath\n1380 1560 m 1320 1560 l 1320 1711 l 1350 1591 l 1380 1711 l cp\neoclip\nn 1350 3015 m\n 1350 1575 l gs col0 s gr gr\n\n% arrowhead\nn 1380 1711 m 1350 1591 l 1320 1711 l 1380 1711 l cp gs 0.00 setgray ef gr col0 s\n/Symbol ff 180.00 scf sf\n495 3420 m\ngs 1 -1 sc (q=3p/2) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1305 1530 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2745 3015 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1125 2250 m\ngs 1 -1 sc (A) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1935 3150 m\ngs 1 -1 sc (B) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_bitant_example.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_bitant_example.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sat Jun 8 19:19:08 2002\n%%For: dp@nbdell15 (Denis Pollney,,,)\n%%BoundingBox: 0 0 302 269\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 269 moveto 0 0 lineto 302 0 lineto 302 269 lineto closepath clip newpath\n-65.2 315.4 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n /DrawEllipse {\n\t/endangle exch def\n\t/startangle exch def\n\t/yrad exch def\n\t/xrad exch def\n\t/y exch def\n\t/x exch def\n\t/savematrix mtrx currentmatrix def\n\tx y tr xrad yrad sc 0 0 1 startangle endangle arc\n\tclosepath\n\tsavematrix setmatrix\n\t} def\n\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n0 slj 0 slc\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Polyline\n7.500 slw\nn 1800 2250 m 3375 2250 l 3375 4725 l 1800 4725 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\nn 3375 1350 m 1800 2250 l 3375 2250 l 4950 1350 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\nn 3375 2250 m 4950 1350 l 4950 3825 l 3375 4725 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Ellipse\nn 2700 1350 315 135 0 360 DrawEllipse gs col0 s gr\n\n% Polyline\ngs clippath\n1142 3806 m 1171 3858 l 1303 3783 l 1184 3817 l 1273 3731 l cp\neoclip\nn 1800 3465 m\n 1170 3825 l gs col0 s gr gr\n\n% arrowhead\nn 1273 3731 m 1184 3817 l 1303 3783 l 1273 3731 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\n [60] 0 sd\nn 3375 1350 m\n 3375 3825 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 3375 3825 m\n 4950 3825 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 3375 3825 m\n 1800 4725 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 2700 1755 m\n 2700 4725 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 1805 3474 m\n 4145 2124 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 4140 2970 m\n 1575 2970 l gs col0 s gr [] 0 sd\n% Polyline\ngs clippath\n5685 3000 m 5685 2940 l 5534 2940 l 5654 2970 l 5534 3000 l cp\neoclip\nn 4140 2970 m\n 5670 2970 l gs col0 s gr gr\n\n% arrowhead\nn 5534 3000 m 5654 2970 l 5534 2940 l 5534 3000 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\nn 2700 4725 m\n 2700 4995 l gs col0 s gr \n% Polyline\n [60] 0 sd\nn 1800 2970 m\n 1575 2970 l gs col0 s gr [] 0 sd\n% Polyline\ngs clippath\n2730 885 m 2670 885 l 2670 1036 l 2700 916 l 2730 1036 l cp\neoclip\nn 2700 1710 m\n 2700 900 l gs col0 s gr gr\n\n% arrowhead\nn 2730 1036 m 2700 916 l 2670 1036 l 2730 1036 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n1035 3960 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2655 855 m\ngs 1 -1 sc (z) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5715 3015 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1710 1305 m\ngs 1 -1 sc (rotation) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1845 1485 m\ngs 1 -1 sc (axis) col0 sh gr\n$F2psEnd\nrs\n", |
| "fig/rotate_grid.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n2 2 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 1800 1800 5175 1800 5175 5400 1800 5400 1800 1800\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2070 1800 2070 2565\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2430 2070 1800 2070\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2430 2295 1800 2295\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 1530 4635 1530 5400\n2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5\n\t 1800 5400 1260 5400 1260 1800 1800 1800 1800 5400\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2430 2520 1800 2520\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 2340 1800 2340 2565\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 1260 5175 1800 5175\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 1260 4950 1800 4950\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 2\n\t 1260 4725 1800 4725\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1800 5490 1800 1575\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1125 3600 5400 3600\n4 0 0 50 0 16 12 0.0000 4 135 480 1845 2025 00 01\\001\n4 0 0 50 0 16 12 0.0000 4 135 480 1845 2250 10 11\\001\n4 0 0 50 0 16 12 0.0000 4 135 480 1845 2475 20 21\\001\n4 0 0 50 0 16 12 0.0000 4 135 480 1305 5130 11 10\\001\n4 0 0 50 0 16 12 0.0000 4 135 480 1305 5355 01 00\\001\n4 0 0 50 0 16 12 0.0000 4 135 480 1305 4905 21 20\\001\n4 0 0 50 0 16 12 0.0000 4 180 1080 3105 2880 physical grid\\001\n4 0 0 50 0 16 12 1.5708 4 180 1005 1575 4095 ghost zones\\001\n4 0 0 50 0 16 12 0.0000 4 150 105 1800 1485 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 5445 3690 x\\001\n4 0 0 50 0 16 12 0.0000 4 135 105 1935 1755 0\\001\n4 0 0 50 0 16 12 0.0000 4 135 105 2160 1755 1\\001\n4 0 0 50 0 16 12 0.0000 4 105 105 4995 1755 n\\001\n4 0 0 50 0 16 12 0.0000 4 135 105 945 1980 0\\001\n4 0 0 50 0 16 12 0.0000 4 135 105 945 2205 1\\001\n4 0 0 50 0 16 12 0.0000 4 105 135 945 5400 m\\001\n4 0 0 50 0 0 12 0.0000 4 135 90 945 2430 2\\001\n", |
| "fig/rotate_bbh.fig": "#FIG 3.2\nLandscape\nCenter\nMetric\nA4 \n100.00\nSingle\n-2\n1200 2\n1 3 0 1 0 0 50 0 20 0.000 1 0.0000 3375 2250 64 64 3375 2250 3439 2250\n1 3 0 1 0 0 50 0 20 0.000 1 0.0000 2025 3375 64 64 2025 3375 2089 3375\n2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5\n\t 1350 1350 4050 1350 4050 4050 1350 4050 1350 1350\n2 2 0 1 0 6 60 0 20 0.000 0 0 -1 0 0 5\n\t 2700 1350 4050 1350 4050 4050 2700 4050 2700 1350\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2115 3465 2430 3735\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 3285 2160 2970 1890\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 1260 2700 4275 2700\n2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2\n\t1 1 1.00 60.00 120.00\n\t 2700 4185 2700 1125\n4 0 0 50 0 16 12 0.0000 4 150 105 2655 1080 y\\001\n4 0 0 50 0 16 12 0.0000 4 105 90 4365 2745 x\\001\n", |
| "fig/rotate_quadrant_example.eps": "%!PS-Adobe-2.0 EPSF-2.0\n%%Title: rotate_quadrant_example.eps\n%%Creator: fig2dev Version 3.2 Patchlevel 3d\n%%CreationDate: Sat Jun 8 19:04:20 2002\n%%For: dp@nbdell15 (Denis Pollney,,,)\n%%BoundingBox: 0 0 302 203\n%%Magnification: 1.0000\n%%EndComments\n/$F2psDict 200 dict def\n$F2psDict begin\n$F2psDict /mtrx matrix put\n/col-1 {0 setgray} bind def\n/col0 {0.000 0.000 0.000 srgb} bind def\n/col1 {0.000 0.000 1.000 srgb} bind def\n/col2 {0.000 1.000 0.000 srgb} bind def\n/col3 {0.000 1.000 1.000 srgb} bind def\n/col4 {1.000 0.000 0.000 srgb} bind def\n/col5 {1.000 0.000 1.000 srgb} bind def\n/col6 {1.000 1.000 0.000 srgb} bind def\n/col7 {1.000 1.000 1.000 srgb} bind def\n/col8 {0.000 0.000 0.560 srgb} bind def\n/col9 {0.000 0.000 0.690 srgb} bind def\n/col10 {0.000 0.000 0.820 srgb} bind def\n/col11 {0.530 0.810 1.000 srgb} bind def\n/col12 {0.000 0.560 0.000 srgb} bind def\n/col13 {0.000 0.690 0.000 srgb} bind def\n/col14 {0.000 0.820 0.000 srgb} bind def\n/col15 {0.000 0.560 0.560 srgb} bind def\n/col16 {0.000 0.690 0.690 srgb} bind def\n/col17 {0.000 0.820 0.820 srgb} bind def\n/col18 {0.560 0.000 0.000 srgb} bind def\n/col19 {0.690 0.000 0.000 srgb} bind def\n/col20 {0.820 0.000 0.000 srgb} bind def\n/col21 {0.560 0.000 0.560 srgb} bind def\n/col22 {0.690 0.000 0.690 srgb} bind def\n/col23 {0.820 0.000 0.820 srgb} bind def\n/col24 {0.500 0.190 0.000 srgb} bind def\n/col25 {0.630 0.250 0.000 srgb} bind def\n/col26 {0.750 0.380 0.000 srgb} bind def\n/col27 {1.000 0.500 0.500 srgb} bind def\n/col28 {1.000 0.630 0.630 srgb} bind def\n/col29 {1.000 0.750 0.750 srgb} bind def\n/col30 {1.000 0.880 0.880 srgb} bind def\n/col31 {1.000 0.840 0.000 srgb} bind def\n\nend\nsave\nnewpath 0 203 moveto 0 0 lineto 302 0 lineto 302 203 lineto closepath clip newpath\n-65.2 249.4 translate\n1 -1 scale\n\n/cp {closepath} bind def\n/ef {eofill} bind def\n/gr {grestore} bind def\n/gs {gsave} bind def\n/sa {save} bind def\n/rs {restore} bind def\n/l {lineto} bind def\n/m {moveto} bind def\n/rm {rmoveto} bind def\n/n {newpath} bind def\n/s {stroke} bind def\n/sh {show} bind def\n/slc {setlinecap} bind def\n/slj {setlinejoin} bind def\n/slw {setlinewidth} bind def\n/srgb {setrgbcolor} bind def\n/rot {rotate} bind def\n/sc {scale} bind def\n/sd {setdash} bind def\n/ff {findfont} bind def\n/sf {setfont} bind def\n/scf {scalefont} bind def\n/sw {stringwidth} bind def\n/tr {translate} bind def\n/tnt {dup dup currentrgbcolor\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add\n 4 -2 roll dup 1 exch sub 3 -1 roll mul add srgb}\n bind def\n/shd {dup dup currentrgbcolor 4 -2 roll mul 4 -2 roll mul\n 4 -2 roll mul srgb} bind def\n /DrawEllipse {\n\t/endangle exch def\n\t/startangle exch def\n\t/yrad exch def\n\t/xrad exch def\n\t/y exch def\n\t/x exch def\n\t/savematrix mtrx currentmatrix def\n\tx y tr xrad yrad sc 0 0 1 startangle endangle arc\n\tclosepath\n\tsavematrix setmatrix\n\t} def\n\n/$F2psBegin {$F2psDict begin /$F2psEnteredState save def} def\n/$F2psEnd {$F2psEnteredState restore end} def\n\n$F2psBegin\n10 setmiterlimit\n0 slj 0 slc\n 0.06299 0.06299 sc\n%\n% Fig objects follow\n%\n% Polyline\n7.500 slw\nn 3375 1350 m 1800 2250 l 3375 2250 l 4950 1350 l 3375 1350 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\nn 1800 2250 m 3375 2250 l 3375 3465 l 1800 3465 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Polyline\nn 3375 2250 m 3375 3465 l 4950 2520 l 4950 1350 l 3375 2250 l\n cp gs col6 1.00 shd ef gr gs col0 s gr \n% Ellipse\nn 2700 1350 315 135 0 360 DrawEllipse gs col0 s gr\n\n% Polyline\ngs clippath\n1142 3806 m 1171 3858 l 1303 3783 l 1184 3817 l 1273 3731 l cp\neoclip\nn 1800 3465 m\n 1170 3825 l gs col0 s gr gr\n\n% arrowhead\nn 1273 3731 m 1184 3817 l 1303 3783 l 1273 3731 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\n [60] 0 sd\nn 1805 3474 m\n 4145 2124 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 4140 2970 m\n 1575 2970 l gs col0 s gr [] 0 sd\n% Polyline\ngs clippath\n5685 3000 m 5685 2940 l 5534 2940 l 5654 2970 l 5534 3000 l cp\neoclip\nn 4140 2970 m\n 5670 2970 l gs col0 s gr gr\n\n% arrowhead\nn 5534 3000 m 5654 2970 l 5534 2940 l 5534 3000 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\n [60] 0 sd\nn 1800 2970 m\n 1575 2970 l gs col0 s gr [] 0 sd\n% Polyline\ngs clippath\n2730 885 m 2670 885 l 2670 1036 l 2700 916 l 2730 1036 l cp\neoclip\nn 2700 1710 m\n 2700 900 l gs col0 s gr gr\n\n% arrowhead\nn 2730 1036 m 2700 916 l 2670 1036 l 2730 1036 l cp gs 0.00 setgray ef gr col0 s\n% Polyline\n [60] 0 sd\nn 3375 1350 m\n 3375 2250 l gs col0 s gr [] 0 sd\n% Polyline\n [60] 0 sd\nn 2700 1755 m\n 2700 3465 l gs col0 s gr [] 0 sd\n% Polyline\nn 2700 3465 m\n 2700 3825 l gs col0 s gr \n% Polyline\ngs clippath\n3075 3660 m 3135 3660 l 3135 3509 l 3105 3629 l 3075 3509 l cp\n3135 3225 m 3075 3225 l 3075 3376 l 3105 3256 l 3135 3376 l cp\neoclip\nn 3105 3240 m\n 3105 3645 l gs col0 s gr gr\n\n% arrowhead\nn 3135 3376 m 3105 3256 l 3075 3376 l 3135 3376 l cp gs 0.00 setgray ef gr col0 s\n% arrowhead\nn 3075 3509 m 3105 3629 l 3135 3509 l 3075 3509 l cp gs 0.00 setgray ef gr col0 s\n/Helvetica ff 180.00 scf sf\n1035 3960 m\ngs 1 -1 sc (x) col0 sh gr\n/Helvetica ff 180.00 scf sf\n2655 855 m\ngs 1 -1 sc (z) col0 sh gr\n/Helvetica ff 180.00 scf sf\n5715 3015 m\ngs 1 -1 sc (y) col0 sh gr\n/Helvetica ff 180.00 scf sf\n3240 3690 m\ngs 1 -1 sc (reflection plane) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1755 1395 m\ngs 1 -1 sc (rotation) col0 sh gr\n/Helvetica ff 180.00 scf sf\n1890 1575 m\ngs 1 -1 sc (axis) col0 sh gr\n$F2psEnd\nrs\n" |
| } |
| } |