\documentclass{article}
\usepackage{latexml}
\usepackage{amsmath}
\def\mockarray{\begin{array}{cc} 
  a & b \\
  c & d \end{array}}
\def\mockcases{\begin{cases}{cc} 
  d & c \\
  b & a \end{cases}}

\begin{document}

% standalone cases 
\[\mockcases\]

% standalone array
\[\mockarray\]
  
% lbrace array 
\[\{ \mockarray\]
  
% rbrace array 
\[\mockarray \}\]

% matrix multiplication
\[ \mockarray \mockcases \]

% matrix in inequality
\[ a + b < \mockarray \]

% opfunction equation with piecewise matrix
\[ \arcsin \pi + \neg a = \{ \mockarray \]

\end{document}