\start83P\ \comment=Program file dated 04/10/96, 18:39 \protected=FALSE \name=TRIANGLE ClrHome Degree FnOff LabelOff AxesOff GridOff Horiz ZStandard ZInteger Line(15,15,\(-)\15,\(-)\15) Line(15,15,45,\(-)\15) Line(\(-)\15,\(-)\15,45,\(-)\15) Text(10,42,"A") Text(10,80,"B") Text(23,61,"C") Text(23,41,"E\o\") Text(23,76,"F\o\") Text(6,59,"D\o\") Text(1,1,"TRIANGLE") Disp "ENTER VALUES" Disp "FOR ANY 3, A-F" 0\->\D 0\->\E 0\->\F 0\->\G 0\->\H 0\->\I 0\->\J 0\->\K 0\->\L 0\->\M 0\->\O Pause ClrHome Lbl 1 If D+E+F>180 Goto A If M=3 Goto 8 Menu("ENTER ANY THREE","SIDE A",2,"SIDE B",3,"SIDE C",4,"ANGLE D",5,"ANGLE E",6,"ANGLE F",7) Lbl 2 Prompt A If G=0 1+M\->\M 1\->\G Goto 1 Lbl 3 Prompt B If H=0 1+M\->\M 1\->\H Goto 1 Lbl 4 Prompt C If I=0 1+M\->\M 1\->\I Goto 1 Lbl 5 Prompt D If J=0 1+M\->\M 1\->\J Goto 1 Lbl 6 Prompt E If K=0 1+M\->\M 1\->\K Goto 1 Lbl 7 Prompt F If L=0 1+M\->\M 1\->\L Goto 1 Lbl 8 If GJH=1 Then \root\((A\^2\+B\^2\-2ABcos(D)\->\C cos\^-1\(((B\^2\+C\^2\-A\^2\)/(2BC))\->\F 180-D-F\->\E Goto 9 End If HLI=1 Then \root\((B\^2\+C\^2\-2BCcos(F)\->\A cos\^-1\(((C\^2\+A\^2\-B\^2\)/(2CA))\->\E 180-F-E\->\D Goto 9 End If IKG=1 Then \root\((C\^2\+A\^2\-2CAcos(E)\->\B cos\^-1\(((A\^2\+B\^2\-C\^2\)/(2AB))\->\D 180-E-D\->\F Goto 9 End If GHI=1 Then If (A+B>C)(B+C>A)(C+A>B)=0 Goto A cos\^-1\(((A\^2\+B\^2\-C\^2\)/(2AB))\->\D cos\^-1\(((A\^2\+C\^2\-B\^2\)/(2AC))\->\E 180-E-D\->\F Goto 9 End If JHL=1 Then 180-D-F\->\E Bsin(D/sin(E\->\C Bsin(F/sin(E\->\A Goto 9 End If LIK=1 Then 180-F-E\->\D Csin(F/sin(D\->\A Csin(E/sin(D\->\B Goto 9 End If KGJ=1 Then 180-E-D\->\F Asin(E/sin(F\->\B Asin(D/sin(F\->\C Goto 9 End If KLH=1 Then 180-E-F\->\D Bsin(D/sin(E\->\C Bsin(F/sin(E\->\A Goto 9 End If LJG=1 Then 180-F-D\->\E Asin(E/sin(F\->\B Asin(D/sin(F\->\C Goto 9 End If JKI=1 Then 180-D-E\->\F Csin(F/sin(D\->\A Csin(E/sin(D\->\B Goto 9 End If LKG=1 Then 180-F-E\->\D Asin(D/sin(F\->\C Asin(E/sin(F\->\B Goto 9 End If JLI=1 Then 180-D-F\->\E Csin(E/sin(D\->\B Csin(F/sin(D\->\A Goto 9 End If KJH=1 Then 180-E-D\->\F Bsin(F/sin(E\->\A Bsin(D/sin(E\->\C Goto 9 End If HGK=1 Then B\->\H A\->\G E\->\K Asin(E/B\->\N If abs(N>1 Goto A sin\^-1\(N\->\F 180-F\->\L 180-E-F\->\D 180-E-L\->\J \root\((A\^2\+B\^2\-2ABcos(D)\->\C \root\((A\^2\+B\^2\-2ABcos(J)\->\I If J>0 1\->\O Goto 9 End If GIL=1 Then A\->\G C\->\I F\->\L Csin(F/A\->\N If abs(N>1 Goto A sin\^-1\(N\->\D 180-D\->\J 180-F-D\->\E 180-F-J\->\K \root\((C\^2\+A\^2\-2CAcos(E)\->\B \root\((C\^2\+A\^2\-2CAcos(K)\->\H If K>0 1\->\O Goto 9 End If IHJ=1 Then C\->\I B\->\H D\->\J Bsin(D/C\->\N If abs(N>1 Goto A sin\^-1\(N\->\E 180-E\->\K 180-D-E\->\F 180-D-K\->\L \root\((B\^2\+C\^2\-2BCcos(F)\->\A \root\((B\^2\+C\^2\-2BCcos(L)\->\G If L>0 1\->\O Goto 9 End If GHL=1 Then A\->\G B\->\H F\->\L Bsin(F/A\->\N If abs(N>1 Goto A sin\^-1\(N\->\E 180-E\->\K 180-F-E\->\D 180-F-K\->\J \root\((B\^2\+A\^2\-2BAcos(D)\->\C \root\((B\^2\+A\^2\-2BAcos(J)\->\I If J>0 1\->\O Goto 9 End If IGJ=1 Then C\->\I A\->\G D\->\J Asin(D/C\->\N If abs(N>1 Goto A sin\^-1\(N\->\F 180-F\->\L 180-D-F\->\E 180-D-L\->\K \root\((A\^2\+C\^2\-2ACcos(E)\->\B \root\((A\^2\+C\^2\-2ACcos(K)\->\H If K>0 1\->\O Goto 9 End If HIK=1 Then B\->\H C\->\I E\->\K Csin(E/B\->\N If abs(N>1 Goto A sin\^-1\(N\->\D 180-D\->\J 180-E-D\->\F 180-E-J\->\L \root\((C\^2\+B\^2\-2CBcos(F)\->\A \root\((C\^2\+B\^2\-2CBcos(L)\->\G If L>0 1\->\O Goto 9 End If JKL=1 Then If D+E+F\!=\180 Goto A End Disp "SORRY,","I CAN NOT HELP" Goto \theta\ Lbl 9 If O=1 Text(13,1,"POSS 1" Text(24,1,"SIDES=") Disp A Disp B Disp C Output(1,1,"A=") Output(2,1,"B=") Output(3,1,"C=") Pause Text(24,1,"ANGLES=") Disp D Disp E Disp F Output(1,1,"D=") Output(2,1,"E=") Output(3,1,"F=") If O=0 Goto \theta\ Pause Text(13,1,"POSS 2" Text(24,1,"SIDES= " Disp G Disp H Disp I Output(1,1,"A=") Output(2,1,"B=") Output(3,1,"C=") Pause Text(24,1,"ANGLES=" Disp J Disp K Disp L Output(1,1,"D=") Output(2,1,"E=") Output(3,1,"F=") Goto \theta\ Lbl A Disp "IMPOSSIBLE" Lbl \theta\ Pause ZPrevious AxesOn Full Stop COPYRIGHT STEPHEN OSTERMILLER 1996 \stop83P\