00001 00006 #ifndef __UIUC_CHARM_ILSI_C_H 00007 #define __UIUC_CHARM_ILSI_C_H 00008 00009 #ifdef __cplusplus 00010 extern "C" { 00011 #endif 00012 00018 typedef struct { 00019 /* Input parameters: */ 00020 double maxResidual; /* (1) If nonzero, upper bound on total residual error. */ 00021 double maxIterations; /* (2) If nonzero, upper bound on number of iterations to take. */ 00022 double solverIn[8]; /* Solver-specific input parameters (normally 0) */ 00023 /* Output parameters: */ 00024 double residual; /* (11) Residual error of final solution (estimate) */ 00025 double iterations; /* (12) Number of iterations actually taken. */ 00026 double solverOut[8]; /* Solver-specific output parameters (normally 0) */ 00027 } ILSI_Param; 00028 00030 void ILSI_Param_new(ILSI_Param *param); 00031 00032 00034 typedef struct ILSI_Comm ILSI_Comm; 00035 00036 00051 typedef void (*ILSI_Solver)(ILSI_Param *param, ILSI_Comm *comm, 00052 int n, const double *b, double *x); 00053 00055 void ILSI_CG_Solver(ILSI_Param *param, ILSI_Comm *comm, 00056 int n, const double *b, double *x); 00057 00058 00059 #ifdef __cplusplus 00060 } 00061 #endif 00062 00063 #endif 00064