OB.DAAC Logo
NASA Logo
Ocean Color Science Software

ocssw V2022
bbt_2_rad.c
Go to the documentation of this file.
1 #include "viirs_sim_sdr.h"
2 #include <math.h>
3 #define H_CON 6.6262e-34 /* Plank's const J s^-1 */
4 #define C_CON 2.99792458e8 /* speed of light m s^-1 */
5 #define K_CON 1.3807e-23 /* Boltzman's constant J K^-1 */
6 #define C1 2. * H_CON * pow( C_CON, 2. ) * 1.e24
7 #define C2 H_CON * 1.e6 * C_CON / K_CON
8 
9 float bbt_2_rad(float bbt, float lam)
10 /*-----------------------------------------------------------------------------
11  Program: bbt_2_rad.c
12 
13  Description: convert a BBT into a radiance for VIIRS use
14 
15  Returns, radiance in W m^-2 sec^-1 sr^-1
16 
17  Arguments:
18  Type Name I/O Description
19  ---- ---- --- -----------
20  float bbt I brightness temperature in degrees K
21  float lam I wavelength in microns = nm / 10^3
22 
23  Modification history:
24 
25  W. Robinson, SAIC 8 Jul 2010 Original development
26 
27 ----------------------------------------------------------------------------*/ {
28  float rad;
29  /*
30  * perform computation
31  */
32  rad = C1 / (pow(lam, 5.) * (exp(C2 / (lam * bbt)) - 1.));
33 
34  return rad;
35 }
float bbt_2_rad(float bbt, float lam)
Definition: bbt_2_rad.c:9
#define C1
Definition: bbt_2_rad.c:6
#define C2
Definition: bbt_2_rad.c:7