From: Clark F Morris on
On Tue, 18 Mar 2008 19:34:51 -0600, Robert <no(a)e.mail> wrote:

>On Tue, 18 Mar 2008 09:09:44 -0600, Howard Brazee <howard(a)brazee.net> wrote:
>
>>On Mon, 17 Mar 2008 21:53:23 -0600, Robert <no(a)e.mail> wrote:
>>
>>>The others were confused. They thought binary integer was the same as binary floating
>>>point.
>>
>>It could be. I'm glad people I worked with didn't think those were
>>the same thing.
>>
>>>That's why IBM was able to sell them decimal hardware.
>>
>>So they didn't buy IBM decimal hardware for the same reasons as
>>everybody else? Was their thinking in this matter ever published?
>
>Lots of muddled thinking on numeric errors has been published. Some talk about 'binary
>arithmetic' without making a distinction between integer and floating point. Here's an
>example:

Try doing a simple divide like calculate the value of 1 / 5 in binary.
You get a never ending fraction.
>
>" Why did computers use binary in the first place?
>
> Many early computers (such as the ENIAC, or the IBM 650) were in fact decimal
>machines. In the 1950s, however, most computers turned to binary representations of
>numbers as this made useful reductions in the complexity of arithmetic units (for example,
>a binary adder requires about 15% less circuitry than a decimal adder). This reduction in
>turn led to greater reliability and lower costs.
>
> Storing decimal integers in a simple binary coded decimal (BCD) form, rather than a
>pure binary form, also uses up to 20% more storage than the binary form, depending on the
>coding used.
>
> Decimal arithmetic, therefore, is inherently less efficient than binary arithmetic,
>and at the time this justified the switch to binary floating-point arithmetic (just as a
>two-digit representation for the year in a date was justifiable at the time). However, the
>programming and conversion overheads and other costs of using binary arithmetic suggest
>that hardware decimal arithmetic is now the more economical option for most applications.
>
> Has any company formally announced hardware decimal floating-point support?
>
> Yes. IBM announced on 18 April 2007 hardware decimal floating point facilities for IBM
>z9 EC and z9 BC:
>
>Since then, IBM has also announced support for decimal floating-point in the Power6
>processors, and has released details of the decimal floating-point unit in the z6
>microprocessor.
>http://www2.hursley.ibm.com/decimal/decifaq3.html#calcs
>
>Cowlishaw accidentally overlooks the fact that every Intel x86 processor/FPU made since
>1980 has supported 17 digit hardware decimal floating point. Now that IEEE 754r is on the
>horizon, Intel is dropping it (I think they already did in Itanium).
>
>"based on Intel�s investigation on the frequency of
>use and performance requirements for decimal processing in existing applications, the
>potential benefits of hardware-implemented decimal arithmetic do not justify its cost in
>terms of dedicating transistors and power consumption to it on a processor core.
>Consequently, Intel is proposing the use of software emulation instead.
>
>Just as the computing landscape changed dramatically from the ratification of the first
>floating point standard to its current revision, equally big changes are in store for the
>next 15 to 20 years. The multi-core processor revolution has begun and is poised to make
>even greater leaps in performance (and performance per watt) for personal computers.
>Intel�s research and development plans suggest the possibility of a 256-core processor by
>the 2015 time frame."
>http://www.intel.com/standards/floatingpoint.pdf
From: Robert on
On Mon, 31 Mar 2008 21:55:10 -0300, Clark F Morris <cfmpublic(a)ns.sympatico.ca> wrote:

>On Tue, 18 Mar 2008 19:34:51 -0600, Robert <no(a)e.mail> wrote:
>

>>Lots of muddled thinking on numeric errors has been published. Some talk about 'binary
>>arithmetic' without making a distinction between integer and floating point. Here's an
>>example:
>
>Try doing a simple divide like calculate the value of 1 / 5 in binary.

OK.

01 numerator value 1 binary pic 9(9).
01 denominator value 5 binary pic 9(9).
01 quotient binary pic 9(9)v9(4).

compute quotient = numerator / denominator
display quotient

0000000002000

>You get a never ending fraction.

Looks pretty diadic to me.
From: Michael Mattias on
"Robert" <no(a)e.mail> wrote in message
news:jbd3v3tomdipsgke42j5cklujltahbtjle(a)4ax.com...
> On Mon, 31 Mar 2008 21:55:10 -0300, Clark F Morris
> <cfmpublic(a)ns.sympatico.ca> wrote:
>
>>Try doing a simple divide like calculate the value of 1 / 5 in binary.
>
> OK.
>
> 01 numerator value 1 binary pic 9(9).
> 01 denominator value 5 binary pic 9(9).
> 01 quotient binary pic 9(9)v9(4).
>
> compute quotient = numerator / denominator
> display quotient
>
> 0000000002000
>
>>You get a never ending fraction.
>
> Looks pretty diadic to me.

That's because you did not do it in binary, you did it in decimal.
One-fifth is rational in decimal, but irrational in binary.



MCM


From: Clark F Morris on
On Mon, 31 Mar 2008 22:37:12 -0600, Robert <no(a)e.mail> wrote:

>On Mon, 31 Mar 2008 21:55:10 -0300, Clark F Morris <cfmpublic(a)ns.sympatico.ca> wrote:
>
>>On Tue, 18 Mar 2008 19:34:51 -0600, Robert <no(a)e.mail> wrote:
>>
>
>>>Lots of muddled thinking on numeric errors has been published. Some talk about 'binary
>>>arithmetic' without making a distinction between integer and floating point. Here's an
>>>example:
>>
>>Try doing a simple divide like calculate the value of 1 / 5 in binary.
>
>OK.
>
>01 numerator value 1 binary pic 9(9).
>01 denominator value 5 binary pic 9(9).
>01 quotient binary pic 9(9)v9(4).
>
>compute quotient = numerator / denominator
>display quotient
>
>0000000002000
>
>>You get a never ending fraction.
>
>Looks pretty diadic to me.
You may have to do this in Assembler to get the results that I am
talking about. Take a look at the generated instructions. If I had
access to an IBM mainframe I would compile a small test program to see
what the underlying code is.

Clark
From: tlmfru on

Clark F Morris <cfmpublic(a)ns.sympatico.ca> wrote in message
news:if05v3503beg04nonbeci3n8eqo2vill79(a)4ax.com...
> On Mon, 31 Mar 2008 22:37:12 -0600, Robert <no(a)e.mail> wrote:
>
> >On Mon, 31 Mar 2008 21:55:10 -0300, Clark F Morris
<cfmpublic(a)ns.sympatico.ca> wrote:
> >
> >>On Tue, 18 Mar 2008 19:34:51 -0600, Robert <no(a)e.mail> wrote:
> >>
> >
> >>>Lots of muddled thinking on numeric errors has been published. Some
talk about 'binary
> >>>arithmetic' without making a distinction between integer and floating
point. Here's an
> >>>example:
> >>
> >>Try doing a simple divide like calculate the value of 1 / 5 in binary.
> >
> >OK.
> >
> >01 numerator value 1 binary pic 9(9).
> >01 denominator value 5 binary pic 9(9).
> >01 quotient binary pic 9(9)v9(4).
> >
> >compute quotient = numerator / denominator
> >display quotient
> >
> >0000000002000
> >
> >>You get a never ending fraction.
> >
> >Looks pretty diadic to me.


He's right, you know.

0.2 (decimal) in binary = 1/8 + 1/16 + 1/128 + 1/256 ... = .00110011 ... =
0.19921875. etc. Obviously binary division is done by black magic
involving shifts & counts.

PL