
-----------------------------------
GlobeTrotter
Sun Oct 16, 2005 6:09 pm

Cool Textile-Like Patterns
-----------------------------------

setscreen ("graphics:max;max,nobuttonbar")
for x : 1 .. maxx
    for y : 1 .. maxy
        if BOOLEAN EXPRESSION HERE then
            drawdot (x, y, 0)
        else
            drawdot (x, y, 7)
        end if
    end for
end for



Put any of the following into the code for different effects.


(round (sin (x) / cos (y)) = 1) xor (sin (x) div cos (y) = 1)


tan (x) div tan (y) = 1


x mod y = 0


x mod 5 = 0 or y mod 5 = 0


(round (tan (x + y)) = 0) xor (round (tan (x / 2 + y / 2)) = 0)


round (sin (x)) = 1 and round (cos (x)) = 1 and round (cos (x)) = 1 or round (sin (y)) = 1 and round (cos (y)) = 1 and round (cos (y)) = 1


sind (x) + sind (y) = 0


(round (sin (x)) = 1 and round (cos (x)) = 1 and round (cos (x)) = 1 or round (sin (y)) = 1 and round (cos (y)) = 1 and round (cos (y)) = 1) xor (round (sin (x) / cos (y)) = 1) xor (sin (x) div cos (y) = 1)


Post some you come up with

-----------------------------------
[Gandalf]
Sun Oct 16, 2005 7:42 pm


-----------------------------------
Nice and simple program :).

setscreen ("graphics:max;max,nobuttonbar")
for x : 1 .. maxx
    for y : 1 .. maxy
        if (round (sin (x)) = 1 and round (cos (x)) = 1 and round (cos (x)) = 1 or round (sin (y)) = 1 and round (cos (y)) = 1 and round (cos (y)) = 1) xor (round (sin (x) / cos (y)) = 1) xor (sin (x) div cos (y) = 1) then
            drawdot (x, y, x mod 2)
        else
            drawdot (x, y, y mod 2)
        end if
    end for
end for

Also (insert this into my program, where the large expression is): 
(round (tan (x + y)) = 0) or (round (tan (x / 2 + y / 2)) = 0) or round (cos (x - y)) = 0

tan (x) div tan (y) = 1 or tan (x - 5) < 1 and tan (y - 5) < 1

-----------------------------------
Mr. T
Sun Oct 16, 2005 8:35 pm

Alex's Opinion
-----------------------------------
How do you come up with these patterns? Is it just guessing and checking? :?

-----------------------------------
GlobeTrotter
Sun Oct 16, 2005 9:16 pm


-----------------------------------
Yes

-----------------------------------
beard0
Sun Oct 16, 2005 9:53 pm


-----------------------------------
abs (sin (x) - cos (y)) < x/maxx
For the gradient pattern effect  :D
