6H| A t R}>F > x t } | x d 6 n& I1=0 : incident angle x& R1=0 : refracted angle P1=3.14159 * X=256: Y=128 : point of refraction  R7=100: R6=R7/1.5  : & 0,127 511,127 511,128 0,128 & I=0 255 4 : draw in normal 256,I  I + 1,8: "medium 1": 1,9: "medium 2" 7 420: "enter refractive index (medium 1 to 2)"I0;  1,1: [A63 32][A63 8]; " "refractive index "[F5.2 I0]; ' I0>1 " Critical angle?": 290 $ I0=1 " Same medium!": 290 ' I0=0 " Don't be silly!": 220  I2=(1-I0*I0): cos c.a. ) I3=(I0/I2)*180/P1: angle in degrees * " critical angle "[F7.2 I3]" degrees" "G I=: 55,1: [I4 I]: 420: "Enter incident angle (degrees)";I2$; , I2$="+" 160 I1=(I2$) 6 I1<0 I1>90 290 @ I1=I1*P1/180 J A=(R7*(I1)): B=(R6*(I1)) T X-A,Y+B X,Y ^ R2=(I1)/I0 h" R2>1 X,Y X+A,Y+B: 290 r4 R3=(1-R2*R2): r2=sin(refract), r3=cos(refract) | A=(R7*R2): B=(R6*R3)  X,Y X+A,Y-B  290   1,16: [A63 32][A63 8];: E21AYfff}P}V)B4Frefmodel0F_~w+ yOxx:=( 2Gw-*GO~A