Changeset 25380
- Timestamp:
- 08/11/20 20:10:30 (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/bamg/BamgOpts.cpp
r24113 r25380 50 50 void BamgOpts::Check(void){/*{{{*/ 51 51 52 int i; 52 if(this->anisomax<1) _error_("'anisomax' option should be >=1"); 53 if(this->coeff==0) _error_("'coeff' should be positive"); 54 if(this->errg<0) _error_("'errg' option should be >0"); 55 if(this->gradation<1) _error_("'gradation' option should be >=1"); 56 if(this->Hessiantype!=0 && this->Hessiantype!=1) _error_("'Hessiantype' supported options are 0 and 1"); 57 if(this->maxnbv<3) _error_("'maxnbv' option should be >3"); 58 if(this->maxsubdiv<=1) _error_("'maxsubdiv' should be >1"); 59 if(this->Metrictype!=0 && this->Metrictype!=1 && this->Metrictype!=2) _error_("'Metrictype' supported options are 0, 1 and 2"); 60 if(this->nbjacobi<=0) _error_("'nbjacobi' option should be >0"); 61 if(this->nbsmooth<=0) _error_("'nbsmooth' option should be >0"); 53 62 54 if (this->anisomax<1) _error_("'anisomax' option should be >=1"); 55 if (this->coeff==0) _error_("'coeff' should be positive"); 56 if (this->errg<0) _error_("'errg' option should be >0"); 57 if (this->gradation<1) _error_("'gradation' option should be >=1"); 58 if (this->Hessiantype!=0 && this->Hessiantype!=1) _error_("'Hessiantype' supported options are 0 and 1"); 59 if (this->maxnbv<3) _error_("'maxnbv' option should be >3"); 60 if (this->maxsubdiv<=1) _error_("'maxsubdiv' should be >1"); 61 if (this->Metrictype!=0 && this->Metrictype!=1 && this->Metrictype!=2) _error_("'Metrictype' supported options are 0, 1 and 2"); 62 if (this->nbjacobi<=0) _error_("'nbjacobi' option should be >0"); 63 if (this->nbsmooth<=0) _error_("'nbsmooth' option should be >0"); 63 if(this->Crack!=0 && this->Crack!=1) _error_("'Crack' supported options are 0 and 1"); 64 if(this->KeepVertices!=0 && this->KeepVertices!=1) _error_("'KeepVertices' supported options are 0 and 1"); 64 65 65 if (this->Crack!=0 && this->Crack!=1) _error_("'Crack' supported options are 0 and 1"); 66 if (this->KeepVertices!=0 && this->KeepVertices!=1) _error_("'KeepVertices' supported options are 0 and 1"); 67 68 if (this->hmin<=0) _error_("'hmin' option should be >0"); 69 if (this->hmax<=0 || this->hmax<this->hmin) _error_("'hmax' option should be between 0 and hmin=" << this->hmin); 70 if (this->hminVertices && this->hminVerticesSize[1]!=1) _error_("'hminVertices' should be a column"); 71 if (this->hmaxVertices && this->hmaxVerticesSize[1]!=1) _error_("'hmaxVertices' should be a column"); 72 if (this->hVertices && this->hVerticesLength<2) _error_("'hVertices' should be a vector"); 73 if (this->metric && (this->metricSize[1]!=1 && this->metricSize[1]!=3)) _error_("'metric' should have either 1 (iso) or 3 (aniso) columns."); 74 if (this->field){ 75 if (this->errSize[0]!=1 || this->errSize[1]!=this->fieldSize[1]) _error_("'err' should be of size " << 1 << " x " << this->fieldSize[1]); 76 for (i=0;i<this->fieldSize[1];i++) {if (this->err[i]<=0) _error_("'err' option should be >0");}; 66 if(this->hmin<=0) _error_("'hmin' option should be >0"); 67 if(this->hmax<=0 || this->hmax<this->hmin) _error_("'hmax' option should be between 0 and hmin=" << this->hmin); 68 if(this->hminVertices && this->hminVerticesSize[1]!=1) _error_("'hminVertices' should be a column"); 69 if(this->hmaxVertices && this->hmaxVerticesSize[1]!=1) _error_("'hmaxVertices' should be a column"); 70 if(this->hVertices && this->hVerticesLength<2) _error_("'hVertices' should be a vector"); 71 if(this->metric && (this->metricSize[1]!=1 && this->metricSize[1]!=3)) _error_("'metric' should have either 1 (iso) or 3 (aniso) columns."); 72 if(this->field){ 73 if(this->errSize[1]!=this->fieldSize[1]) _error_("'err' should have "<< this->fieldSize[1]<<" columns"); 74 for(int i=0;i<this->fieldSize[1];i++){if (this->err[i]<=0) _error_("'err' option should be >0");}; 77 75 } 78 76
Note:
See TracChangeset
for help on using the changeset viewer.