<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On 12 February 2016 at 19:16, Bhalla, Amneet Pal S <span dir="ltr"><<a href="mailto:amneetb@live.unc.edu" target="_blank">amneetb@live.unc.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div style="word-wrap:break-word">
Hi Folks,
<div><br>
</div>
<div>I want to extract the CSR format from PETSc matrices and ship it to CUDA. Is there an easy way of doing this?</div></div></blockquote><div><br></div><div>Yep, see these web pages<br><br><a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatGetRowIJ.html">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatGetRowIJ.html</a><br><br><a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatGetColumnIJ.html">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatGetColumnIJ.html</a><br><br><a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatSeqAIJGetArray.html">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Mat/MatSeqAIJGetArray.html</a><br><br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word">
<div>If so is there an example/source code showing this extraction? </div></div></blockquote><div><br></div><div>Not that I know of. <br>But there isn't much to it, the description on these webpages should be sufficient.<br><br></div><div>Thanks,<br></div><div> Dave<br></div><div><br> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="word-wrap:break-word">
<div><br>
</div>
<div>Thanks,</div>
<div><br>
<div>
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div style="color:rgb(0,0,0);letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;word-wrap:break-word">
<div>— Amneet </div>
<div><br>
</div>
</div>
</div>
</div>
</div>
<br>
</div>
</div>
</blockquote></div><br></div></div>