<div dir="ltr">Hi Jason,<div><br></div><div>If you take a look at the validator in the clump finder that is using the cython `gravitational_binding_energy` function, you'll see that there is already an option to use particles in the gravitational binding energy calculation. See the `_gravitationally_bound` function in `yt/analysis_modules/level_sets/clump_validators.py`.</div><div><br></div><div>When you create your master clump, all you need to do is set `use_particles=True` when you add the `gravitationally_bound` validator to the master clump. In fact, the example in the yt docs does this:</div><div><br></div><div><a href="http://yt-project.org/docs/dev/analyzing/analysis_modules/clump_finding.html#clump-validators">http://yt-project.org/docs/dev/analyzing/analysis_modules/clump_finding.html#clump-validators</a><br></div><div><br></div><div>Hope that helps, let us know if you need any additional advice.</div><div><br></div><div>-Nathan</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 17, 2016 at 1:50 PM, Jason Galyardt <span dir="ltr"><<a href="mailto:jason.galyardt@gmail.com" target="_blank">jason.galyardt@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Hi all,<br><br></div><div>I'd like to use the yt clump finder to identify gravitationally bound clumps. However, my FLASH simulation includes both gas (on the mesh) and massive particles. I would like to use both of these gravitational sources in the determination of boundedness, but it's not clear to me that the current implementation of gravitational_binding_energy() in yt/utilities/lib/misc_<wbr>utilities.pyx does this. I suspect that it would be relatively straightforward to add the ('deposit', 'io_mass') field to the gravitational_binding_energy() function, but I'm not entirely sure how to access this field in a safe manner in Cython.<br><br>Has anyone already solved this problem?<br><br></div><div>Thanks,<br></div><div>Jason <br><br>-----<br></div><div>Jason Galyardt <br></div><div>University of Georgia<br><br></div></div>
<br>______________________________<wbr>_________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" rel="noreferrer" target="_blank">http://lists.spacepope.org/<wbr>listinfo.cgi/yt-users-<wbr>spacepope.org</a><br>
<br></blockquote></div><br></div>