[yt-users] Comoving units

Matthew Turk matthewturk at gmail.com
Mon Nov 23 11:05:30 PST 2009


Hi Cameron,

Over here it's working for me with 1.5 and trunk:

In [2]: pf = load("RD0005-mine/RedshiftOutput0005")

In [3]: pf["kpccm"]
Out[3]: 7692.3076923076915

Looking at the source, which I am now officially putting on my "clean
this up" list, it looks like the comoving units only get set up if the
parameter "ComovingCoordinates" is set in the enzo parameter file:

http://yt.enzotools.org/browser/trunk/yt/lagos/OutputTypes.py#L323

and then if it is, this routine gets called:

http://yt.enzotools.org/browser/trunk/yt/lagos/OutputTypes.py#L340

which sets up all the /h and comoving stuff.  I guess the question now
is, is yt skipping over the line where it sets those units up, or is
it misunderstanding the ComovingCoordinates line in the parameter
file?  Could you let me know what the value of "
pf['ComovingCoordinates'] " is, and what the line in the Enzo
parameter file is as well?  For me, it looks like:

In [5]: pf["ComovingCoordinates"]
Out[5]: 1

and the line in the file is:

ComovingCoordinates                   = 1

Thanks, Cameron!

-Matt

On Mon, Nov 23, 2009 at 10:58 AM, Cameron Hummels
<chummels at astro.columbia.edu> wrote:
> Hello everyone:
>
>   I upgraded to the new version of yt, and I noticed there was a change in
> unit designation.  I used to be able to specify units in comoving units of
> kpc as: "kpccm", but that functionality now appears to be broken.  Does
> anyone know what the new syntax is for using comoving units?
> Here is a code example that used to work, but it no longer does in the new
> version:
>
> pf = EnzoStaticOutput(filename)
> thick_faceon =  10.0/pf['kpccm']
>
>                                                                     Thanks!
>                                                                     Cameron
>
>
> --
> Cameron Hummels
> PhD Candidate, Astronomy Department of Columbia University
> Public Outreach Director, Astronomy Department of Columbia University
> NASA IYA New York State Student Ambassador
> http://outreach.astro.columbia.edu
>
> _______________________________________________
> 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