0001 global noCheckSum;
0002 noCheckSum=true;
0003
0004
0005
0006 nNmax=50;
0007
0008
0009 epsilonM=1.77;
0010
0011
0012 scrsz = get(0,'ScreenSize');
0013 figAspectRatio=2;
0014 figWidth=3/4*scrsz(3);
0015 figure('Name','Fig. 6.10(a)', ...
0016 'Position',[(scrsz(3)-figWidth)/2 scrsz(4)-150-figWidth/figAspectRatio figWidth figWidth/figAspectRatio]);
0017
0018 nNbTheta=31;
0019 theta=transpose(linspace(0,pi,nNbTheta));
0020 nNbPhi=nNbTheta;
0021 phi=linspace(-pi,pi,nNbPhi);
0022
0023 xs=sin(theta) * cos(phi);
0024 ys=sin(theta) * sin(phi);
0025 zs=repmat(cos(theta),1,nNbPhi);
0026
0027
0028 lambda=393;
0029
0030
0031 epsilonIn=epsAg(lambda);
0032
0033
0034 a=50;
0035
0036
0037 stM=PweSolveSingleSphere(nNmax,a,lambda,epsilonM,epsilonIn,'noplot','coeff');
0038
0039
0040
0041 stEsurf=PweEsurf(lambda,epsilonM,stM,a,nNbTheta,'Outside');
0042
0043
0044 Ecr2=transpose(abs(stEsurf.Ecr).^2);
0045 Ec2=Ecr2+transpose(abs(stEsurf.Ect).^2);
0046 Es2=transpose(abs(stEsurf.Esf).^2);
0047
0048
0049
0050 MLoc=Ec2 * (cos(phi).^2) + Es2 * (sin(phi).^2);
0051 MLocPerp=Ecr2 * (cos(phi).^2);
0052
0053
0054
0055 hpl1=subplot(1,2,1);
0056 set(hpl1,'Outerposition',[0,0,0.5,1]);
0057
0058 surf(xs,ys,zs,log10(MLoc));
0059 axis tight; axis equal; axis off;
0060 colormap gray; colorbar('eastOutside','fontsize',8);
0061 set(hpl1,'CameraViewAngle',8.5);
0062 hold on;
0063 line([-1.6;1.6], [0;0],[0;0],'LineStyle','--','Color','k');
0064 line([0;0],[-1.8;1.8], [0;0],'LineStyle','--','Color','k');
0065 line([0;0],[0;0],[-1.4;1.4], 'LineStyle','--','Color','k');
0066 quiver3(-1.7,0,0,0.5,0,0,'k');
0067 text(-1.55,-0.1,-0.07,'\bf E_0');
0068 quiver3(-1.7,0,0,0,0,0.5,'k');
0069 text(-1.9,0,0.3,'\bf k');
0070 text(-0.9,0,1.85,'\bf log_{10}( M_{Loc}=|E_{Loc}|^2/|E_{Inc}|^2 )');
0071 ht=title('Silver sphere in water - a=50nm - \lambda=393 nm');
0072 set(ht,'Position',get(ht,'Position')+[1.4 -1.1 0]);
0073 hold off;
0074
0075 hpl2=subplot(1,2,2);
0076 set(hpl2,'Outerposition',[0.5,0,0.5,1])
0077 surf(xs,ys,zs,MLocPerp./MLoc);
0078 axis tight; axis equal;axis off;
0079 colormap gray; colorbar('eastOutside','fontsize',8);
0080 set(hpl2,'CameraViewAngle',8.5);
0081 hold on;
0082 line([-1.6;1.6], [0;0],[0;0],'LineStyle','--','Color','k');
0083 line([0;0],[-1.8;1.8], [0;0],'LineStyle','--','Color','k');
0084 line([0;0],[0;0],[-1.4;1.4], 'LineStyle','--','Color','k');
0085 quiver3(-1.7,0,0,0.5,0,0,'k');
0086 text(-1.55,-0.1,-0.07,'\bf E_0');
0087 quiver3(-1.7,0,0,0,0,0.5,'k');
0088 text(-1.9,0,0.3,'\bf k');
0089 text(-0.6,0,1.85,'\bf |E^{Perp}_{Loc}|^2/|E_{Loc}|^2');
0090 hold off;