wiki:ProtectionOptions

Protection Options

There are several ways to handle density and pressure protections in AstroBEAR. These parameters can all be set in physics.data

The most two important parameters are:

  • MinTemp which sets the threshold for protections of pressure and is in Kelvin
  • MinDensity which sets the threshold for protections of density and is in CU (computational units)

Density Protections

  • When the density in a cell drops below the MinDensity the code can either restart from the last root step or modify the density and continue. lRestartOnDensityProtections controls this behavior

There are a few ways to modify the density

  • Set it to MinDensity (iDensityProtect = 0)
  • Set it to the minimum nearby density (iDensityProtect = 1)
  • Set it to the average surrounding density (iDensityProtect = 2)

And usually the momentum needs to be modified to avoid high flow speeds.

  • Momentum conserving (iMomentumProtect = 0)
  • Set to zero (iMomentumProtect = 1)
  • Average of nearby velocities (iMomentumProtect = 2)

Species Tracers

  • When species are being tracked (lTrackHydrogen,lTrackHelium,lTrackSulfur [not yet implemented]), density protections also trigger protections in the tracers. Total density is set to the protected value of computational density, and ionization fractions are set to the defaults xH, xHe, xHeII set in physics.data.

Pressure Protections

  • When the temperature in a cell drops below the MinTemp the code can either restart from the last root step or modify the energy and continue. lRestartOnPressureProtections controls this behavior.

There are a few ways to modify the pressure

  • Set the temperature to MinTemp (iPressureProtect = 0)
  • Set the pressure to the minimum nearby pressure (iPressureProtect = 1)
  • Set the pressure to the average nearby pressure (iPressureProtect = 2)
  • Set the temperature to the minimum nearby temperature (iPressureProtect = 3)
  • Set the temperature to the average nearby temperature (iPressureProtect = 4)

In general the higher the protection number, the more 'robust' the code will be. So the default mode is

lRestartOnDensityProtections=.false.
lRestartOnPressureProtections=.false.
iDensityProtect=2
iMomentumProtect=2
iPressureProtect=4

Any of these can be modified by adding lines to physics.data.

Last modified 7 years ago Last modified on 08/30/17 13:49:57
Note: See TracWiki for help on using the wiki.