Changeset 3960
- Timestamp:
- 05/26/10 16:20:04 (15 years ago)
- Location:
- issm/trunk/src/mex
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/mex/Mergesolutionfromftog/Mergesolutionfromftog.cpp
r2333 r3960 11 11 12 12 /*input datasets: */ 13 bool flag_ys0; 13 14 Vec uf=NULL; 14 15 Mat Gmn=NULL; … … 23 24 24 25 /*checks on arguments on the matlab side: */ 25 CheckNumMatlabArguments(nlhs,NLHS,nrhs,NRHS,__FUNCT__,&MergesolutionfromftogUsage); 26 if((nlhs!=NLHS) || (nrhs!=4 && nrhs!=5)){ 27 MergesolutionfromftogUsage(); 28 ISSMERROR(" usage. See above"); 29 } 26 30 27 31 /*Input datasets: */ … … 32 36 33 37 /*!Reduce vector: */ 34 Mergesolutionfromftogx(&ug, uf,Gmn,ys,nodesets); 38 if (nrhs==4){ 39 Mergesolutionfromftogx(&ug, uf,Gmn,ys,nodesets); 40 } 41 else{ 42 FetchData(&flag_ys0,YSFLAG); 43 Mergesolutionfromftogx(&ug, uf,Gmn,ys,nodesets,flag_ys0); 44 } 35 45 36 46 /*write output datasets: */ -
issm/trunk/src/mex/Mergesolutionfromftog/Mergesolutionfromftog.h
r3913 r3960 23 23 #define YS (mxArray*)prhs[2] 24 24 #define NODESETS (mxArray*)prhs[3] 25 #define YSFLAG (mxArray*)prhs[4] 25 26 26 27 /* serial output macros: */ … … 31 32 #define NLHS 1 32 33 #undef NRHS 33 #define NRHS 434 #define NRHS 5 34 35 35 36 #endif /* _MERGESOLUTIONFROMFTOG_H */ -
issm/trunk/src/mex/Reduceloadfromgtof/Reduceloadfromgtof.cpp
r2333 r3960 11 11 12 12 /*input datasets: */ 13 bool flag_ys0; 13 14 Vec pg=NULL; 14 15 Mat Gmn=NULL; … … 24 25 25 26 /*checks on arguments on the matlab side: */ 26 CheckNumMatlabArguments(nlhs,NLHS,nrhs,NRHS,__FUNCT__,&ReduceloadfromgtofUsage); 27 if((nlhs!=NLHS) || (nrhs!=5 && nrhs!=6)){ 28 ReduceloadfromgtofUsage(); 29 ISSMERROR(" usage. See above"); 30 } 27 31 28 32 /*Input datasets: */ … … 34 38 35 39 /*!Reduce load from g to f size: */ 36 Reduceloadfromgtofx(&pf, pg, Gmn, Kfs, ys, nodesets); 40 if (nrhs==5){ 41 Reduceloadfromgtofx(&pf, pg, Gmn, Kfs, ys, nodesets); 42 } 43 else{ 44 FetchData(&flag_ys0,YSFLAG); 45 Reduceloadfromgtofx(&pf, pg, Gmn, Kfs, ys, nodesets,flag_ys0); 46 } 47 37 48 38 49 /*write output datasets: */ -
issm/trunk/src/mex/Reduceloadfromgtof/Reduceloadfromgtof.h
r3913 r3960 24 24 #define YS (mxArray*)prhs[3] 25 25 #define NODESETS (mxArray*)prhs[4] 26 #define YSFLAG (mxArray*)prhs[5] 26 27 27 28 /* serial output macros: */ … … 32 33 #define NLHS 1 33 34 #undef NRHS 34 #define NRHS 535 #define NRHS 6 35 36 36 37 -
issm/trunk/src/mex/Reducevectorgtos/Reducevectorgtos.cpp
r2333 r3960 16 16 /* output datasets: */ 17 17 Vec ys=NULL; 18 Vec ys0=NULL;19 18 20 19 /*Boot module: */ … … 29 28 30 29 /*!Reduce vector: */ 31 Reducevectorgtosx(&ys, &ys0,yg,nodesets);30 Reducevectorgtosx(&ys,yg,nodesets); 32 31 33 32 /*write output datasets: */ 34 33 WriteData(YS,ys); 35 WriteData(YS0,ys0);36 34 37 35 /*Free ressources: */ … … 39 37 VecFree(&yg); 40 38 VecFree(&ys); 41 VecFree(&ys0);42 39 43 40 /*end module: */ … … 48 45 { 49 46 _printf_("\n"); 50 _printf_(" usage: [ys,ys0]= %s(yg,nodesets);\n",__FUNCT__);47 _printf_(" usage: ys = %s(yg,nodesets);\n",__FUNCT__); 51 48 _printf_("\n"); 52 49 } -
issm/trunk/src/mex/Reducevectorgtos/Reducevectorgtos.h
r3913 r3960 24 24 /* serial output macros: */ 25 25 #define YS (mxArray**)&plhs[0] 26 #define YS0 (mxArray**)&plhs[1]27 26 28 27 /* serial arg counts: */ 29 28 #undef NLHS 30 #define NLHS 229 #define NLHS 1 31 30 #undef NRHS 32 31 #define NRHS 2
Note:
See TracChangeset
for help on using the changeset viewer.