<div class="gmail_quote">On Mon, Jul 23, 2012 at 9:18 PM, Nicholas Pezolano <span dir="ltr"><<a href="mailto:npezolano@gmail.com" target="_blank">npezolano@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I am trying to draw random numbers from a complex multivariate mixture distribution needed for a monte carlo simulation.  X:= mu + Lambda.* W + gamma.*sqrt(W) , where they are all NxN dense matrices of equal size  where N ranges from 100,000 to 2,000,000.</blockquote>
<div><br></div><div>Are these really matrices in the sense of linear operators? Are you also doing operations like MatMult or KSPSolve with them? If not, then from PETSc's perspective, these things are vectors and should be stored that way. If you store them as MatDense, you could use MatGetArray.</div>
<div><br></div><div>I assume that you have 100 TB of memory or whatever is required to store these enormous dense beasts?</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
 I need to do the dot product multiplication and addition for every part of this distribution. Would petsc be the right tool for this or should i just stick to C and mpi. I've already used many petsc functions that have made life much eaiser</blockquote>
</div><br>