Commit cbf7795c authored by Lukas Riedel's avatar Lukas Riedel

Merge branch '81-output-should-display-the-exact-computed-solution' into 'master'

Resolve "Output should display the exact computed solution"

Closes #81

See merge request !78

(cherry picked from commit 6af502d5)
parent 404d32d7
......@@ -155,18 +155,23 @@ bool Simulation<Traits>::compute_time_step ()
template<typename Traits>
void Simulation<Traits>::run ()
{
const auto t_start = controller->getTime();
output->write_vtk_output(t_start);
output->write_vtk_output(controller->getTime());
while(controller->doStep()) {
const auto time = controller->getTime();
const auto dt = controller->getDT();
if(!compute_time_step()){
continue;
}
if(adaptivity->adapt_grid(*grid, gv, *gfs, *param, *fboundary, time+dt, *uold, *unew)){ // reset operators if grid changes
operator_setup();
}
output->write_vtk_output(controller->getTime());
if(controller->doStep()
&& adaptivity->adapt_grid(*grid, gv, *gfs, *param, *fboundary,
time+dt, // need "old" boundary condition
*uold, *unew))
{
operator_setup(); // reset operators if grid changes
}
}
}
......
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