Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

The universe is all a spin-off of the Big Bang.


devel / comp.arch / Re: 0.0 / 0.0 = -NAN ?

SubjectAuthor
o Re: 0.0 / 0.0 = -NAN ?MitchAlsup

1
Re: 0.0 / 0.0 = -NAN ?

<7b7c633e-9d66-4558-a133-edf39bf1020bn@googlegroups.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=24978&group=comp.arch#24978

  copy link   Newsgroups: comp.arch
X-Received: by 2002:ac8:5c4d:0:b0:2e0:71b7:2829 with SMTP id j13-20020ac85c4d000000b002e071b72829mr8619326qtj.323.1651460035082;
Sun, 01 May 2022 19:53:55 -0700 (PDT)
X-Received: by 2002:a05:6830:1645:b0:606:fe3:fa21 with SMTP id
h5-20020a056830164500b006060fe3fa21mr2066282otr.268.1651460034834; Sun, 01
May 2022 19:53:54 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!news.misty.com!border2.nntp.dca1.giganews.com!nntp.giganews.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.arch
Date: Sun, 1 May 2022 19:53:54 -0700 (PDT)
In-Reply-To: <02217559-0b3b-4dfb-b3c2-32133646c890n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=2600:1700:291:29f0:2d48:3ed6:e08a:690f;
posting-account=H_G_JQkAAADS6onOMb-dqvUozKse7mcM
NNTP-Posting-Host: 2600:1700:291:29f0:2d48:3ed6:e08a:690f
References: <83274dd7-3dfa-4dc5-8ff2-aed29f253b1an@googlegroups.com>
<eb5ab9e4-a280-4234-be6b-5ccdbbee3e6fn@googlegroups.com> <02217559-0b3b-4dfb-b3c2-32133646c890n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <7b7c633e-9d66-4558-a133-edf39bf1020bn@googlegroups.com>
Subject: Re: 0.0 / 0.0 = -NAN ?
From: MitchAl...@aol.com (MitchAlsup)
Injection-Date: Mon, 02 May 2022 02:53:55 +0000
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable
Lines: 58
 by: MitchAlsup - Mon, 2 May 2022 02:53 UTC

On Sunday, May 1, 2022 at 9:22:28 PM UTC-5, Skybuck Flying wrote:
> I discovered another dangerous one while trying to compute overlap of interval (basically ranges) and/or trying to clip/cap line segments:
>
> 0 * +infinity = -NAN
<
Careful::
<
-0.0 × +infinity does equal -NaN.
>
> This happens as the ray is on the edge of a boundary/box... cause tMinX will become -NAN.
>
> Leading to weird situations depending on how the code was written, either the wrong point will be taken or it will not clip at all.
>
> Once intersection segment with ray and box has been calculated, the ray segment has to be checked against the interestion segment to check if it overlaps... it's still possible it does not overlap.. for a "ray segment box intersection" algorithm. Analog to "line triangle intersection" algorithm, first "line plane intersection" then check if intersection point lies inside triangle which lies inside the plane.
>
> I have seen some papers that try and work around these issues at least for ray/box intersection, but if these tricks work for ray segment box intersection remains to be seen.
>
> Anyway best way to solve it is to use custom code for when delta x, y, or z is zero... instead of trying to divide or multiply by zero and infinity and such things cause certain combinations can lead to -NAN problems. Also win32 and win64 behave differently in delphi somewhat... perhaps 0 * infinity produces something else in win64... not yet sure...
>
> It's in my video which I will upload shortly... hmmm...
>
> Anyway... I am leaving math hell for now... leaving fpu hell... and returning back to the surface ! =D
>
> This guy has an interesting take on it, basically saying 0 * infinity is the inverted case as 0 / 0, same kind of problem ! =D
>
> https://math.stackexchange.com/questions/698690/when-0-is-multiplied-with-infinity-what-is-the-result
>
> "
> What I would say is that you can multiply any non-zero number by infinity and get either infinity or negative infinity as long as it isn't used in any mathematical proof. Because multiplying by infinity is the equivalent of dividing by 0. When you allow things like that in proofs you end up with nonsense like 1 = 0. Multiplying 0 by infinity is the equivalent of 0/0 which is undefined. –
> PHP Guru
> "
>
> (Here will be my video: https://youtu.be/lAcneKBJ9zY in case anybody wants to see some math hell in action lol, doubt it :))
>
> Bye,
> Skybuck =D

1
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor