Liebe Gitlab-Nutzerin, lieber Gitlab-Nutzer,
es ist nun möglich sich mittels des ZIH-Logins/LDAP an unserem Dienst anzumelden. Die Konten der externen Nutzer:innen sind über den Reiter "Standard" erreichbar.
Die Administratoren

Dear Gitlab user,
it is now possible to log in to our service using the ZIH login/LDAP. The accounts of external users can be accessed via the "Standard" tab.
The administrators

Commit 68fe64e3 authored by Naumann, Andreas's avatar Naumann, Andreas
Browse files

tried extending the meshtest

parent 3e8be011
......@@ -3,9 +3,33 @@
#include "ProblemScal.h"
#include <sstream>
#include <string>
#include <stdexcept>
typedef std::vector< std::string > StringVector ;
template< typename Test >
void require(Test l, Test r, int line, std::string message) {
if(l != r) {
std::stringstream ss;
ss<< "Condition for "<<message<<" is wrong\n";
ss<< "l: "<<l<<"\n"<<"r: "<<r<<"\n";
throw std::runtime_error(ss.str());
template< typename Test >
void require(Test l, Test r, std::string message, StringVector& res) {
if(l != r) {
std::stringstream ss;
ss<< "Condition for "<<message<<" is wrong\n";
ss<< "l: "<<l<<"\n"<<"r: "<<r<<"\n";
using namespace AMDiS;
void testMesh(int dim) {
void testMesh(int dim, int nrEls, int nrVert , StringVector& res) {
std::stringstream ss;
ss<< dim;
Parameters::addGlobalParameter(0, "dimension of world", ss.str());
......@@ -15,6 +39,11 @@ void testMesh(int dim) {
mesh.createDOFAdmin("vertex_dofs", ln_dof);
require(mesh.getDim(), dim, __LINE__, "mesh dimension");
std::stringstream ss2;
ss2<<"\ncurrent dimension: "<<dim<<"\n";
require(mesh.getNumberOfElements() , nrEls, ss2.str() + "number of elements",res);
require(mesh.getNumberOfVertices(), nrVert, ss2.str() + "number of vertices",res);
int main(int argc, char** argv) {
......@@ -23,10 +52,17 @@ int main(int argc, char** argv) {
Parameters::addGlobalParameter(0,"testMesh2->macro file name","macro/macro.stand.2d");
Parameters::addGlobalParameter(0,"testMesh3->macro file name","macro/macro.stand.3d");
StringVector errorMessages;
testMesh(1,1,2, errorMessages);
testMesh(2,4,5, errorMessages);
testMesh(3,6,8, errorMessages);
return 0;
if(errorMessages.size() > 0)
std::cout<<" got errors: \n";
for(StringVector::size_type i=0; i< errorMessages.size();++i)
if (errorMessages.size() != 0)
return 1;
return 0;
......@@ -54,7 +54,7 @@ public:
void buildBeforeCoarsen(AdaptInfo *adaptInfo, Flag flag) {
MSG("calculation of parametric coordinates\n");
int preDOFs = this->getFeSpace()->getAdmin()->getNumberOfPreDOFs(VERTEX);
int preDOFs = this->getFeSpace()->getAdmin()->getNumberOfPreDofs(VERTEX);
int dim = this->getMesh()->getDim();
int dow = Global::getGeo(WORLD);
WorldVector<double> vertexCoords;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment