[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Exposing more math functionality
From: |
Andy Wingo |
Subject: |
Re: Exposing more math functionality |
Date: |
Fri, 27 Aug 2010 21:02:26 -0700 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) |
On Fri 27 Aug 2010 08:44, Andy Wingo <address@hidden> writes:
> On Thu 19 Aug 2010 09:04, Andy Wingo <address@hidden> writes:
>
>> Regarding modf -- it seems that the R6RS extends the definition of
>> `modulo' (called `mod') to be defined over the real numbers.
>>
>> (mod 10 3) => 1
>> (mod 10 3.0) => 1.0
>> (mod 10 3.1) => 0.7
>>
>> This appears to be a compatible extension of the R5RS' `modulo', so we
>> should just extend our definition. That way we can avoid adding another
>> symbol.
>
> This was a mistaken impression, something I realized while trying to
> implement this. From the R6RS rationale, section 11.6.6:
>
> div and mod [...]
I was pointed to http://mumble.net/~campbell/tmp/division.txt today,
which is enlightening. I don't know what to do with it yet. I like the
snarky take on div0 and mod0 though ;)
Andy
--
http://wingolog.org/