Degree in LaTeX (\deg(v))
- LaTeX command
\deg(v)- Package
- No package needed: built into LaTeX
- Mode
- Math mode only
Where it is used
Degree of vertex v: the number of edges incident to it, counting loops twice.
\deg is one of LaTeX's predefined operator names, so it prints upright with correct spacing, unlike typing deg, which gives three italic letters. The handshake lemma states \sum_v \deg(v) = 2|E|, and many authors abbreviate to d(v) or d_G(v). Minimum and maximum degree are written \delta(G) and \Delta(G). For a subscripted graph, \deg_G(v) works naturally. The same command also typesets the degree of a polynomial, \deg(p), in algebra. A regular graph has \deg(v) = k for every vertex.
Minimal compilable example
Paste this into an empty .tex file and compile it with pdfLaTeX, XeLaTeX or LuaLaTeX.
\documentclass{article}
\begin{document}
Degree: $\deg(v)$
\[ \sum_{v \in V} \deg(v) = 2|E|, \quad \delta(G) \leq \deg(v) \leq \Delta(G) \]
\end{document}Related symbols
All Graph Theory →Frequently asked questions
- How do I write Degree in LaTeX?
- Type \deg(v) in math mode, for example $\sum_{v \in V} \deg(v) = 2|E|, \quad \delta(G) \leq \deg(v) \leq \Delta(G)$. It works in plain LaTeX without loading any package.
- Which package do I need for \deg(v)?
- None. \deg(v) is part of standard LaTeX, so it compiles with nothing in the preamble but the document class.
- Can I use \deg(v) in text mode, or only in math mode?
- Only in math mode. Outside $...$ LaTeX stops with "Missing $ inserted", so write $\deg(v)$ in running text.
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