[yt-users] fields in ghost zones

David Collins dcollins at physics.ucsd.edu
Mon Jun 7 21:14:11 PDT 2010


> There is no more *.grid* file. That was for Enzo 1.0 if I am not wrong. You
> probably meant the *.cpu* files, right ?

That's correct.

>
> To go further, is there a way I can:
>
>     - restart Enzo with WritePotential = 1 using a file that had
> WritePotential = 0 ?
>     - restart Enzo and use Tracer Particles with a file that did not have
> any of them ?

Both are possible, but you have to rewrite the datasets as well a the
supporting meta data (boundary and hierarchy).  I don't know the
details about writing tracer particles, but very recently I wrote a
script to add the potential field to a dataset.  Unfortunately, the
script was for my version of Enzo, which doesn't use packed AMR and
has extra fields for my MHD implementation.  I've attached a draft of
a code that will do the same thing for the more recent Enzo 1.5 with
the PackedAMR version, though I don't have time right now to do much
more.

Basically, you need to have a GravPotential field in the hdf5 files,
it needs to have a label in the parameter file, it needs to have it's
field_type listed and be counted in NumberOfBaryonFields in the
hierarchy file and the boundary file, and (if you're not using
OutOfCore Boundary) needs to have space in the hdf5 boundary file.
There are a lot of things to get right.

Alternatively, you could start a simulation with the desired size and
processor layout, and use h5py to write the density, energy, and
velocity fields into that.  That will ensure the hierarchy and
boundary are constructed properly.

Easiest still would be to just start the initial relax sims with the
gravitational potential written, that will have everything set up
right.

If anyone out there has an easier solution, that would be sweet.

d.

>
> Thanks again for your help,
>
>
> JC
>



-- 
Sent from my Stone Tablet and carried by my Pterodactyl.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: EnzoAddPotential.py
Type: application/octet-stream
Size: 4958 bytes
Desc: not available
URL: <http://lists.spacepope.org/pipermail/yt-users-spacepope.org/attachments/20100607/c09b00de/attachment.obj>


More information about the yt-users mailing list