TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Currently, using \max{1,2} will print:

max 1,2.

How do I alter it such that it prints:


without having to use \max{\{1,2\}} in text?

Note: I'm fine with making a new function called \max2 that achieves this (if overwriting the original function is a problem for some reason).

share|improve this question
up vote 3 down vote accepted

\max does not take an argument so you don't need \max{\{1,2\}} just \max\{1,2\} . However if you want to save yourself those two backslashes

share|improve this answer
In LaTeX, \max is defined as a mathop item that can take subscript limits, viz., \def\max{\mathop{\operator@font max}}. With your setup, the command $\max_z{a,b}$ is legal but results in something rather awful-looking. It may be wise to leave \max alone and provide an entirely new command, e.g., \def\maxi#1{\textrm{max}\{#1\}}. – Mico Oct 11 '12 at 15:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.