<html><head></head><body><div class="yahoo-style-wrap" style="font-family:Helvetica Neue, Helvetica, Arial, sans-serif;font-size:16px;"><div dir="ltr" data-setdir="false">Dear developers</div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false">I tried to run ex24.c <a href="https://petsc.org/release/src/snes/tutorials/ex24.c.html" rel="nofollow" target="_blank">https://petsc.org/release/src/snes/tutorials/ex24.c.html</a> using the following command line</div><div dir="ltr" data-setdir="false"><span><br></span></div><div dir="ltr" data-setdir="false"><span>./ex24 -sol_type quadratic -dm_plex_simplex 0 -field_petscspace_degree 1 -potential_petscspace_degree 1 -dm_plex_box_faces 2,1</span></div><div dir="ltr" data-setdir="false"><span><br></span></div><div dir="ltr" data-setdir="false"><span>I discovered that at<br></span></div><div dir="ltr" data-setdir="false"><span><span><pre width="80">254: <a href="https://petsc.org/release/manualpages/Sys/PetscCall/" rel="nofollow" target="_blank">PetscCall</a>(PetscWeakFormSetIndexBdResidual(wf, label, 1, 0, 0, 0, f0_bd_quadratic_q, 0, NULL));</pre></span></span><div> reverses the value of the integrals at the top only. That is</div></div><div dir="ltr" data-setdir="false">The boundary integral corresponding to node 5 becomes that of 4 and vise-versa. <br></div><div dir="ltr" data-setdir="false">Same thing for nodes 5 and 6.</div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false">The mesh index is as follows<br></div><div dir="ltr" data-setdir="false">*4---*5---*6<br></div><div dir="ltr" data-setdir="false"> | | |<br></div><div dir="ltr" data-setdir="false"> | | |</div><div dir="ltr" data-setdir="false">*1--- *2---*3</div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false">However, if I use <span><span>-dm_plex_simplex 1 there is no problem.</span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div><div dir="ltr" data-setdir="false"><span><span>The model is in the form Au = b</span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div><div dir="ltr" data-setdir="false"><span><span>the value of b with <span> <span><span>"-dm_plex_simplex 0" is</span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><div>[0.25<br>0.0104167<br>0.<br>0.<br>0.145833<br>0.<br>-0.583333<br>0.177083<br>0.<br>0.0833333<br>-0.28125<br>0.<br>0.<br>-0.6875<br>0.<br>-0.75<br>-0.364583<br><div>0.]</div><div><br></div><div dir="ltr" data-setdir="false">and for <span><span><span><span><span><span>-dm_plex_simplex 1</span></span></span></span></span></span><br></div><div dir="ltr" data-setdir="false"><div>[0.0833333<br>0.0104167<br>0.<br>0.<br>0.145833<br>0.<br>-0.583333<br>0.177083<br>0.<br>0.25<br>-0.260417<br>0.<br>1.43404e-16<br>-0.645833<br>0.<br>-0.75<br>-0.427083<br>0.]<br><br></div><div dir="ltr" data-setdir="false">you can see that the value at node 1 =0.25 and node 4 = <span><span><span><span><span>0.0833333 ( simplex 0)<br></span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span>which is reversed, that is, <span><span><span><span><span>node 4 =0.25 and node 1 = <span><span><span><span><span>0.0833333</span></span></span></span></span></span></span></span></span></span> (simplex 1)<br></span></span></span></span></span></div></div><div dir="ltr" data-setdir="false"><br></div><div dir="ltr" data-setdir="false">So, my own calculation shows that at node 1 should be 0.083333 not 0.25.</div><div dir="ltr" data-setdir="false">The -dm_plex_simplex 1 gives the correct answer but <span><span><span><span><span>-dm_plex_simplex 0 gives wrong answer.</span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span><br></span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span><br></span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span>Would you please help me in this matter. </span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span>Sincerely yours</span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span>Azeddine M</span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><span><span><span> </span></span></span></span></span><br></div><div dir="ltr" data-setdir="false"> <br></div></div></span></span></span></span><div><br></div><span><span><span><span></span></span></span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div><div dir="ltr" data-setdir="false"><span><span><br></span></span></div></div></body></html>