[yt-users] Projection Question

Matthew Turk matthewturk at gmail.com
Fri Apr 12 15:17:03 PDT 2013


On Fri, Apr 12, 2013 at 6:13 PM, david collins <dcollins4096 at gmail.com> wrote:
> Hi, all--
>
> I have a dumb projection question.
>
> Why is it that when I do a projection, the minimum pdx is smaller than the
> minimum cell width in my simulation?
>
>>>> pf.h.get_smallest_dx()
> 0.0001220703125
>>>> 1./pf.h.get_smallest_dx()
> 8192.0
>
> Additionally, the sum of the areas is not what I expect.  I expect
>
>>>> proj=pf.h.proj(0,'Density')
>>>> (proj['pdx']*proj['pdy']).sum()
> 0.25
>
>
> I get 0.25, instead of 1 (consistent with the above, if all the widths are
> down by a factor of 2.)
>
> I assumed that proj['pdx'] is the width of the zone of the projection, which
> I naievely expect to be the smallest cell width along any line of sight.
>
> Could one of you good people fill in what I'm misunderstanding?

Sure!  pdx is halfwidth, and the px values are cell centers.  I think
this is somewhere in the method paper, but there's no clear place to
stick it in the documentation.

-Matt

>
> Thanks a ton!
> d.
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>



More information about the yt-users mailing list