Just starting out with Mathematica and trying to use the Dirac Equation. I'm working with the following form of the Dirac Equation:
$$ i \hbar \gamma^\mu \partial_\mu \psi - m c \psi = 0 $$
And my input is the following:
ToExpression["i \hbar \gamma^\mu \partial_\mu \psi - m c \psi = 0", TeX]
My expected output would be the Wolfram representation of the Dirac equation, but instead I'm getting a conditional. I'm guessing this is probably a novice mistake. The output Mathematica gives me is:
$$ \psi \neq 0 \ \&\& \ \mu == cm $$
Any idea what I'm doing wrong here? Thanks for your help.
Update Re: Duplicate
The suggested duplicate seems to answer most questions except for dealing with special symbols. It's understood that in the above, \hbar or $\hbar$ has to be imported. I am unaware of how to do this and appreciate if someone can help.
ToExpression["i \hbar \gamma^\mu \partial_\mu \psi - m c \psi = 0", \ TeXForm, Hold]but this doesnt import\hbar– k_v Mar 26 '15 at 05:05\hbaris not properly imported. Is\hbarnot native to Wolfram and/or is there a link explaining how to "import" special symbols? Thanks! – crockpotveggies Mar 26 '15 at 05:08ToExpressionis to create a Mathematica expression, and what you're getting is an expression that doesn't actually correspond to the Dirac equation mathematically, even if it visually looks like your LaTeX input. And that doesn't depend on $\hbar$ being there or not. It's the symbols $\mu$ in super and subscripts. Their meaning is lost. – Jens Mar 26 '15 at 05:25\[Gamma]Mathematica doesn't correspond to the Dirac equation mathematically? And I need to "fill in the blanks" and start creating matrices and functions. – crockpotveggies Mar 26 '15 at 05:29Holdattribute. The evaluation will give nonsense unless you're much more explicit in the LaTeX input. – Jens Mar 26 '15 at 05:43