Skip to main content

meenpy is a library of utilities for mechanical engineering problem solving.

Project description

meenpy

meenpy is a library of utilities for mechanical engineering problem solving.

meenpy.numerics enables the succinct articulation equations, efficient assembly of systems, and provides a transparent solving interface.

Installation

Check out the package manager uv and add meenpy to your project or workspace.

uv add meenpy

Alternatively, install meenpy directly with pip.

pip install meenpy

Usage

from meenpy.numerics import ScalarEquation, MatrixEquation, TabularEquation, System
import sympy as sym, pandas as pd

## Variable Definitions
T, x, p, v = sym.symbols("T, x, p, v")
T_amb, h, Qd = sym.symbols("T_amb, h, Qd")
column_map = {T: "Temperature", x: "Quality", p: "Pressure", v: "Specific Volume"}

## Equation Definitions
water = TabularEquation(pd.read_csv("test/water.csv"), ["Temperature", "Quality"], residual_type="all_column_differential")
convection = ScalarEquation(Qd, h * (T - T_amb))

## System Composition and Solution
water_system = System([water, convection], column_map)
water_system_solution = water_system.solve({T_amb: 25, h: 1, Qd: 100}, {T: 115, x: 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.

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

meenpy-0.1.3.tar.gz (7.4 kB view details)

Uploaded Source

Built Distribution

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

meenpy-0.1.3-py3-none-any.whl (8.5 kB view details)

Uploaded Python 3

File details

Details for the file meenpy-0.1.3.tar.gz.

File metadata

  • Download URL: meenpy-0.1.3.tar.gz
  • Upload date:
  • Size: 7.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.8.22

File hashes

Hashes for meenpy-0.1.3.tar.gz
Algorithm Hash digest
SHA256 58f6809a45d83c72ad444e4c10a4c8401b80763108fac9e284b4539a6e395993
MD5 6d9c41fd0a76cf5c6ffeee1089f323be
BLAKE2b-256 27458455109cfae9385f326801325314c515ed401c1a63b229b3727fd058490a

See more details on using hashes here.

File details

Details for the file meenpy-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: meenpy-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 8.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.8.22

File hashes

Hashes for meenpy-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 9fc69dccf323ec1cb476d61a9890b5267fc51444f4eff5ef3dde2b5b0d1d477e
MD5 defa676314b2ae827dbe967fc0481619
BLAKE2b-256 75338134e15fe118b78dc2c3a2b1eb2581d3742ce5d999cd1bc9fae654ce3502

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