POV-Ray : Newsgroups : povray.general : What does 1.XQNAN000... mean? Server Time
24 Dec 2024 13:01:29 EST (-0500)
  What does 1.XQNAN000... mean? (Message 1 to 3 of 3)  
From: Tim Nikias v2 0
Subject: What does 1.XQNAN000... mean?
Date: 13 Jun 2003 20:39:05
Message: <3eea6ea9$1@news.povray.org>
So, while fiddling with trace() and objects declared into
arrays, I've noticed the following: when outputting the
specular value (asked that in a recent thread), I get,
when using str(Value,1,20) this:

1.#QNAN000000000000000

Now, I expect NAN is Not A Number. I'm not too
sure how this can happen... I'll look some more into it,
but perhaps some information on NAN and possible
origins (dividing by something near 0 or multiplying with
something too large) might aid me in looking for the actual
error (which might be in my code, can't tell for sure yet).

Nontheless, shouldn't POV have some means of avoiding
that?

-- 
Tim Nikias v2.0
Homepage: http://www.digitaltwilight.de/no_lights
Email: Tim### [at] gmxde


Post a reply to this message

From: Tim Cook
Subject: Re: What does 1.XQNAN000... mean?
Date: 13 Jun 2003 20:40:58
Message: <3eea6f1a@news.povray.org>
Tim Nikias v2.0 wrote:
> Nontheless, shouldn't POV have some means of avoiding
> that?

Maybe it's an 'E' in a large number in scientific notation.

-- 
Tim Cook
http://home.bellsouth.net/p/PWP-empyrean

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GFA dpu- s: a?-- C++(++++) U P? L E--- W++(+++)>$
N++ o? K- w(+) O? M-(--) V? PS+(+++) PE(--) Y(--)
PGP-(--) t* 5++>+++++ X+ R* tv+ b++(+++) DI
D++(---) G(++) e*>++ h+ !r--- !y--
------END GEEK CODE BLOCK------


Post a reply to this message

From: Tim Nikias v2 0
Subject: Re: What does 1.XQNAN000... mean?
Date: 13 Jun 2003 21:05:11
Message: <3eea74c7@news.povray.org>
So, fiddling with the code came up with this:
I can't really find where the error is placed. I'll
try to cut down the source-code to the bare
minimum which'll reproduce the error with
#QNAN . I've tried using the same pretty close
numbers in the calculation where this error
is returned. In the scene, it uses 0.47... with
pow(0.47.... , 1/.03).
Works fine outside of scene, but not inside of
it.

Only thing I noticed is that when commenting out
an array declaration (trying to fill it with UV-Vectors),
the error is gone.
So, if I do:
#declare Array=array[2] { <1,.03>,<.9,.02> }
everything is working, but with
#declare Array=array[2]
#declare Array[0]=<1,.03>;
#declare Array[1]=<.9,.02>;
the error pops up.

Anyways, I'll post the code once its stripped. If anyone
has got any suggestions what to look for, I'd be happy
to attempt that.

-- 
Tim Nikias v2.0
Homepage: http://www.digitaltwilight.de/no_lights
Email: Tim### [at] gmxde

> So, while fiddling with trace() and objects declared into
> arrays, I've noticed the following: when outputting the
> specular value (asked that in a recent thread), I get,
> when using str(Value,1,20) this:
>
> 1.#QNAN000000000000000
>
> Now, I expect NAN is Not A Number. I'm not too
> sure how this can happen... I'll look some more into it,
> but perhaps some information on NAN and possible
> origins (dividing by something near 0 or multiplying with
> something too large) might aid me in looking for the actual
> error (which might be in my code, can't tell for sure yet).
>
> Nontheless, shouldn't POV have some means of avoiding
> that?
>
> -- 
> Tim Nikias v2.0
> Homepage: http://www.digitaltwilight.de/no_lights
> Email: Tim### [at] gmxde
>
>


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.