估算大气参数的软件包
pyatmos的Python项目详细描述
欢迎来到ATMOS
pyatmos包是一个科学程序的档案,旨在实现对各种大气模型的大气特性的估计。目前,可行的大气模型包括:
- 国际标准大气(ISA)模式,最长86公里
- NRLMSISE-00型
如何安装
pyatmos可以与
pip install pyatmos
如何使用
国际标准大气
在10公里的高度(默认为几何高度)计算ISA。在
^{pr2}$在50公里的位势高度计算ISA。在
>>>isa(50,'geopotential'){'temperature[K]':270.65,'pressure[Pa]':75.94476758456234,'density[kg/m^3]':0.0009775244455727493}
计算90公里处的ISA。在
>>>isa(90)Exception:geometricaltitudeshouldbein[-0.611,86.0]km>>>isa(90,'geopotential')Exception:geopotentialaltitudeshouldbein[-0.610,84.852]km
NRLMSISE-00
获取太空气象数据
>>>frompyatmosimportdownload_sw,read_sw>>># Download or update the space weather file from www.celestrak.com>>>swfile=download_sw()>>># Read the space weather data>>>swdata=read_sw(swfile)Updatingthespaceweatherdata...Finished
在2015年10月5日03:00:00 UTC,使用NRLMSISE-00模型计算温度、密度not,包括异常氧气。在
>>> from pyatmos import nrlmsise00
>>> # Set a specific time and location
>>> t = '2015-10-05 03:00:00' # time(UTC)
>>> lat,lon = 25,102 # latitude and longitude [degree]
>>> alt = 70 # altitude [km]
>>> para_input,para_output = nrlmsise00(t,lat,lon,alt,swdata)
>>> print(para_input,'\n')
>>> print(para_output)
{'Year': 2015, 'DayOfYear': 278, 'SecondOfDay': 10800.0, 'Latitude[deg]': 25, 'Longitude[deg]': 102, 'Altitude[km]': 70, 'LocalSolarTime[hours]': 9.8, 'f107Average[10^-22 W/m^2/Hz]': 150, 'f107Daily[10^-22 W/m^2/Hz]': 150, 'ApDaily': 4, 'Ap3Hourly': array([4, 4, 4, 4, 4, 4, 4])}
{'Density': {'He[1/m^3]': 9100292488300570.0, 'O[1/m^3]': 0, 'N2[1/m^3]': 1.3439413974205876e+21, 'O2[1/m^3]': 3.52551376755781e+20, 'AR[1/m^3]': 1.6044163757370681e+19, 'H[1/m^3]': 0, 'N[1/m^3]': 0, 'ANM O[1/m^3]': 0, 'RHO[kg/m^3]': 8.225931818480755e-05}, 'Temperature': {'TINF[K]': 1027.3184649, 'TG[K]': 219.9649472491653}}
在2004年7月8日10:30:50 UTC,使用NRLMSISE-00模型计算温度、密度not,包括异常氧气。在
>>> t = '2004-07-08 10:30:50'
>>> lat,lon,alt = -65,-120,100
>>> para_input,para_output = nrlmsise00(t,lat,lon,alt,swdata)
>>> print(para_input,'\n')
>>> print(para_output)
{'Year': 2004, 'DayOfYear': 190, 'SecondOfDay': 37850.0, 'Latitude[deg]': -65, 'Longitude[deg]': -120, 'Altitude[km]': 100, 'LocalSolarTime[hours]': 2.5138888888888893, 'f107Average[10^-22 W/m^2/Hz]': 109.0, 'f107Daily[10^-22 W/m^2/Hz]': 79.3, 'ApDaily': 2, 'Ap3Hourly': array([2. , 2. , 2. , 2. , 2. , 3.125, 4.625])}
{'Density': {'He[1/m^3]': 119477307274636.89, 'O[1/m^3]': 4.1658304136233e+17, 'N2[1/m^3]': 7.521248904485598e+18, 'O2[1/m^3]': 1.7444969074975662e+18, 'AR[1/m^3]': 7.739495767665198e+16, 'H[1/m^3]': 22215754381448.5, 'N[1/m^3]': 152814261016.3964, 'ANM O[1/m^3]': 1.8278224834873257e-37, 'RHO[kg/m^3]': 4.584596293339505e-07}, 'Temperature': {'TINF[K]': 1027.3184649, 'TG[K]': 192.5868649143824}}
在2010年2月15日12:18:37 UTC,使用NRLMSISE-00模型计算500公里、85度纬度、210度经度的温度、密度,包括异常氧气。在
>>> t = '2010-02-15 12:18:37'
>>> lat,lon,alt = 85,210,500
>>> para_input,para_output = nrlmsise00(t,lat,lon,alt,swdata,omode='Oxygen')
>>> print(para_input,'\n')
>>> print(para_output)
{'Year': 2010, 'DayOfYear': 46, 'SecondOfDay': 44317.0, 'Latitude[deg]': 85, 'Longitude[deg]': 210, 'Altitude[km]': 500, 'LocalSolarTime[hours]': 2.310277777777779, 'f107Average[10^-22 W/m^2/Hz]': 83.4, 'f107Daily[10^-22 W/m^2/Hz]': 89.4, 'ApDaily': 14, 'Ap3Hourly': array([14. , 5. , 7. , 6. , 15. , 5.375, 4. ])}
{'Density': {'He[1/m^3]': 2830075020953.2334, 'O[1/m^3]': 5866534735436.941, 'N2[1/m^3]': 59516979995.87239, 'O2[1/m^3]': 1558775273.2950978, 'AR[1/m^3]': 825564.7467165776, 'H[1/m^3]': 142697077779.00586, 'N[1/m^3]': 53473812381.891624, 'ANM O[1/m^3]': 4258921381.0652237, 'RHO[kg/m^3]': 1.790487924033088e-13}, 'Temperature': {'TINF[K]': 850.5598890315023, 'TG[K]': 850.5507885501303}}
在2019年8月20日23:10:59 UTC,使用NRLMSISE-00模型在900km,3°纬度,5°经度处计算温度,密度,包括异常氧气。它不仅使用每日AP,还使用3小时AP磁指数。在
>>> t = '2019-08-20 23:10:59'
>>> lat,lon,alt = 3,5,900
>>> para_input,para_output = nrlmsise00(t,lat,lon,alt,swdata,omode='Oxygen',aphmode = 'Aph')
>>> print(para_input,'\n')
>>> print(para_output)
{'Year': 2019, 'DayOfYear': 232, 'SecondOfDay': 83459.0, 'Latitude[deg]': 3, 'Longitude[deg]': 5, 'Altitude[km]': 900, 'LocalSolarTime[hours]': 23.51638888888889, 'f107Average[10^-22 W/m^2/Hz]': 67.4, 'f107Daily[10^-22 W/m^2/Hz]': 67.7, 'ApDaily': 4, 'Ap3Hourly': array([4. , 4. , 3. , 3. , 5. , 3.625, 3.5 ])}
{'Density': {'He[1/m^3]': 74934329990.0412, 'O[1/m^3]': 71368139.39199762, 'N2[1/m^3]': 104.72048033793158, 'O2[1/m^3]': 0.09392848471935447, 'AR[1/m^3]': 1.3231114543012155e-07, 'H[1/m^3]': 207405192640.34592, 'N[1/m^3]': 3785341.821909535, 'ANM O[1/m^3]': 1794317839.638502, 'RHO[kg/m^3]': 8.914971667362366e-16}, 'Temperature': {'TINF[K]': 646.8157488121493, 'TG[K]': 646.8157488108872}}
更改日志
- ^{str 1}1.1.2美元-2020年7月26日
- 添加了下载数据的进度条
- ^{str 1}1.1.0美元-2020年3月29日
- 增加了国际标准大气(ISA)模式,最长可达86公里
下一个版本
- 完成帮助文档
- 改进代码结构,使其更易于阅读
- 添加其他大气模型,如U.S.Standard Atmosphere 1976(USSA1976)或标准大气扩展委员会(COESA)长达1000公里,非官方澳大利亚标准大气2000(UASA2000),以及Jacchia-Bowman 2008经验热层密度模型(JB2008)
参考文献
- U、 美国标准大气,1976年,美国政府印刷局,华盛顿特区
- Public Domain Aeronautical Software
- https://gist.github.com/buzzerrookie/5b6438c603eabf13d07e
- https://ww2.mathworks.cn/help/aerotbx/ug/atmosisa.html
- Original Fortran and C code
- MSISE-00 in Python and Matlab
- NRLMSISE-00 Atmosphere Model - Matlab
- NRLMSISE-00 Atmosphere Model - Aerospace Blockset
- NRLMSISE-00 Atmosphere Model - CCMC
- NRLMSISE-00 empirical model of the atmosphere: Statistical comparisons and scientific issues
- 项目
标签: