stairs Art/Electric
PROGRAMS
general
color methods
col hypercube
fuzzy logic 1
fuzzy logic 2
fuzzy logic 3
macrame
mandelzoom
julia set
ripples
sines
newtons basin
hadamard matrix
 
PROGRAMS 2
L-systems
IF-Systems
 
e-mail
FUZZY LOGIC TWO
grapic
escape time diagram & link to partly true

PROGRAM fuzzylog !(1993 april from Pascal to True Basic 2004 march )
!(© 2004 W.van Duyn)
SET MODE "color"
SET WINDOW 0,1199,0,903 !Aspect ratio 1:1 tuned to 1280x1024 res
PRINT "input Truth Value (tval) try: 1, Limit (lim) try:1"
INPUT tval, lim
PRINT "Input displacement on x-y axes (dx,dy) try: 0.5,0.5"
INPUT dx,dy
PRINT "Input size(h), scale(f), magnification(mag), try: 4,32,1"
INPUT h,f,mag !for precise image use f=2^n
CLEAR
SET COLOR "black"
BOX AREA 10,1189,10,893 !creates a colored background
FLOOD 10,10
FOR i = -h*f to h*f
LET ii=i
LET xxx = dx*tval+(ii/(2*f))*tval/mag
FOR j = -h*f to h*f
LET jj=j
LET y = dy*tval+(jj/(2*f))*tval/mag
LET x = xxx
LET konxy=0
LET mm=0
DO WHILE mm=<40 AND konxy=<lim
LET xx=tval-abs(x-y)
LET yy=tval-abs(y-(tval-x))
LET konxy=(xx^2)+(yy^2) !circular motif
LET x=xx
LET y=yy
LET mm = mm+1
LOOP
LET xi=i+600 !alter to suit monitor resolution
LET yj=j+452 !ditto...
CALL colpatA(mm)
PLOT xi,yj
NEXT J
NEXT I
END

SUB colpatA(mm)
LET mc=MOD(mm,9)
IF mc=0 THEN SET COLOR 6  !"brown"
IF mc=1 THEN SET COLOR 16 !"black"
IF mc=2 THEN SET COLOR 14 !"green"
IF mc=3 THEN SET COLOR 10 !"yellow"
IF mc=4 THEN SET COLOR 9  !"blue"
IF mc=5 THEN SET COLOR 12 !"red"
IF mc=6 THEN SET COLOR 15 !"white"
IF mc=7 THEN SET COLOR 8  !"dark gray"
IF mc=8 THEN SET COLOR 5  !"magenta"
IF mm=41 THEN SET COLOR 15 !"white"
END SUB

Website, Text and Some Images Copyright © 2002 tzingaro.com, all rights reserved.