<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, May 15, 2015 at 4:43 PM, Sanjay Kharche <span dir="ltr"><<a href="mailto:Sanjay.Kharche@manchester.ac.uk" target="_blank">Sanjay.Kharche@manchester.ac.uk</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
Dear All<br>
<br>
When I put in my convection terms, my solution is not well behaved. Following is an elaboration. I am wondering if I missed something in Petsc.<br>
<br>
I am solving the 3D heat equation with convection terms using second order finite differences and the boundary conditions are 1st order. It is solved on an uneven geometry defined inside a box, where a voltage variable diffuses. I am using a ts solver. The 3D DMDA vector uses a star stencil (I have also tried the box stencil). I assign the RHS at FD nodes where there is geometry. I get a stable solution if I do not have convection terms. However, when I use the convection terms, an error seems to build up. Eventually, the non-geometry part of the box also starts having a non-zero voltage. I checked my FD scheme for errors in terms. I also tested it out on a non-petsc explicit solver. The scheme is correctly written in the RHS function. The explicit solver is stable for the integration parameters I am using. Can you suggest what could be missing in terms of Petsc or otherwise?<br></blockquote><div><br></div><div>Use the Method of Manufactured Solutions to check your residual function.</div><div><br></div><div> Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
cheers<br>
<span class="HOEnZb"><font color="#888888">Sanjay<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">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></div>