Given vector $\vec x = \left\{ x_i\right\}_{i=1}^n$ find an algebraic expression for $\vec y = \left\{ x^2_i\right\}_{i=1}^n$ Given vector 
$$\vec x = \begin{bmatrix} x_1 \\ \vdots \\ x_n \end{bmatrix},$$
How can we write out vector 
$$\vec y =  \begin{bmatrix} y_1 \\ \vdots \\ y_n \end{bmatrix} := \begin{bmatrix} x^2_1 \\ \vdots \\ x^2_n \end{bmatrix}$$ 
in terms of $\vec x$ using only matrix operations? 
It is simple to write $\vec y$ in terms of $\vec x$ element wise, for example in the form of system of equations $y_i = x_i^2$ for $i = 1, \dots, n$.
However, I am struggling to do so using matrix notation and operations.
The best guess I could come up with was to write expressions like 
$$
\begin{aligned}
\vec y &= \vec x ^T \cdot I_{n \times n} \cdot\vec x, 
& I_{n \times n}  -\text{ identity matrix,  } &
& I_{n \times n} & =
\begin{bmatrix} 
1 & 0 & \cdots & 0 \\ 
0 & 1 & \cdots & 0 \\ 
\vdots & \vdots & \ddots & \vdots \\ 
0 & 0 & \cdots & 1 \\ \end{bmatrix} 
\\
\vec y &= \left\langle \vec x, \vec x \right \rangle 
= \left\| \vec x \right\|
& - \text{ inner product / norm,  } &
& \left\| \vec x \right\| &= \left\langle \vec x, \vec x \right \rangle  = 
\sum_{i=1}^{n} x_i^2
\end{aligned}
$$
both of which are obviously flawed.
Any hint would be appreciated.

$\begin{pmatrix}
x_1 & 0 & 0\\
0 & x_2 & 0\\
0 & 0 & x_3\\
\end{pmatrix}\begin{pmatrix}x_1\\x_2\\x_3\end{pmatrix}=\begin{pmatrix}x_1^2\\x_2²\\x_3^2\end{pmatrix}$
