1
$\begingroup$

I'd like to express a numerical value of h c/k T. The below does only show me the equation, but not the actual value. Any suggestions how I can achieve it would be greatly apprecaited.

Clear["Global`*"];
h = Quantity[1, "PlanckConstant"];
c = Quantity[1, "SpeedOfLight"] ;
k = Quantity[1, "BoltzmannConstant"];

\!\(\*SubscriptBox[\(T\), \(\[AliasDelimiter]\)]\) = 
  Quantity[7200, "Kelvin"];

\[Lambda] == h c/k T 
UnitConvert[\[Lambda], "meters"] // N

enter image description here

$\endgroup$
6
  • $\begingroup$ replace the ‘==‘ with ‘=‘ and re-evaluate $\endgroup$
    – Conor
    Feb 12, 2021 at 23:33
  • $\begingroup$ still getting UnitConvert[ T (Quantity[1, ("PlanckConstant" "SpeedOfLight")/( "BoltzmannConstant")]), "meter"] $\endgroup$
    – Nickpick
    Feb 12, 2021 at 23:35
  • 1
    $\begingroup$ looks like you haven’t defined T $\endgroup$
    – Conor
    Feb 12, 2021 at 23:40
  • 1
    $\begingroup$ Also replace “meters” with “Meters” $\endgroup$
    – Conor
    Feb 12, 2021 at 23:43
  • 2
    $\begingroup$ you're right. thanks works now $\endgroup$
    – Nickpick
    Feb 12, 2021 at 23:43

0

Browse other questions tagged or ask your own question.