Skip to main content

OpenUtility

OpenUtility is an alpha-stage Python package for Pyomo-based utility-system optimization. It focuses on investment selection, dispatch, thermal and electric balances, operating-cost reporting, and solver orchestration for industrial utility systems.

The package is intended to sit beside process-integration and thermodynamic tools rather than replace them. OpenPinch, TESPy workflows, manufacturer data, or other upstream tools can generate plain input data; OpenUtility consumes that data without importing those packages at runtime.

Package Scope

OpenUtility currently includes:

  • typed input data classes for utility-system candidates, costs, thermal nodes, operating periods, and HPR performance maps;
  • Pyomo MILP model construction for utility investment and dispatch decisions;
  • HiGHS solving through Pyomo SolverFactory("appsi_highs") and the required highspy package;
  • HPR investment and dispatch modeling, where HPR means heat pump and refrigeration;
  • generic reporting helpers for model results, benchmarks, operating costs, and fuel consumption;
  • generic bilevel decomposition bookkeeping, no-good cut helpers, and utility-system decomposition wrappers;
  • thermal interval helpers for stream-like plain Python objects.

OpenUtility does not currently include:

  • OpenPinch or TESPy as runtime dependencies;
  • HPR thermodynamic cycle design, refrigerant screening, or performance-map generation;
  • continuous HPR sizing; first-release HPR sizing is represented by selecting among fixed-capacity candidates;
  • global interpolation across unrelated HPR temperature points;
  • a full public case-study replication package in the distributed wheel;
  • a public API named BEELINE, although generic bilevel decomposition utilities are included.

OpenUtility/ is the reusable public package. Private replication workflows and large study-specific artifacts are intentionally outside the package boundary and are not included in release tests or built wheels.

OpenUtility targets Python >=3.14.2.

Academic Basis

OpenUtility began as a Python/Pyomo implementation of utility-system optimization methods developed by Julia Jimenez Romero, Adisa Azapagic, and Robin Smith:

  • Julia Jimenez Romero, "Reduction of Industrial Energy Demand through Sustainable Integration of Distributed Energy Hubs," PhD thesis, The University of Manchester, 2022.
  • Jimenez Romero, J., Azapagic, A., and Smith, R., Computers and Chemical Engineering, 170, Article 108060, 2023. https://doi.org/10.1016/j.compchemeng.2022.108060
  • Jimenez Romero, J., Azapagic, A., and Smith, R., "BEELINE: BilevEl dEcomposition aLgorithm for synthesis of Industrial eNergy systEms," Computers and Chemical Engineering, 180, Article 108406, 2024. https://doi.org/10.1016/j.compchemeng.2023.108406

The package has since been generalized beyond the original replication workflows and extended with HPR optimization. In OpenUtility, HPR means heat pump and refrigeration: fixed-capacity HPR candidates can be selected and dispatched against multi-period thermal-node balances using alpha versioned plain performance maps. HPR electricity is currently handled by a period-indexed overlay, while the original non-HPR electricity balance remains static. The HPR implementation is an optimization-layer model; thermodynamic map generation remains outside OpenUtility.

Install

From PyPI (Python >=3.14.2):

python -m pip install OpenUtility

For development from a checkout:

python -m pip install -e ".[dev,docs,release]"

To install a local checkout:

python -m pip install .

Quick Start

from OpenUtility import (
    SteamLevelCandidate,
    UtilitySystemModelData,
    build_utility_system_model,
    pyomo_utility_system_solver,
)

data = UtilitySystemModelData(
    steam_mains=("MP",),
    steam_levels=(
        SteamLevelCandidate(
            name="MP_100",
            steam_main="MP",
            temperature=100.0,
            source_heat_available=5.0,
            sink_heat_demand=5.0,
            generation_enthalpy_delta=1.0,
            use_enthalpy_delta=1.0,
            source_heat_upper_bound=5.0,
            sink_heat_upper_bound=5.0,
        ),
    ),
    power_demand=0.0,
    grid_import_limit=0.0,
    grid_export_limit=0.0,
)
model = build_utility_system_model(data)
status = pyomo_utility_system_solver("appsi_highs")(model)

Verification

Run the full release gate:

python tools/release_check.py

The gate runs linting, formatting, type checking, tests with coverage, Sphinx, source/wheel build, wheel inspection, twine check, dependency audit, and a fresh wheel-install smoke test.

For offline local triage only:

python tools/release_check.py --skip-audit --skip-smoke-install

Documentation

Read the online documentation.

Build docs locally:

python -m sphinx -W -b html docs /tmp/openutility-docs-html

OpenUtility is alpha-stage software. Public reusable APIs are exposed through OpenUtility.__all__ and OpenUtility.utility_system.__all__.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

openutility-0.1.2.tar.gz (205.2 kB view details)

Uploaded Source

Built Distribution

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

openutility-0.1.2-py3-none-any.whl (68.5 kB view details)

Uploaded Python 3

File details

Details for the file openutility-0.1.2.tar.gz.

File metadata

  • Download URL: openutility-0.1.2.tar.gz
  • Upload date:
  • Size: 205.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for openutility-0.1.2.tar.gz
Algorithm Hash digest
SHA256 52e1d2913bd9d24991e2bf63b46e9433a5a8a0a33373084bb064f4fd575c34b6
MD5 f67d6c3872378399c8764a45dbbbeae3
BLAKE2b-256 04f45a8d3d8f4e612704812c073a93689ce836175ce3359577031ab7db99c854

See more details on using hashes here.

Provenance

The following attestation bundles were made for openutility-0.1.2.tar.gz:

Publisher: release.yml on waikato-ahuora-smart-energy-systems/OpenUtility

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file openutility-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: openutility-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 68.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for openutility-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 783bd57b37199d822a1cc990b365d0986131bd7f69776427c5731463fd951600
MD5 9f2e197e096f75d15237a294177c5438
BLAKE2b-256 0583b3636da58a1b249e5d3e772cb9cdb2973bdce2d1149b5ff173366328405c

See more details on using hashes here.

Provenance

The following attestation bundles were made for openutility-0.1.2-py3-none-any.whl:

Publisher: release.yml on waikato-ahuora-smart-energy-systems/OpenUtility

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.1.4

2 files

0.1.3

2 files

This release

0.1.2 This release

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page