UnitsΒΆ

The default parameters in PyChem are

UnitLength_in_cm                  = 3.085e+21;            # 1.0 kpc */
UnitMass_in_g                     = 1.989e+43;            # 1.0e10 solar masses */
UnitVelocity_in_cm_per_s          = 20725573.785998672;   # 207 km/sec */

To change this default, you can pass new values during the initialisatio of PyChem:

params={}
params['UnitLength_in_cm']          = 3.085e+21          # unit length in kpc
params['UnitMass_in_g']             = 1.989e+33          # unit mass in solar mass
params['UnitVelocity_in_cm_per_s']  = 9918338477366.2539 # unit velocity in kpc/yr

from PyChem import chemistry
chemistry.init_chimie("../chemistry.simple.dat",params=params)

The internal units of time will then be in years. It is possible to retrives these values with the following command:

chemistry.GetParameters()