<div dir="ltr"><div dir="ltr"><div>Hello Thomas and Sean,</div><div><br></div><div>For Paramesh, I have not had much success using Grid_markRefineSpecialized but have obtained reasonably good results by calling gr_markInRectangle in Grid_markRefineDerefine.</div><div><br></div><div>Once you refine those blocks, they will stay at that level. Logic needs to be added to gr_markInRectangle to derefine the area if at a later time in the simulation you desire a coarser mesh there.</div><div><br></div><div>Block count and max/min level of refinement may still need to be adjusted to get good behavior.<br></div><div><br></div><div>Hope that helps you out.</div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Jun 6, 2023 at 12:23 PM Kaldawi, Thomas <<a href="mailto:Tkal@lle.rochester.edu">Tkal@lle.rochester.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div class="msg-7192681908250704891">
<div style="display:none;font-size:1px;color:rgb(255,255,255);line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden">
I think I am starting to get it to work. For me, I needed to copy and paste some parts of the simulation_initBlock into the Grid_markRefineDerefine so I could loop through the x and y coordinates for each block. You may also need to set the
</div>
<div style="display:none;font-size:1px;color:rgb(255,255,255);line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden">ZjQcmQRYFpfptBannerStart</div>
<u></u>
<div dir="ltr" id="m_-7192681908250704891pfptBannerdeicmia" style="display:block;text-align:left;margin:16px 0px;padding:8px 16px;border-radius:4px;min-width:200px;background-color:rgb(208,216,220);border-top:4px solid rgb(144,164,174)">
<div id="m_-7192681908250704891pfptBannerdeicmia" style="float:left;display:block;margin:0px 0px 1px;max-width:600px">
<div id="m_-7192681908250704891pfptBannerdeicmia" style="display:block;background-color:rgb(208,216,220);color:rgb(0,0,0);font-family:"Arial",sans-serif;font-weight:bold;font-size:14px;line-height:18px">
This Message Is From an External Sender
</div>
<div id="m_-7192681908250704891pfptBannerdeicmia" style="display:block;background-color:rgb(208,216,220);color:rgb(0,0,0);font-weight:normal;font-family:"Arial",sans-serif;font-size:12px;line-height:18px;margin-top:2px">
This message came from outside your organization.
</div>
</div>
<div style="clear:both;display:block;line-height:0;font-size:0.01px;height:0px"> </div>
</div>
<u></u>
<div style="display:none;font-size:1px;color:rgb(255,255,255);line-height:1px;height:0px;max-height:0px;opacity:0;overflow:hidden">ZjQcmQRYFpfptBannerEnd</div>
<div dir="auto">
I think I am starting to get it to work. For me, I needed to copy and paste some parts of the simulation_initBlock into the Grid_markRefineDerefine so I could loop through the x and y coordinates for each block.
<div><br>
</div>
<div>You may also need to set the region wider than needed if you do not have enough blocks. This is the problem I was having, because I would give it a rectangular region, but because I did not have enough blocks in the y direction it would not recognize that
region as part of the foil. </div>
<div><br>
</div>
<div>Thank you for the help! <br>
<div dir="ltr"><br>
<blockquote type="cite">On Jun 6, 2023, at 12:54, Lewis,Sean <<a href="mailto:scl63@drexel.edu" target="_blank">scl63@drexel.edu</a>> wrote:<br>
<br>
</blockquote>
</div>
<blockquote type="cite">
<div dir="ltr">
<div>
<p class="MsoNormal">Hi Thomas,<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I am attempting something very similar (though for an astrophysical simulation). Assuming your setup uses Paramesh, there’s a set of routines meant for defining a specific region to be refined: /source/Grid/GridMain/paramesh/{Grid_markRefineSpecialized.F90,gr_markInRectangle.F90}.
Grid_markRefineSpecialized can be called by Grid_markRefineDerefine() and given a specific rectangular (or spherical/elliptical) region to mark all blocks within for refinement.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I personally have not gotten this behavior to work however, the grid seems to just ignore the refinement region, but it might be a place for you to start. I’m still running tests on this, but if anyone else has used this routine and thinks
it may be good for Thomas please chime in. I’ll let you know if I make any progress with this.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">-Sean<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal"><b><span style="font-family:"Times New Roman",serif;color:black">Sean C. Lewis<u></u><u></u></span></b></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:"Times New Roman",serif">Doctoral Candidate<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:"Times New Roman",serif">Department of Physics<u></u><u></u></span></p>
</div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:"Times New Roman",serif">Drexel University</span><u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div style="border-color:rgb(181,196,223) currentcolor currentcolor;border-style:solid none none;border-width:1pt medium medium;padding:3pt 0in 0in">
<p class="MsoNormal"><b><span style="font-size:12pt;color:black">From: </span></b><span style="font-size:12pt;color:black">flash-users <<a href="mailto:flash-users-bounces@flash.rochester.edu" target="_blank">flash-users-bounces@flash.rochester.edu</a>> on behalf of "Kaldawi, Thomas" <<a href="mailto:Tkal@lle.rochester.edu" target="_blank">Tkal@lle.rochester.edu</a>><br>
<b>Date: </b>Tuesday, June 6, 2023 at 10:28 AM<br>
<b>To: </b>"<a href="mailto:flash-users@flash.rochester.edu" target="_blank">flash-users@flash.rochester.edu</a>" <<a href="mailto:flash-users@flash.rochester.edu" target="_blank">flash-users@flash.rochester.edu</a>><br>
<b>Subject: </b>[FLASH-USERS] Extra Refinement for Area<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<table style="width:100%" width="100%" cellpadding="0" border="0">
<tbody>
<tr>
<td style="border-color:currentcolor currentcolor currentcolor goldenrod;border-style:none none none solid;border-width:medium medium medium 3pt;background:cornsilk;padding:0in 3pt">
<p><b><span style="font-family:"Arial",sans-serif;font-variant:small-caps">External.<u></u><u></u></span></b></p>
</td>
</tr>
</tbody>
</table>
<div>
<div>
<p class="MsoNormal"><span><span style="font-size:12pt;color:black">Hello,
</span></span><span style="font-size:12pt;color:black"><u></u><u></u></span></p>
</div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">I am trying to add refinement to a specific area of the LaserSlab simulation. In the Pdf I sent, I have the entire simulation, which is just a target, support, and two very thin foils at the bottom
connected to the support. As you can see, I have refined the edges of the target and the support; however, the foils are too thin to be recognized. If I increase the total blocks in the y direction to ~70, the two foils can easily be distinguished, but I do
not want this much refinement in the rest of the simulation. Is there a way to simply add blocks/refine only a certain area in the simulation?
<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"><u></u> <u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black">For clarification, the foils are two different sizes, one is half a micron, and the other is around 30 nanometers; thus, I need a fairly high level of refinement for that area. Also, the foils
are supposed to connect from the yellow/green support to the left wall. However, they cut off before reaching the left side of the window. So, the red foil is indeed supposed to appear between those sections, but for some reason it just cuts off even more
than the second foil.<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:12pt;color:black"><u></u> <u></u></span></p>
</div>
<p class="MsoNormal"><span><span style="font-size:12pt;color:black">Thanks!</span></span><span style="font-size:12pt;color:black"><u></u><u></u></span></p>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
_______________________________________________<br>
flash-users mailing list<br>
<a href="mailto:flash-users@flash.rochester.edu" target="_blank">flash-users@flash.rochester.edu</a><br>
<br>
For list info, including unsubscribe:<br>
<a href="https://urldefense.com/v3/__https://flash.rochester.edu/mailman/listinfo/flash-users__;!!KwNVnqRv!ARsrGmalBuUizNMY533OJUdZ4_bDE34_GVKV9Bvy58XBzT_RKtSd4LnLQhtpo6gZ_1G164e5g5GSsmhimH_Cqw$" rel="noreferrer" target="_blank">https://urldefense.com/v3/__https://flash.rochester.edu/mailman/listinfo/flash-users__;!!KwNVnqRv!ARsrGmalBuUizNMY533OJUdZ4_bDE34_GVKV9Bvy58XBzT_RKtSd4LnLQhtpo6gZ_1G164e5g5GSsmhimH_Cqw$</a> <br>
</div></blockquote></div><br clear="all"><br><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr">Thanks,<div>Ben</div></div></div>