This is the version of Planck's Equation I am unable to Plot:
L[λ_]:=((8.0*π*2.9979x10^8*2.9979*10^8*6.626*10^-34)/\
λ^5)*(1.0/((E^((2.9979*10^8*6.626*10^-34)/(1.3806*10^-34*\
λ*5000.0)) )-1.0))
Color curves by the peak wavelength:
PlanckPlot[wen_] :=
PlanckRadiationLaw[Quantity[wen, "Kelvins"],
"SpectralPlot"] /. {ColorData[97, 1] ->
PlanckRadiationLaw[Quantity[wen, "Kelvins"], "Color"]}
Show[PlanckPlot /@ {6000, 5778, 5500, 5000, 4500, 4000, 3500},
PlotRange -> {{0, 3*10^(-6)}, All}, ImageSize -> 350,
Frame -> {{True, False}, {True, False}},
FrameLabel -> {"Wavelenght(m)",
"Spectral energy density(kJ/\!\(\*SuperscriptBox[\(m\), \
\(3\)]\))"}]
Color along the curves according to the wavelength:
PlanckPlot[wen_] :=
PlanckRadiationLaw[Quantity[wen, "Kelvins"],
"SpectralPlot"] /. {ColorData[97, 1] ->
PlanckRadiationLaw[Quantity[wen, "Kelvins"], "Color"]}
ColorPlanckPlot[wen_] :=
ListLinePlot[
First[Cases[PlanckPlot[wen],
Line[a_] :> Map[Apply[{#*10^9, #2} &], a], Infinity]],
ColorFunction -> (PlanckRadiationLaw[
Quantity[1, "WienWavelengthDisplacementLawConstant"]/
Quantity[#/10^9, "Meters"], "Color"] &),
ColorFunctionScaling -> False]
Show[ColorPlanckPlot /@ {6000, 5778, 5500, 5000, 4500, 4000, 3500},
PlotRange -> {{0, 2000}, All},
Frame -> {{True, False}, {True, False}},
FrameLabel -> {"Wavelenght(nm)",
"Spectral energy density(kJ/\!\(\*SuperscriptBox[\(m\), \
\(3\)]\))"}, ImageSize -> 350]
Using builtin functionalities and SI units:
h = Quantity["PlanckConstant"] // UnitConvert // QuantityMagnitude
(* 132521403/200000000000000000000000000000000000000000 *)
c = Quantity["SpeedOfLight"] // UnitConvert // QuantityMagnitude
(* 299792458 *)
kB = Quantity["BoltzmannConstant"] // UnitConvert // QuantityMagnitude
(* 1380649/100000000000000000000000000000 *)
With[{T = 5000},
Plot[(2 h c^2)/λ^5 1/(E^((h c)/(λ kB T)) - 1), {λ, 0, 5000*10^-9},
AxesLabel -> {"λ [m]", "flux [W/m^3]"}]]
You can see that this matches the built-in plot you get with
PlanckRadiationLaw[Quantity[5000, "Kelvins"], "SpectralPlot"]
x
with*
and you're all set. $\endgroup$UnitConvert@Quantity["BoltzmannConstant"] // N
to see the value in SI units. Your values of $c$ and $h$ are already in SI units, so use meters for $\lambda$. The final units will be in watts per cubic meter, or watts per square meter of surface area per meter of wavelength, which may be confirmed by evaluatingQuantity["PlanckConstant"] Quantity["SpeedOfLight"]^2/ Quantity["Meters"]^5/Quantity["Watts"] // UnitConvert // QuantityUnit
$\endgroup$