#1622 issue with field_type is std::complex
Metadata
Property | Value |
---|---|
Reported by | Andreas Dedner (A.S.Dedner@warwick.ac.uk) |
Reported at | Apr 20, 2015 11:54 |
Type | Bug Report |
Version | 2.3 |
Operating System | Unspecified / All |
Last edited by | Andreas Dedner (A.S.Dedner@warwick.ac.uk) |
Last edited at | Jun 10, 2015 14:21 |
Closed by | Andreas Dedner (A.S.Dedner@warwick.ac.uk) |
Closed at | Jun 10, 2015 14:21 |
Closed in version | Unknown |
Resolution | Implemented |
Comment |
Description
Using complex numbers fails for some of the dune-istl solvers.
- amg: the aggregate uses field_type to store the max value instead of real_type
- ilu: at one point some cast into int is performed int generation = (int) firstmatrixelement(*kj); This cast is not available for std::complex
I attached a possible fix which allows me to run my code again mostly using std::abs to convert from field_type to real_type. But I'm not quite sure if that is always the right way to fix this.