## Chapter 18: lojbau mekso: Mathematical Expressions in Lojban

### 14. Infix operators revisited

The following cmavo are discussed in this section:

tu'o PA null operand ge'a VUhU null operator gei VUhU exponential notation

The infix operators presented so far have always had exactly two operands, and for more or fewer operands forethought notation has been required. However, it is possible to use an operator in infix style even though it has more or fewer than two operands, through the use of a pair of tricks: the null operand “tu'o” and the null operator “ge'a”. The first is suitable when there are too few operands, the second when there are too many. For example, suppose we wanted to express the numerical negation operator “va'a” in infix form. We would use:

✥14.1 li tu'o va'a ny. du li no vu'u ny. the-number (null) additive-inverse n equals the-number zero minus n -n = 0 - n

The “tu'o” fulfills the grammatical requirement for a left operand for the infix use of “va'a”, even though semantically none is needed or wanted.

Finding a suitable example of “ge'a” requires exhibiting a ternary operator, and ternary operators are not common. The operator “gei”, however, has both a binary and a ternary use. As a binary operator, it provides a terse representation of scientific (also called “exponential”) notation. The first operand of “gei” is the exponent, and the second operand is the mantissa or fraction:

✥14.2 li cinonoki'oki'o du li bi gei ci the-number three-zero-zero-comma-comma equals the-number eight scientific three. 300,000,000 = 3 × 10^{8}

Why are the arguments to “gei” in reverse order from the conventional symbolic notation? So that “gei” can be used in forethought to allow easy specification of a large (or small) imprecise number:

✥14.3 gei reno (scientific) two-zero 10^{20}

Note, however, that although 10 is far and away the most common exponent base, it is not the only possible one. The third operand of “gei”, therefore, is the base, with 10 as the default value. Most computers internally store so-called “floating-point” numbers using 2 as the exponent base. (This has nothing to do with the fact that computers also represent all integers in base 2; the IBM 360 series used an exponent base of 16 for floating point, although each component of the number was expressed in base 2.) Here is a computer floating-point number with a value of 40:

✥14.4 papano bi'eju'u re gei pipanopano bi'eju'u re ge'a re (one-one-zero base 2) scientific (point-one-zero-one-zero base 2) with-base 2 .1010_{2}× 2^{1102}