/* test2.c Emilio 3/29/99 */ const char * cpszUsage = {"usage: test2 \n"}; #include "emu.h" float *x; int main(int argc, char *argv[]) { int v, yr, mo, i, tvar = 0; int bug=0; Initialize(&argc, argv, DOMASK); /* TEST THE NEW VARIABLE-READING FUNCTIONALITIES */ printf("\n ============= IN test2.c ================== "); for (v=0; v < nVars; v++) { printf("\n v=%d, name: %s", v, pstVars[v].name); printf("\n .nParams=%d: ", pstVars[v].nParams); for (i=0; i < pstVars[v].nParams; i++) printf(" %.3f ", pstVars[v].P[i]); printf("\n .nStrParams=%d: ", pstVars[v].nStrParams); for (i=0; i < pstVars[v].nStrParams; i++) printf(" <%s> ", pstVars[v].szP[i]); } printf("\n ============= END test2.c ================== \n"); x = alloc1d_f(0,nRows*nCols-1); for (v = 0; v < nVars; v++) for (tvar = 0; tvar < nTimeSteps;tvar++) { getyrmonth(tvar, &yr, &mo); if (bDebug) printf("\n pstVars[%d]=%s: tvar=%d, year=%d, month=%d * ", v,pstVars[v].param,tvar,yr,mo+1); ReadXY(x, pstVars[v], yr, mo); } CleanUp(); return(0); } void ProcessCommandLineArgs(int * pArgc, char * argv[]) {} void LocalCleanUp(void) { free1d_f(x,0,nRows*nCols-1); }