POV-Ray : Newsgroups : povray.newusers : (X <= D) different than ((X<D) | (X=D)) ? : Re: (X <= D) different than ((X<D) | (X=D)) ? Server Time
28 Jul 2024 20:34:29 EDT (-0400)
  Re: (X <= D) different than ((X<D) | (X=D)) ?  
From: Margus Ramst
Date: 22 Apr 2000 10:32:43
Message: <3901AA4C.28062CFA@peak.edu.ee>
Yes, those conditions should be equivalent.
It seems to be a precision-related issue, since the correct result is achieved
by adding some very small value to D in the condition (X <= D). Also, when the
loop is shorter, e.g. D=1, the result is correct for X = X + 0.1
The second version works because for some reason the condition (X = D) evaluates
correctly. However, the conditions like (X != D) (X <= D) etc do not.
I tested this under official 3.1g (Windows & Linux) and Megapov 0.4g (Windows)
and due to the inconsistency regarding conditional operators, it looks like a
bug to me. Comments?

-- 
Margus Ramst

Personal e-mail: mar### [at] peakeduee
TAG (Team Assistance Group) e-mail: mar### [at] tagpovrayorg


Post a reply to this message

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