Trig Functions Implemented



NOTE: In order to be able to use the FD and BK functions, the end points of a line must be calculated. This requires trig functions. In this version FD and BK are implemented. Also LT, SE, RT, PD, PU, HM, SX, SY, and CS are implemented. A serious weakness with this version of the applet is that only one command at a time can be entered.

The lines which actually calculate the end points of the line to be drawn are:

newX = x + n*Math.cos(temp_angle*Math.PI/180); newY = y + n*Math.sin(temp_angle*Math.PI/180);