diff --git a/.gitignore b/.gitignore index 5ca0973..05d4011 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .DS_Store +__pychache__/ diff --git a/README.md b/README.md index ddb04a9..f2bfb9d 100644 --- a/README.md +++ b/README.md @@ -10,16 +10,21 @@ Author info: *Joost van den Born*, *born@astron.nl* *Below you can find a set of models describing the atmospheric refraction and dispersion.* **Contents:** -- atmosphericModel.py : Python model that can be used to calculate the atmospheric refraction and dispersion -- refractionModel.py : Python script that compares the output of the different rerfraction models. +- atmosphericModel : Python model that can be used to calculate the atmospheric refraction and dispersion, the main content of this repository. +- refractionModel.py : Python script that compares the output of the different refraction models. Can be used as an example on how to use atmosphericModel.py -- 1976USSA.txt : Table with temperature, pressure, density and more as a function of altitude. - Values derived from the 1976 U.S. Standard Atmosphere. -- manual.pdf : Manual for using atmosphericModel.py - atmospheric refraction example: jupyter notebook example -- [Tech note]...models.pdf : Tech note describing the models. +**On the contents of the atmosphericModel package** +The package contains the following files: +- 1976USSA.txt : Data file of the 1976 US Standard Atmosphere. +- ciddorModel.py : Contains the `Observatory()` class to calculate the refractive index of atmospheric air, using the Ciddor (1996) model. +- dispersionModels.py : Contains various atmospheric models that can be used to calculate the atmospheric dispersion +- examples.py : Contains several quick functions, e.g. to quickly calculate the refractive index. +- refractionModels.py : Contains various atmospheric models that can be used to calculate the atmospheric refraction +- refractivityModels.py : Contains various functions from literature to calculate the refractive index. Some examples of works included are Ciddor (1996), Barrell & Sears (1939), SLALIB, Owens (1967) and Edlen (1966). + **On the dispersion model:** diff --git a/atmospheric refraction example.html b/atmospheric refraction example.html index 65634ed..7b94324 100644 --- a/atmospheric refraction example.html +++ b/atmospheric refraction example.html @@ -13286,6 +13286,57 @@ div#notebook { + +
There are also some quick calculation functions defined in the examples.py file, if you just want to know the refractive index, the refraction or the dispersion at standard atmospheric conditions (conditions='STANDARD') or at Cerro Armazones (conditions='CERRO_ARMAZONES').
# Quick refractive index
+nq = quick_refractive_index(l=1.49, conditions='STANDARD')
+print('Quick refractive index: {}'.format(nq))
+
+# Quick refraction
+rq = quick_refraction(l1, zenith_obs, conditions='CERRO_ARMAZONES') * 3.6e3
+print('Quick refraction: {:.3f} arcsec'.format(rq))
+
+# Quick dispersion
+dq = quick_dispersion(l1, l2, zenith_obs, conditions='CERRO_ARMAZONES') * 3.6e6
+print('Quick dispersion: {:.3f} mas'.format(dq))
+