|
![](/i/fill.gif) |
Mike Williams wrote:
> Let's try so solve this equation
>
> abs(x/6+3-floor(x/6+3)-.5)-2/6 = 0
[snip]
Sorry, I wanted a triangle wave if said equation equals y, not if it is less
than or equal to zero. That way, by making it less than or equal to zero I
get a regular pattern of solid space and empty space. That equation should
give me what I want, but I was wondering why there was a plane at x=0:
x-floor(x):
y
/ / /| / / /
/ / / |/ / /
-------------x
dividing by 6 increases the wavelength, adding 3 translates it, subtracting
the .5 makes half of it go below the x-axis, and taking the absolute value
inverts the lower portion to form the parts with negative slope:
y
/\/\/|\/\/\
-----------x
So I'm thinking perhaps it is a bug.
Anyway, I got what I wanted using modulo so it doesn't matter.
--
David Fontaine <dav### [at] faricy net> ICQ 55354965
My raytracing gallery: http://davidf.faricy.net/
Post a reply to this message
|
![](/i/fill.gif) |