lentil.radiometry.Blackbody#
- class lentil.radiometry.Blackbody(wave, temp, waveunit='nm', valueunit='photlam')[source]#
Class for representing a blackbody emitter.
- Parameters:
wave (array_like) – Array of wavelengths or wavenumbers
temp (float) – Temperature in K
waveunit (str) – Wavelength units, as accepted by
Unit()
. Default isnm
.valueunit (str) – Flux units, as accepted by
Unit()
. Default isphotlam
.
Examples
Create a Blackbody object with wavelength range 400-4000 nm and a temperature of 4000K:
>>> import matplotlib.pyplot as plt >>> import numpy as np >>> import lentil >>> wave = np.arange(400,4000) >>> temp = 5000 >>> src = lentil.radiometry.Blackbody(wave,temp,waveunit='nm') >>> plt.plot(src.wave, src.value), plt.grid() >>> plt.xlabel('Wavelength [nm]'), plt.ylabel('Flux [photons/sec/m^2/sr]')
Attributes
Methods
|
Add Spectrum and other, element-wise |
|
Append Spectrum to the end of caller |
|
Return |
|
Compute a binned representation of the |
|
|
|
Crop a |
|
Divide Spectrum and other, element-wise |
|
Locate the indices defining the continuous nonzero portion of the |
|
Create a |
|
Compute the integrated value between |
|
Multiply Spectrum and other, element-wise |
|
Pad a Spectrum |
|
Spectrum elements raised to powers from other, element-wise |
|
Sample the |
|
Sample the |
|
|
|
Subtract Spectrum and other, element-wise |
|
Set new wavelength and/or value units. |
|
Trim the zero or near-zero ends off the |
|
Create a |