[Trilinos-Users] Problem with EpetraExt::MatrixMatrix::Multiply

Williams, Alan B william at sandia.gov
Wed Sep 2 14:44:44 MDT 2009


If I understand what you're doing, it looks like you load the laplace_2d matrix into 'I', and then form the identity matrix in 'D'.
Then your call to MatrixMatrix::Multiply should produce B_jor == 'I' == laplace_2dmatrix.
Is that not what's happening?

Alan


From: trilinos-users-bounces at software.sandia.gov [mailto:trilinos-users-bounces at software.sandia.gov] On Behalf Of bender calculon
Sent: Tuesday, September 01, 2009 2:18 PM
To: trilinos-users at software.sandia.gov
Subject: [Trilinos-Users] Problem with EpetraExt::MatrixMatrix::Multiply

Hi,

I think that my problem is very simple but I don't find the way to resolve it.

When I use

EpetraExt::MatrixMatrix::Multiply(D,false,I,false,B_jor);

[for example D = diagonal matrix, I = sparse matrix ]

in B_jor i don't have an identity matrix but only the first element equal to one. So i think that i have some problem whit EpetraExt::MatrixMatrix::Multiply.


The matrix I is generate by

Trilinos_Util::CrsMatrixGallery Matrix(CLP.Get("-problem", "laplace_2d"), Comm);
Epetra_CrsMatrix I = Matrix.GetMatrixRef();
Epetra_Map Map = Matrice.GetMapRef();

and the matrix D by

Epetra_CrsMatrix D(I);
Epetra_Vector Diag(Map);
D.PutScalar(0);
I.ExtractDiagonalCopy (Diag);
Diag.Reciprocal(Diag);
D.ReplaceDiagonalValues(Diag);

Thanks

Mau
________________________________
Doretta Doretta ti "cerca"! Vieni a trovarla sul suo Spaces!<http://doretta82live.spaces.live.com/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://software.sandia.gov/pipermail/trilinos-users/attachments/20090902/bca07c01/attachment.html 


More information about the Trilinos-Users mailing list