GithubHelp home page GithubHelp logo

plumpmath / rink-rs Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tiffany352/rink-rs

0.0 0.0 0.0 821 KB

Unit conversion tool and library written in rust

License: GNU General Public License v3.0

Rust 96.16% HTML 3.84%

rink-rs's Introduction

Rink

Build Status codecov crates.io downloads

Rink is a unit-aware calculator. It can be used for physics and engineering calculations, as well as dimensionality analysis.

Rink supports most systems of measurements including SI, CGS, natural, international customary, US customary, UK customary, as well as historical measurements. In addition, Rink supports currency conversions.

Unique features:

  • High-precision bignum rational arithmetic
  • Detailed error messages
  • Shows SI physical quantities
  • Finds applicable SI derived units automatically
  • Helps with dimensionality analysis, such as by offering unit factorizations and finding units for quantities.
  • Open source
  • First-class support for non-absolute temperature scales

Describes (hopefully) everything you need to know to use Rink's expression language.

Rink is available via a web interface in addition to the terminal-based interface. Useful for doing calculations on mobile.

Install

cargo install rink

Running rink will give you a CLI interface for you to enter queries.

Examples

> kWh/year -> W
0.1140795 watt (power)
> W -> J
Conformance error: 1 watt (power) != 1 joule (energy)
Suggestions: multiply left side by time, multiply right side by frequency
> gallon gasoline -> kWh
approx. 36.63388 kWh (energy)
> googol^100
1.0e10000 (dimensionless)

Library Usage

Add this to your Cargo.toml:

[dependencies]
rink = "0.4"

and this to your crate root:

extern crate rink;

License

Rink source code is licensed under the Mozilla Public License, version 2. See LICENSE-MPL for details.

The data file definitions.units is licensed under the GNU General Public License, version 3. See LICENSE-GPL for details.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work will grant the rights lined out in the MPL, including larger works with secondary licenses.

Changelog

See here: https://github.com/tiffany352/rink-rs/releases

rink-rs's People

Contributors

yzhs avatar tiffany352 avatar whitequark avatar causal-agent avatar deeunderscore avatar delan avatar aaron1011 avatar bhipple avatar lpghatguy avatar murarth avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.