[Tex/LaTex] \begin{equation}: “Display math should end with $$” error

equationserrorsmath-mode

I'm pretty new to LaTeX, completely new actually, and there is one thing I can't quite understand.

I get the error "Display math should end with $$"
when writing an equation like this:

\begin{equation}

$R_{2}$=$\frac{U_{R_2}}{I_2}$=$\frac{2,95\, \mathrm{V}$}{$0,03*10^{-3}\, \mathrm{A}$} = 7,10\,\mathrm{k}\Omega \,.

\label{eq:Bsp_OhmsLaw}\end{equation}

I tried a lot of things, I also skimmed these forums. Nothing seemed to help 🙁

Thanks in advance!

Best Answer

In addition to removing the $ as cmhughes suggested, the blank lines in the equation environment confuse things. This may be why you added the dollar signs - with the blanks, LaTeX otherwise complains about missing $ symbols in the code.

Here's a working version:

\documentclass{article}

\begin{document}

\begin{equation}
  R_{2}=\frac{U_{R_2}}{I_2}=\frac{2,95\, \mathrm{V}}{0,03*10^{-3}\, \mathrm{A}} = 7,10\,\mathrm{k}\Omega \,.
  \label{eq:Bsp_OhmsLaw}
\end{equation}

\end{document}

equation