Skip to main content

Community Edition: SDK for structural collapse detection in DAE systems (limited to 5 variables, rate-limited)

Project description

PyPI Python License

NAPIX Stability Engine

A professional SDK for detecting structural collapse in Differential-Algebraic Equation (DAE) systems before failure occurs.

Quick Start

from napix_stability import StabilityEngine, StabilityResult

engine = StabilityEngine(w1=0.4, w2=0.35, w3=0.25)

system = {
    "equations": ["x1 - x2 + sin(t)", "x1 + x2 - cos(t)"],
    "constraints": ["x1**2 + x2**2 - 1"],
    "variables": ["x1", "x2"]
}

data = {"x1": 0.8, "x2": 0.6}

result = engine.analyze(system, data)
print(f"Risk Score: {result.risk_score:.1f}")
print(f"State: {result.state}")
print(f"Time to Failure: {result.time_to_failure} min")

Features

  • Constraint Sensitivity Analysis — Detect Implicit Function Theorem breakdown
  • Reduced Jacobian Spectral Radius — Identify eigenvalue blow-up
  • Pencil Condition Number — Quantify algebraic loop ill-conditioning
  • Unified Risk Score (0–100) — Single actionable metric
  • State Classification — STABLE / PRE-COLLAPSE / IMMINENT_SHOCK
  • Time-to-Failure Estimation — Trend-based extrapolation

Installation

pip install napix-stability

Optional GPU acceleration:

pip install napix-stability[gpu]

API Reference

StabilityEngine(w1=0.4, w2=0.35, w3=0.25)

Parameter Description
w1 Weight for constraint sensitivity (default 0.4)
w2 Weight for spectral radius (default 0.35)
w3 Weight for pencil condition (default 0.25)

engine.analyze(system_definition, live_data) → StabilityResult

StabilityResult fields:

Field Type Description
sigma_g float Constraint sensitivity
lambda_max float Spectral radius of reduced Jacobian
kappa_p float Pencil condition number
risk_score float Unified collapse score (0–100)
state str Classification
dominant_mode str Driving instability mode
time_to_failure float or None Estimated minutes until collapse

Use Cases

  • Aviation — Detect flight control surface jamming via actuator DAE models
  • Energy — Monitor power grid voltage collapse boundaries
  • Finance — Identify systemic risk in coupled asset-liability models
  • Healthcare — Predict hemodynamic decompensation in critical care

License

MIT

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

napix_stability-1.1.1.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

napix_stability-1.1.1-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file napix_stability-1.1.1.tar.gz.

File metadata

  • Download URL: napix_stability-1.1.1.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.5

File hashes

Hashes for napix_stability-1.1.1.tar.gz
Algorithm Hash digest
SHA256 54c5df1cfe8f0c76d4b85c10adc732747736f8e97cb1db7bf11eb6f31f424a7b
MD5 8a5cf818d0ccadea33be10e067f9c76f
BLAKE2b-256 423c8f001cebe36b1921a8cf7b02da423a628173dee6f5cc9cdb5a3342fea465

See more details on using hashes here.

File details

Details for the file napix_stability-1.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for napix_stability-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e28bf87c882e55640ef5fb9f1f3911dfe91d706bc6fa32fb51429d1bf1004ef7
MD5 13e26e7a9d118eba8e7c8e57aaada812
BLAKE2b-256 7e847b2a3d653898acd68eee2ab859c106776968aace4a0c016c45fca0f0380c

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