Metadata-Version: 2.4
Name: petropt
Version: 1.0.0
Summary: Python library for petroleum engineering — Standing PVT, Dranchuk Z-factor, Arps decline, volumetrics, gas P/Z, Archie water saturation, density porosity, Vshale, LAS log I/O. MIT licensed.
Project-URL: Homepage, https://petropt.com
Project-URL: Documentation, https://tools.petropt.com/docs/
Project-URL: Online Tools, https://tools.petropt.com
Author: Mehrdad G. Shirangi
Author-email: Groundwork Analytics LLC <info@petropt.com>
License-Expression: MIT
License-File: LICENSE
Keywords: Archie,Arps,Dranchuk,LAS,Larionov,OGIP,OOIP,PVT,STOIIP,Standing,Vshale,Z-factor,decline-curve,density-porosity,material-balance,oil-gas,open-source,petroleum-engineering,petrophysics,recovery-factor,reservoir-engineering,well-logs
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Education
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Natural Language :: English
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Scientific/Engineering
Classifier: Topic :: Scientific/Engineering :: Physics
Requires-Python: >=3.10
Requires-Dist: lasio>=0.31
Requires-Dist: numpy>=1.24
Requires-Dist: pandas>=2.0
Provides-Extra: notebooks
Requires-Dist: jupyter; extra == 'notebooks'
Requires-Dist: matplotlib; extra == 'notebooks'
Description-Content-Type: text/markdown

# petropt — The Python Library for Petroleum Engineering

[![PyPI](https://img.shields.io/pypi/v/petropt)](https://pypi.org/project/petropt/)
[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](LICENSE)
[![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://pypi.org/project/petropt/)

> Petroleum engineering correlations for Python. MIT licensed.

**[Online Calculators](https://tools.petropt.com)** · **[Documentation](https://tools.petropt.com/docs/)**

## Install

```bash
pip install petropt
```

## Quick Start

```python
import petropt
import numpy as np

# Load a bundled production dataset
df = petropt.datasets.load_sample_production()

# PVT: Standing bubble point pressure
pb = petropt.correlations.standing_bubble_point(api=35, gas_sg=0.65, temp=200)

# Decline: Arps hyperbolic forecast
t = np.arange(0, 60)
q = petropt.correlations.arps_decline(qi=1000, di=0.05, b=0.5, t=t)

# Volumetrics: STOIIP estimate
ooip = petropt.correlations.stoiip(area=640, thickness=50, porosity=0.20, sw=0.30, bo=1.25)

# Petrophysics: water saturation from resistivity
sw = petropt.petrophysics.archie_sw(rt=20.0, phi=0.20, rw=0.05)

# Well logs: read a LAS file
logs = petropt.io.read_las("well.las")
```

## What's Inside

### Correlations
- **PVT** — Standing bubble point / Rs / Bo, Dranchuk Z-factor
- **Decline** — Arps (exponential, hyperbolic, harmonic)
- **Volumetrics** — STOIIP, GIIP, recovery factor
- **Material balance** — gas P/Z

### Petrophysics
- **Vshale** — linear, Larionov (Tertiary / older), Clavier
- **Porosity** — density
- **Water saturation** — Archie

### I/O
- **LAS files** — read well logs into pandas DataFrames (wraps lasio)

### Datasets
- **Sample production** — bundled 2-well, 12-month dataset for demos

## Links

- [tools.petropt.com](https://tools.petropt.com) — petroleum engineering web calculators by Groundwork Analytics
- [tools.petropt.com/docs/](https://tools.petropt.com/docs/) — documentation

## Citation

```
Shirangi, M.G. (2026). petropt: The Python Library for Petroleum Engineering.
https://pypi.org/project/petropt/
```

## License

MIT — see [LICENSE](LICENSE) for details.
