Small bugfixes in refractionModels.py

This commit is contained in:
yosata committed 2020-11-15 18:04:39 +01:00
1 parent 7a084d1635
commit a3521a2426
3 files changed
+7 -7

No files matched your search

+4 -4
View File
@@ -391,7 +391,7 @@ class refraction(Observatory):
R : float
Atmospheric refraction in degrees
'''
_R = np.arcsin(n * np.sin( np.deg2rad(zenith) )) - np.deg2rad(zenith)
_R = np.arcsin(n1 * np.sin( np.deg2rad(zenith) )) - np.deg2rad(zenith)
return np.degrees(_R)
@@ -430,7 +430,7 @@ class refraction(Observatory):
Parameters
----------
n1 : float
Refractive index at the wavelength of interest
Refractive index at the wavelength of interest at the observer
zenith : float
Angle of observation in degrees.
zenith = 0 means the observation is directly overhead.
@@ -469,10 +469,10 @@ class refraction(Observatory):
_R = R0 + _h * 1000
# Gladstone-Dale relation between refractive index and density
_n_h = 1 + (n0 - 1) / _Dens[0] * _Dens
_n_h = 1 + (n1 - 1) / _Dens[0] * _Dens
# Calculation of the zenith angle for given height and refractive index, from the refractive invariant
_z = np.arcsin( (n0 * R0) / (_n_h * _R) * np.sin(zenith) )
_z = np.arcsin( (n1 * R0) / (_n_h * _R) * np.sin(zenith) )
# Calculation of log space derivative of n and r
_lnn = np.log(_n_h)
+1 -1
View File
@@ -120,7 +120,7 @@ rho = at.rho(p=101325, T=273.15, RH=0.2, xc=300)
# Initializing refraction model and setting the reduced height
ref = refraction(lat=30, h=2200)
ref.setReducedHeight(p=101325, rho)
ref.setReducedHeight(p=101325, rho=rho)
# Calculating the atmospheric refraction
atm_ref = ref.cassini(n, zenith=30)
+2 -2
View File
@@ -21,14 +21,14 @@ def setup_package():
# write_version_py()
setup(name='AstroAtmosphere',
version='1.3',
version='1.3.1',
description='Collection of equations for refractive index, refraction and dispersion calculations of atmospheric air.',
long_description=__readme__,
long_description_content_type='text/markdown',
author='Joost van den Born',
author_email='born@astron.nl',
url='https://gitlab.astro-wise.org/micado/atmosphericmodel',
download_url='https://gitlab.astro-wise.org/micado/atmosphericmodel/-/archive/v1.3/atmosphericmodel-v1.3.tar.gz',
download_url='https://gitlab.astro-wise.org/micado/atmosphericmodel/-/archive/v1.3.1/atmosphericmodel-v1.3.1.tar.gz',
license='GNU General Public License v3',
data_files = [('',['LICENSE.txt'])],
package_dir={'AstroAtmosphere': 'AstroAtmosphere'},