<div dir="ltr"><div>Ah, that's the problem, I was running version 3.8.3, with 3.9.3 it's working fine. I see that the implementation of DMLabelFilter changed in version 3.9 to mitigate this problem, that when the start is below or at the start of the label node range it wont allocate.</div><div><br></div><div>Thanks for the quick response!</div><div><br></div><div>Best,<br></div><div>Emiel<br></div><br></div><br><div class="gmail_quote"><div dir="ltr">Op do 19 jul. 2018 om 12:48 schreef Matthew Knepley <<a href="mailto:knepley@gmail.com">knepley@gmail.com</a>>:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Thu, Jul 19, 2018 at 6:21 AM Emiel van de Ven <<a href="mailto:emiel.van.de.ven@gmail.com" target="_blank">emiel.van.de.ven@gmail.com</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>Dear PETSc users,</div><div><br></div><div>I have a mesh where I have a label that contains some elements. If I understand correctly, after uniform refinement, the label also contains the refined faces and vertices. Since I'd like to have only cells in the label, I thought to remove the rest using something like:</div><div><br></div><div>DMPlexGetDepthStratum(dm, 3, &vStart, &vEnd);</div><div>DMLabelFilter(label, vStart, vEnd);</div><div><br></div><div>However, I don't fully understand the functioning of DMLabelFilter. When vStart>0, it works as I would expect, but when vStart=0, it simply removes all the points from the label. Why is this happening?</div><div><br></div><div>Since for the cells vStart usually is 0, I can't use this method. Am I missing something?</div><div><br></div><div>Attached is a minimal working example.</div></div></blockquote><div><br></div><div>I have just compiled and run your example. This is what I get:</div><div><br></div><div>
<span></span>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">master *:~/Downloads/tmp$ ./main</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">Label 'Cell Sets':</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo"><span class="m_8001026011650788397gmail-Apple-converted-space"> </span>Index has been calculated in [1, 10)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 1 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 2 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 3 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 4 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 5 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 6 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 7 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 8 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 9 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">Label 'Cell Sets':</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo"><span class="m_8001026011650788397gmail-Apple-converted-space"> </span>Index has been calculated in [0, 10)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 1 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 2 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 3 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 4 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 5 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 6 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 7 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 8 (4)</p>
<p class="m_8001026011650788397gmail-p1" style="margin:0px;font-variant-numeric:normal;font-variant-east-asian:normal;font-weight:normal;font-stretch:normal;font-size:11px;line-height:normal;font-family:Menlo">[0]: 9 (4)</p>
<br></div><div>What version are your running with?</div><div><br></div><div> Thanks,</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"><div dir="ltr"><div>Best,</div><div>Emiel<br></div></div>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="m_8001026011650788397gmail_signature" data-smartmail="gmail_signature"><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.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div></div>
</blockquote></div>