POV-Ray : Newsgroups : povray.general : Problems with the sum() and prod(). (Bug in v3.5 ?) : Re: Problems with the sum() and prod(). (Bug in v3.5 ?) Server Time
5 Aug 2024 00:21:59 EDT (-0400)
  Re: Problems with the sum() and prod(). (Bug in v3.5 ?)  
From: Tor Olav Kristensen
Date: 10 Jan 2003 13:36:16
Message: <Xns92FFC7EA67D58torolavk@204.213.191.226>
"Jaap Frank" <jjf### [at] xs4allnl> wrote in news:3e1ee7c2$1@news.povray.org:

> 
> "Tor Olav Kristensen" <tor### [at] hotmailcom> wrote in message
> news:web.3e1e2ad581e209a5b417814a0@news.povray.org...
>>
>> If I have understood the documentation
>> for the new sum() and prod() functions
>> right, then POV-Ray v3.5 for Windows
>> behaves very oddly in some cases.
>>
>> I have observed two different beahiours:
>>
>> 1)
>> When I run some code with these
>> functions, POV-Ray just "hangs" and
>> does not finish parsing, even if the
>> calculations are very short. In this
>> state it does not react when I press
>> the Stop button.
>>
>> When I try to close it down, then it
>> says "POV-Ray is currently rendering -
>> do you want to stop ?".
>>
>> If I answer Yes, then POV-Ray closes
>> down as it should. If I answer No,
>> then POV-Ray just continues to "hang".
>>
>> The Pause button is working OK.
>>
>> 2)
>> When I run some other code with these
>> functions, POV-Ray finishes but
>> produces wrong results.
>>
>>
>> Can anyone confirm this behaviour ?
>>
>> I have inserted my test code below.
>>
>> The relevant documentation is here:
>> http://www.povray.org/documentation/view/140/
>> (Section 6.1.6.1)
>>
>> My PC runs Win98SE and has a 166MHz MMX
>> Pentium processor with 96MB of RAM.
>>
>>
>> Tor Olav
>>
>> [...]
> 
> Hello Tor Olav,
> 
> I get identical results and have a 450MHz MMX
> PIII with 1 GB RAM.
> 
> I've tried some different things and I think if a function gives
> 0 as answer, the sum_function uses 1 instead, for:
> 
> #declare Fn = function(x) { sum(i, 1, 2, pow(x, 2)) }
> 
> with x =0:        2 instead of 0,
> 
>  and sum(i,1,8,pow(x,2))     gives 8 as answer.
> 
> There may be wrong more things, but this is what I
> discovered so far.

Thank you for verifying this Jaap.

I'm not sure if this is the same
bug as the one described here:

http://news.povray.org/povray.bugreports/26015/

Can anyone tell if it is ?


And have some with a Mac or a
Linux PC tried the examples that
I posted ?


Tor Olav


Post a reply to this message

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