Maximum in LaTeX (\max)

max⁡\max
LaTeX command
\max
Package
No package needed: built into LaTeX
Mode
Math mode only

Where it is used

Maximum operator: the largest element of a set or the greatest value a function reaches on its domain.

Optimization problems, the max norm \|x\|_\infty = \max_i |x_i|, and ReLU activations \max(0, x) all rely on \max. It behaves like \sum with respect to limits: below the operator in display style, beside it in inline text. Brackets after it are not auto-sized, so write \max\left( a, b \right) or \max\bigl( \dots \bigr) when the argument contains fractions. When the maximum might not exist, use \sup instead. For an argmax operator, declare one with the starred \DeclareMathOperator* so its subscript also goes underneath in displays.

Minimal compilable example

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

∥x∥∞=max⁡1≤i≤n∣xi∣\|x\|_\infty = \max_{1 \le i \le n} |x_i|
\documentclass{article}
\begin{document}
Maximum: $\max$

\[ \|x\|_\infty = \max_{1 \le i \le n} |x_i| \]
\end{document}

Related symbols

All 부등식 및 순서 →

Frequently asked questions

How do I write Maximum in LaTeX?
Type \max in math mode, for example $\|x\|_\infty = \max_{1 \le i \le n} |x_i|$. It works in plain LaTeX without loading any package.
Which package do I need for \max?
None. \max is part of standard LaTeX, so it compiles with nothing in the preamble but the document class.
Can I use \max in text mode, or only in math mode?
Only in math mode. Outside $...$ LaTeX stops with "Missing $ inserted", so write $\max$ in running text.
Math poweredAI로 LaTeX 작성

최고의 AI LaTeX 편집기, Overleaf 대안

Octree는 15개 이상의 대학의 연구자들이 AI를 사용하여 논문을 더 빠르게 작성하도록 도움

  • AI로 아름다운 TikZ 다이어그램 생성
  • 이미지를 업로드하고 LaTeX로 원활하게 변환
  • 논문 작성 및 서식에 대한 즉각적인 지원 받기