Boost logo

Boost :

From: Peter Bell (pbell_at_[hidden])
Date: 2001-05-09 17:47:25


John Max Skaller wrote:
>
> scleary_at_[hidden] wrote:
>
> > Fixed-point arithmetic therefore shares several annoying attributes with
> > floating-point arithmetic; as an extreme example, assuming a 4-bit
> > underlying representation (ignoring signs) with the implied decimal in the
> > middle:
> > 0.1 + 0.1 != 0.2
>
> This is not true for fixed point. Addition and subtraction
> are always exact (or overflow).
>
[... much deleted ...]

I think there is some confusion here. John is talking about *decimal* fixed point,
and Steve about *binary* fixed point, so both are correct :-)

Peter.

-- 
//
//  Peter L. Bell         pbell_at_[hidden]
//                        +61 2 9805 2955
//
Problems worthy
of attack
prove their worth
by hitting back.     - Piet Hein

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk