On Fri, May 25, 2012 at 9:49 AM, Jed Brown <jedbrown at mcs.anl.gov> wrote:
> No, its not okay. > > I think MatGetArray needs to be removed. Pretty much any use of it is > wrong. It is not even the right thing for dense matrices because they > should be distributed differently than PETSc does now. > Without it, people cannot get directly to the AIJ data structure. No matter how wrong it is, it is a constant request. I would keep it in just to satisfy that large number of petsc-maints. Matt > On May 25, 2012 8:44 AM, "Hui Zhang" <mike.hui.zhang at hotmail.com> wrote: > >> A new question: can I use MatSetValues in the following way? >> >> MatGetArray(A,&a); >> a[0]= 1; >> MatSetValues(A,...); /* in particular, is this allowed inside >> GetArray/RestoreArray? */ >> MatRestoreArray(A,&a); >> >> Thanks! >> Hui >> >> On May 14, 2012, at 2:29 PM, Barry Smith wrote: >> >> > >> > If B is 50% dense then store it in a dense format. It will be much >> faster and the extra memory is minimal. Even 30% dense. >> > >> > Barry >> > >> > On May 14, 2012, at 5:13 AM, Hui Zhang wrote: >> > >> >> I have two matrices A and B stored in sparse format. While A is >> really sparse, B is relatively >> >> dense (say non-zeros entries about 50%). Now to multiply the two >> matrices, among >> >> >> >> A*B >> >> or >> >> (B^T * A^T)^T >> >> >> >> which is better, or no big difference ? >> >> >> >> Thanks! >> >> >> > >> > >> >> -- What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead. -- Norbert Wiener -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20120525/f3b2f68a/attachment.html>
