diff --git a/AMDiS/src/BoundaryManager.h b/AMDiS/src/BoundaryManager.h index 85fffc2aeaa304cba6f3ebf734965a13f74c3a6c..a923143610d6cb028d1d1acc9229ef515604db37 100644 --- a/AMDiS/src/BoundaryManager.h +++ b/AMDiS/src/BoundaryManager.h @@ -57,7 +57,7 @@ namespace AMDiS { BoundaryType type = localBC->getBoundaryType(); TEST_EXIT(localBCs[type] == NULL) - ("There is already a condition for this type.\n"); + ("There is already a condition for this type %d.\n",type); localBCs[type] = localBC; std::vector<BoundaryCondition*>& boundMap = globalBoundaryMap[type]; diff --git a/AMDiS/src/ElInfo.h b/AMDiS/src/ElInfo.h index f2a44cbe6dbee5ff5d9e3d2c22408a9900390116..26fd4657302daaffa26376f375fd8be38039f251 100644 --- a/AMDiS/src/ElInfo.h +++ b/AMDiS/src/ElInfo.h @@ -417,7 +417,7 @@ namespace AMDiS { * transformation to the reference element. * pure virtual => must be overriden in sub-class. */ - virtual double getNormal(int side, WorldVector<double> &normal) = 0; + virtual double getNormal(int side, WorldVector<double> &normal) const = 0; /** \brief diff --git a/AMDiS/src/ElInfo1d.cc b/AMDiS/src/ElInfo1d.cc index a7cb7d9cae8c0e37fe25b8e7466478b755b566b3..c174e4877b952eb7a1c61216b6e179ace9296ccf 100644 --- a/AMDiS/src/ElInfo1d.cc +++ b/AMDiS/src/ElInfo1d.cc @@ -186,7 +186,7 @@ namespace AMDiS { /* coord; return the absulute value of the determinant from the */ /* transformation to the reference element */ /****************************************************************************/ - double ElInfo1d::getNormal(int side, WorldVector<double> &normal) + double ElInfo1d::getNormal(int side, WorldVector<double> &normal) const { normal = coord[side] - coord[(side + 1) % 2]; double det = norm(&normal); diff --git a/AMDiS/src/ElInfo1d.h b/AMDiS/src/ElInfo1d.h index 7bfefb6e3084283e005e33cc7c6c6e0819463896..dc2ba3e53ee2a664b874255d5cd9cde048f35e4e 100644 --- a/AMDiS/src/ElInfo1d.h +++ b/AMDiS/src/ElInfo1d.h @@ -53,7 +53,7 @@ namespace AMDiS { double calcGrdLambda(DimVec<WorldVector<double> >& grd_lam); /// 1-dimensional realisation of ElInfo's getNormal method. - double getNormal(int side, WorldVector<double> &normal); + double getNormal(int side, WorldVector<double> &normal) const; /// 1-dimensional realisation of ElInfo's getElementNormal method. double getElementNormal( WorldVector<double> &normal) const; diff --git a/AMDiS/src/ElInfo2d.cc b/AMDiS/src/ElInfo2d.cc index 1988a5408762d3d44d04d62c14bd9d7837867645..56dcc741a3e49f1babeba66fe2938c0cef1cb11d 100644 --- a/AMDiS/src/ElInfo2d.cc +++ b/AMDiS/src/ElInfo2d.cc @@ -711,7 +711,7 @@ namespace AMDiS { } - double ElInfo2d::getNormal(int side, WorldVector<double> &normal) + double ElInfo2d::getNormal(int side, WorldVector<double> &normal) const { FUNCNAME("ElInfo::getNormal()"); @@ -722,7 +722,7 @@ namespace AMDiS { normal[0] = coord[i1][1] - coord[i0][1]; normal[1] = coord[i0][0] - coord[i1][0]; } else { // dow == 3 - WorldVector<double> e0, elementNormal; + WorldVector<double> e0, e1, e2, elementNormal; e0 = coord[i1]; e0 -= coord[i0]; diff --git a/AMDiS/src/ElInfo2d.h b/AMDiS/src/ElInfo2d.h index 2187e6d056f4961d49b60bd191074fc7b782a765..8a37387534d7a27ffdc6ccc4c91aa7a77791a86e 100644 --- a/AMDiS/src/ElInfo2d.h +++ b/AMDiS/src/ElInfo2d.h @@ -54,7 +54,7 @@ namespace AMDiS { double calcGrdLambda(DimVec<WorldVector<double> >& grd_lam); /// 2-dimensional realisation of ElInfo's getNormal method. - double getNormal(int side, WorldVector<double> &normal); + double getNormal(int side, WorldVector<double> &normal) const; /// 2-dimensional realisation of ElInfo's getElementNormal method. double getElementNormal(WorldVector<double> &normal) const; diff --git a/AMDiS/src/ElInfo3d.cc b/AMDiS/src/ElInfo3d.cc index 954ce92cff7513e2a39188a3647d1db15a4d2ce1..4be605592eda9865eda581a045813cdcc3a8eaeb 100644 --- a/AMDiS/src/ElInfo3d.cc +++ b/AMDiS/src/ElInfo3d.cc @@ -451,7 +451,7 @@ namespace AMDiS { } - double ElInfo3d::getNormal(int face, WorldVector<double> &normal) + double ElInfo3d::getNormal(int face, WorldVector<double> &normal) const { FUNCNAME("ElInfo3d::getNormal()"); diff --git a/AMDiS/src/ElInfo3d.h b/AMDiS/src/ElInfo3d.h index 1e061d8803b0cc262e96f52ab404250a01da4d86..38327ca1cc65f9d87a67c2f170f18fa9c69a599e 100644 --- a/AMDiS/src/ElInfo3d.h +++ b/AMDiS/src/ElInfo3d.h @@ -66,7 +66,7 @@ namespace AMDiS { double calcGrdLambda(DimVec<WorldVector<double> >& grd_lam); /// 3-dimensional realisation of ElInfo's getNormal method. - double getNormal(int side, WorldVector<double> &normal); + double getNormal(int side, WorldVector<double> &normal) const; /// update ElInfo after refinement (of some neighbours). Only in 3d! void update(); diff --git a/AMDiS/src/Initfile.cc b/AMDiS/src/Initfile.cc index f36c36d604ca77ac30dcba020d1e3fd2ea037a91..ef3e4a8140eab254a37c357482d98284fea69761 100644 --- a/AMDiS/src/Initfile.cc +++ b/AMDiS/src/Initfile.cc @@ -57,7 +57,7 @@ namespace AMDiS { std::ifstream inputFile; inputFile.open(fn.c_str(), std::ios::in); if (!inputFile.is_open()) - throw runtime_error("init-file cannot be opened for reading"); + throw runtime_error("init-file '" + fn + "' cannot be opened for reading"); fn_include_list.insert(fn); read(inputFile); diff --git a/AMDiS/src/reinit/HL_SignedDist.cc b/AMDiS/src/reinit/HL_SignedDist.cc index ce032b5c021925046512fac71bf8a8fdac4a9111..01574eb1742773560524ba275788f3600b1802dc 100644 --- a/AMDiS/src/reinit/HL_SignedDist.cc +++ b/AMDiS/src/reinit/HL_SignedDist.cc @@ -120,8 +120,9 @@ void HL_SignedDist::calcVelocityExt(AdaptInfo *adaptInfo_, TEST_EXIT(velExt)("velExt not defined !\n"); TEST_EXIT(vel_DOF_)("velocity vector vel_DOF_ not defined !\n"); - if (calcSDFct) + if (calcSDFct) { TEST_EXIT(lS_DOF_)("illegal level set function lS_DOF_ !\n"); + } DOFVector<double> *newVel_DOF_ = new DOFVector<double>(vel_DOF_->getFeSpace(), "vel_DOF_"); @@ -194,8 +195,9 @@ void HL_SignedDist::calcVelocityExt(AdaptInfo *adaptInfo_, int nVelDOFs = vel_DOF_.size(); - if (calcSDFct) + if (calcSDFct) { TEST_EXIT(lS_DOF_)("illegal level set function lS_DOF_ !\n"); + } std::vector<DOFVector<double> *> newVel_DOF_(nVelDOFs); for (int nV = 0; nV < nVelDOFs; ++nV) { @@ -275,8 +277,9 @@ void HL_SignedDist::calcVelocityExtFromVelocityField(AdaptInfo *adaptInfo_, TEST_EXIT(velExt)("velExt not defined !\n"); TEST_EXIT(elFct == NULL)("not implemented yet for elFct != NULL !\n"); - if (calcSDFct) + if (calcSDFct) { TEST_EXIT(lS_DOF_)("illegal level set function lS_DOF_ !\n"); + } ((VelocityExtFromVelocityField *)(velExt))->setVelocityField(velField_, lS_DOF_, vel_DOF_);