Skip to content

Commit 1373845

Browse files
committed
Merge pull request #167 from selmanTerzi/feature/fixes-for-parareal
done bug fixes in interface_impl and sdc_impl
2 parents 32ba0bf + f94e5c7 commit 1373845

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/pfasst/controller/interface_impl.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ namespace pfasst
9797
template<typename time>
9898
void Controller<time>::set_step(size_t n)
9999
{
100-
t += (n - step) * dt;
100+
t += ((int)n - (int)step) * dt;
101101
step = n;
102102
}
103103

src/pfasst/controller/sdc_impl.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ namespace pfasst
2222
void SDC<time>::run()
2323
{
2424
auto sweeper = this->get_level(0);
25-
25+
2626
for (; this->get_time() < this->get_end_time(); this->advance_time()) {
2727
bool initial = this->get_step() == 0;
2828
for (this->set_iteration(0);
@@ -41,7 +41,7 @@ namespace pfasst
4141
}
4242
}
4343
sweeper->post_step();
44-
sweeper->advance();
44+
if(this->get_time() + this->get_time_step() < this->get_end_time()) sweeper->advance();
4545
}
4646
}
4747
} // ::pfasst

0 commit comments

Comments
 (0)