]> gitweb.michael.orlitzky.com - mjotex.git/blob - mjo-common.tex
Add mathtools package to mjo-common.tex.
[mjotex.git] / mjo-common.tex
1 %
2 % Only the most commonly-used macros. Needed by everything else.
3 %
4
5 \usepackage{mathtools}
6
7 % Place the argument in matching left/right parntheses.
8 \DeclarePairedDelimiter{\of}{ \lparen }{ \rparen }
9
10 % Group terms using parentheses.
11 \newcommand*{\qty}[1]{ \left\lparen {#1} \right\rparen }
12
13 % Create a set from the given elements
14 \DeclarePairedDelimiter{\set}{ \lbrace }{ \rbrace }
15
16 % A set comprehension, where the ``such that...'' bar is added
17 % automatically. The bar was chosen over a colon to avoid ambiguity
18 % with the L : V -> V notation. We can't leverage \set here because \middle
19 % needs \left and \right present.
20 \newcommand*{\setc}[2]{ \left\lbrace {#1}\ \middle|\ {#2} \right\rbrace }
21
22 % A pair of things.
23 \DeclarePairedDelimiterX{\pair}[2]{ \lparen }{ \rparen}{ {#1}, {#2} }