next up previous
Next: 2.3 $B$^$H$a(B Up: 2 $B==?J(BBASIC$B$G%0%i%U%#%C%/%9(B Previous: 2.1 $B%$%s%H%m(B

2.2 $B%A%e!<%H%j%"%k$rK:$l$??M8~$1(B

$B%A%e!<%H%j%"%k$N%3%T!<$r;}$C$FMh$k$N$rK:$l$?(B ($B;}$C$FMh$F2<$5$$(B)$B!"(B $B$H$$$&?M$N$?$a$K(B ($B%3%s%T%e!<%?!<$N2hLL>e$G8+$i$l$^$9$,!"(B $B<+J,$GBG$A9~$`>l9g$O;f$r8+$J$,$i$NJ}$,$d$j$d$9$$$H;W$$$^$9(B)$B!"(B $B!V(B2.6 $B%0%i%U%#%C%/%9!W$NNcBj%W%m%0%i%`$r$3$3$K0zMQ$7$F$*$-$^$9!#(B

$BNc(B14 ($B4X?t$N%0%i%U(B)

10 DEF f(x)=x^3-3*x+1 
20 SET WINDOW -4,4,-4,4
30 DRAW GRID
40 FOR x=-4 TO 4 STEP 0.1
50    PLOT LINES: x,f(x);
60 NEXT x
70 END
($BMWE@(B: 1$BJQ?t $B$NIA$-J}$NDj@W$_$?$$$J%W%m%0%i%`(B)

$BNc(B15 (OPTION ANGLE DEGREES, DRAW GRID())

10 OPTION ANGLE DEGREES
20 DEF f(x)=sin(x)
30 SET WINDOW -360,360,-4,4
40 DRAW GRID(90,1)
50 FOR x=-360 TO 360
60    PLOT LINES: x,f(x);
70 NEXT x
80 END
($BMWE@(B: $B;03Q4X?t$NC10L$rEY$K$9$k(B OPTION ANGLE DEGREES $B$H(B DRAW GRID(,) $B$N;H$$J}(B)

$BNc(B16 (``PLOT LINES'' $B$G@~$r@Z$k(B)
2$B$D$N4X?t$N%0%i%U$rIA$/$?$a$K!"ESCf$G!V@Z$k!WI,MW$,$"$k!#(B
100 DEF f(x)=x^2
110 DEF g(x)=x^3
120 SET WINDOW -4,4,-4,4
130 DRAW GRID
140 FOR x=-4 TO 4 STEP 0.1
150    PLOT LINES: x,f(x);
160 NEXT x
170 PLOT LINES
180 FOR x=-4 TO 4 STEP 0.1
190    PLOT LINES: x,g(x);
200 NEXT x
210 END
($BMWE@(B: ``PLOT LINES: x,y;'' $B$O@~$r$D$J$2$F$$$/$N$G!"(B 170 $B9TL\$N%;%_%3%m%s$J$7$N(B PLOT LINES $B$G@~$r@Z$k!#(B)

$BNc(B17 ($B%Q%i%a!<%?!<6J@~(B)

10 OPTION ANGLE DEGREES
20 DEF f(t)=3*COS(t)
30 DEF g(t)=2*SIN(t)
40 SET WINDOW -4,4,-4,4
50 DRAW grid
60 FOR t=0 TO 360
70    PLOT LINES: f(t),g(t);
80 NEXT t
90 END
($BMWE@(B: $B%Q%i%a!<%?!<6J@~(B $ x=f(t)$, $ y=g(t)$ $B$NIA$-J}$NDj@W$_$?$$$J%W%m%0%i%`(B)

$BNc(B18 ($B6KJ}Dx<0I=<($N6J@~(B)

10 DEF f(t)=SIN(2*t)
20 SET WINDOW -1,1,-1,1
30 DRAW grid
40 FOR t=0 TO 2*PI STEP PI/360
50 PLOT LINES: f(t)*COS(t), f(t)*SIN(t);
60 NEXT t
70 END
($BMWE@(B: $B6KJ}Dx<0(B $ r=f(\theta)$ $B$O!"(B $ x=f(\theta)\cos\theta$, $ y=f(\theta)\sin\theta$ $B$H$7$FC1$J$k%Q%i%a!<%?!<6J@~(B)

$BNc(B19 ($BD>8r:BI8$+$i6K:BI8$X$NJQ49(B)

100 SET WINDOW -4,4,-4,4
110 DRAW grid
120 FOR t=0 TO 2*pi STEP pi/180
130    LET x=cos(t)+1
140    LET y=sin(t)
150    LET r=x^2+y^2
160    LET a=ANGLE(x,y)*2
170    PLOT LINES: r*cos(a),r*sin(a);
180 NEXT t
190 END


\begin{yodan}[$BD>8r:BI8(B $\leftrightarrow$ $B6K:BI8JQ49(B]
$BNc(B19$B$ON(D>$K8@$C$F!

$B%a%b(B: hypotenuse ($BD>3Q;03Q7A$N(B) $B


next up previous
Next: 2.3 $B$^$H$a(B Up: 2 $B==?J(BBASIC$B$G%0%i%U%#%C%/%9(B Previous: 2.1 $B%$%s%H%m(B
Masashi Katsurada
$BJ?@.(B23$BG/(B6$B7n(B8$BF|(B