diff options
author | tradke <tradke@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 2001-08-01 11:38:17 +0000 |
---|---|---|
committer | tradke <tradke@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 2001-08-01 11:38:17 +0000 |
commit | 1ec7c99cb05a7a5dde7ed81fbc185be658822bda (patch) | |
tree | 40ea9282884da6a01d6cbae0eea39cc0968abb8f /src/iobasicGH.h | |
parent | ad7050ddb6009847f4b345dbb6c32e1e02e54466 (diff) |
For info output, you can now specify the reduction values to print by setting
IOBasic::outInfo_reductions or add an option string to the variable name
in IOBasic::outInfo_vars. Scalar variables will be output by their value.
The option string syntax is
IOBasic::outInfo_vars = "var1[reductions=<minimum maximum>] var2"
and might still change slightly in the future.
git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/IOBasic/trunk@96 b589c3ab-70e8-4b4d-a09f-cba2dd200880
Diffstat (limited to 'src/iobasicGH.h')
-rw-r--r-- | src/iobasicGH.h | 50 |
1 files changed, 37 insertions, 13 deletions
diff --git a/src/iobasicGH.h b/src/iobasicGH.h index fe1cb16..d9c6b9a 100644 --- a/src/iobasicGH.h +++ b/src/iobasicGH.h @@ -1,9 +1,9 @@ /*@@ - @header iobasic.h + @header iobasicGH.h @date Friday 18th September 1999 @author Gabrielle Allen - @desc - The extensions to the GH structure from IOBasic. + @desc + The extensions to the GH structure from IOBasic. @enddesc @version $Header$ @@*/ @@ -11,25 +11,40 @@ #include "StoreNamedData.h" -typedef struct IOBASICGH { +typedef struct IOBASIC_REDUCTION +{ + int handle; + char *name; + char is_valid; + CCTK_REAL value; + struct IOBASIC_REDUCTION *next; +} iobasic_reduction_t; +typedef struct IOBASIC_REDUCTIONLIST +{ + unsigned int num_reductions; + iobasic_reduction_t *reductions; +} iobasic_reductionlist_t; + +typedef struct IOBASIC_GH +{ /* how often to output */ int outScalar_every; int outInfo_every; + char info_reductions_changed; - /* flags indicating output for var [i] */ - char *do_outInfo; + /* flags indicating output for variable i */ char *do_outScalar; - /* directory in which to output */ + /* directory in which to place scalar output */ char *outdirScalar; /* The last iteration output */ int *outInfo_last; int *outScalar_last; - /* The values for info */ - CCTK_REAL **infovals; + /* The reduction lists for info output for all variables */ + iobasic_reductionlist_t *info_reductions; /* database for names of output files that were already created */ pNamedData *filenameListScalar; @@ -37,7 +52,16 @@ typedef struct IOBASICGH { } iobasicGH; -/* function prototypes */ -void IOBasic_Write (cGH *GH, int vindex, const char *alias); -void IOBasic_WriteGF (cGH *GH, int vindex, const char *alias); -int IOBasic_WriteInfo (cGH *GH, CCTK_REAL *val,int vindex, const char *operator, const char *alias); +/* prototypes of functions to be registered */ +int IOBasic_InfoOutputGH (cGH *GH); +int IOBasic_TriggerInfoOutput (cGH *GH, int vindex); +int IOBasic_TimeForInfoOutput (cGH *GH, int vindex); +int IOBasic_ScalarOutputGH (cGH *GH); +int IOBasic_TriggerScalarOutput (cGH *GH, int vindex); +int IOBasic_TimeForScalarOutput (cGH *GH, int vindex); +int IOBasic_ScalarOutputVarAs (cGH *GH, const char *vname, const char *alias); + +/* other function prototypes */ +void IOBasic_WriteInfo (cGH *GH, int vindex); +void IOBasic_WriteScalarGS (cGH *GH, int vindex, const char *alias); +void IOBasic_WriteScalarGA (cGH *GH, int vindex, const char *alias); |