<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Sat, Oct 27, 2018 at 2:02 AM Fengwen Wang <<a href="mailto:fwan@mek.dtu.dk">fwan@mek.dtu.dk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">




<div dir="ltr">
<div id="m_-2269199865122680712divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif" dir="ltr">
<p>Dear Colleagues,</p>
<p><br>
</p>
<p>I use the finite element method to solve my problem in Petsc.</p>
<p><br>
</p>
<p>Mesh is defined as a  regular mesh using DMDA.  I have a special boundary condition which I  do not know how to impose it in Petsc.
<br>
</p>
<p><br>
</p>
<p>In a 2D problem, the domain is unit size, two degrees of freedom per node (u, v). I would like impose the following boundary condition:</p>
<p><br>
</p>
<p>u(x=1) = -v ( y=1) and v(x=1 )= -u (y=1) .</p>
<p><br>
</p>
<p>How can I impose such a boundary condition in Petsc?  </p></div></div></blockquote><div>In a serial code, you could do this just by equating those variables, but in parallel we have no support for such a boundary condition.</div><div><br></div><div>  Thanks,</div><div><br></div><div>     Matt</div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div id="m_-2269199865122680712divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif" dir="ltr">
<p>Thanks a lot. <br>
</p>
<p><br>
</p>
<p>Best regards</p>
<p>Fengwen<br>
</p>
<p><br>
</p>
<p><br>
</p>
<div id="m_-2269199865122680712Signature">
<div style="font-family:Tahoma;font-size:13px">
<div style="font-family:Tahoma;font-size:13px">
<div class="m_-2269199865122680712BodyFragment"><font size="2">
<div class="m_-2269199865122680712PlainText">____________________________________________________<br>
Senior Researcher<br>
Department of Mechanical Engineering, DTU<br>
Nils Koppels Allé       <br>
Building 404    <br>
2800  Kgs. Lyngby <br>
<a href="mailto:fwan@mek.dtu.dk" target="_blank">fwan@mek.dtu.dk</a></div>
</font></div>
</div>
</div>
</div>
</div>
</div>

</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="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="http://www.cse.buffalo.edu/~knepley/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div></div></div>