\documentclass{article} \usepackage{amsmath} \usepackage{mathtools} \MHInternalSyntaxOn \def\MT_start_cases_ams:n#1{% \RIfM@\else \nonmatherr@{\begin{\@currenvir}} \fi \MH_group_align_safe_begin: \left#1 \alignedat@a } \def\MH_end_cases_ams:{% \endaligned \MH_group_align_safe_end: } \newcommand*\defcases[3]{% \newenvironment{#1} {\MT_start_cases_ams:n {#2}} {\MH_end_cases_ams:\right#3} } \MHInternalSyntaxOff \defcases{mylcases}{\lbrace}{.} \defcases{myrcases}{.}{\rbrace} \defcases{mybcases}{\lbrace}{\rbrace} \defcases{mylrcases}{[}{\rbrace} \begin{document} \[ \begin{mylcases}{2} a &{} = b &{} = c \\ a &{} = b &{} = c \\ a &{} = b &{} = c \end{mylcases}\qquad \begin{myrcases}{2} a &{} = b &{} = c \\ a &{} = b &{} = c \\ a &{} = b &{} = c \end{myrcases}\qquad \begin{mybcases}{2} a &{} = b &{} = c \\ a &{} = b &{} = c \\ a &{} = b &{} = c \end{mybcases}\qquad \begin{mylrcases}{2} a &{} = b &{} = c \\ a &{} = b &{} = c \\ a &{} = b &{} = c \end{mylrcases} \] \end{document}