Skip to content
Snippets Groups Projects
Commit 82476058 authored by Jö Fahlke's avatar Jö Fahlke
Browse files

[solvers.hh] Always convert the reduction to double explicitly.

This already happened for most solvers when setting the reduction in the
result struct.  It is may be needed when the field type is some extended
number type that prohibits implicit conversion to `double`.  This commit
brings the remaining two solvers in line that did not do this yet.
parent ba9e6e7f
Branches
Tags
1 merge request!138[solvers.hh] Always convert the reduction to double explicitly.
Pipeline #
......@@ -127,7 +127,7 @@ namespace Dune {
// fill statistics
res.iterations = i;
res.reduction = max_value(def/def0);
res.reduction = static_cast<double>(max_value(def/def0));
res.conv_rate = pow(res.reduction,1.0/i);
res.elapsed = watch.elapsed();
......@@ -1512,7 +1512,7 @@ namespace Dune {
// fill statistics
res.iterations = i;
res.reduction = max_value(def/def0);
res.reduction = static_cast<double>(max_value(def/def0));
res.conv_rate = pow(res.reduction,1.0/i);
res.elapsed = watch.elapsed();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment