Home

Introduction

Contents

Scripts

FeedBack

Date 06/09/2010
Script S3_2_10.m
Download Script S3_2_10.m
%==============================================
%Two polarizers
%==============================================
%
%a beam of polarized light
%with E oscillating in the plane xz
v1=[1;0]
%
%the matrix of a polarizer
%whose transmission axis
%rotates in the plane xy
tetag=0:5:180;
teta=tetag*pi/180;
max=length(teta)
for i=1:max
%elements of the matrix
c1=cos(teta(i));
s1=sin(teta(i));
a11=c1^2;
a12=c1*s1;
a21=c1*s1;
a22=s1^2;
m2=[a11 a12;a21 a22];
%beam emerging from the polarizer
vf=m2*v1
%the complex conjugate transpose
vft=vf';
%the corresponding intensity
Int(i)=vft*vf;
end
%array of the intensities
Int
plot(tetag,Int,'ro-'),grid on, title('Intensity of the beam')
axis([0,180,0,1]), figure
check=cos(teta).^2
plot(tetag,check,'bd-'),grid on, title('Intensity using directly the Malus law')
axis([0,180,0,1])
%==============================================
%
Top