Python API for Fortran MSISE-00 neutral atmosphere model.
Project description
MSISE-00 in Python
NRL MSISE-00 atmospheric model for Python &g3; 3.6, also accessible via Matlab ≥ R2014b. Valid from altitude z = 0..1000 km.
The plot immediately below shows a slice at 200km on a world-wide grid. The yellow ball represents the sun footprint on Earth.
Install
- Mac:
brew install gcc
- Linux:
apt install gfortran
- Windows or use Windows Subsystem for Linux.
And then:
pip install -e .
Examples
MSISE00 can be used from the command line, as an imported module, and even from Matlab ≥ R2014b.
import module
import msise00
from datetime import datetime
atmos = msise00.rungtd1d(time=datetime(2013, 3, 31, 12), altkm=150., glat=65., glon=-148.)
atmos is an xarray.Dataset containing all the simulation output values.
atmos
is 4-D: (time, altitude, lat, lon), and indexed like atmos['N2']
Command Line
Write NetCDF4 output (HDF5 compatible) with command line argument -w filename.nc
.
Altitude Profile
at a single time:
msis00 -t 2017-08-21T20:48 -c 40 -90
Alt. profile time-range
with hourly time step:
msis00 -t 2017-08-21 2017-08-22 -c 40 -90
Grid: time,lat,lon
This example takes several minutes, and generates the plots in the README:
msis00
A single time lat/lon can be plotted:
msise00 -t 2017-01-02T12
Reference
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.