Skip to content
Snippets Groups Projects
Commit 59547d32 authored by podlesny's avatar podlesny
Browse files

only do 1 iteration step, add debug print

parent d0abcbce
No related branches found
No related tags found
No related merge requests found
...@@ -124,6 +124,8 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run( ...@@ -124,6 +124,8 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run(
Vector total_v; Vector total_v;
nBodyAssembler_.nodalToTransformed(velocityIterates, total_v); nBodyAssembler_.nodalToTransformed(velocityIterates, total_v);
print(velocityIterates, "velocityIterates start:");
for (fixedPointIteration = 0; fixedPointIteration < fixedPointMaxIterations_; for (fixedPointIteration = 0; fixedPointIteration < fixedPointMaxIterations_;
++fixedPointIteration) { ++fixedPointIteration) {
...@@ -148,8 +150,11 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run( ...@@ -148,8 +150,11 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run(
updaters.state_->extractAlpha(newAlpha); updaters.state_->extractAlpha(newAlpha);
nBodyAssembler_.postprocess(total_v, velocityIterates); nBodyAssembler_.postprocess(total_v, velocityIterates);
//Rprint(velocityIterates, "velocityIterates loop:");
updaters.rate_->postProcess(velocityIterates); updaters.rate_->postProcess(velocityIterates);
bool breakCriterion = displacementCriterion(updaters, last_u); //stateCriterion(alpha, newAlpha); bool breakCriterion = true; //displacementCriterion(updaters, last_u); //stateCriterion(alpha, newAlpha);
printRegularityTruncation(globalFriction_, total_v);
if (lambda_ < 1e-12 or breakCriterion) { if (lambda_ < 1e-12 or breakCriterion) {
fixedPointIteration++; fixedPointIteration++;
...@@ -171,6 +176,8 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run( ...@@ -171,6 +176,8 @@ FixedPointIterator<Factory, NBodyAssembler, Updaters, ErrorNorms>::run(
nBodyAssembler_.postprocess(total_v, velocityIterates); nBodyAssembler_.postprocess(total_v, velocityIterates);
updaters.rate_->postProcess(velocityIterates); updaters.rate_->postProcess(velocityIterates);
print(velocityIterates, "velocityIterates end:");
// Cannot use return { fixedPointIteration, multigridIterations }; // Cannot use return { fixedPointIteration, multigridIterations };
// with gcc 4.9.2, see also http://stackoverflow.com/a/37777814/179927 // with gcc 4.9.2, see also http://stackoverflow.com/a/37777814/179927
FixedPointIterationCounter ret; FixedPointIterationCounter ret;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment