Skip to main content

Python bindings for the Java library NeqSim (via JPype), with python stubs

Project description

jNeqSim

License

Python interface for the NeqSim java package, with stubs. Java interface is created with jpype, and stubs are generated with stubgenj

PYPI

https://pypi.org/project/jneqsim/

[!NOTE] JNeqSim mirrors NeqSims versions

Demo

demo.gif

Example

from jneqsim import neqsim


def pressurize_gas():
    inlet_fluid = neqsim.thermo.system.SystemSrkEos()
    neqsim.thermo.system.SystemSrkEos()
    thermo_ops = neqsim.thermodynamicOperations.ThermodynamicOperations(inlet_fluid)
    inlet_fluid.addComponent("methane", 100.0)

    inlet_fluid.setTemperature(10, "C")
    inlet_fluid.setPressure(20, "bara")
    inlet_fluid.setMultiPhaseCheck(True)
    inlet_fluid.setSolidPhaseCheck("methane")

    thermo_ops.TPflash()
    thermo_ops.bubblePointTemperatureFlash()

    inlet_fluid.initProperties()
    enthalpy = inlet_fluid.getEnthalpy()

    inlet_fluid.setPressure(1.0, "bara")
    thermo_ops.PHflash(enthalpy)

Dependencies

:+1: Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

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

jneqsim-2.5.26.tar.gz (87.9 MB view details)

Uploaded Source

Built Distribution

jneqsim-2.5.26-py3-none-any.whl (85.7 MB view details)

Uploaded Python 3

File details

Details for the file jneqsim-2.5.26.tar.gz.

File metadata

  • Download URL: jneqsim-2.5.26.tar.gz
  • Upload date:
  • Size: 87.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for jneqsim-2.5.26.tar.gz
Algorithm Hash digest
SHA256 1d7061f8f2304382fb811af7e55789829e313a4d5a9b961eafa4c070241c30f4
MD5 837fa05100e0cd7481ca16c9fdf740ee
BLAKE2b-256 b518ea87beed156c554217fdfc9a1a80be1db2fbda86007f719c7ef30f28c9b0

See more details on using hashes here.

File details

Details for the file jneqsim-2.5.26-py3-none-any.whl.

File metadata

  • Download URL: jneqsim-2.5.26-py3-none-any.whl
  • Upload date:
  • Size: 85.7 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.0 CPython/3.12.4

File hashes

Hashes for jneqsim-2.5.26-py3-none-any.whl
Algorithm Hash digest
SHA256 38dcc2c0ad24fb1f6e5fbb42d178fd1e0488fdeb35b2bf5e9c79cd98417a6da8
MD5 8b8eb53afb3543123990ce3d0ec96840
BLAKE2b-256 f6b6555e605f7ba59da8ef3dcc42dce3d87da23f5b5339e70c1132feb84bcec1

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