ExoEOS
Differentiable equations of state for planetary atmospheres and fluids, built with JAX.
The first implementation is a calorically perfect ideal-gas mixture. It provides one small state interface that is intended to remain common to future real-gas models.
Installation
python -m pip install exoeos
Quick start
All public quantities use SI units. Component molar masses are in kg mol-1,
component molar heat capacities are in J mol-1 K-1, temperature is in K, and
pressure is in Pa.
import jax
import jax.numpy as jnp
from exoeos import IdealGas
eos = IdealGas(
molar_masses=jnp.array([2.01588e-3, 4.002602e-3]),
molar_heat_capacities=jnp.array([28.84, 20.786]),
)
x = jnp.array([0.85, 0.15])
state = eos.state(T=1000.0, P=1.0e5, x=x)
state.Z
state.mass_density
state.number_density
state.log_fugacity_coefficients
state.residual_gibbs
state.residual_enthalpy
state.cp
state.cv
state.thermal_expansion
state.adiabatic_gradient
jitted_density = jax.jit(
lambda temperature: eos.state(temperature, 1.0e5, x).mass_density
)
density_gradient = jax.grad(jitted_density)(1000.0)
x contains normalized mole fractions on its last axis. ExoEOS does not
renormalize composition. Component molar masses and heat capacities are
required because T, P, and x alone do not determine mass density or
caloric properties. Reference enthalpies and entropies default to zero; pass
physical reference data when absolute values are needed.
The complete units, shape, reference-state, and transformation contract is in the thermodynamic-state contract.
Development
python -m pip install -e ".[test]"
pytest tests/unittests
The current scope is the ideal gas. Cubic equations of state, including Peng--Robinson, are reserved for later implementations behind the same state contract.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file exoeos-0.1.0.tar.gz.
File metadata
- Download URL: exoeos-0.1.0.tar.gz
- Upload date:
- Size: 26.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
943368dfb7ea8d939352e10a97aa7c0dc15242c20257cc1b6a9aad9d470cd6b9
|
|
| MD5 |
baa6185cf174de0678a6dcaa1b52e3b2
|
|
| BLAKE2b-256 |
97f1522f18fb7fa4e36fe3658b0033ca3d5d97a31240ab1c68577c0bd6e2c731
|
Provenance
The following attestation bundles were made for exoeos-0.1.0.tar.gz:
Publisher:
publish.yml on HajimeKawahara/exoeos
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
exoeos-0.1.0.tar.gz -
Subject digest:
943368dfb7ea8d939352e10a97aa7c0dc15242c20257cc1b6a9aad9d470cd6b9 - Sigstore transparency entry: 2408980554
- Sigstore integration time:
-
Permalink:
HajimeKawahara/exoeos@64bdc743b41a653690a59b0a9af3c66161c4d6fc -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/HajimeKawahara
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@64bdc743b41a653690a59b0a9af3c66161c4d6fc -
Trigger Event:
push
-
Statement type:
File details
Details for the file exoeos-0.1.0-py3-none-any.whl.
File metadata
- Download URL: exoeos-0.1.0-py3-none-any.whl
- Upload date:
- Size: 19.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d069a7c15fa7a66ab9780a6c3afd60d7b124f2258b09d845afd8a6c113e21622
|
|
| MD5 |
5901135058149d6ddc464e4a883bb171
|
|
| BLAKE2b-256 |
890dd808f107f991c2d92570c6721c5e3a46be35858d03cf61dd87a6ff6e45bd
|
Provenance
The following attestation bundles were made for exoeos-0.1.0-py3-none-any.whl:
Publisher:
publish.yml on HajimeKawahara/exoeos
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
exoeos-0.1.0-py3-none-any.whl -
Subject digest:
d069a7c15fa7a66ab9780a6c3afd60d7b124f2258b09d845afd8a6c113e21622 - Sigstore transparency entry: 2408980687
- Sigstore integration time:
-
Permalink:
HajimeKawahara/exoeos@64bdc743b41a653690a59b0a9af3c66161c4d6fc -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/HajimeKawahara
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@64bdc743b41a653690a59b0a9af3c66161c4d6fc -
Trigger Event:
push
-
Statement type: