Shankar,<br><br>The overdensity in the profile is referring to dark matter + baryons.  The field called "Density" is just baryon density.<br><br>The nans come from spherical shells of the radial profile that had nothing in them.  If you look at the TotalMassMsun field, you'll notice that it is flat over the points where you get the nans and the value of myweight is 0.<br>
<br>Britton<br><br><div class="gmail_quote">On Wed, Dec 2, 2009 at 3:49 PM, Eric Hallman <span dir="ltr"><<a href="mailto:Eric.Hallman@colorado.edu">Eric.Hallman@colorado.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div style="word-wrap: break-word;">For question 1, you would use that only if you believe the *correct* OD for virialization is 200 only with respect to either mean matter density or critical density.  The number 200 is somewhat arbitrary.  But for your purposes, your conversion is correct.  As to which number you should use for virial overdensity, I would recommend looking through linear collapse theory in an expanding universe if you are concerned at this level which is correct (e.g. Peebles or the Press-Schechter papers, or any of the new ones)<div>
<br></div><div><br><div><div><div></div><div class="h5"><div>On Dec 2, 2009, at 3:40 PM, Agarwal, Shankar wrote:</div><br></div></div><blockquote type="cite"><div><div><div></div><div class="h5">Britton and Eric,<br><br>So I guess if the convention in halo_profiler is (Baryon + Dark Matter Density) / (Mean  density) , then I should use<br>
<br>    virial_overdensity = 200/Omega_matter = 200/0.258 = 775<br><br>instead of 200.<br><br><br><br>A separate stupid question :<br><br>I have run a Box=200Mpc/h with 512^3 dark matter particle simulation. <a href="http://drop.io/slice" target="_blank">http://drop.io/slice</a><br>
The most dense point in the box is only 1.3e-27 gm/cm^3, which is about 520*matter_mean_density (for omega_matter=0.26).<br><br>Then I ran halo_profiler.py on it. Here are the first few lines...<br><br><br>ActualOverdensity  CellVolume     Density         RadiusMpc      Temperature    TotalMassMsun     myweight<br>
1.411083e+03    1.884580e+73    5.022445e-28    1.086579e+00    3.470612e+07    3.350352e+13    4.667973e+12<br>1.349560e+03    2.826870e+73    2.846061e-28    1.108807e+00    2.697442e+07    4.806416e+13    1.054647e+12<br>
1.199229e+03    3.298015e+73    3.425752e-28    1.131491e+00    2.577368e+07    4.982850e+13    8.115086e+11<br>1.029234e+03    5.653740e+73    2.792583e-28    1.154639e+00    3.303925e+07    7.331169e+13    2.847611e+12<br>
1.135776e+03    7.538320e+73    3.070320e-28    1.178260e+00    3.784802e+07    1.078674e+14    2.675091e+12<br>1.135776e+03    7.538320e+73    nan     1.202365e+00    nan     1.078674e+14    0.000000e+00<br>1.135776e+03    7.538320e+73    nan     1.226962e+00    nan     1.078674e+14    0.000000e+00<br>
1.018853e+03    8.951755e+73    3.040255e-28    1.252063e+00    3.025227e+07    1.149060e+14    1.974464e+12<br>9.159449e+02    1.083633e+74    1.950294e-28    1.277677e+00    3.573580e+07    1.250475e+14    1.774217e+12<br>
9.158806e+02    1.177862e+74    1.275998e-28    1.303816e+00    3.568055e+07    1.359117e+14    5.672694e+11<br>8.432311e+02    1.413435e+74    1.915018e-28    1.330489e+00    2.360579e+07    1.501570e+14    1.880053e+12<br>
7.995894e+02    1.649007e+74    2.735319e-28    1.357708e+00    2.651133e+07    1.661165e+14    2.674878e+12<br><br><br>Looking at ActualOverdensity column, Is it possible to have a halo with overdensities in 1000's when the peak overdensity is 520. <br>
<br>And do the "nan" correspond to some kind of profile maxima ?<br><br><br>regards<br>shankar<br><br><br><br><br>-----Original Message-----<br>From: <a href="mailto:yt-users-bounces@lists.spacepope.org" target="_blank">yt-users-bounces@lists.spacepope.org</a> on behalf of Eric Hallman<br>
Sent: Wed 12/2/2009 12:56 PM<br>To: Discussion of the yt analysis package<br>Subject: Re: [yt-users] HaloProfiler ActualOverdensity<br><br>Shankar and Britton,<br>   I have gone through this argument extensively, and discovered that  <br>
both definitions are used, with roughly equal frequency in the  <br>literature. Lately, it has been trending toward OD = density/mean  <br>density (matter). I think the main reason for the density with respect  <br>to critical in the past has been due to an historical preference for  <br>
omega_m=1 universes (SCDM).<br><br>cheers,<br><br><br>On Dec 2, 2009, at 11:50 AM, Britton Smith wrote:<br><br><blockquote type="cite">Shankar,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">
As I stated in my previous email, you will find both definitions  <br></blockquote><blockquote type="cite">used in the literature.  I'm not going to spend time in a citation  <br></blockquote><blockquote type="cite">battle.  The good news is that both definitions differ only by a  <br>
</blockquote><blockquote type="cite">factor of Omega_matter, so you can change the value of  <br></blockquote><blockquote type="cite">virial_overdensity accordingly.<br></blockquote><blockquote type="cite"><br></blockquote>
<blockquote type="cite">Britton<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On Wed, Dec 2, 2009 at 11:27 AM, Agarwal, Shankar <<a href="mailto:sagarwal@ku.edu" target="_blank">sagarwal@ku.edu</a>>  <br>
</blockquote><blockquote type="cite">wrote:<br></blockquote><blockquote type="cite">Hi Britton,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I just wanted a clarification on the definition of  <br>
</blockquote><blockquote type="cite">ActualOverdensity. In your mail, you said...<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"> "ActualOverdensity has the same physical meaning as the regular  <br>
</blockquote><blockquote type="cite">Overdensity<br></blockquote><blockquote type="cite"> field.  It is (Baryon Density + Dark Matter Density) / (Mean  <br></blockquote><blockquote type="cite">density of the<br></blockquote>
<blockquote type="cite"> universe).  If you search the literature, you will find alternate<br></blockquote><blockquote type="cite"> definitions that use critical density instead of mean density. The  <br></blockquote><blockquote type="cite">
one used<br></blockquote><blockquote type="cite"> here is a little more common."<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Are you sure you did not mean (Baryon Density + Dark Matter  <br>
</blockquote><blockquote type="cite">Density) / (critical density) ?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Because, in halo_profiler.py, there is a virial filter...<br>
</blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">hp.add_halo_filter(HP.VirialFilter,must_be_virialized=True,<br></blockquote><blockquote type="cite">                  overdensity_field='ActualOverdensity',<br>
</blockquote><blockquote type="cite">                  virial_overdensity=200,<br></blockquote><blockquote type="cite">                  virial_filters=[['TotalMassMsun','>=','1e14']],<br></blockquote>
<blockquote type="cite">                  virial_quantities=['TotalMassMsun','RadiusMpc'])<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">
Isn't 200 w.r.t rho_ciritcal (not rho_mean_matter)? Look <a href="http://arxiv.org/abs/astro-ph/0011495" target="_blank">http://arxiv.org/abs/astro-ph/0011495</a><br></blockquote><blockquote type="cite"><br></blockquote>
<blockquote type="cite"><br></blockquote><blockquote type="cite">shankar<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">
<br></blockquote><blockquote type="cite">-----Original Message-----<br></blockquote><blockquote type="cite">From: <a href="mailto:yt-users-bounces@lists.spacepope.org" target="_blank">yt-users-bounces@lists.spacepope.org</a> on behalf of Britton Smith<br>
</blockquote><blockquote type="cite">Sent: Wed 11/25/2009 1:30 PM<br></blockquote><blockquote type="cite">To: Discussion of the yt analysis package<br></blockquote><blockquote type="cite">Subject: Re: [yt-users] Hop vs HaloProfiler<br>
</blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Hi Shankar,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I will answer the HaloProfiler related questions and leave the Hop  <br>
</blockquote><blockquote type="cite">questions<br></blockquote><blockquote type="cite">for Stephen.  However, could you post the failure output for what  <br></blockquote><blockquote type="cite">you tried<br></blockquote>
<blockquote type="cite">to do with Hop.  That will probably be helpful for answering your  <br></blockquote><blockquote type="cite">question.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">
Is Halo_0000_profile.dat related to the first Halo listed in  <br></blockquote><blockquote type="cite">HopAnalysis.out<br></blockquote><blockquote type="cite"><blockquote type="cite">file ?<br></blockquote></blockquote><blockquote type="cite">
<blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Yes, the HaloProfiler will always use the same indices for halos as  <br></blockquote><blockquote type="cite">
all of<br></blockquote><blockquote type="cite">the halo finders in yt.  So, the file Halo_N_profile.dat will always  <br></blockquote><blockquote type="cite">refer<br></blockquote><blockquote type="cite">to halo N on the halo list.<br>
</blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">What is # ?<br></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote>
<blockquote type="cite">This is just a comment character so that plotting programs don't try  <br></blockquote><blockquote type="cite">to read<br></blockquote><blockquote type="cite">in what's on that line.  The tab between it and the first field name  <br>
</blockquote><blockquote type="cite">is<br></blockquote><blockquote type="cite">there to accommodate the routines that read those files back in to the<br></blockquote><blockquote type="cite">HaloProfiler.<br></blockquote>
<blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">What is the meaning of ActualOverdensity ? And units ?<br></blockquote></blockquote><blockquote type="cite">
<blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">ActualOverdensity has the same physical meaning as the regular  <br></blockquote><blockquote type="cite">
Overdensity<br></blockquote><blockquote type="cite">field.  It is (Baryon Density + Dark Matter Density) / (Mean density  <br></blockquote><blockquote type="cite">of the<br></blockquote><blockquote type="cite">universe).  If you search the literature, you will find alternate<br>
</blockquote><blockquote type="cite">definitions that use critical density instead of mean density.  The  <br></blockquote><blockquote type="cite">one used<br></blockquote><blockquote type="cite">here is a little more common (I think, but I'm not sure).  As per  <br>
</blockquote><blockquote type="cite">these<br></blockquote><blockquote type="cite">definitions, overdensity is a unitless quantity.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">In yt, there is an Overdensity field that is calculated on a cell-by- <br>
</blockquote><blockquote type="cite">cell<br></blockquote><blockquote type="cite">basis.  For calculation of virial quantities for halos, the  <br></blockquote><blockquote type="cite">overdensity you<br></blockquote><blockquote type="cite">
calculate should be explicitly the total mass (baryon + dm) / total  <br></blockquote><blockquote type="cite">volume /<br></blockquote><blockquote type="cite">mean density, where total refers to all cells enclosed within the  <br>
</blockquote><blockquote type="cite">sphere of<br></blockquote><blockquote type="cite">the radial profile, not just the shell from r_(i-1) to r_i.   <br></blockquote><blockquote type="cite">Technically,<br></blockquote><blockquote type="cite">
you could get this by doing a profile of the Overdensity field,  <br></blockquote><blockquote type="cite">weighted by<br></blockquote><blockquote type="cite">CellVolume, with accumulation set to True.  However, if for some  <br>
</blockquote><blockquote type="cite">reason, the<br></blockquote><blockquote type="cite">user wanted to do profiles of the overdensity field in a different  <br></blockquote><blockquote type="cite">way, say<br></blockquote>
<blockquote type="cite">weighted by CellMass, or just counting the material shell-by-shell<br></blockquote><blockquote type="cite">(accumulation=False), this number would not be correct for the  <br></blockquote><blockquote type="cite">
calculation<br></blockquote><blockquote type="cite">of virial quantities.  For that reason, the HaloProfiler automatically<br></blockquote><blockquote type="cite">generates this ActualOverdensity field which is assured to be  <br>
</blockquote><blockquote type="cite">calculated in<br></blockquote><blockquote type="cite">the correct way.  That way the user doesn't accidentally override a  <br></blockquote><blockquote type="cite">proper<br></blockquote>
<blockquote type="cite">calculation of the overdensity used for the virial quantities.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Other than the ActualOverdensity field (which is automatically  <br>
</blockquote><blockquote type="cite">generated by<br></blockquote><blockquote type="cite">the HaloProfiler, and thus does not exist outside that context) you  <br></blockquote><blockquote type="cite">can<br></blockquote><blockquote type="cite">
always get the units of any field with:<br></blockquote><blockquote type="cite">lagos.fieldInfo[some_field].units<br></blockquote><blockquote type="cite">For more information, see here:<br></blockquote><blockquote type="cite">
<a href="http://yt.enzotools.org/doc/faq.html#how-do-i-know-what-the-units-returned-are" target="_blank">http://yt.enzotools.org/doc/faq.html#how-do-i-know-what-the-units-returned-are</a><br></blockquote><blockquote type="cite">
<br></blockquote><blockquote type="cite">What is the meaning of CellVolume? And units ?<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">What is Density referring to ? And units ?<br></blockquote>
<blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite">CellVolume and Density are the volume of a cell and the baryon  <br></blockquote><blockquote type="cite">density.  In<br>
</blockquote><blockquote type="cite">this context, they are the values of those fields in the radial  <br></blockquote><blockquote type="cite">profile.  If<br></blockquote><blockquote type="cite">you did it as per the recipe, the CellVolume is the total  <br>
</blockquote><blockquote type="cite">accumulated volume<br></blockquote><blockquote type="cite">for all cells within the sphere radius.  Density SHOULD be the<br></blockquote><blockquote type="cite">mass-weighted, mean baryon density for cells within spherical shells.<br>
</blockquote><blockquote type="cite">However, after looking at the recipe on the website, I see that, in  <br></blockquote><blockquote type="cite">error, I<br></blockquote><blockquote type="cite">set the weight_field of the Density profile to None, instead of<br>
</blockquote><blockquote type="cite">CellMassMsun.  Therefore, the Density profile may be meaningless as  <br></blockquote><blockquote type="cite">is.  I<br></blockquote><blockquote type="cite">will change the recipe on the website ASAP.<br>
</blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">What is mywieght ?<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">
<br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">The myweight field is a temporary field for keeping track of the  <br></blockquote><blockquote type="cite">weight<br></blockquote>
<blockquote type="cite">field for a weight radial profile.  It should be ignored and we  <br></blockquote><blockquote type="cite">might just<br></blockquote><blockquote type="cite">want to not write it out in the future.<br>
</blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">I also got the projection/ directory. But I got errors...<br></blockquote></blockquote>
<blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">It looks like the HaloProfiler tried to do a projection of  <br></blockquote><blockquote type="cite">
Metallicity, but<br></blockquote><blockquote type="cite">your simulation data did not have the MetalDensity field.  You need  <br></blockquote><blockquote type="cite">to set<br></blockquote><blockquote type="cite">CosmologyUseMetallicityField (or something like that) to 1 in your  <br>
</blockquote><blockquote type="cite">enzo<br></blockquote><blockquote type="cite">parameter file in order to get this field.  You can also just remove  <br></blockquote><blockquote type="cite">the<br></blockquote><blockquote type="cite">
line in the HaloProfiler recipe that adds the metallicity field to  <br></blockquote><blockquote type="cite">the list<br></blockquote><blockquote type="cite">of projections.<br></blockquote><blockquote type="cite"><br></blockquote>
<blockquote type="cite">Cheers,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Britton<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">
_______________________________________________<br></blockquote><blockquote type="cite">yt-users mailing list<br></blockquote><blockquote type="cite"><a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
</blockquote><blockquote type="cite"><a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br></blockquote><blockquote type="cite">
<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">_______________________________________________<br></blockquote><blockquote type="cite">yt-users mailing list<br></blockquote><blockquote type="cite">
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br></blockquote><blockquote type="cite"><a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
</blockquote><br>Dr. Eric J. Hallman<br>NSF Astronomy and Astrophysics Postdoctoral Fellow<br>Center for Astrophysics and Space Astronomy<br>University of Colorado at Boulder<br>hallman (at) <a href="http://casa.colorado.edu" target="_blank">casa.colorado.edu</a><br>
Phone: (312) 725-4626<br><a href="http://solo.colorado.edu/%7Ehallman/" target="_blank">http://solo.colorado.edu/~hallman/</a><br><br><br></div></div><span><winmail.dat></span>_______________________________________________<div class="im">
<br>yt-users mailing list<br><a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br><a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
</div></div></blockquote></div><div class="im"><br><div> <span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: medium; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px;"><div style="word-wrap: break-word;">
<div><div>Dr. Eric J. Hallman</div><div>NSF Astronomy and Astrophysics Postdoctoral Fellow                    </div><div>Center for Astrophysics and Space Astronomy </div><div>University of Colorado at Boulder  </div><div>
hallman (at) <a href="http://casa.colorado.edu" target="_blank">casa.colorado.edu</a> </div><div>Phone: (312) 725-4626    </div><div><a href="http://solo.colorado.edu/%7Ehallman/" target="_blank">http://solo.colorado.edu/~hallman/</a></div>
</div></div></span></div></span></div></span> </div><br></div></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" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br>