Barry Rowlingson wrote: > Prof Brian Ripley wrote: > >> FAQ Q7.31 and ?"==" should enlighten you. >> >> None of 0.05, 0.1 ... 0.9, 0.95 are exactly representable on a binary >> computer. >> > > Doesn't the string "0.95" constitute an exact representation? And my > computer is definitely binary. Although I suspect it is also bipolar. > Will you stop pulling Brian's l...., ah, well, then again, never mind...
"Representable as binary floating point numbers" is correct, never mind on which computer. (Binary computers can and do also do BCD arithmetic (binary coded decimal) for bookkeeping applications, specifically to avoid cumulating roundoff. At least some have harware support for it. Similarly, nothing is keeping a decimal computer from doing binary arithmetic.) And actually, three of those numbers *are* representable in binary floating point. ;-) > It's the lack of understanding of the underlying encoding of real > numbers - or even the actual *existence* of the underlying encoding - > that means the cry of 'FAQ Q7.31!' will long echo down the halls of R-help. > -- O__ ---- Peter Dalgaard Ă˜ster Farimagsgade 5, Entr.B c/ /'_ --- Dept. of Biostatistics PO Box 2099, 1014 Cph. K (*) \(*) -- University of Copenhagen Denmark Ph: (+45) 35327918 ~~~~~~~~~~ - ([EMAIL PROTECTED]) FAX: (+45) 35327907 ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.