Skip to content

ivarout/py_unit_converter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

py_unit_converter

A simple python module to calculate unit conversion factors. To use, simply copy unit_converter.py to wherever appropriate.

To calculate the unit conversion factor between two units:

>>> unit_conversion_factor(source_unit="lb", target_unit="kg")

0.45359237

>>> unit_conversion_factor("m/s^2","in/ms^2")

3.937007874015748e-05

To check if units are compatible:

>>> units_compatible("lb/s", "kg/h")

True

>>> units_compatible("m/s", "m/s^2")

False

Releases

No releases published

Packages

No packages published

Languages