$ cat .units
period(len) units=[m;s] 2pi*sqrt(len/gravity) ; (period/2pi)^2 * gravity
$ units
2980 units, 109 prefixes, 97 nonlinear units
You have: period(20cm)
You want:
Definition: 0.89729351 s
You have: period(20cm)
You want: ms
* 897.29351
/ 0.0011144625
You have: period(2ft)
You want: ms
* 1566.5419
/ 0.00063834872
You have: 5 GiB
You want: bytes
* 5.3687091e+09
/ 1.8626451e-10
You have: 5 hundred million
You want:
Definition: 5e+08
You have: tempF(100)
You want: tempC
37.777778
is it supposed to be a competitor? learn how to use a new language? I don't get it.I like the idea of keeping units, but I'm not sure this makes things easier:
≫ V * A / J
V × (A / J)
= 1 V·A/J
You have: V*A/J
You want:
Definition: 1 / s