| Version 6 (modified by , 15 years ago) ( diff ) |
|---|
global.data Explained
Arguably the most important data file in AstroBEAR 2.0, global.data contains global domain and solver data. This data is broken up into several namelists, which are read in by different sections of the code.
GlobalData
The GlobalData namelist contains global parameters. These parameters hold for the entire problem domain, and many of them actually describe it.
nDim: The number of dimensions in the problem. For AstroBEAR, this should be either2or3, since AstroBEAR only does 2D and 3D problems. A 1D problem can be approximated with a long, narrow 2D problem domain.
MaxLevel: The maximum refinement level for this simulation.MaxLevelis the number of refinement levels over the base grid (so aMaxLevelof0is fixed-grid). This value can never be less than0, and if it is greater than0then the problem is an AMR problem.
MinimumGridPoints: The minimum number of cells per dimension that a grid can have. Since a grid must have at least one cell,MinimumGridPointsshould never be less than1. A lowMinimumGridPointsallows AstroBEAR to create smaller grids, which lets it refine more efficiently. LowMinimumGridPointsvalues also run the risk of creating a lot more grids, which will boost administrative and communication costs.
nDomains: The number of domains comprising the problem domain. Multiple domains are useful if you want to impose different physical processes in different regions of your problem domain (i.e., different cooling curves), but most problems do not require this degree of complexity. Unless you have a specific reason for wanting multiple domains in your problem, it is best to leave this set to1.
lRestart: Should be set toTif you intend to restart a simulation from a Chombo file, orFif you intend to start the simulation from the beginning. You must have a Chombo file in your problem'sout/directory if you want to use this option, and it's index must match that of theRestartFramevariable (see below).
RestartFrame: The index of the frame from which you wish to restart. This number should be greater than or equal to0. In order to use this, you must have a Chombo file of the same index value in your problem'sout/directory (for example,RestartFrame 5will crash unless the fileout/chombo00005.hdfis present). Regardless of its value, theRestartFramevariable does nothing if thelRestartflag is set toF.
start_time: The start time in computational units. This quantity is used to calculate the time per frame within a simulation, and should not be changed even if you are restarting the job.
final_time: The final time (end time) in computational units. Needless to say, this should be greater thanstart_time.
GmX: This is a three-integer array, with each element representing the number of cells in the domain along the given dimension. Thus, the total domain size in cells isGmX(1) * GmX(2) * GmX(3). This array is subject to the following constraints:- All elements must be integers.
- All elements must be greater than or equal to
MinimumGridPoints. - If
nDim = 2, then the thirdGmXentry must be1.
GxBounds: This is a double-precision array with six values. The first three values set the lower spatial bounds of the problem domain, and the last three values set the upper bounds. For instance, the problem domain's boundaries along the x-axis are set by the first and fourth elements inGxBounds. TheGxBoundsarray has three constraints:GxBounds(1) < GxBounds(4)(i.e., they must define a legitimatexinterval).GxBounds(2) < GxBounds(5)(i.e., they must define a legitimateyinterval).- IF
nDim = 3, thenGxBounds(3) < GxBounds(6). Otherwise,GxBounds(3)andGxBounds(6)must equal zero.
Gmthbc: A six-integer array defining the boundary conditions along the edges of all three dimensions. IfnDim = 2, thenGmthbc(3)andGmthbc(6)should both be set to 1. The other boundary conditions can be chosen from one of the following options:1— Extrapolated boundaries.2— Periodic boundaries.3— Reflecting boundaries.
initial_maxspeed: The maximum initial wave speed; essentially, the maximum rate at which information can propagate across the grid. The higher the maximum initial wave speed, the smaller the initial timestep will be. Timesteps are adaptive in AstroBEAR, so in general it is a good idea to give yourself a higher maximum initial speed than you think you'll need—if the initial speed is too high, the system will adjust. Aninitial_maxspeedof about30.d0is common.
iThreaded: Turns threaded execution on or off. Threading is not fully implemented in AstroBEAR 2.0, so this flag should be left at0.
LevelData
The LevelData namelist contains values that are local to a given level. Every grid on a given level n will have the same LevelData attributes, but the values for level j != n might be substantially different.
All LevelData variables are multi-element. The data file should have values for every level from 0 to MaxLevel (see the GlobalData namelist above).
CoarsenRatio: The refinement ratio for grids on that level. ACoarsenRatioof 2 on level n means that ani*j*kcell refined region on level n will produce a2i*2j*2kgrid on level n+1. Virtually all of our simulations useCoarsenRatios of 2. TheCoarsenRatiovalues should always be integers.
qTolerance: These tolerances are used withinSetErrFlags()to determine whether or not to flag a cell for refinement. The higher the tolerance, the more extreme the variable gradients have to be to warrant refinement. TheqTolerancevariables are double-precision and must be greater than 0.d0, but a wide range of values is possible. 1.d-3 and 1.d-5 are common choices.
DesiredFillRatios: Single or double precision values between 0 and 1. The desired fill ratio determines what fraction of the cells in a new subgrid must be flagged for refinement. If a potential subgrid's fill ratio is below its parent grid'sDesiredFillRatiosvalue, then AstroBEAR will attempt to break it into smaller grids with higher fill ratios. Problems with low fill ratios will refine more cells than they need to, but will likely use fewer grids to do so. It becomes a trade-off between the cost of additional refinement and the cost of grid management and communication. Typical fill ratios range between .5 to .99 (although .99 can be extremely slow).