THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
A new Flyspray task has been opened. Details are below.
User who did this - Christoph GrĂ¼ninger (gruenich)
Attached to Project - DuMuX
Summary - Replace assert by NumericalProblem
Task Type - Bug Report
Category - General
Status - Assigned
Assigned To - Christoph GrĂ¼ninger
Operating System - Unspecified
Severity - Medium
Priority - Normal
Reported Version - SVN
Due in Version - 2.3
Due Date - Undecided
Details - In the Box assembler dumux/implicit/box/boxassembler.hh:306 we have a
test whether all entries are finite. I like the test and it already helped me
finding bugs. Unfortunately it breaks the execution if the test fails. In many
cases it would be better to try a smaller time step.
The following patch would implement this behavior and improve the error message.
Any objections?
Philipp proposed this behavoir when we talked the last time about this topic.
--- dumux/dumux/implicit/box/boxassembler.hh (revision 9943)
+++ dumux/dumux/implicit/box/boxassembler.hh (working copy)
@@ -24,6 +24,7 @@
#ifndef DUMUX_BOX_ASSEMBLER_HH
#define DUMUX_BOX_ASSEMBLER_HH
+#include <dumux/common/exceptions.hh>
#include <dumux/implicit/common/implicitassembler.hh>
#include <dumux/parallel/vertexhandles.hh>
@@ -302,8 +303,12 @@
// update the right hand side
this->residual_[globI] +=
this->model_().localJacobian().residual(i);
- for (int j = 0; j < this->residual_[globI].dimension; ++j)
- assert(std::isfinite(this->residual_[globI][j]));
+ for (int j = 0; j < this->residual_[globI].dimension; ++j) {
+ if (!std::isfinite(this->residual_[globI][j])) {
+ DUNE_THROW(NumericalProblem,
+ \"residual_[\" << globI << \"][\" << j << \" is
not finite\");
+ }
+ }
if (this->enableJacobianRecycling_()) {
this->storageTerm_[globI] +=
this->model_().localJacobian().storageTerm(i);
More information can be found at the following URL:
http://www.dumux.org/flyspray/index.php?do=details&task_id=175
You are receiving this message because you have requested it from the Flyspray
bugtracking system. If you did not expect this message or don't want to
receive mails in future, you can change your notification settings at the URL
shown above.
_______________________________________________
Dumux mailing list
[email protected]
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux