Feet down below his knee

Following up this post from yesterday, I downloaded and compiled GNU units to give it a test run. Although it’s feature-packed, it won’t let me use units like in\sqrt{\textrm{in}}. Also, the inclusion of addition/subtraction and the change to equal precedence for multiplication and division make it, I think, a little less usable than the traditional units. For example, in traditional units, btu/hr ft degF is interpreted as

BTUhr ft F\frac{\textrm{BTU}}{\textrm{hr ft F}}

because multiplication has higher precedence than division. In GNU units, you’d have to do that as btu/hr/ft/degF. Since you’d say the unit as “BTU per hour foot degree Fahrenheit,” I think the traditional method is better.

I made a couple of additions to my local units.lib file to handle, in a limited way, the in\sqrt{\textrm{in}} and m\sqrt{\textrm{m}} units that come up in fracture toughness values.

rootm       !k!
rootin      0.1593737745 rootm

This defines rootm as a fundamental unit and rootin as a derived unit. The proportionality constant is the square root of 0.0254. Now I can do things like

You have: 25 MPa rootm
You want: ksi rootin
  * 22.751193
  / 0.04395374

which is pretty much all I need the root units for.

Tags: