Integers in LaTeX (\mathbb{Z})

Z\mathbb{Z}
LaTeX command
\mathbb{Z}
Package
Add to your preamble:\usepackage{amssymb}
Mode
Math mode only
Copy the Unicode character
ℤU+2124

Where it is used

Blackboard-bold Z, the set of all integers, positive, negative and zero.

The Z comes from the German Zahlen. Common constructions include the cyclic group \mathbb{Z}/n\mathbb{Z}, the p-adic integers \mathbb{Z}_p (beware: some authors use \mathbb{Z}_n for the cyclic group instead), the lattice \mathbb{Z}^n, and \mathbb{Z}[i] for Gaussian integers. Subsets are written with subscripts such as \mathbb{Z}_{\ge 0}. \mathbb works only on capital letters in the standard fonts. Avoid simulating it with bold \mathbf{Z}, which was the older printed convention. In ring theory, \mathbb{Z} is the initial ring, and every abelian group is a \mathbb{Z}-module.

Minimal compilable example

Paste this into an empty .tex file and compile it with pdfLaTeX, XeLaTeX or LuaLaTeX.

Z/nZ={0ˉ,1ˉ,…,n−1‾}\mathbb{Z}/n\mathbb{Z} = \{\bar{0}, \bar{1}, \ldots, \overline{n-1}\}
\documentclass{article}
\usepackage{amssymb}
\begin{document}
Integers: $\mathbb{Z}$

\[ \mathbb{Z}/n\mathbb{Z} = \{\bar{0}, \bar{1}, \ldots, \overline{n-1}\} \]
\end{document}

Related symbols

All نظرية المجموعات →

Frequently asked questions

How do I write Integers in LaTeX?
Type \mathbb{Z} in math mode, for example $\mathbb{Z}/n\mathbb{Z} = \{\bar{0}, \bar{1}, \ldots, \overline{n-1}\}$. Load amssymb first with \usepackage{amssymb}.
Which package do I need for \mathbb{Z}?
\mathbb{Z} needs amssymb: add \usepackage{amssymb} to your preamble before the document starts.
Can I use \mathbb{Z} in text mode, or only in math mode?
Only in math mode. Outside $...$ LaTeX stops with "Missing $ inserted", so write $\mathbb{Z}$ in running text. If you only need the glyph in text, paste the Unicode character ℤ instead (with XeLaTeX or LuaLaTeX and a font that has it).
Math poweredاكتب LaTeX باستخدام الذكاء الاصطناعي

أفضل محرر LaTeX بالذكاء الاصطناعي، بديل Overleaf

يساعد Octree الباحثين من أكثر من 15 جامعة على كتابة أوراق البحث بشكل أسرع باستخدام الذكاء الاصطناعي

  • أنشئ رسوم TikZ جميلة باستخدام الذكاء الاصطناعي
  • ارفع صورة وحولها إلى LaTeX بسلاسة
  • احصل على مساعدة فورية في كتابة وتنسيق أوراق البحث