# \mathbb{Z} yields undefined control sequence error

I am using WinEdt 6 for compiling my TeX documents. I am getting an error with contains the line $\mathbb{Z}$ showing that it is undefined control sequence. How should I rectify it? Should I include any math packages or something. I am a beginner in using TeX.

-
This was my very first LaTeX error! It took me days to figure out; no online resource I read thought to mention that it was assuming the amssymb package. –  Ryan Reich Dec 19 '11 at 16:19
tex.ac.uk/cgi-bin/texfaq2html?label=numbersets describes the AMS fonts, and says "Support files for using the fonts, both under Plain TeX and LaTeX (packages amssymb and amsfonts), are available. [...]". this of course doesn't help, if you're a person who doesn't like to read faq answers... –  wasteofspace Dec 19 '11 at 16:56

Load the amsfonts package, this provides that command:

\documentclass{article}
\usepackage{amsfonts}
\begin{document}
$\mathbb{Z}$
\end{document}


Optionally you could load amssymb, as this in turn loads amsfonts.

\documentclass{article}
\usepackage{amssymb}
\begin{document}
$\mathbb{Z}$
\end{document}


For reference, the Comprehensive LaTeX Symbol List has also a list of math alphabets, in table 213 on page 68.

-
Thank you. Would the same be sufficient for \mathds?? –  Ramana Venkata Dec 19 '11 at 11:03
@RamanaVenkata No, for that you have to load the dsfont package. –  Torbjørn T. Dec 19 '11 at 11:07
Thanks for you help. –  Ramana Venkata Dec 19 '11 at 11:08