subroutine arc6(rad,bang,ang) C C RAD(real)=radius of the arc in inches C BANG(real)=beginning angle in degrees C ANG(real)=number of degrees in the arc C +ve numbers: arc is drawn counter-clockwise C -ve numbers: arc is drawn clockwise C C The arc is drawn from the current pen position through C the desired angles. The pen is left down at the end of the arc. C PI=3.14159 RADF=0.01745329 THETA=BANG*RADF FANG=(BANG+ANG)*RADF CALL WHERE(X,Y,FACT) XCENTR=X-RAD*COS(THETA) !calculate the center of the arc YCENTR=Y-RAD*SIN(THETA) CALL PENDN 10 IF(ANG.GT.0..AND.THETA.GE.FANG)GOTO 30 IF(ANG.LT.0..AND.THETA.LE.FANG)GOTO 30 XR=XCENTR+RAD*COS(THETA) !determine polar co-ordinates YR=YCENTR+RAD*SIN(THETA) 20 CALL PLOT(XR,YR,1) !draw the arc segment IF(ANG.GT.0.)THETA=THETA+.02 !increment the angle IF(ANG.LT.0.)THETA=THETA-.02 GOTO 10 30 RETURN END