Symmetric level-index arithmetic
The level-index (LI) representation of numbers, and its algorithms for arithmetic operations, were introduced by Charles Clenshaw and Frank Olver in 1984.[1]
The symmetric form of the LI system and its arithmetic operations were presented by Clenshaw and Peter Turner in 1987.[2]
Michael Anuta, Daniel Lozier, Nicolas Schabanel and Turner developed the algorithm for symmetric level-index (SLI) arithmetic, and a parallel implementation of it. There has been extensive work on developing the SLI arithmetic algorithms and extending them to complex and vector arithmetic operations.
Definition
[edit]The idea of the level-index system is to represent a non-negative real number X as
where , and the process of exponentiation is performed ℓ times, with . ℓ and f are the level and index of X respectively. x = ℓ + f is the LI image of X. For example,
so its LI image is
The mapping function is called the generalized logarithm function. It is defined as
and it maps onto itself monotonically, thus being invertible on this interval. The inverse, the generalized exponential function, is defined by
The density of values X represented by x has no discontinuities as we go from level ℓ to ℓ + 1 (a very desirable property) since
The generalized logarithm function is closely related to the iterated logarithm used in computer science analysis of algorithms.
A sign bit may also be used to allow negative numbers. One takes sgn(X) and stores it as a boolean sX (0 only occurs when X = 0 so could be stored either way, +1 chosen here). Mathematically, this is equivalent to taking the negative (additive inverse) of a number, and finding the SLI image for that. Using one bit for the sign enables the representation of negative numbers.
The symmetric form is used to allow negative exponents, if the magnitude of X is less than 1. One takes sgn(log(X)) or sgn(|X| − |X|−1) and stores it as a boolean rX (0 only occurs when X = 1 so could be stored either way, +1 chosen here). Mathematically, this is equivalent to taking the reciprocal (multiplicative inverse) of a small-magnitude number, and finding the SLI image for that. Using one bit for the reciprocal sign enables the representation of extremely small numbers.
Formally, we can define the SLI representation for an arbitrary real X (not 0 or 1) as
where sX is the sign (additive inversion or not) of X, and rX is the reciprocal sign (multiplicative inversion or not) as in the following equations:
whereas for X = 0 or 1, we have
For example,
and its SLI representation is
Adding
[edit]Most arithmetic operations in LI can be easily reduced to addition due to the nature of logarithms.[3] If we have some x, y, and z related by , taking the logarithm of both sides gives us , and once more gives us . The only non-trivial operation left to define is addition.
The problem of addition is posed as being able to find some z, given an arbitrary x and y with , such that . We also say that the levels of , , and are l, m, and n, and their indices are f, g, and h. It is helpful to define these 3 sequences, each indexed with some j:
With this defined, we can now state that z is equal to for the smallest j where . To find the actual values in these sequences, we use a set of recursive definitions each with an initial condition:
This can also be used to implement subtraction by changing the initial condition for c to be .
When using SLI, is not the only case; and should also be considered; typically called "large", "mixed", and "small" arithmetic. In mixed arithmetic, we replace the b sequence with and define as ; and in small arithmetic we replace the b sequence with , and becomes
See also
[edit]References
[edit]- ↑ Clenshaw, Charles William; Olver, Frank William John (1984). "Beyond floating point". Journal of the ACM. 31 (2): 319–328. doi:10.1145/62.322429.
- ↑ Clenshaw, Charles William; Turner, Peter R. (1988-10-01) [1986-09-16, 1987-06-04]. "The Symmetric Level-Index System". IMA Journal of Numerical Analysis. 8 (4). Oxford University Press, Institute of Mathematics and Its Applications: 517–526. doi:10.1093/imanum/8.4.517. ISSN 0272-4979. OCLC 42026743. Retrieved 2018-07-10.
- ↑ Clenshaw, Charles William; Olver, Frank William John; Turner, Peter Richard (1989). "Level-index arithmetic: An introductory survey". Numerical Analysis and Parallel Processing (Conference proceedings / The Lancaster Numerical Analysis Summer School 1987). Lecture Notes in Mathematics (LNM). 1397. Springer Berlin Heidelberg: 95–169. doi:10.1007/BFb0085718. ISBN 978-3-540-46732-8. Retrieved 2026-08-05.
{{cite journal}}: CS1 maint: periodical has ISBN (link)
Further reading
[edit]- Clenshaw, Charles William; Olver, Frank William John; Turner, Peter R. (1989). "Level-index arithmetic: An introductory survey". Numerical Analysis and Parallel Processing (Conference proceedings / The Lancaster Numerical Analysis Summer School 1987). Lecture Notes in Mathematics (LNM). 1397: 95–168. doi:10.1007/BFb0085718. ISBN 978-3-540-51645-3.
{{cite journal}}: CS1 maint: periodical has ISBN (link) - Clenshaw, Charles William; Turner, Peter R. (1989-06-23) [1988-10-04]. "Root Squaring Using Level-Index Arithmetic". Computing. 43 (2). Springer-Verlag: 171–185. doi:10.1007/BF02241860. ISSN 0010-485X.
- Zehendner, Eberhard (Summer 2008). "Rechnerarithmetik: Logarithmische Zahlensysteme" (PDF) (Lecture script) (in German). Friedrich-Schiller-Universität Jena. pp. 21–22. Archived (PDF) from the original on 2018-07-09. Retrieved 2018-07-09.
- Hayes, Brian (September–October 2009). "The Higher Arithmetic". American Scientist. 97 (5): 364–368. doi:10.1511/2009.80.364. Archived from the original on 2018-07-09. Retrieved 2018-07-09. . Also reprinted in: Hayes, Brian (2017). "Chapter 8: Higher Arithmetic". Foolproof, and Other Mathematical Meditations (1 ed.). The MIT Press. pp. 113–126. ISBN 978-0-26203686-3. ISBN 0-26203686-X.
External links
[edit]- sli-c-library (hosted by Google Code), "C++ Implementation of Symmetric Level-Index Arithmetic".