<div dir="ltr"><div dir="ltr">On Wed, Jan 14, 2026 at 12:13 PM Micol Bassanini via petsc-users <<a href="mailto:petsc-users@mcs.anl.gov">petsc-users@mcs.anl.gov</a>> wrote:</div><div class="gmail_quote gmail_quote_container"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="msg-6619090627653650104">




<div dir="ltr">
<div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Dear User Support Team,</div>
<div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
I have a question regarding my project.</div>
<div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
I would like to compute a matrix product between a DMDA matrix that is distributed across multiple ranks and a dense matrix that is available on only a single processor. What is the recommended or standard approach for implementing this kind of operation?</div>
<div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
</div></div></div></blockquote><div>It sounds like you should distribute your dense matrix. You might do it using MatSetValues(), or MatCreateSubmatrix().</div><div><br></div><div>  Thanks,</div><div><br></div><div>     Matt </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="msg-6619090627653650104"><div dir="ltr"><div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">Thank you in advance for your help.</div>
<div style="text-align:left;text-indent:0px;margin-top:1em;margin-bottom:1em;font-family:Aptos,Aptos_EmbeddedFont,Aptos_MSFontService,Calibri,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Best regards,<br>
Micol</div>
</div>

</div></blockquote></div><div><br clear="all"></div><div><br></div><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div>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><br></div><div><a href="https://urldefense.us/v3/__http://www.cse.buffalo.edu/*knepley/__;fg!!G_uCfscf7eWS!d6GQrZ5VUzxJEZ4hXZgXG8TrQNNtN-ZE3lm4bZVNzzLNU388FLqczz7lHcXEKa2F8LI0nctKw_i09T6PUbnU$" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div></div></div>