Notes
- When an expression is here said to be "undefined," it means that, in the absence of external information about the interpretation of the expression, it is semantically void, meaningless, and/or nonsensical.
- Mathematical operators take one or more operands, which are here referred to by an 'x' subscripted with a number.
- Operators defined here as "unary" are defined as operating on their first operand that is not equal to tu'o (referred to as "the operand" within the respective definitions), regardless of where it occurs in the operand list.
- See also: CLL section 18.16, example 16.3 and the paragraph before it, in which the operand of va'a is in the x_1 place; CLL section 18.14, example 14.1, in which the operand of va'a is in the x_2 place.
- If all operands of an operator are tu'o, the value of the expression is equal to tu'o.
- If an operand described in an operator's definition is missing from the operator's operand list and there is no default value given, the missing operand shall be interpreted as tu'o.
- If one or more extra operands not described in an operator's definition are present in the operator's operand list, they affect the evaluation in an undefined or unspecified manner analogous to sumti attached to a selbri with do'e.
- Lojban mathematical operators are defined in terms of conventional mathematical operators, and thus there is an implicit type system used in determining the value of an expression. Mekso operands may be of any of the following types:
- number — a "number" production in the formal grammar, usually corresponding to an element of the complex plane
- array — an array, vector, ordered list/set, or tuple of one or more mekso values, constructed using jo'i
- matrix — a composition of one or more arrays of numbers, all of the same size, constructed using pi'a or sa'i
- function
- If an operator is applied to operands of a type which its definition does not address, the expression is undefined.
- The operand tu'o is polymorphic; its type in an expression is determined by its surrounding context.
- Operator-specific type information (currently in the "Notes" subsections) needs to be included in the main definitions somehow without being too clunky.
Proposed Definitions And Examples
cmavo: fu'u (VUhU0)
Current definition
unspecif operator — n-ary mathematical operator: elliptical/unspecified mathematical expression (mex) operator -
Proposed definition
elliptical/unspecified mathematical operator
Proposed keyword
Examples of fu'u Usage
Notes
- This is the semantic analogue of zo'e, co'e, et alii.
Proposed Definition of ge'a
- ge'a (VUhU0)
- null operator — mathematical operator: null mathematical expression (mex) operator (used in >2-ary ops) --
Examples of ge'a Usage
cmavo: fe'i (VUhU1)
Current definition
divided by — n-ary mathematical operator: divided by; division operator; (((a / b) / c) / ...) --
Proposed definition
mathematical division operator, n-ary, left-associative
Proposed keyword
Notes
- The operands of fe'i are numbers, and a fe'i expression evaluates to a number.
- When fe'i has only one operand, it is the identity function.
Examples of fe'i Usage
cmavo: pi'i (VUhU1)
Current definition
times — n-ary mathematical operator: times; multiplication operator; (((a * b) * c) * ...) --
Proposed definition
mathematical multiplication operator, n-ary, left-associative
Proposed keywords
Notes
- When reducing a pi'i expression from left to right, the types of the two operands considered at each point must take one of the two forms:
- number and number — standard mathematical multiplication; evalutes to a number
- number and matrix or matrix and number — scaling the elements of a matrix by a factor; evaluates to a matrix
- number and array of numbers or array of numbers and number — scaling the elements of an array by a factor; evaluates to an array of numbers
- matrix and matrix — standard matrix multiplication; the number of columns in the first matrix must equal the number of rows in the right matrix, otherwise the result is undefined; evaluates to a matrix
- matrix and array of numbers — The operator sa'i is implicitly applied to the array, and the expression is then evaluated as a matrix-matrix multiplication, yielding a one-column matrix that is then implicitly converted to an array of the numbers in its column.
- When pi'i has only one operand, it is the identity function.
Examples of pi'i Usage
Proposed Definition of su'i
- su'i (VUhU1)
- plus — n-ary mathematical operator: plus; addition operator; (((a + b) + c) + ...) --
Examples of su'i Usage
Proposed Definition of vu'u
- vu'u (VUhU1)
- minus — n-ary mathematical operator: minus; subtraction operator; (((a - b) - c) - ...) --
Examples of vu'u Usage
Proposed Definition of fa'i
- fa'i (VUhU2)
- reciprocal of — unary mathematical operator: reciprocal; multiplicative inverse; 1/a --
Examples of fa'i Usage
cmavo: gei (VUhU2)
Current definition
exponential notation — trinary mathematical operator: order of magnitude/value/base; b * (c to the a power) --
Proposed definition
scientific notation: x_2 * (x_3 ^ x_1); x_2 defaults to 1; x_3 defaults to 10
Proposed keyword
Notes
- The operands of gei are numbers, and a gei expression evaluates to a number.
Examples of gei Usage
- li cinonoki'oki'o du li bi gei ci
- 300,000,000 = 3 * 10^8 (CLL, §18.14, example 14.2)
- gei reno
- 10^20 (CLL, §18.14, example 14.3)
- papano bi'eju'u re gei pipanopano bi'eju'u re ge'a re
- .1010_2 * 2 ^ 110_2 (CLL, §18.14, example 14.4)
Proposed Definition of ju'u
- ju'u (VUhU2)
- number base — binary mathematical operator: number base; a interpreted in the base b --
Examples of ju'u Usage
Proposed Definition of pa'i
- pa'i (VUhU2)
- ratio — binary mathematical operator: ratio; the ratio of a to b --
Examples of pa'i Usage
Proposed Definition of te'a
- te'a (VUhU2)
- to the power — binary mathematical operator: to the power; exponential; a to the b power --
Examples of te'a Usage
Proposed Definition of cu'a
- cu'a (VUhU3)
- absolute value — unary mathematical operator: absolute value/norm |a| --
Examples of cu'a Usage
Proposed Definition of de'o
- de'o (VUhU3)
- logarithm — binary mathematical operator: logarithm; log/ln a to base b; default base 10 or e --
Examples of de'o Usage
Proposed Definition of fe'a
- fe'a (VUhU3)
- nth root of — binary mathematical operator: nth root of; inverse power a to the 1/b power --
Examples of fe'a Usage
Proposed Definition of ne'o
- ne'o (VUhU3)
- factorial — unary mathematical operator: factorial; a! --
Examples of ne'o Usage
Proposed Definition of va'a
- va'a (VUhU3)
- additive inverse — unary mathematical operator: additive inverse; - a --
Examples of va'a Usage
Proposed Definition of pi'a
- pi'a (VUhU4)
- matrix of rows — n-ary mathematical operator: operands are vectors to be treated as matrix rows --
Examples of pi'a Usage
Proposed Definition of re'a
- re'a (VUhU4)
- transpose — unary mathematical operator: matrix transpose/dual; A* --
Examples of re'a Usage
Proposed Definition of ri'o
- ri'o (VUhU4)
- integral — trinary mathematical operator: integral of a with respect to b over range c --
Examples of ri'o Usage
Proposed Definition of sa'i
- sa'i (VUhU4)
- matrix of columns — n-ary mathematical operator: operands are vectors to be treated as matrix columns --
Examples of sa'i Usage
Proposed Definition of sa'o
- sa'o (VUhU4)
- derivative — trinary mathematical operator: derivative of a with respect to b of degree c --
Examples of sa'o Usage
Proposed Definition of si'i
- si'i (VUhU4)
- sigma summation — trinary mathematical operator: sigma summation of a using variable b over range c --
Examples of si'i Usage
Impact