[FLASH-USERS] Negative densities after amr_prolong?

Nathan Goldbaum goldbaum at ucolick.org
Tue May 15 18:40:28 EDT 2012


Hello all,

I'm running a problem in a modified version of flash4-beta that includes sink particles.  I've been running this problem in this version of flash4 for a while with no issues using outflow boundary conditions.  However, I'd like to switch to periodic boundary conditions for numerical reasons.

I've modified my flash.par so that the simulation uses periodic boundary conditions:

# Boundary conditions
xl_boundary_type   = "periodic"
xr_boundary_type   = "periodic"
yl_boundary_type   = "periodic"
yr_boundary_type   = "periodic"
zl_boundary_type   = "periodic"
zr_boundary_type   = "periodic"
grav_boundary_type = "periodic"

I initialize the problem with lrefine_min = lrefine_max so that the initial conditions for the magnetic and velocity fields are read in without interpolating.  Once the simulation dumps a checkpoint file after initializing everything, I kill the simulation after one timestep and modify lrefine_min and lrefine_max to the values I want for the rest of the simulation.

Unfortunately, with periodic conditions, the prolongation routine produces negative densities when the simulation tries to derefine in the first timestep:

mpiexec ./flash4
MaterialProperties initialized
Initializing Sink Particles
[io_readData] Opening DiskDyn_hdf5_chk_0000 for restart
Progress Initializing Polytropic Equation of State
Source terms initialized
iteration, no. not moved =            0       30880
iteration, no. not moved =            1           6
iteration, no. not moved =            2           0
refined: total leaf blocks =        32768
refined: total blocks =        37449
INFO: Grid_fillGuardCells is ignoring masking.
Finished with Grid_initDomain, restart
Ready to call Hydro_init
Hydro initialized
Gravity initialized
Initial dt verified
*** Wrote plotfile to DiskDyn_forced_hdf5_plt_cnt_0000 ****
Initial plotfile written
Driver init all done
Advance Particles, sink integrator = leapfrog
SinksOnGasAccel:: sink_softening_type_gas = linear
SinksOnGasAccel:: maxradius_pbc =   4.800000000000000E+019
       n          t         dt  (         x,          y,          z) |  dt_hydro 
       1 4.0000E+10 2.1235E+10  (-3.703E+18, -1.172E+18,  6.094E+17) |  2.124E+10
iteration, no. not moved =            0        4918
iteration, no. not moved =            1        1591
iteration, no. not moved =            2           0
refined: total leaf blocks =         5216
refined: total blocks =         5961
WARNING after amr_prolong: min. unk(DENS_VAR)=-0.1820363743126234321119E-21    PE=3     block=1                                type=2                               
 16  0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22
 15  0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22
WARNING after amr_prolong: min. unk(DENS_VAR)=-0.1820418210164601860886E-21    PE=4     block=3                                type=2                               
 16  0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22
 15  0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22 0.38E-22

Does anyone have any idea why this is happening and what I can do to avoid the error?  Any idea why this only show up when I run using periodic boundary conditions and not when I run using outflow boundary conditions?

Thanks very much for your help with this,

Nathan Goldbaum
Graduate Student
Astronomy & Astrophysics, UCSC
goldbaum at ucolick.org
http://www.ucolick.org/~goldbaum




More information about the flash-users mailing list