Home > SPlaC v1_0 > BookFigures > MakeFig6_2.m

MakeFig6_2

PURPOSE ^

Function to reproduce Fig. 6.2

SYNOPSIS ^

function MakeFig6_2()

DESCRIPTION ^

 Function to reproduce Fig. 6.2
 Distance-dependence of decay rate EFs and EM radiative efficiency
 for selected cases of a dipole in air emitting
 close to a planar silver or gold surface.

 This file is part of the SPlaC v1.0 package (copyright 2008)
 Check the README file for further information

EXAMPLE OF OUTPUT ^

Example figure output

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 %%%%%%%%%%%%%%%%%%
0002 % Computations
0003 %%%%%%%%%%%%%%%%%%
0004 
0005 % dielectric constant of outside medium (real positive)
0006 epsilonM=1.0; % air
0007 
0008 % distance of dipole from interface (in nm)
0009 dArray=[1 2 3 4 5 7 10 15 20 30 40 50]; % [1 x D]
0010 nNbD=length(dArray);
0011 zerod=0*dArray; % [1 x D]
0012 % initialize arrays
0013 MTotPerpAg633=zerod;
0014 MTotParaAg633=zerod;
0015 MTotPerpAu633=zerod;
0016 MTotPerpAu514=zerod;
0017 MRadPerpAg633=zerod;
0018 MRadParaAg633=zerod;
0019 MRadPerpAu633=zerod;
0020 MRadPerpAu514=zerod;
0021 
0022 % loop through each distance
0023 for indd=1:nNbD
0024     d=dArray(indd);
0025     
0026     % Solve dipole emission problem for selected cases
0027     nNbStep=5000; % for integrals
0028     % Ag/air interface at 633nm
0029     stAllM=PlnSinglePlaneDecayRateEFs(epsilonM,633,epsAg(633),d,nNbStep);
0030     MTotPerpAg633(indd)=stAllM.MTotPerp;
0031     MTotParaAg633(indd)=stAllM.MTotPara;
0032     MRadPerpAg633(indd)=stAllM.MRadPerp;
0033     MRadParaAg633(indd)=stAllM.MRadPara;
0034     
0035     % Au/air interface at 633nm
0036     stAllM=PlnSinglePlaneDecayRateEFs(epsilonM,633,epsAu(633),d,nNbStep);
0037     MTotPerpAu633(indd)=stAllM.MTotPerp;
0038     MRadPerpAu633(indd)=stAllM.MRadPerp;
0039 
0040     % Au/air interface at 514nm
0041     stAllM=PlnSinglePlaneDecayRateEFs(epsilonM,514,epsAu(514),d,nNbStep);
0042     MTotPerpAu514(indd)=stAllM.MTotPerp;
0043     MRadPerpAu514(indd)=stAllM.MRadPerp;
0044 end
0045 
0046 %%%%%%%%%%%%%%%%%%
0047 % Drawing
0048 %%%%%%%%%%%%%%%%%%
0049 
0050 % create, position, and resize figure
0051 scrsz = get(0,'ScreenSize'); % scrsz(4) contains screen height
0052 figAspectRatio=1.3;
0053 figHeight=scrsz(4)-150;
0054 figWidth=figAspectRatio*figHeight;
0055 figure('Name','Fig. 6.2', ...
0056     'Position',[(scrsz(3)-figWidth)/2 50 figWidth figHeight]);
0057 
0058 % plot results
0059 % (a) MTot
0060 subplot(2,2,1);
0061 loglog(dArray,MTotPerpAg633, 's-', ...
0062     dArray,MTotParaAg633, 'o-', ...
0063     dArray,MTotPerpAu633, '^-', ...
0064     dArray,MTotPerpAu514, 'd-');
0065 axis([0.5 55 0.1 1e5]);
0066 set(gca,'YGrid','on','YMinorGrid','off');
0067 title('(a) Total decay rate EFs in air');
0068 xlabel('Distance, d [nm]');
0069 ylabel('M_{Tot}');
0070 legend({'Ag, Perp, \lambda=633nm','Ag, Para, \lambda=633nm', ...
0071     'Au, Perp, \lambda=633nm','Au, Perp, \lambda=514nm'},'Location','NorthEast');
0072 
0073 
0074 % (b) MRad
0075 h=subplot(2,2,2);
0076 axpos2=get(h,'Position');
0077 loglog(dArray,MRadPerpAg633, 's-', ...
0078     dArray,MRadParaAg633, 'o-', ...
0079     dArray,MRadPerpAu633, '^-', ...
0080     dArray,MRadPerpAu514, 'd-');
0081 axis([0.5 55 0.08 2]);
0082 set(gca,'YGrid','on','YMinorGrid','off');
0083 title('(b) Radiative decay rate EFs in air');
0084 xlabel('Distance, d [nm]');
0085 ylabel('M_{Rad}');
0086 h=legend({'Ag, Perp, \lambda=633nm','Ag, Para, \lambda=633nm', ...
0087     'Au, Perp, \lambda=633nm','Au, Perp, \lambda=514nm'},'Location','West');
0088 % reposition legend
0089 set(h,'Position',get(h,'Position')+[0 -0.05 0 0]);
0090 
0091 
0092 % (c) etaRad
0093 h=subplot(2,2,[3;4]);
0094 % change width and recenter:
0095 axpos3=get(h,'Position');
0096 axpos3(1)=axpos3(1)+(axpos3(3)-axpos2(3))/2; % recenter
0097 axpos3(3)=axpos2(3); % change width
0098 set(h,'Position',axpos3);
0099 
0100 loglog(dArray,MRadPerpAg633./MTotPerpAg633, 's-', ...
0101     dArray,MRadParaAg633./MTotParaAg633, 'o-', ...
0102     dArray,MRadPerpAu633./MTotPerpAu633, '^-', ...
0103     dArray,MRadPerpAu514./MTotPerpAu514, 'd-');
0104 axis([0.5 55 5e-6 2]);
0105 set(gca,'YGrid','on','YMinorGrid','off');
0106 title('(c) EM Radiative efficiency in air');
0107 xlabel('Distance, d [nm]');
0108 ylabel('\eta^{EM}_{Rad}');
0109 legend({'Ag, Perp, \lambda=633nm','Ag, Para, \lambda=633nm', ...
0110     'Au, Perp, \lambda=633nm','Au, Perp, \lambda=514nm'},'Location','SouthEast');

This web page is part of the SPlaC package © 2008. Contact: Eric Le Ru
Generated on Wed 03-Dec-2008 11:10:14 by m2html © 2003 (adapted)