Wikipedia:Reference desk/Archives/Mathematics/2017 August 6

= August 6 =

Is there any advantage to a floating point number system for computer that is other than binary or base ten (BCD)
Floating point number system on computers are binary that is base two. The only other floating point number system is BCD or based ten.

But binary floating point cannot represent 1/10 accurately while both binary and BCD/base ten cannot represent 1/3 accurately.

So why not have a floating point number system using base 720720 which has many many divisors because it is Superior highly composite number? 96.66.16.169 (talk) 16:00, 6 August 2017 (UTC)
 * It is not efficient to perform computations and store information with such a huge base. At this point, you might as well store the rational number exactly (in the form $$(p,q)$$ representing $$p/q$$).--Jasper Deng (talk) 18:14, 6 August 2017 (UTC)
 * Many calculator programs do store results as rationals. This avoids rounding error for simple calculations such as 1.01 * 100 - 101 not being 0. It does not remove rounding errors for more complex operations though, e.g. (1/(√5 - 2) - 2)2 - 5 not 0.
 * It should be noted that BCD is not exactly the same a decimal; it uses two digits like binary but each group of four represents 1 decimal digit. Computers can easily use octal and hexadecimal using a similar scheme. You could have system that uses a group of 20 binary digits to store 1 base-720720 digit, but you'd still run into rounding errors when, say, the denomitor is 17. --RDBury (talk) 20:10, 6 August 2017 (UTC)


 * It is more efficient to use a power of 2. Bubba73 You talkin' to me? 23:19, 6 August 2017 (UTC)


 * Densely packed decimal used in IEEE decimal floating point uses base 1000 to hold the digits which is almost as efficient - efficiency isn't a major consideration for that. Dmcq (talk) 09:18, 9 August 2017 (UTC)


 * A floating point representation on a ternary computer might have some advantages. For example, repeated rounding would be stable (i.e. rounding once to the final precision produces the same result as with any number of intermediate-precision rounding steps); no tie-breaking rule is needed from a number that is already represented using a finite number of ternary digits. This stability does not extend to common scenarios though: rounding numbers before addition can still lead to a different result than rounding the result.  —Quondum 02:55, 13 August 2017 (UTC)