Skip to main content

pyResToolbox - A collection of Reservoir Engineering Utilities

Project description

pyrestoolbox

-----------------------------A collection of Reservoir Engineering Utilities -----------------------------

This set of functions focuses on those that the author uses often while crafting programming solutions. These are the scripts that are often copy/pasted from previous work - sometimes slightly modified - resulting in a trail of slightly different versions over the years. Some attempt has been made here to make this implementation flexible enough such that it can be relied on as-is going forward.

Includes functions to perform simple calculations including;

  • Inflow for oil and gas
  • PVT Calculations for oil
  • PVT calculation for gas
  • Return critical parameters for typical components
  • Creation of Black Oil Table information
  • Creation of layered permeability distribution consistent with a Lorenze heterogeneity factor
  • Extract problem cells information from Intesect (IX) print files
  • Generation of AQUTAB include file influence functions for use in ECLIPSE
  • Creation of Corey and LET relative permeability tables in Eclipse format

Apologies in advance that it is only in oilfield units with no current plans to add multi-unit support.

Changelist in 1.3.4:

  • Extend ECL deck zip/check function to handle IX formatted decks, and support zipping multiple decks at once.

Changelist in 1.3.2:

  • Added robust Rachford Rice solver in Simulation Helpers
  • Moved relative permeability functions and simulation helpers to seperate .simtools module

Changelist in 1.2.0

  • Added Component Critical Property Library

Changelist in v1.1.4:

  • Attempting to fix reported issue with required dependencies not installing correctly

Changelist in v1.1:

  • Fix API to SG calculation (141.4 vs 141.5)
  • Added lower limit to first rho_po estimate for Oil Density with McCain method to avoid negative values with high Rs
  • Added oil_sg and oil_api functions
  • Modified HY Z-Factor solve algorithm to improve robustness
  • Modified DAK Z-Factor solve algorithm to improve robustness
  • Added Gas Z-Factor correlation from Wang, Ye & Wu (2021)
  • Removed 'LIN' Z-Factor method due to significant errors above 12,000 psi. Use WYW method instead if speed needed.

Head to the project site for more information & documentation; https://github.com/mwburgoyne/pyResToolbox

Start by importing the package; from pyrestoolbox import pyrestoolbox as rtb

Function List includes

  • Gas Flow Rate Radial
  • Gas Flow Rate Linear
  • Oil Flow Rate Radial
  • Oil Flow Rate Linear

  • Gas Tc & Pc Calculation
  • Gas Z-Factor
    Calculation
  • Gas Viscosity
  • Gas Viscosity * Z
  • Gas Compressibility
  • Gas Formation Volume Factor
  • Gas Density
  • Gas Water of Condensation
  • Convert P/Z to P
  • Convert Gas Gradient to SG
  • Delta Pseudopressure
  • Gas Condensate FWS SG

  • Component Critical Properties Library

  • Oil Density from MW
  • Oil Critical Properties with Twu
  • Incrememtal GOR post Separation
  • Oil Bubble Point Pressure
  • Oil GOR at Pb
  • Oil GOR at P
  • Oil Compressibility
  • Oil Density
  • Oil Formation Volume Factor
  • Oil Viscosity
  • Generate Black Oil Table data
  • Estimate soln gas SG from oil
  • Estimate SG of gas post separator
  • Calculate weighted average surface gas SG
  • Oil API to SG
  • Oil SG to API

  • Calculate suite of brine properties

  • Lorenz coefficient from Beta value
  • Lorenz coefficient from flow fraction
  • Lorenz coefficient to flow fraction
  • Lorenz coefficient to permeability array

  • Summarize IX convergence errors from PRT file
  • Create Aquifer Influence Functions
  • Solve Rachford Rice for user specified feed Zis and Ki's
  • Create sets of rel perm tables

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

pyrestoolbox-1.3.5.tar.gz (96.2 kB view details)

Uploaded Source

Built Distribution

pyrestoolbox-1.3.5-py3-none-any.whl (90.6 kB view details)

Uploaded Python 3

File details

Details for the file pyrestoolbox-1.3.5.tar.gz.

File metadata

  • Download URL: pyrestoolbox-1.3.5.tar.gz
  • Upload date:
  • Size: 96.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

File hashes

Hashes for pyrestoolbox-1.3.5.tar.gz
Algorithm Hash digest
SHA256 70f4249a92beb69e03644bbb6207a4286f9d43c3fb970172e9b976722b555964
MD5 5ee18050a25f5f36dcbe39beaf46c91c
BLAKE2b-256 6e85c052759e66a2bd6bb116f89aee29ee98725a1d0b0be862f3b5aba6e32ebd

See more details on using hashes here.

File details

Details for the file pyrestoolbox-1.3.5-py3-none-any.whl.

File metadata

  • Download URL: pyrestoolbox-1.3.5-py3-none-any.whl
  • Upload date:
  • Size: 90.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.2

File hashes

Hashes for pyrestoolbox-1.3.5-py3-none-any.whl
Algorithm Hash digest
SHA256 55fa3b6d05a7553b7a906db5b1401dae7264ec6d2287a5430b8f65ba6e1d73fa
MD5 f4714fee9e029dab8067f6e6013a2cd4
BLAKE2b-256 e6365f868e86010c72cefa9ad1b363cdd4a4058cc850640329f94fe10f486cfc

See more details on using hashes here.

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