Python package to simulate wave-dominated shallow-marine environments
Project description
pyBarSim
pyBarSim is a Python package to simulate wave-dominated shallow-marine environments using Storms (2003)'s BarSim.
Installation
You can directly install pyBarSim from pip:
pip install pybarsim
Or from GitHub using pip:
pip install git+https://github.com/grongier/pybarsim.git
Usage
Basic use:
import numpy as np
from pybarsim import BarSim2D
import matplotlib.pyplot as plt
# Set the parameters
run_time = 10000.
barsim = BarSim2D(np.linspace(1000., 900., 200),
np.array([(0., 950.), (run_time, 998.)]),
np.array([(0., 25.), (run_time, 5.)]),
spacing=100.)
# Run the simulation
barsim.run(run_time=10000., dt_fair_weather=15., dt_storm=1.)
# Interpolate the outputs into a regular grid
barsim.regrid(900., 1000., 0.5)
# Compute the mean grain size
barsim.summarize()
# Plot the median grid size in the regular grid
barsim.record_['Mean grain size'].plot(figsize=(12, 4))
plt.show()
For a more complete example, see the Jupyter notebook using_pybarsim.ipynb or the Binder link above.
Citation
If you use pyBarSim in your research, please cite the original article:
Storms, J.E.A. (2003). Event-based stratigraphic simulation of wave-dominated shallow-marine environments. Marine Geology, 199(1), 83-100. doi:10.1016/S0025-3227(03)00144-0
Here is the corresponding BibTex entry if you use LaTex:
@Article{Storms2003,
author="Storms, Joep E.A.",
title="Event-based stratigraphic simulation of wave-dominated shallow-marine environments",
journal="Marine Geology",
year="2003",
volume="199",
number="1",
pages="83--100",
issn="0025-3227",
doi="https://doi.org/10.1016/S0025-3227(03)00144-0",
}
Credits
This software was written by:
| Guillaume Rongier |
Joep Storms |
Andrea Cuesta Cano |
|---|
License
Copyright notice: Technische Universiteit Delft hereby disclaims all copyright interest in the program pyBarSim written by the Author(s). Prof. Dr. Ir. J.D. Jansen, Dean of the Faculty of Civil Engineering and Geosciences
© 2023, G. Rongier, J.E.A. Storms, A. Cuesta Cano
This work is licensed under a MIT OSS licence.
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.
Source Distribution
File details
Details for the file pyBarSim-0.0.2.tar.gz.
File metadata
- Download URL: pyBarSim-0.0.2.tar.gz
- Upload date:
- Size: 16.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.10.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06279d5fe9992c90f1bc4e18edc9ee63d8749149db99a4d9cd4f31abd0688c05
|
|
| MD5 |
ae06596932d42e568ba7885f7aabc40c
|
|
| BLAKE2b-256 |
f56c2b7d35b6213cf1e90424b409af350462a814728a87dbc85e940f74864391
|