Changes between Version 39 and Version 40 of ModulesOnAstroBear


Ignore:
Timestamp:
01/21/13 13:52:06 (12 years ago)
Author:
Jonathan
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • ModulesOnAstroBear

    v39 v40  
    224224Astrophysical problems involve many different physical units and constants with a wide range of scales.  To avoid overflow or underflow - we scale our units into ''computational units'' before storing them in the data arrays.  Note with double precision this would be quite rare - but it still convenient to work within physical units appropriate to the problem.
    225225
    226 Usually, the physical scales are defined in the [PhysicsDataExplained physics.data] file --you simply enter the scales for density, temperature, velocity, etc in cgs units, and AstroBEAR will read them in.  ''Note that nScale is in cm^{-3}^ and !TempScale is in Kelvin''
     226Usually, the physical scales are defined by a few parameters in the [PhysicsDataExplained physics.data] file --you simply enter the scales for density, temperature, velocity, etc in cgs units, and AstroBEAR will read them in.  ''Note that nScale is in cm^{-3}^ and !TempScale is in Kelvin''.  When the code runs it will calculate other scales such as the computational time scale, mass scale, magnetic field scale, and so on which are then dumped to a scales.data file in your run directory.  All of those units will be in cgs with the magnetic field scale in gauss.  It is often useful to know the computational time scale before running your job as this will affect the final time specified in global.data.  The computational time scale can be calculated as follows:
     227
     228 * tScale=lScale / (pScale/rScale)^1/2^
     229where you may have to first derive
     230 * rScale=Xmu*amu*nScale
     231 * pScale=nScale*k,,B,,*!TempScale
    227232
    228233You have two options for making sure that you only put scaled quantities in the data arrays: you can scale your input values before you enter them into your input file (and then assume that you are reading in scaled quantities), or you can use physical quantities in your input files and then scale them within your problem module: