Sorry, I totally forgotten about types:

typedef LinearAlgebra::distributed::Vector<LevelNumber> LevelVectorType;
SolverCG<LevelVectorType> solver(solver_control);
std::vector<PreconditionMG<dim, LevelVectorType,
  MGTransferMatrixFree<dim,LevelNumber>  >  > SCPreconditionMGs;



W dniu sobota, 17 lutego 2018 06:32:07 UTC+1 użytkownik Matthias Maier 
napisał:
>
> Hi Michał, 
>
> It would be helpful if you could sent us a small, minimal example that 
> shows the problem (in particular, what type is "LevelVectorType" and 
> "SCPreconditoinMGs", "solver"). 
> The example should be as short as possible and doesn't need to be 
> functional / or do anything at all - we essentially only need to be able 
> to figure out the types you try to wrap into the linear_operator object. 
>
> Best, 
> Matthias 
>
>
> On Tue, Feb 13, 2018, at 12:47 CST, Michał Wichrowski <[email protected] 
> <javascript:>> wrote: 
>
> > Dear all, 
> > I'm trying to use iterative inverse with distributed deal.II vector. 
> From 
> > following lines 
> > 
> > const auto S    = linear_operator<LevelVectorType> 
> (mg_sc_matrices[level]); 
> > const auto Shat = 
> > inverse_operator<LevelVectorType>(S,solver,SCPreconditionMGs[level]); 
> > 
> >  I get compilation errors: 
> > 
> > 
> > /home/mwichro/lib/deal.II/include/deal.II/lac/linear_operator.h:678:1: 
> > note: candidate: template<class Payload, class Solver, class 
> > Preconditioner, class Range, class Domain> 
> dealii::LinearOperator<Domain, 
> > Range, Payload> dealii::inverse_operator(const 
> > dealii::LinearOperator<Range, Domain, Payload>&, Solver&, const 
> > Preconditioner&) 
> >  inverse_operator(const LinearOperator<Range, Domain, Payload> &op, 
> >  ^ 
> > /home/mwichro/lib/deal.II/include/deal.II/lac/linear_operator.h:678:1: 
> > note:   template argument deduction/substitution failed: 
> > 
> /home/mwichro/deal-ii-projects/StokeMatrixFree/StokesMatrixFree.cc:1051:55: 
> > note:   mismatched types 
> > ‘dealii::LinearAlgebra::distributed::Vector<double>’ and 
> > ‘dealii::internal::LinearOperator::EmptyPayload’ 
> >     const auto Shat = 
> > inverse_operator<LevelVectorType>(S,solver,SCPreconditionMGs[level]); 
> >                                                        ^ 
> > 
> /home/mwichro/deal-ii-projects/StokeMatrixFree/StokesMatrixFree.cc:1051:55: 
> > note:   ‘const 
> > 
> dealii::LinearOperator<dealii::LinearAlgebra::distributed::Vector<double>, 
> > dealii::LinearAlgebra::distributed::Vector<double>, 
> > dealii::internal::LinearOperator::EmptyPayload>’ is not derived from 
> ‘const 
> > dealii::LinearOperator<Range, Domain, 
> > dealii::LinearAlgebra::distributed::Vector<double> >’ 
> > CMakeFiles/StokesMatrixFree.dir/build.make:62: recipe for target 
> > 'CMakeFiles/StokesMatrixFree.dir/StokesMatrixFree.cc.o' failed 
> > make[2]: *** [CMakeFiles/StokesMatrixFree.dir/StokesMatrixFree.cc.o] 
> Error 1 
> > 
> > 
> > I think that proper Payload is needed, but I didn't found right one. 
> > 
> > Michał 
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
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 [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to