12 releases

new 0.1.11 Nov 27, 2020
0.1.10 Nov 23, 2020
0.1.7 Oct 14, 2020
0.1.5 Sep 29, 2020
0.1.1 Aug 31, 2020

#24 in Math

Download history 91/week @ 2020-08-28 114/week @ 2020-09-04 102/week @ 2020-09-11 40/week @ 2020-09-18 83/week @ 2020-09-25 70/week @ 2020-10-02 73/week @ 2020-10-09 98/week @ 2020-10-16 64/week @ 2020-10-23 33/week @ 2020-10-30 127/week @ 2020-11-06 47/week @ 2020-11-13 76/week @ 2020-11-20

343 downloads per month

MIT license

580KB
7.5K SLoC

fend is an arbitrary-precision unit-aware calculator.

This is the cross-platform CLI for fend.

Unique features:

  • Arbitrary-precision arithmetic using rational numbers
  • Full support for complex numbers
  • Binary, octal, hexadecimal and all other bases between 2 and 36
  • Keep track of units, with support for SI, US and UK customary and many historical units
  • Emacs-style CLI shortcuts
  • Trigonometric functions
  • Lambda calculus

See the manual for more information.

Installation

Packaging status

Install fend by running cargo install fend in your terminal. Alternatively you can download the latest stable binaries here. fend is also available in the AUR.

You can then run fend to start a REPL session:

$ cargo install fend
...
$ fend
> 1 ft to cm
30.48 cm
>

Manual

You can find the fend manual here.

Examples

> 5'10" to cm
177.8 cm
> cos (pi/4) + i * (sin (pi/4))
approx. 0.7071067811 + 0.7071067811i
> 0b1001 + 3
0b1100
> 0xffff to decimal
65535
> 1 1/2' to cm
45.72 cm
> 1 lightyear to parsecs
approx. 0.3066013937 parsecs
> (x: 2x) pi
approx. 6.2831853071

License

fend is MIT-licensed. See LICENSE.md for more information.

fend optionally includes the GPLv3-licenced definitions.units and currency.units data files from GNU Units. This can be changed via the gpl feature defined in core/Cargo.toml.

Dependencies

~1.5MB
~28K SLoC