{"id":45123,"library":"iapws","title":"IAPWS","description":"Python implementation of international standards from the International Association for the Properties of Water and Steam (IAPWS). Provides thermodynamic properties of water and steam based on IAPWS-IF97 and related formulations. Current version: 1.5.5, updated 2024. Release cadence is irregular.","status":"active","version":"1.5.5","language":"python","source_language":"en","source_url":"https://github.com/jjgomera/iapws","tags":["steam","water","thermodynamics","IAPWS","properties"],"install":[{"cmd":"pip install iapws","lang":"bash","label":"Standard install"}],"dependencies":[{"reason":"Required for numerical operations in property calculations.","package":"numpy","optional":false},{"reason":"Used for root-finding and integration in some models.","package":"scipy","optional":false}],"imports":[{"note":"In versions prior to 1.5, the module structure was different; the recommended import is the top-level package.","wrong":"from iapws.iapws97 import IAPWS97","symbol":"IAPWS97","correct":"from iapws import IAPWS97"},{"note":"Using direct module import instead of the package-level symbol can break due to internal refactoring.","wrong":"import iapws.IAPWS95","symbol":"IAPWS95","correct":"from iapws import IAPWS95"}],"quickstart":{"code":"from iapws import IAPWS97\n\n# Create steam object at 10 MPa and 500 K\nsteam = IAPWS97(P=10, T=500)\nprint(f\"Density: {steam.rho:.3f} kg/m³\")\nprint(f\"Enthalpy: {steam.h:.3f} kJ/kg\")\nprint(f\"Entropy: {steam.s:.3f} kJ/kg·K\")","lang":"python","description":"Create an IAPWS-IF97 steam object using pressure (MPa) and temperature (K), then access thermodynamic properties."},"warnings":[{"fix":"Convert pressure to MPa and temperature to Kelvin before passing to the constructor.","message":"In version 1.5, the IAPWS97 class no longer accepts non-SI units (e.g., bar, °C). All inputs must be in MPa and K.","severity":"breaking","affected_versions":">=1.5"},{"fix":"Use 1.0 for 10 bar, or 0.1 for 1 bar. Always double-check units: 1 MPa = 10 bar = 1000 kPa.","message":"The IAPWS97 class expects pressure in MPa, not kPa or bar. Common mistake: passing 10.0 thinking it's 10 bar yields incorrect results.","severity":"gotcha","affected_versions":"all"},{"fix":"Replace calls to `_PS(P, S)` with `IAPWS97(P=P, S=S)`.","message":"The function `iapws.iapws97._PS` is deprecated and will be removed in a future release. Use `IAPWS97(P=..., S=...)` constructor instead.","severity":"deprecated","affected_versions":">=1.5"}],"env_vars":null,"search_vec":"'1.5.5':36 '2024':38 'associ':10 'base':26 'cadenc':40 'current':34 'formul':33 'iapw':1,18,29,46 'iapws-if97':28 'if97':30 'implement':3 'intern':5,9 'irregular':42 'properti':13,21,47 'provid':19 'python':2 'relat':32 'releas':39 'standard':6 'steam':17,25,43 'thermodynam':20,45 'updat':37 'version':35 'water':15,23,44","created_at":"2026-06-07T12:53:28.844294+00:00","updated_at":"2026-06-07T12:53:28.844294+00:00","problems":[{"fix":"Upgrade with `pip install --upgrade iapws` and use `from iapws import IAPWS97`.","cause":"Using an outdated version (<1.0) or incorrect import path.","error":"AttributeError: module 'iapws' has no attribute 'IAPWS97'"},{"fix":"Ensure pressure is between 0.001 and 100 MPa. For lower pressures, use IAPWS95 if subcritical steam is needed.","cause":"Pressure input is outside the valid range for IAPWS-IF97 (0.001 to 100 MPa).","error":"ValueError: Pressure out of range (0.001, 100) MPa"},{"fix":"Use the correct constructor for IAPWS97: `IAPWS97(P=..., T=...)` or `IAPWS97(P=..., h=...)`. Check the official API.","cause":"Using a deprecated keyword argument like 'T' in a function that expects only state variables in specific order.","error":"TypeError: __init__() got an unexpected keyword argument 'T'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":"https://github.com/jjgomera/iapws","github":"https://github.com/jjgomera/iapws","docs":null,"changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["science","engineering"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"passing","verified_at":"2026-06-29","last_verified":"2026-06-29","next_check":"2026-07-29","install_tag":null}}