How can I convert
Wm−2sr−1nmm−1
to
Wm−2nm−1
I have the following matlab code to illustrate the spectral energy distribution of solar radiation:
h = 6.626e-34; % Planck's Constant = 4.135 x 10^-15 eV s
c = 3e8; % speed of light (MKS)
T= 6000; % kelvin
k = 1.38066e-23; % Boltzmann constant in J/K
lamda = 0:20e-9:3200e-9;
p = 2*3.14*h*c*c./(lamda.^5);
b6000 = p./(exp(h*c./(lamda*k*T)-1));
lamda = lamda.*1000000;
plot(lamda,b6000,'.');
title('Planck Radiation Law');
xlabel('Wavelength [\mu{m}]')
ylabel('Irradiance [W m^{-2} sr^{-1} nmm^{-1}]');
xlim([0 3.2]);
This is my result:
How would I change my yaxis to be the same as the example shown?
but I need the yaxis to be in units of
Wm−2nm−1
so that the curve looks like
From the plot, it seems that dividing the irradiance by 10.^14 would do the trick, is this correct? Could someone explain the unit conversion, for a non-physicist?
This function is taken from here
http://web.mit.edu/8.13/matlab/Examples/planck.m
Updated version:
From all of the advice given here, this is the updated and hopefully correct methods:
h = 6.626e-34; % Planck's Constant
c = 3e8; % speed of light
T = 6000; % absolute temperature
k = 1.38066e-23; % Boltzmann constant in J/K
lambda = 0:20e-9:3200e-9; % wavelength
% spectral radiance
p = 2*h*c*c./(lambda.^5);
b6000 = p./(exp(h*c./(lambda*k*T))-1);
b6000 = (1e-9).*b6000;
% multiply by the square of the ratio of the solar radius of earth's
% orbital radius
b6000 = b6000.*(2.177e-5);
% apply Lambert's cosine law
b6000 = b6000.*pi;
% convert units for lambda
lambda = lambda.*1e6;
% print result
fh = figure(1);
plot(lambda,b6000)
xlabel('Wavelength [\mu{m}]');
ylabel('Irradiance [W m^{-2} nm^{-1}]');
Answer
The dimensional prefactor that ends up in your code is hc2λ5=6.626×10−34 J s×(3×108 m s−1)2(˜λ m)5,
Note also that you need to distinguish carefully between radiance (which is the Planck's law quantity you're calculating), which is the power flow per unit of solid angle, and irradiance, which is integrated over solid angle, as detailed in Carl Witthoft's answer.
If you put this together, then, the spectral radiance is Bλ(T)=10−92×6.626×10−34×(3×108)2˜λ5Wm−2sr−1nm−1exp(6.626×10−34×3×108˜λ×6000×1.38066×10−23)−1.
Finally, note that nmm is not an SI unit. The matlab function you are basing yourself on has a typo at a crucial place which, in my view, renders it essentially useless, or at least useless without a careful examination of what it's actually calculating. Be very careful whenever you see that sort of thing!
No comments:
Post a Comment