[yt-users] volume-weighted 1D profiles
Mateusz Ruszkowski
mateuszr at umich.edu
Wed Nov 18 18:34:14 PST 2015
Hi,
I am trying to understand how Profile1D works. I would like to produce a volume-weighted 1D profile in a sphere. For a uniform grid, even if the radial bins/shells are not spaced logarithmically (i.e., if they are spaced uniformly in r), there are obviously more zones in shells located at larger radii, so the volume effect should be accounted for automatically.
So do I need specify weight_field = “cell_volume” in this case, or do I set it to “None” in order to generate a volume-weighted profile? That is, do I do this
prof = yt.Profile1D(sp, “r", rbins, prof_min, prof_max, True, weight_field="cell_volume”)
or
prof = yt.Profile1D(sp, “r", rbins, prof_min, prof_max, True, weight_field=“None”)
Thanks,
Mateusz
More information about the yt-users
mailing list