Skip to main content

Petrochemical modelling software ThorPT

Project description

Thor GIF

ThorPT - This is ThorPT

ThorPT is a modelling package for fluid coupled geolgical processes in the crust. Fluid production and migration in the crust is fundamental for the earth's geochemical cycling and ThorPT is specified for modelling this fluid production and fluid transfer. It includes the latest developments in petrogeochemical modelling and helps the user to test different scenarios:

  • Single rock modelling:

    1. Petrological purposes to test changes in mineral assemblages and coupled fluid production, e.g., while prograde metamorphism
    2. Mechanical testing of the rock based on the Mohr-Coulomb theory
    3. Quantification of the production of fluid masses
  • Multi rock modelling (Work in progress):

    1. Stacks of rock sequences involving fluid transfer
    2. Outcrop modelling
    3. *Contact zones and fluid-rock ratios

1. Getting started with the package

Information and requirements: There are currently two ways to use the package. Prerequisite in both cases is to get and install a working version of theriak-domino, because we need access to its executables. Check the software at https://github.com/Theriak-Domino/theriak-domino

The latest updates incorporate packages written in the programming language Julia. Therefore, it is now necessary to have a version of Julia (>=v1.9; https://julialang.org/) installed on your machine (see juypter installation notebook for more details).

Further, you need the ThorPT input files to pass informations to the software. This is a simple text file and can be found in the latest release of ThorPT jupyter.

1.1 Recommended for all users

Quick start: Get the jupyter working directory that includes all instructions and installs ThorPT with its dependencies. You can find it in the latest release of ThorPT jupyter.

1.2 Recommended to users familair with Python

Install the package manually into your python environment and develop your own script.

1.1 Use the package with the jupyter environment

Download the jupyter release that includes:

  • Jupyter notebook script to install ThorPT and all dependencies
  • Jupyter script to run ThorPT and containing functions
  • Datafiles directory with
    • initial file
    • examples for modelling

Before you start, make sure that you have followed all the steps and executed all the cells in the "install_ThorPT" Jupyter notebook!

Instructions: Creating the link to the software theriak

  • Declare the working directory of the theriak executable in order to do minimizations with ThorPT.

  • Open the file "init.txt" and edit the first line after "Theriak:".
    (You find the file in the released package you downloaded from github, it is located in the DataFiles folder)

  • Insert the file path of theriak. In the latest versions of TheriakDomino it is located in the "programs" folder.
    Windows example:"Theriak:C:\TheriakDominoWIN.2023.06.11\Programs"

1.2 Manual installation to your python environment

1.2.1 Install the package

ThorPT is public on the test PyPi servers and will be published on the offical servers soon. You can get the package by using the following command to import it to your python environment.

pip install thorpt

1.2.2 Import the package

from thorpt import start_ThorPT

1.2.3 Run the main module

The software will prompt you for two input files:

  1. init file that defines parameters for the modelling
  2. usage of a P-T path (pressure unit has to be defined in the init file, using "kbar" or "GPa")

start_ThorPT.run_main_routine()

1.2.4 Plotting module with ThorPT

Plotting is based on the ξόρκι module. This module comprises pre defined plots for phase assemblages, oxygen isotopes and several plots for visualising the fluid production and transfer. Options are possible to save the image files and generate a gif.

First steps: from thorpt.xorki import * Read variables from a hdf5 with the function

from thorpt.xorki import *
data = ThorPT_hdf5_reader()
data.open_ThorPT_hdf5()

Activate the plotting module - Predefined plots for evaluation:

compPlot = ThorPT_plots(data.filename, data.mainfolder, data.rock, data.compiledrock)

Default plotting functions are then:

compPlot.boxplot_to_GIF(rock_tag='NAME')

compPlot.pt_path_plot(rock_tag='NAME')

compPlot.permeability_plot(rock_tag='NAME')

compPlot.time_int_flux_plot(rock_tag='NAME')

compPlot.porosity_plot(rock_tag='NAME')

compPlot.release_fluid_volume_plot(rock_tag='NAME')

Funding and author

The development of this package was supported by the European Research Council (ERC) under the European Union's Horizon 2020 research and innovation programme (grant agreement No 850530).

Author: Thorsten A. Markmann (thorsten.markmann@unibe.ch)

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

thorpt-1.0.3.tar.gz (5.7 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

thorpt-1.0.3-py3-none-any.whl (917.1 kB view details)

Uploaded Python 3

File details

Details for the file thorpt-1.0.3.tar.gz.

File metadata

  • Download URL: thorpt-1.0.3.tar.gz
  • Upload date:
  • Size: 5.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.6

File hashes

Hashes for thorpt-1.0.3.tar.gz
Algorithm Hash digest
SHA256 6cc4682b941fd00f20ed9617185c365d32ebcdb094c74bf224cae6f4d689d591
MD5 006d62fd749261b37ff34ef53ccddc06
BLAKE2b-256 7cdef96c1c3f2dca1a61b145b8ea95c3d38a7a9c1bbad4d314429fd5a044918a

See more details on using hashes here.

File details

Details for the file thorpt-1.0.3-py3-none-any.whl.

File metadata

  • Download URL: thorpt-1.0.3-py3-none-any.whl
  • Upload date:
  • Size: 917.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.6

File hashes

Hashes for thorpt-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 2eae055f7b7d94cb576b68a268528bf7ad8623a3c5da1fbc880d292df99a6126
MD5 24f5e33d5c35bc02dde72ef6491ca2e5
BLAKE2b-256 809b9c7d9d83d8001530ea72d7779452f05534758cc160f1f7dbe011b3987f1a

See more details on using hashes here.

Supported by

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