chickadee » simple-units » make-units

(make-units NAME BASE-NAME [system: UNITS-SYSTEM] UNIT-SPEC...) => unitssyntax

Returns a new units.

Also pollutes the UNITS-SYSTEM with the new units, unless it already exists by-name. In which case the new units is said to be standalone.

NAME is a symbol, the name of the units.

BASE-NAME is a symbol, the name of the unit with factor 1.

UNIT-SPEC is the form <unit-spec>.

<unit-spec> := <unit-name> <unit-value>

<unit-value> ::= <unit-factor> <unit-value> ::= <unit-name> <unit-value> ::= (<unit-factor> <unit-name>)

<unit-name> ::= <symbol>

<unit-factor> ::= <number>