


Convert quanta (photons) to energy (watts) energy = Quanta2Energy(WAVELENGTH,PHOTONS) Convert PHOTONS represented at the sampled WAVELENGTH positions to energy (watts or joules). WAVELENGTH is a column vector describing the wavelength samples [nm] PHOTONS can be a matrix in either RGB or XW (space-wavelength) format. In the XW format each spatial position is in a row and the wavelength varies across columsn. The output, ENERGY, [watts or Joules] is returned in same format as input (RGB or XW). CAUTION: The input form differs from the Energy2Quanta() call, which has the energy spectra in the columns. Examples: wave = 400:10:700; p1 = blackbody(wave,5000,'photons'); e = Quanta2Energy(wave,p1); % e us a row vector, space-wavelength (XW) format p2 = Energy2Quanta(wave,transpose(e)); % Notice the TRANSPOSE figure; plot(wave,p1,'ro',wave,p2,'k-') Copyright ImagEval Consultants, LLC, 2003.
