<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style id="owaParaStyle" type="text/css">P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">Hi Hong,<br>
<br>
Thank you! From <font size="2"><span style="font-size:10pt;">Barry's email, </span>
</font>I have learned that PETSc aims at sparse matrix. Therefore, I may consider using MatGetArray() for further parallel calculations, or using Elemental/PLAPACK for dense matrix calculations. I notice PETSc could use PLAPACK, but if I understand correctly,
that has only been implemented for LU, Cholesky decomposition, not matrix-matrix multiplications (although it looks to be simple).<br>
<br>
As regards my question, I am sorry that I need<br>
<br>
<div><span class="Apple-style-span" style="font-family: Tahoma; font-size: 14px;"><span class="Apple-style-span" style="font-family: arial; font-size: small;"><font class="Apple-style-span" face="Tahoma">C_seqdense =</font> <span class="Apple-style-span" style="font-family: Tahoma; font-size: 14px;">A_seqdense*B_seqdense^T<br>
</span></span></span>
<div><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px"><span class="Apple-style-span" style="font-family:arial; font-size:small"><font class="Apple-style-span" face="Tahoma">C_seqdense =</font> <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A_seqdense^T*B_seqdense<br>
<br>
for the time being, not aij format.<br>
<br>
Cheers<br>
<br>
Gao</span></span></span><br>
</div>
</div>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div style="direction: ltr;" id="divRpF646981"><font color="#000000" face="Tahoma" size="2"><b>From:</b> Hong Zhang [hzhang@mcs.anl.gov]<br>
<b>Sent:</b> Thursday, April 05, 2012 4:30 PM<br>
<b>To:</b> Gao Bin<br>
<b>Cc:</b> PETSc users list<br>
<b>Subject:</b> Re: [petsc-users] question about MatMatMultTranspose<br>
</font><br>
</div>
<div></div>
<div>Bin :
<div>We do not have plan for supporting parallel (mpiaij format)
<div>C = <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A*B^T</span></div>
<div><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">because sparse inner product is too expensive, and we have parallel C = A^T*B.</span></div>
<div><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px"><br>
</span></div>
<div><font class="Apple-style-span" face="Tahoma">For sequential </font>C = <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A*B^T, currently we only support </span></div>
<div><font class="Apple-style-span" face="Tahoma"><span class="Apple-style-span" style="font-family:arial">C_seqaij = <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A_seqaij*B_seqaij^T</span></span></font></div>
<div><font class="Apple-style-span" face="Tahoma"><span class="Apple-style-span" style="font-family:arial"><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px"><br>
</span></span></font></div>
<div><font class="Apple-style-span" face="Tahoma">Do you want </font></div>
<div><font class="Apple-style-span" face="Tahoma">C_seqdense =</font> <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A_seqaij*B_seqaij^T</span></div>
<div><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">or </span></div>
<div><span class="Apple-style-span" style="font-family:Tahoma; font-size:14px"><span class="Apple-style-span" style="font-family:arial; font-size:small"><font class="Apple-style-span" face="Tahoma">C_seqdense =</font> <span class="Apple-style-span" style="font-family:Tahoma; font-size:14px">A_seqaij*B_seqdense^T?</span></span></span></div>
<div><font class="Apple-style-span" face="Tahoma"><br>
</font></div>
<div><font class="Apple-style-span" face="Tahoma">Hong</font></div>
<div>
<div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div>
<div style="direction:ltr; font-size:10pt; font-family:Tahoma"><br>
Good to know it is simpler ;-) I am switching to the developed version and try it. Again, thank you very much.<br>
<br>
P.S., Moreover, I notice that some functions is not for MATMPIDENSE. May I ask if they are too difficult to implement (for instance, C=A*B^T and C=A^T*B for MATMPIDENSE)? Thank you.<br>
<br>
Cheers<br>
<br>
Gao<br>
<div style="font-size:16px; font-family:Times New Roman">
<hr>
<div style="direction:ltr"><font color="#000000" face="Tahoma">
<div class="im"><b>From:</b> <a href="mailto:petsc-users-bounces@mcs.anl.gov" target="_blank">
petsc-users-bounces@mcs.anl.gov</a> [<a href="mailto:petsc-users-bounces@mcs.anl.gov" target="_blank">petsc-users-bounces@mcs.anl.gov</a>] on behalf of Jed Brown [<a href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>]<br>
</div>
<b>Sent:</b> Thursday, April 05, 2012 2:32 PM<br>
<b>To:</b> PETSc users list; Hong Zhang
<div class="im"><br>
<b>Subject:</b> Re: [petsc-users] question about MatMatMultTranspose<br>
</div>
</font><br>
</div>
<div>
<div class="h5">
<div></div>
<div>
<div class="gmail_quote">On Thu, Apr 5, 2012 at 05:16, Gao Bin <span dir="ltr"><<a href="mailto:bin.gao@uit.no" target="_blank">bin.gao@uit.no</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div style="direction:ltr; font-size:10pt; font-family:Tahoma">Thank you for your quick reply. But as pointed out at
<a href="http://www.mcs.anl.gov/petsc/petsc-dev/docs/manualpages/Mat/MatMatTransposeMult.html" target="_blank">
http://www.mcs.anl.gov/petsc/petsc-dev/docs/manualpages/Mat/MatMatTransposeMult.html</a>:<br>
<br>
This routine is currently only implemented for pairs of SeqAIJ matrices. C will be of type MATSEQAIJ.<br>
<br>
Therefore I can not use it for dense matrix, am I right? If so, will MatMatTransposeMult be extended for other types of matrix later on? Thank you very much.</div>
</blockquote>
</div>
<br>
<div>This is much simpler than the sparse case. Hong, did you intend to get around to this?</div>
</div>
</div>
</div>
</div>
</div>
</div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
</div>
</body>
</html>