<div dir="ltr">Hi Rajika,<div><br></div><div>As you've discovered, it's not possible (as far as I'm aware, anyway) to do something like this with yt's field system, which assumes all fields can be calculated locally or by taking into account data that are at most a few zones away in any direction.</div><div><br></div><div>Usually whenever I'm looking for something like this I end up using a profile object, which has options for cumulatively summing profiled data.</div><div><br></div><div>Can you describe a little bit more what you want to do with this field?</div><div><br></div><div>-Nathan<br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jul 4, 2016 at 6:26 PM, Rajika Kuruwita <span dir="ltr"><<a href="mailto:rajikakuruwita@gmail.com" target="_blank">rajikakuruwita@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">Hi yt users,<div><br></div><div>I've been using yt for a few years, and I know how to simple fields, but I'm wondering if someone has created a field that calculates enclosed mass at all cells (so, I guess the mass in a sphere centred on the centre of the simulation domain, or centre of mass). I've tried to think of a few ways of doing this, but all require iterating over all cells, and that's not very efficient. If anyone has an suggestions or can help, that would be great!</div><div><br></div><div>Regards,</div><div>Rajika.</div></div>
<br>_______________________________________________<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/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div></div></div>