[Trilinos-Users] PETSc interface

Lucie Freret lfreret at arrow.utias.utoronto.ca
Wed Apr 30 14:46:53 MDT 2014


Hello All,

I try to apply a Trilinos preconditioner (ML) to a PETSc linear system.
As a first test, I consider the example given in EpetraExt package:
http://trilinos.sandia.gov/packages/docs/dev/packages/epetraext/doc/html/epetraext_petsc_cpp.html

Unfortunately, I can't compile it and get some errors (see below).
I have tried with both petsc-3.4.4 and petsc-3.1.3 (and trilinos 11.4)

It is said here  
(http://trilinos.sandia.gov/packages/docs/dev/packages/epetraext/doc/html/epetraext_petsc_interface.html) that the Epetra_PETScAIJMatrix class was first released with Trilinos 9.0 and  
PETSc-2.3.3

Does anyone already tried to use Petsc interface with older versions  
(of Trilinos and/or PETSc) ?

Thanks,
Lucie





epetraext_petsc_cpp(88): error: object of abstract class type  
"Epetra_PETScAIJMatrix" is not
allowed:
              pure virtual function  
"Epetra_RowMatrix::NumGlobalNonzeros64" has no
overrider
              pure virtual function  
"Epetra_RowMatrix::NumGlobalRows64" has no overrider
              pure virtual function  
"Epetra_RowMatrix::NumGlobalCols64" has no overrider
              pure virtual function  
"Epetra_RowMatrix::NumGlobalDiagonals64" has no
overrider
      Epetra_PETScAIJMatrix epA(A);
                            ^
epetraext_petsc_cpp(196): error: argument of type  
"PetscErrorCode={int} (*)(void *, Vec, Vec)" is
incompatible with parameter of
type "PetscErrorCode={int} (*)(PC, Vec, Vec)"
      ierr = PCShellSetApply(pc,ShellApplyML);CHKERRQ(ierr);

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.



More information about the Trilinos-Users mailing list