Is it possible to consider floating-point arithmetic as some common algebraic structure?
For example, consider something like simplified IEEE754 single precision binary floating-point subset of numbers that consist of 1 sign bit, 23-bit mantissa and 8-bit exponent
Let $\mathcal{F}$ be a floating-point set which consists of:
- finite floating-point numbers, such that each number is described by three integers: $(-1)^{s}\cdot M\cdot 2^{q} $. $s$ is a sign($0$ or $1$), $ \ M$ and $q$ must be integers in the ranges $0$ through $2^{23} -1 $ and $-128$ to $127$ respectively.
- two infinities: $+\infty$ and $-\infty$
- NaN (not a number)
Let's consider four operations defined on the $\mathcal{F}$ : summation, subtraction, multiplication and division(as multiplication by a reciprocal).
The result is NaN in each of the following cases:
– On of the operands is NaN
– The divisions 0/0 and ±∞/±∞
– The multiplications 0×±∞ and ±∞×0
– The additions ∞ + (−∞), (−∞) + ∞ and equivalent subtractions
If sum or product of finite numbers cannot be represented as finite floating-point number, the result is infinity.
Finally, let $\mathfrak F$ be an algebraic structure with the set and operations we have defined.
So, is it possible to characterize this structure somehow?
Excuse me if my question is too absurd 🙂
Best Answer
Look into D.E. Knuth's The Art of Computer Programming, Vol. 2, Section 4.2.2 A, p. 214-223, he gives an axiomatic approach of floating point arithmetic which seems to be what you are looking for.