[Haskell-cafe] Ord/Ix and Bounded?

Akhra Gannon tanuki at gmail.com
Sun Apr 17 01:29:09 UTC 2022


Granted Double doesn't have Bounded, but consider a type representing a
sigmoid transformation. minBound==0.0, maxBound==1.0, but NaN could still
be in play.

On Sat, Apr 16, 2022, 6:24 PM Akhra Gannon <tanuki at gmail.com> wrote:

> NaN violates this. Of course floats are rife with broken instances to
> begin with, but in this case it might be important?
>
> On Sat, Apr 16, 2022, 6:06 PM Zemyla <zemyla at gmail.com> wrote:
>
>> Are there any laws relating Bounded to Ord and Ix? For instance, any
>> reasonable type should say
>>
>> minBound <= x == True for all x
>> maxBound >= x == True for all x
>> inRange (minBound, maxBound) x == True for all x
>>
>> _______________________________________________
>> Haskell-Cafe mailing list
>> To (un)subscribe, modify options or view archives go to:
>> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
>> Only members subscribed via the mailman list are allowed to post.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20220416/e66398bf/attachment.html>


More information about the Haskell-Cafe mailing list