[Tex/LaTex] How to denote n elements in a vector

matricesvector

I have a column vector with two 1's and n 2's, where n is an integer. What is a clever way of denoting that there are n 2's in the matrix? I was thinking of using like a side brace, but I don't know how to do that, and I think it might look messy. Does anyone have any suggestions?

This is what I currently have:

\begin{align*}
\begin{bmatrix}
1 & 1 \\
2 & 1 \\
3 & 1 \\
3 & 1 \\
\vdots & \vdots  \\
n \text{ times } & n \text{ times } \\
\vdots & \vdots \\
3 & 1 
\end{bmatrix}
\begin{bmatrix}
m \\ b
\end{bmatrix} = \begin{bmatrix}
1 \\ 1 \\ 2 \\ 2 \\ \vdots \\ n \text{ times } \\ \vdots \\ 2
\end{bmatrix},
\end{align*}

In the above code, the rows with entries 3 and 1 are supposed to appear in the left-hand matrix n times, and the 2 in the right-hand matrix is supposed to appear n times. My current notation is pretty confusing, though.

Best Answer

Here is a realisation with some fine-tuning of @marmot's suggestion:

\documentclass{article}
\usepackage{mathtools}%
\usepackage{graphicx}

\begin{document}

\begin{align*}
\begin{bmatrix}
1 & 1 \\
2 & 1 \\
3 & 1 \\
3 & 1 \\[-1.2ex]
\vdots & \vdots \\
\rotatebox{90}{\footnotesize$ n $ times} &\rotatebox{90}{\footnotesize$ n $ times} \\[-1.3ex]
\vdots & \vdots \\[-0.4ex]
3 & 1
\end{bmatrix}
\begin{bmatrix}
m \\ b
\end{bmatrix} = \begin{bmatrix}
1 \\ 1 \\ 2 \\ 2 \\[-1.2ex]  \vdots \\\rotatebox{90}{\footnotesize$ n $ times} \\[-1.3ex] \vdots \\[-0.4ex] 2
\end{bmatrix}
\end{align*}

\end{document} 

enter image description here

Related Question