Create a simple vertical vector with several vertical curly braces outside the square bracket

arraysbracesbracketsmathtoolsvertical

I could not code a vertical vector with several vertical curly braces outside the square bracket of the vector. The best thing I have obtained so far is by using rcases from mathtools package that gives me a vertical vector with the corresponding vertical curly braces inside the square bracket of the vector. My code is as the following:

\documentclass{article}

\usepackage{amsmath,mathtools}

\begin{document}

\begin{equation}
    \mathcal{O}(t) = \left[ \begin{array}{c}
    \begin{rcases} c_1^\top \\ \vdots \\ c_p^\top \end{rcases}C\\ \begin{rcases} c_1^\top A \\ \vdots \\ c_p^\top A \end{rcases} CA \\ \vdots \\ \begin{rcases}c_1^\top A^{t-1} \\ \vdots \\ c_p^\top A^{t-1}\end{rcases} CA^{t-1}
    \end{array}\right].
\end{equation}

\end{document}

that gives me this output:
enter image description here

which is still not accepted. Any hints that can help me to bring out the vertical curly braces would be greatly appreciated.

Best Answer

You can use \vphantom to replicate the vertical space of an object and use that together with a \left....\right\} construction to simulate an \rcases-like environment:

enter image description here

\documentclass{article}

\usepackage{mathtools}

\begin{document}

\[
  \mathcal{O}(t) = \left[ \begin{array}{ c }
    \begin{array}{ @{} c @{} }
      c_1^\top \\ \vdots \\ c_p^\top
    \end{array} \\[1.5\normalbaselineskip]
    \begin{array}{ @{} c @{} }
      c_1^\top A \\ \vdots \\ c_p^\top A
    \end{array} \\
    \vdots \\
    \begin{array}{ @{} c @{} }
      c_1^\top A^{t - 1} \\ \vdots \\ c_p^\top A^{t - 1}
    \end{array}
  \end{array}\right]
  \begin{array}{ @{} l @{} }
    \left.\hskip-\nulldelimiterspace\vphantom{\begin{array}{ @{} c @{} }
      c_1^\top \\ \vdots \\ c_p^\top
    \end{array}}\right\} C \\[1.5\normalbaselineskip]
    \left.\hskip-\nulldelimiterspace\vphantom{\begin{array}{ @{} c @{} }
      c_1^\top A \\ \vdots \\ c_p^\top A
    \end{array}}\right\} CA \\
    \vphantom{\vdots} \\
    \left.\hskip-\nulldelimiterspace\vphantom{\begin{array}{ @{} c @{} }
      c_1^\top A^{t - 1} \\ \vdots \\ c_p^\top A^{t - 1}
    \end{array}}\right\} CA^{t - 1}
  \end{array}
\]

\end{document}

A slight horizontal correction (\hskip-\nulldelimiterspace) reduces the space between the array and the row indicators.