Such That (Colon) in LaTeX (:)

::
LaTeX command
:
Package
No package needed: built into LaTeX
Mode
Text and math mode

Where it is used

Colon read as 'such that' in quantified statements and set-builder notation, separating a variable from its condition.

In math mode a plain colon is treated as a relation, getting equal thick space on both sides, which suits \{x : x > 0\} and \forall x : P(x). For a function signature use \colon instead, since it has punctuation spacing: f\colon A \to B looks right, whereas f : A \to B leaves a gap before the colon. For definitions, := built from two characters can look misaligned vertically; a dedicated definition symbol from an extension package fixes that. Some authors prefer \mid or a vertical bar in set-builder notation; choose one and stay consistent.

Minimal compilable example

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

{n∈Z:n2<10}\{ n \in \mathbb{Z} : n^2 < 10 \}
\documentclass{article}
\usepackage{amssymb}
\begin{document}
Such That (Colon): $:$

\[ \{ n \in \mathbb{Z} : n^2 < 10 \} \]
\end{document}

Related symbols

All المحددات الكمية →

Frequently asked questions

How do I write Such That (Colon) in LaTeX?
Type : in math mode, for example $\{ n \in \mathbb{Z} : n^2 < 10 \}$. It works in plain LaTeX without loading any package.
Which package do I need for :?
None. : is part of standard LaTeX, so it compiles with nothing in the preamble but the document class.
Can I use : in text mode, or only in math mode?
Both. : compiles in running text as well as inside $...$; in a formula keep it in math mode so it gets math fonts and spacing.
Math poweredاكتب LaTeX باستخدام الذكاء الاصطناعي

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

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

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