Home > atmlab > forwardmodel > di2planckTb.m

di2planckTb

PURPOSE ^

DI2PLANCKTB Planck Tb of jacobians and higher Stokes components

SYNOPSIS ^

function [tb,dtb] = di2planckTb(f,i,di)

DESCRIPTION ^

 DI2PLANCKTB   Planck Tb of jacobians and higher Stokes components

     Converts intensities to brigthness temperatures by "inverting" the Planck
     function. The function *i2planckTb* performs the same operation, but this
     function handles also conversion of jacobians and higher Stokes
     components. These later quantities can be seen as differences between two
     radiance values, and can not be converted to Tb as the spectrum (*i*).

     Use *i2planckTb* if only a spectrum shall be converted.

 FORMAT   [tb,dtb] = di2planckTb(f,i,di)

 OUT      tb    Brightness temperature for *i* [K].
 OUT      dtb   Brightness temperature for *di*.
 IN       f     Frequencies [Hz]. Must be a column vector.
          i     Intensities for spectrum [W/sr*m^2*Hz]. Must be a column 
                vector.
          di    Jacobian or higher Stokes components, in radiance. Can be a
                matrix, where each row corresponds to a frequency.

 See also: i2planckTb, planck

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

DOWNLOAD ^

di2planckTb.m

SOURCE CODE ^

0001 % DI2PLANCKTB   Planck Tb of jacobians and higher Stokes components
0002 %
0003 %     Converts intensities to brigthness temperatures by "inverting" the Planck
0004 %     function. The function *i2planckTb* performs the same operation, but this
0005 %     function handles also conversion of jacobians and higher Stokes
0006 %     components. These later quantities can be seen as differences between two
0007 %     radiance values, and can not be converted to Tb as the spectrum (*i*).
0008 %
0009 %     Use *i2planckTb* if only a spectrum shall be converted.
0010 %
0011 % FORMAT   [tb,dtb] = di2planckTb(f,i,di)
0012 %
0013 % OUT      tb    Brightness temperature for *i* [K].
0014 % OUT      dtb   Brightness temperature for *di*.
0015 % IN       f     Frequencies [Hz]. Must be a column vector.
0016 %          i     Intensities for spectrum [W/sr*m^2*Hz]. Must be a column
0017 %                vector.
0018 %          di    Jacobian or higher Stokes components, in radiance. Can be a
0019 %                matrix, where each row corresponds to a frequency.
0020 %
0021 % See also: i2planckTb, planck
0022 
0023 % 2010-12-15   Created by Patrick Eriksson.
0024 
0025 
0026 function [tb,dtb] = di2planckTb(f,i,di)
0027 
0028 rqre_datatype( f, @istensor1 );                                             %&%
0029 rqre_datatype( i, @istensor1 );                                             %&%
0030 rqre_datatype( di, @istensor2 );                                            %&%
0031 if length(f) ~= length(i)                                                   %&%
0032   error( 'The vectors *f* and *i* must have the same length.' );            %&%
0033 end                                                                         %&%
0034 if length(f) ~= size(di,1)                                                  %&%
0035   error( ...                                                                %&%
0036    'The length of vector *f* and number of rows in *di* must be equal.' );  %&%
0037 end                                                                         %&%
0038 
0039 planck = constants('PLANCK_CONST');
0040 boltzmann = constants('BOLTZMANN_CONST');
0041 speed_light = constants('SPEED_OF_LIGHT');
0042 
0043 a = planck/boltzmann;
0044 b = 2*planck/speed_light^2;
0045 
0046 tb = a * f ./ log((b*f.^3)./i + 1 );
0047 
0048 dtb = repmat( tb.^2./(a*i.*f.*(1+i./(b*f.^3))), 1, size(di,2) ) .* di;
0049 
0050 end

Generated on Mon 15-Sep-2014 13:31:28 by m2html © 2005