Skip to main content

A simple framework to work with physical magnitudes

Project description

Properunits

A simple framework to work with physical magnitudes

Motivation

Properunits does one simple job: it helps you define physical magnitudes in Python using units and automatically convert them to SI units so that downstream calculations are all done consistently.

Properunits does not attempt to do universal unit conversion or tries to implement operations that preserve and transform the units. It is meant to extract numerical values that can be used anywhere without having to worry about unit conversion, while keeping information on the original value and units used.

Status

Properunits is still in development. Please check the documentation in readthedocs.

Quick install

Through pypi:

pip install properunits

Usage

from properunits import Temperature, Pressure

T = Temperature(100, 'C')
p = Pressure(1, 'bar')

print(T.x, T.units) # Return value in SI units.

Copyright and license

Properunits is distributed under the terms of MIT License.

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

properunits-0.0.2.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

properunits-0.0.2-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file properunits-0.0.2.tar.gz.

File metadata

  • Download URL: properunits-0.0.2.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for properunits-0.0.2.tar.gz
Algorithm Hash digest
SHA256 261ead2c38f451d87a76932e956661c03779f7a3fd5bddeb38657ebf8581851a
MD5 d2118151217c075b9221334708d3bfd0
BLAKE2b-256 566b19b967fc0e684f448432387980796ad82cd43f55cad4f80a6b3b63d34b5e

See more details on using hashes here.

File details

Details for the file properunits-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: properunits-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 6.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for properunits-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 782659a2aab2e5bcf548b1a4c5e52930f5f2c7c5cff8ecbf1f86bc5d6d55e409
MD5 0251750175fd64f9bfa0a70ec9b36872
BLAKE2b-256 d7a2612783973287cc7536aa9dd957db320f7afe967a9045d67ab7456eb1d604

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page