Commit abfaf981 authored by Thomas Witkowski's avatar Thomas Witkowski
Browse files

Small changes in basic demos to make lecture notes consistent.

parent 5ed47991
dimension of world: 2 dimension of world: 2
elliptMesh->macro file name: ./macro/macro.stand.2d elliptMesh->macro file name: ./macro/macro.stand.2d
elliptMesh->global refinements: 10 elliptMesh->global refinements: 0
ellipt->mesh: elliptMesh ellipt->mesh: elliptMesh
ellipt->dim: 2 ellipt->dim: 2
ellipt->components: 1 ellipt->components: 1
ellipt->polynomial degree[0]: 3 ellipt->polynomial degree[0]: 1
ellipt->polynomial degree[1]: 1
ellipt->polynomial degree[2]: 1
ellipt->solver: umfpack ellipt->solver: cg
ellipt->solver->ell: 1
ellipt->solver->max iteration: 1000 ellipt->solver->max iteration: 1000
ellipt->solver->tolerance: 1.e-8 ellipt->solver->tolerance: 1.e-8
ellipt->solver->info: 10 ellipt->solver->info: 10
ellipt->solver->left precon: ilu ellipt->solver->left precon: diag
ellipt->solver->right precon: no ellipt->solver->right precon: no
%ellipt->estimator[0]: residual ellipt->estimator[0]: residual
%ellipt->estimator[0]->error norm: H1_NORM % 1: H1_NORM, 2: L2_NORM ellipt->estimator[0]->error norm: 1 % 1: H1_NORM, 2: L2_NORM
%ellipt->estimator[0]->C0: 0.1 % constant of element residual ellipt->estimator[0]->C0: 0.1 % constant of element residual
%ellipt->estimator[0]->C1: 0.1 % constant of jump residual ellipt->estimator[0]->C1: 0.1 % constant of jump residual
ellipt->marker[0]->strategy: 0 %2 % 0: no adaption 1: GR 2: MS 3: ES 4:GERS ellipt->marker[0]->strategy: 2 % 0: no adaption 1: GR 2: MS 3: ES 4:GERS
ellipt->marker[0]->MSGamma: 0.5
ellipt->adapt[0]->tolerance: 1e-6 ellipt->adapt[0]->tolerance: 1e-4
ellipt->adapt[0]->refine bisections: 2 ellipt->adapt->max iteration: 15
ellipt->adapt->max iteration: 0
ellipt->output->filename: output/ellipt.2d ellipt->output->filename: output/ellipt.2d
ellipt->output->ParaView format: 1 ellipt->output->ParaView format: 1
ellipt->output->ARH format: 1
ellipt->output->AMDiS format: 1
dimension of world: 2 dimension of world: 2
vecelliptMesh->macro file name: ./macro/macro.stand.2d vecelliptMesh->macro file name: ./macro/macro.stand.2d
vecelliptMesh->global refinements: 0 vecelliptMesh->global refinements: 2
vecellipt->mesh: vecelliptMesh vecellipt->mesh: vecelliptMesh
vecellipt->dim: 2 vecellipt->dim: 2
...@@ -30,15 +30,11 @@ vecellipt->marker[1]->strategy: 0 % 0: no adaption 1: GR 2: MS 3: ES ...@@ -30,15 +30,11 @@ vecellipt->marker[1]->strategy: 0 % 0: no adaption 1: GR 2: MS 3: ES
vecellipt->adapt[0]->tolerance: 1e-2 vecellipt->adapt[0]->tolerance: 1e-2
vecellipt->adapt[1]->tolerance: 1e-3 vecellipt->adapt[1]->tolerance: 1e-3
vecellipt->adapt->max iteration: 10 vecellipt->adapt->max iteration: 100
vecellipt->adapt->refine bisections: 2 vecellipt->adapt->refine bisections: 2
vecellipt->output[0]->filename: output/vecellipt0.2d vecellipt->output[0]->filename: output/vecellipt.2d
vecellipt->output[0]->ParaView format: 1 vecellipt->output[0]->ParaView format: 1
vecellipt->output[0]->ARH format: 1
vecellipt->output[0]->AMDiS format: 1
vecellipt->output[1]->filename: output/vecellipt1.2d vecellipt->output[1]->filename: output/vecellipt1.2d
vecellipt->output[1]->ParaView format: 1 vecellipt->output[1]->ParaView format: 1
vecellipt->output[1]->ARH format: 1
vecellipt->output[1]->AMDiS format: 1
...@@ -26,7 +26,7 @@ class F : public AbstractFunction<double, WorldVector<double> > ...@@ -26,7 +26,7 @@ class F : public AbstractFunction<double, WorldVector<double> >
{ {
public: public:
F(int degree) : AbstractFunction<double, WorldVector<double> >(degree) {} F() : AbstractFunction<double, WorldVector<double> >() {}
/// Implementation of AbstractFunction::operator(). /// Implementation of AbstractFunction::operator().
double operator()(const WorldVector<double>& x) const double operator()(const WorldVector<double>& x) const
...@@ -67,9 +67,8 @@ int main(int argc, char* argv[]) ...@@ -67,9 +67,8 @@ int main(int argc, char* argv[])
// ===== create rhs operator ===== // ===== create rhs operator =====
int degree = ellipt.getFeSpace()->getBasisFcts()->getDegree();
Operator rhsOperator(ellipt.getFeSpace()); Operator rhsOperator(ellipt.getFeSpace());
rhsOperator.addTerm(new CoordsAtQP_ZOT(new F(degree))); rhsOperator.addTerm(new CoordsAtQP_ZOT(new F));
ellipt.addVectorOperator(rhsOperator, 0); ellipt.addVectorOperator(rhsOperator, 0);
// ===== add boundary conditions ===== // ===== add boundary conditions =====
...@@ -77,11 +76,7 @@ int main(int argc, char* argv[]) ...@@ -77,11 +76,7 @@ int main(int argc, char* argv[])
// ===== start adaption loop ===== // ===== start adaption loop =====
ptime start_time= microsec_clock::local_time();
adapt.adapt(); adapt.adapt();
time_duration td= microsec_clock::local_time()-start_time;
MSG("elapsed time= %f msec\n", td.total_milliseconds()/1000.0);
ellipt.writeFiles(adaptInfo, true); ellipt.writeFiles(adaptInfo, true);
......
...@@ -22,7 +22,7 @@ public: ...@@ -22,7 +22,7 @@ public:
class F : public AbstractFunction<double, WorldVector<double> > class F : public AbstractFunction<double, WorldVector<double> >
{ {
public: public:
F(int degree) : AbstractFunction<double, WorldVector<double> >(degree) {} F() : AbstractFunction<double, WorldVector<double> >() {}
/// Implementation of AbstractFunction::operator(). /// Implementation of AbstractFunction::operator().
double operator()(const WorldVector<double>& x) const double operator()(const WorldVector<double>& x) const
...@@ -72,9 +72,8 @@ int main(int argc, char* argv[]) ...@@ -72,9 +72,8 @@ int main(int argc, char* argv[])
// ===== create rhs operator ===== // ===== create rhs operator =====
int degree = vecellipt.getFeSpace(0)->getBasisFcts()->getDegree();
Operator rhsOperator0(vecellipt.getFeSpace(0)); Operator rhsOperator0(vecellipt.getFeSpace(0));
rhsOperator0.addTerm(new CoordsAtQP_ZOT(new F(degree))); rhsOperator0.addTerm(new CoordsAtQP_ZOT(new F));
vecellipt.addVectorOperator(rhsOperator0, 0); vecellipt.addVectorOperator(rhsOperator0, 0);
// ===== add boundary conditions ===== // ===== add boundary conditions =====
......
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