[dune-fem] Error with MatrixAdapterType and DiscreteCombinedSpace

Sacconi, Andrea a.sacconi11 at imperial.ac.uk
Tue Jul 22 20:38:28 CEST 2014


Hi all,

I'm trying to figure out where I'm wrong in the case that follows.
I need to use the MatrixAdapterType from the ISTL matrix class (the file is: dune/fem/operator/matrix/istlmatrix.hh ).

If I use it with a scalar function space, no problem at all; instead, if I use a CombinedSpace (obtained by appending one scalar and one vector-valued space), problems arise.
To be precise, this is a useful piece of code:

    typedef LagrangeDiscreteFunctionSpace<ContinuosSpaceType,BulkGridPartType,POLORDER> DiscreteSpaceType;
    typedef ISTLBlockVectorDiscreteFunction<DiscreteSpaceType> DiscreteFunctionType;
    typedef ISTLLinearOperator<DiscreteFunctionType,DiscreteFunctionType> LinearOperatorType;
    typedef typename LinearOperatorType::MatrixAdapterType MatrixAdapterType;

    typedef Dune::Fem::CombinedDiscreteFunctionSpace < DiscreteSpaceType , DiscreteSpaceType > CombinedDiscreteSpaceType;
    typedef ISTLBlockVectorDiscreteFunction<CombinedDiscreteSpaceType> CombinedDiscreteFunctionType;
    typedef ISTLLinearOperator<CombinedDiscreteFunctionType,CombinedDiscreteFunctionType> CombinedLinearOperatorType;
    typedef typename CombinedLinearOperatorType::MatrixAdapterType CombinedMatrixAdapterType;

The errors returned by the compiler are the following:
/usr/local_machine/dune-2.3.1/dune-fem-1.4.0/dune/fem/operator/matrix/istlmatrix.hh:475:84: error: invalid use of incomplete type ‘class Dune::Fem::ISTLParallelMatrixAdapter
/usr/local_machine/dune-2.3.1/dune-fem-1.4.0/dune/fem/operator/matrix/istlmatrixadapter.hh:365:11: error: declaration of ‘class Dune::Fem::ISTLParallelMatrixAdapter

What am I doing wrong? I guess it's related to definitions vs. declarations with templates, but I can't figure out why, since I'm just changing the space on which my ISTL matrix will be built.

Thanks a lot!
Andrea
__________________________________________________________

Andrea Sacconi
PhD student, Applied Mathematics
AMMP Section, Department of Mathematics, Imperial College London,
London SW7 2AZ, UK
a.sacconi11 at imperial.ac.uk




More information about the dune-fem mailing list