From: Richard Todd <richardt@vzavenue.net>
Cc: Robert Uhl <ruhl@4dv.net>, guile-user@gnu.org
Subject: Re: number->string radix patch
Date: Tue, 11 May 2004 00:23:11 -0500 [thread overview]
Message-ID: <4B900A04-A30B-11D8-9EFC-000A95B4C7DC@vzavenue.net> (raw)
In-Reply-To: <87fza8c976.fsf@zagadka.ping.de>
I built guile from CVS on my Mac G5, and I get the same results I did
originally:
/tmp/bldguile richardt$ guile
guile> (number->string 0.25 2)
"0.01"
guile> (number->string 11.33333333333333333 12)
"B.4"
guile> (number->string 1.324e44 16)
"5.EFE0A14FAFEe24"
guile>
I had done the original patch on a G4 machine. I'm thinking it's a
precision difference between macs and intel machines. Those second two
answers are only different in the least significant numbers, which
looks like different amounts of rounding error to me. Someone with an
intel box may be able to do some tuning of the tolerance parameters in
the algorithm. I'd be happy to help in any way I can, but it may be an
unavoidable difference.
On May 10, 2004, at 3:34 PM, Marius Vollmer wrote:
> Richard Todd <richardt@vzavenue.net> writes:
>
>> On Mon, Jan 05, 2004 at 06:36:07PM -0700, Robert Uhl wrote:
>>> Although my one true project is to figure out number->string well
>>> enough
>>> to make it Do the Right Thing for decimals in bases other than 10
>>> (I'm a
>>> big fan of duodecimal).
>>
>> I've seen this wish twice from you in the short time I've been
>> watching guile-user, so I took a crack at it.
>
> Ok, I have finally installed your patch. Thanks again! (I wrote a
> basic ChangeLog entry, but please do that yourself for the next
> patch.)
>
> I used your examples as test cases, but cannot reproduce some:
>
>> guile> (number->string 0.25 2)
>> "0.01"
>> guile> (number->string 11.33333333333333333 12)
>> "B.4"
>> guile> (number->string 1.324e44 16)
>> "5.EFE0A14FAFEe24"
>
> I get
>
> guile> (number->string 0.25 2)
> "0.010"
> guile> (number->string 11.33333333333333333 12)
> "B.400000000000009"
> guile> (number->string 1.324e44 16)
> "5.EFE0A14FAFDF8e24"
>
> The first looks certainly wrong, but I'm not sure about the other two.
> Richard, could you try to investigate this?
>
> --
> GPG: D5D4E405 - 2F9B BCCC 8527 692A 04E3 331E FAF8 226A D5D4 E405
>
_______________________________________________
Guile-user mailing list
Guile-user@gnu.org
http://mail.gnu.org/mailman/listinfo/guile-user
next prev parent reply other threads:[~2004-05-11 5:23 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-01-02 5:21 First look at Guile Std Library available Richard Todd
2004-01-02 9:29 ` Dale Mellor
2004-01-03 1:03 ` Richard Todd
2004-01-03 2:25 ` Andreas Rottmann
2004-01-03 15:00 ` Dale Mellor
2004-01-03 14:36 ` Dale Mellor
2004-01-03 22:42 ` Richard Todd
2004-01-03 16:38 ` Thien-Thi Nguyen
2004-01-03 16:48 ` Nic Ferrier
2004-01-03 22:18 ` Richard Todd
2004-01-04 1:49 ` Thien-Thi Nguyen
2004-01-04 3:50 ` Richard Todd
2004-01-04 12:59 ` Thien-Thi Nguyen
[not found] ` <16376.5782.10995.206284@l.a>
2004-01-04 14:17 ` Dale Mellor
2004-01-04 21:51 ` Richard Todd
2004-01-05 0:30 ` Andreas Rottmann
2004-01-05 5:00 ` Richard Todd
2004-01-05 16:03 ` Robert Uhl
2004-01-05 20:01 ` Richard Todd
2004-01-06 1:36 ` Robert Uhl
2004-01-06 18:41 ` number->string radix patch (Was Re: First look at Guile Std Library available) Richard Todd
2004-01-07 4:04 ` Robert Uhl
2004-01-07 5:26 ` Richard Todd
2004-01-07 20:54 ` Robert Uhl
2004-01-08 7:11 ` I get unknown immediate error in guile 1.7 Roland Orre
2004-01-08 17:14 ` Roland Orre
2004-01-10 20:17 ` Kevin Ryde
2004-05-10 20:34 ` number->string radix patch Marius Vollmer
2004-05-11 3:16 ` Richard Todd
2004-05-11 3:51 ` Keith Wright
2004-05-27 21:56 ` Kevin Ryde
2004-06-10 16:35 ` Marius Vollmer
2004-06-10 16:34 ` Marius Vollmer
2004-05-11 5:23 ` Richard Todd [this message]
2004-05-27 21:54 ` Kevin Ryde
2004-06-10 16:47 ` Marius Vollmer
2004-06-11 1:40 ` Kevin Ryde
2004-01-05 10:08 ` First look at Guile Std Library available Dale Mellor
2004-01-05 3:39 ` Paul Jarc
2004-01-05 4:28 ` Richard Todd
2004-01-05 5:19 ` Paul Jarc
2004-01-06 22:25 ` Ludovic Courtès
2004-01-06 23:53 ` Richard Todd
2004-01-16 20:17 ` Andy Wingo
2004-01-05 14:00 ` Thien-Thi Nguyen
2004-01-05 20:32 ` Richard Todd
2004-01-05 20:59 ` Dale P. Smith
2004-01-06 16:54 ` Thien-Thi Nguyen
2004-01-06 20:32 ` Richard Todd
2004-01-03 18:19 ` Clinton Ebadi
2004-01-03 20:12 ` Thien-Thi Nguyen
2004-01-04 2:02 ` Richard Todd
2004-01-06 20:42 ` Richard Todd
2004-01-06 21:20 ` Paul Jarc
2004-01-03 22:52 ` Richard Todd
2004-01-04 1:53 ` Thien-Thi Nguyen
2004-01-04 20:34 ` Arno Peters
2004-01-05 20:12 ` Richard Todd
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B900A04-A30B-11D8-9EFC-000A95B4C7DC@vzavenue.net \
--to=richardt@vzavenue.net \
--cc=guile-user@gnu.org \
--cc=ruhl@4dv.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).