[Tex/LaTex] Undefined Control Sequence,Missing $ and Display math should end with $$

equationsmath-mode

I am trying to write the below equation and keep getting the various below errors.

  1. Undefined control sequence
  2. Missing $ inserted
  3. Display math should end with $$

I don't really understand the problem with my code. FYI…this is the code

\begin{equation}
\label{eqn: current}
$I_{FS} = \sum_{\substack{i}}*\frac{1}{2}*\frac{W}{L}*(V_{gs}-V_{th})^2*(1+\lambdaV_{ds})=\frac{1}{2}*k*(V_{gs}-V_{th})^2*(1+\lambda*V_{ds})*\sum_{\substack{i}}*\frac{W}{L}$
\end{equation} 

I have tried putting \equation also doesn't work. Previous to that, I used simple $...$ also, still useless.

Would be glad if someone can point out the error and give me a fix for this issue as I am a new user to LaTeX.

Best Answer

use

\begin{equation}\label{eqn: current}
I_{FS} = \sum_{\substack{i}}*\frac{1}{2}*\frac{W}{L}*(V_{gs}-V_{th})^2*(1+\lambdaV_{ds})=\frac{1}{2}*k*(V_{gs}-V_{th})^2*(1+\lambda*V_{ds})*\sum_{\substack{i}}*\frac{W}{L}
\end{equation}

without the $ ...$ They are only for inline math mode, see http://mirror.ctan.org/info/math/voss/mathmode/Mathmode.pdf

Related Question