[Tex/LaTex] causing undefined control sequence


I'm getting this error:

! Undefined control sequence.
l.64 ...p(- \frac{E_j - E_i}{k_B T}) & \quad \text
                                                  {:  E_j > E_i}\\
! Undefined control sequence.
l.65     1 & \quad \text
                        {:  E_j<E_i}\\

which is from this:

w_{i,j}=w_0 exp(-2 \gamma R_{i,j})\left\{ 
  \begin{array}{l l}
    exp(- \frac{E_j - E_i}{k_B T}) & \quad \text{:  E_j > E_i}\\
    1 & \quad \text{:  E_j<E_i}\\
  \end{array} \right.

But I don't understand why I get the error. This is my header:

%\newcommand{\gguide}{{\it Preparing graphics for IOP journals}}
%Uncomment next line if AMS fonts required
\usepackage{graphicx, wrapfig}

And my class file is the standard IoP one from here

Can anyone help me get read of this error?

Best Answer

The mistake is, as TeX also informs. It cannot find your \text command. The error lies probably in package iopams and should be noticed there. It seems that it does not load the ams math package (only its fonts) and thus you need to explicitly include that package as well.

On a side note you should also include $ in your \text command.