<!DOCTYPE html><html><head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body>
<p>Dear petsc-users,<br>
</p>
<p> I am having issues with output of parallel data attached to a
DMPlex (or maybe more fundamental ones about DMPlex...).</p>
<p>So I currently</p>
<ol>
<li>create a DMPlex (DMPlexCreateGmshFromFile or
DMPlexCreateBoxMesh)</li>
<li>partition it</li>
<li>and create a section for my data layout with
DMPlexCreateSection(ctx.dmMesh, NULL, numComp, numDof, numBC,
NULL, NULL, NULL, NULL, &sUavg)</li>
<li>DMSetLocalSection(ctx.dmMesh, sUavg)</li>
<li>create solLoc and solGlob vectors with DMCreateGlobalVector
and DMCreateLocalVector</li>
<li>solve ....</li>
<li>VecView(ctx.solGlob, vtkViewer) on a .vtu file<br>
</li>
</ol>
<p>but when I load data in ParaView I get more cells than expected
and it is as if the cells in the halo are put twice in output. (I
could create a MWE if the above is not clear)<br>
</p>
<p>I guess that the culprit is point (4), but if I replace it with
DMSetGlobalSection then I cannot create the local vector at point
(5).<br>
</p>
<p>How should I handle this properly? In my code I need to create
both local and global vectors, to perform at least GlobalToLocal
and to save the global data.<br>
</p>
<p>(On a side note, I tried also HDF5 but then it complains about
the DM not having a DS...; really, any working solution that
allows data to be explored with Paraview is fine)<br>
</p>
<p>Thanks for any advice!<br>
</p>
<p>Matteo Semplice</p>
</body>
</html>