Some additional information: If I try to compile deal with TrilinosScalar = 
std::complex<double> I get many errors like this:

[  5%] Building CXX object 
[  5%] Building CXX object 
In file included from 
install_dir/dealii/dealii-source/include/deal.II/lac/trilinos_vector.h: In 
member function ‘dealii::TrilinosWrappers::MPI::Vector::value_type* 
error: cannot convert ‘double*’ to 
‘dealii::TrilinosWrappers::MPI::Vector::iterator’ {aka 
‘std::complex<double>*’} in return
 1525 |       return (*vector)[0];

suggesting a hard dependency on double somewhere else.

Pascal Kraft schrieb am Donnerstag, 23. Juli 2020 um 18:42:47 UTC+2:

> Dear Deal.II devs and users,
> In the latest release a lot of (great) work has been done to make complex 
> numbers more of a first-class citizen in deal, which has made my code a lot 
> more readable. Currently, I am stuck with one problem, though. Are there 
> any distributed datatypes for matrices that accept complex numbers?
> The dealii sparse matrix implementation is a template and allows complex 
> numbers - however that implementation has no MPI functionality, which I 
> need.
> The Petsc Sparse Matrix and Trilinos Sparse Matrix are no templates. In 
> the types header I found the declaration of TrilinosScalar as double but 
> changing it and recompiling dealii with the changed header threw an error. 
> I have Trillions compiled with support for complex numbers and also 
> searched through the LinearAlgebra documentation.
> I require GMRES as a solver (which should be possible, because the GMRES 
> Versions all use a templated Vector which can take complex components) and 
> MPI distribution of a sparse system. I have so far only seen FullMatrix to 
> accept complex numbers.
> Can anyone give me a pointer on what is possible?
> Kind regards,
> Pascal Kraft

The deal.II project is located at
For mailing list/forum options, see
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
To view this discussion on the web visit

Reply via email to