Home

Introduction

Contents

Scripts

FeedBack

Date 06/09/2010
Script S3_1_2A.m
Download Script S3_1_2A.m
%==============================================
%Elliptically polarized lightA
%Fig.3.4a, Sec.3.1.2, pag. 110
%==============================================
%
%alfa is the angle called,in the book, epsilon
%(the letter of the Greek alphabet corresponding to e)
%the range of alfa, in radians, is from 0 to 2*pi-alfa1
%
%the angle alfa1 is used to create a break
%in the figures of plane curves
%
alfa1=10*pi/180;
alfa=linspace(0,2*pi-alfa1,20);
%the angle in degrees
alfag=alfa*180/pi
%a series of the phase angles, in degrees
%
%the results are the same
%using the next "uncomment" command row
fig=[0 45 90 135 180 225 270 315 360];
%
%or the following "comment" command row
% fig=[0 45 90 135 180 -135 -90 -45 -0];
%
%the phase angles, in radians
fi=fig*pi/180;
%the number of phase angles and of the
%corresponding plots
max=length(fi);
for i=1:max;
beta=alfa+fi(i);
x=sin(alfa)
y=sin(beta)
plot(x,y,'ro-'),grid on,figure
end
%==============================================
%
Top
Script S3_1_2B.m
Download Script S3_1_2B.m
%==============================================
%Elliptically polarized lightB
%Fig.3.4b, Sec.3.1.2, pag. 110
%==============================================
%
%alfa is the angle called,in the book, epsilon
%(the letter of the Greek alphabet corresponding to e)
%the range of alfa, in radians, is from 0 to 2*pi-alfa1
%
%the angle alfa1 is used to create a break
%in the figures of plane curves
%
alfa1=10*pi/180;
alfa=linspace(0,2*pi-alfa1,20);
alfag=alfa*180/pi
%==============================================
%
%==============================================
%Fig. 3.4b1
%x=sin(alfa) and y=sin(alfa+fig) fig=30°
%tetag=60°
%a=Ax=cos(teta)
%b=Ay=sin(teta)
%==============================================
fig=30;
fi=fig*pi/180;
tetag=60;
teta=tetag*pi/180;
a=cos(teta);
b=sin(teta);
x=a*sin(alfa);
y=b*sin(alfa+fi);
plot(x,y,'r-o'),grid on
axis([-1,1,-1,1])
title('tetag=60° and fig=30°')
figure
%
%==============================================
%Fig. 3.4b2
%x=sin(alfa) and y=sin(alfa+fig) fig=70°
%tetag=60°
%a=Ax=cos(teta)
%b=Ay=sin(teta)
%==============================================
fig=70;
fi=fig*pi/180;
tetag=60;
teta=tetag*pi/180;
a=cos(teta);
b=sin(teta);
x=a*sin(alfa);
y=b*sin(alfa+fi);
plot(x,y,'b-d'),grid on
axis([-1,1,-1,1])
title('tetag=60° and fig=70°')
figure
%
%==============================================
%Fig. 3.4b3
%x=sin(alfa) and y=sin(alfa+fig) fig=45°
%tetag=20°
%a=Ax=cos(teta)
%b=Ay=sin(teta)
%==============================================
fig=45;
fi=fig*pi/180;
tetag=20;
teta=tetag*pi/180;
a=cos(teta);
b=sin(teta);
x=a*sin(alfa);
y=b*sin(alfa+fi);
plot(x,y,'r-o'),grid on
axis([-1,1,-1,1])
title('tetag=20° and fig=45°')
figure
%
%==============================================
%Fig. 3.4b4
%x=sin(alfa) and y=sin(alfa+fig) fig=45°
%tetag=75°
%a=Ax=cos(teta)
%b=Ay=sin(teta)
%==============================================
fig=45;
fi=fig*pi/180;
tetag=75;
teta=tetag*pi/180
a=cos(teta);
b=sin(teta);
x=a*sin(alfa);
y=b*sin(alfa+fi);
plot(x,y,'b-d'),grid on
axis([-1,1,-1,1])
title('tetag=75° and fig=45°')
%==============================================
%
Top