Skip to main content

Library of atmospheric models

Project description

MATMOS

alt text

MATMOS is a direct and inverse atmospheric model library. Currently it supports the International Standard Atmosphere model.

Install

pip install matmos

User's guide

Given an altitude, MATMOS allows you to calculate the temperature, pressure and density of the atmosphere (direct model). If given any of these (temperature, pressure or density), MATMOS will calculate the corresponding altitude and remaining quantities (indirect model).

As temperature is not a monotonic function of altitude (equal values of temperature happen at different altitudes), its inverse cannot be determined without more information. To solve this, the option to specify an altitude range where the temperature is to be found is provided.

The API reference is available here.

Install

pip install matmos

Models

alt text

User's guide

Importing a model

from matmos import ISA

Running and retrieving results

The model is run by simply initializing an instance with height, temperature, pressure or density as inputs. The results are stored as instance attributes and can be retrieved with the usual notation.

MATMOS allows for input in the form of Python numeric types as well as NumPy arrays. The unit convention can be seen in the table below.

Magnitude Altitude Temperature Pressure Density
Unit km K Pa kg/m^3

Direct model

Solving for a given height:

m = ISA(23.5)                       # 23.5 km

m.t                                 # Temperature
m.p                                 # Pressure
m.d                                 # Density

Inverse model

Solving for a given temperature:

m = ISA(t=225, hrange=[0, 20])      # 225 K, in the range from 0 to 20 km

m.h                                 # Altitude
m.t                                 # Temperature
m.d                                 # Density

Solving for a given pressure:

m = ISA(p=98000)                    # 98000 Pa

m.h                                 # Altitude
m.t                                 # Temperature
m.d                                 # Density

Solving for a given density:

m = ISA(p=0.03)                     # 0.03 kg/m^3

m.h                                 # Altitude
m.t                                 # Temperature
m.p                                 # Pressure

Back to top

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

matmos-0.0.0a3.tar.gz (4.8 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page