Skip to main content

cke solver for mm1 queues

Project description

A Continuous Kolmogorov Equation (CKE) solver for M/M/1 queueing systems.

pypi python license

Overview

mm1cke provides a fast and accurate solver for the transient behavior of M/M/1 queues using the continuous Kolmogorov equations (CKE). It is designed for researchers and practitioners in operations research, queueing theory, and performance analysis.

Features

  • Transient analysis of M/M/1 queues

  • Vectorized and efficient implementation

  • Outputs results as Polars DataFrames

  • Easy integration with scientific Python stack

Installation

Install with pip:

pip install mm1cke

Requirements

  • Python >= 3.11

  • simpy >= 4.1, < 5

  • matplotlib >= 3.10, < 4

  • polars >= 1.30, < 4

  • rich >= 14

  • scipy >= 1.15

  • seaborn >= 0.13

  • pydantic >= 2.11

Usage Example

from mm1cke import TransientCase, solve_transient

case = TransientCase(L_0=9, λ=0.88, μ=1, ls_max=500, time_step=0.5)
probs_df = solve_transient(case)
print(probs_df)

# Calculate performance measures (mean and coefficient of variation)
from mm1cke.utils import calculate_performance_measures
plot_df = calculate_performance_measures(probs_df)
print(plot_df)

# Plotting (optional)
import seaborn as sns
import matplotlib.pyplot as plt
ax = sns.lineplot(plot_df, x="t", y="e_l_s")
plt.show()

API Reference

  • mm1cke.TransientCase: Configuration for a transient M/M/1 queue case.

  • mm1cke.solve_transient(case: TransientCase) -> polars.DataFrame: Solves the transient CKE for the given case.

  • mm1cke.utils.calculate_performance_measures(probs_df: polars.DataFrame): Computes mean and coefficient of variation of the queue length over time.

License

MIT License. See LICENSE file for details.

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

mm1cke-0.4.0.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

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

mm1cke-0.4.0-py3-none-any.whl (5.7 kB view details)

Uploaded Python 3

File details

Details for the file mm1cke-0.4.0.tar.gz.

File metadata

  • Download URL: mm1cke-0.4.0.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.4

File hashes

Hashes for mm1cke-0.4.0.tar.gz
Algorithm Hash digest
SHA256 d606034ed85ad0b1e9ffa9b10cfbe94a9bc80968d8ac72fdc9f6a2539e530344
MD5 3a0bd3ae30bc1416af68e1519cfd2744
BLAKE2b-256 52bab55130fb4943ab2f0e320c81bc6b2e533f2f9a22a33d03939b5ecf8035a3

See more details on using hashes here.

File details

Details for the file mm1cke-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: mm1cke-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 5.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.4

File hashes

Hashes for mm1cke-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 01fe4cbedd17a0e5fdc7b7605cede5aced0d23efc3f6a511dd3f7d0937d1bf4c
MD5 beb69062cfb3f78c6905018ed6efdc2a
BLAKE2b-256 f47cbb8dcff7aa9db42fa9d6c680305c20a1d2f8b86d3e3d545f2a58528cb67f

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