<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Jan 28, 2014 at 5:25 PM, Tabrez Ali <span dir="ltr"><<a href="mailto:stali@geology.wisc.edu" target="_blank">stali@geology.wisc.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello<br>
<br>
This is my observation as well (with MUMPS). The first solve (after assembly which is super fast) takes a few mins (for ~1 million unknowns on 12/24 cores) but from then on only a few seconds for each subsequent solve for each time step.<br>
<br>
Perhaps symbolic factorization in MUMPS is all serial?<br></blockquote><div><br></div><div>Yes, it is.</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Like the OP I often do multiple runs on the same problem but I dont know if MUMPS or any other direct solver can save the symbolic factorization info to a file that perhaps can be utilized in subsequent reruns to avoid the costly "first solves".<br>
<br>
Tabrez<div class="HOEnZb"><div class="h5"><br>
<br>
On 01/28/2014 04:04 PM, Barry Smith wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Jan 28, 2014, at 1:36 PM, David Liu<<a href="mailto:daveliu@mit.edu" target="_blank">daveliu@mit.edu</a>> wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi, I'm writing an application that solves a sparse matrix many times using Pastix. I notice that the first solves takes a very long time,<br>
</blockquote>
Is it the first “solve” or the first time you put values into that matrix that “takes a long time”? If you are not properly preallocating the matrix then the initial setting of values will be slow and waste memory. See <a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatXAIJSetPreallocation.html" target="_blank">http://www.mcs.anl.gov/petsc/<u></u>petsc-current/docs/<u></u>manualpages/Mat/<u></u>MatXAIJSetPreallocation.html</a><br>
<br>
The symbolic factorization is usually much faster than a numeric factorization so that is not the cause of the slow “first solve”.<br>
<br>
Barry<br>
<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
while the subsequent solves are very fast. I don't fully understand what's going on behind the curtains, but I'm guessing it's because the very first solve has to read in the non-zero structure for the LU factorization, while the subsequent solves are faster because the nonzero structure doesn't change.<br>
<br>
My question is, is there any way to save the information obtained from the very first solve, so that the next time I run the application, the very first solve can be fast too (provided that I still have the same nonzero structure)?<br>
</blockquote></blockquote>
<br>
<br></div></div><span class="HOEnZb"><font color="#888888">
-- <br>
No one trusts a model except the one who wrote it; Everyone trusts an observation except the one who made it- Harlow Shapley<br>
<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener
</div></div>