Independence symbol (double perp) in LaTeX (\perp\!\!\!\perp)

⊥ ⁣ ⁣ ⁣⊥\perp\!\!\!\perp
LaTeX command
\perp\!\!\!\perp
Package
No package needed: built into LaTeX
Mode
Math mode only

Where it is used

Two \perp signs overlapped with negative spaces, the usual hand-built symbol for statistical independence.

Probabilists write X \perp\!\!\!\perp Y for independent random variables and X \perp\!\!\!\perp Y \mid Z for conditional independence, notation popularized by graphical models and causal inference. Three \! negative thin spaces pull the second \perp almost onto the first, creating a double-stemmed upside-down T. Because it is assembled by hand, its exact look varies a little between fonts; define a macro such as \newcommand{\indep}{\mathrel{\perp\!\!\!\perp}} so it also gets relation spacing. A single \perp is used for independence in some texts, but it collides with orthogonality.

Minimal compilable example

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

X⊥ ⁣ ⁣ ⁣⊥Y∣ZX \perp\!\!\!\perp Y \mid Z
\documentclass{article}
\begin{document}
Independence symbol (double perp): $\perp\!\!\!\perp$

\[ X \perp\!\!\!\perp Y \mid Z \]
\end{document}

Related symbols

All Probability at Statistics →

Frequently asked questions

How do I write Independence symbol (double perp) in LaTeX?
Type \perp\!\!\!\perp in math mode, for example $X \perp\!\!\!\perp Y \mid Z$. It works in plain LaTeX without loading any package.
Which package do I need for \perp\!\!\!\perp?
None. \perp\!\!\!\perp is part of standard LaTeX, so it compiles with nothing in the preamble but the document class.
Can I use \perp\!\!\!\perp in text mode, or only in math mode?
Only in math mode. Outside $...$ LaTeX stops with "Missing $ inserted", so write $\perp\!\!\!\perp$ in running text.
Math poweredSumulat ng LaTeX gamit ang AI

Pinakamahusay na AI LaTeX Editor, Alternatibo sa Overleaf

Tinutulungan ng Octree ang mga researcher mula sa 15+ na unibersidad na sumulat ng research papers nang mas mabilis gamit ang AI

  • Gumawa ng magagandang TikZ diagrams gamit ang AI
  • Mag-upload ng larawan at i-convert ito sa LaTeX nang walang problema
  • Makakuha ng instant na tulong sa pagsulat at pag-format ng research papers