Matrix of an orthogonal projector represented in the canonical basis Find the matrix (represented in the canonical base $\{(1,0,0),(0,1,0),(0,0,1)\}$) of the projector $P:\mathbb{C^3}\rightarrow\mathbb{C^3}$ onto the subspace $$M=[\{f_1,f_2\}]=[\{(0,0,1),(\frac{2}{\sqrt{5}},\frac{-1}{\sqrt{5}},0)\}]$$
where the field is $\mathbb{C}$ so the dimension is $3$.
My attempt:
The basis for $M^{\perp}$ is $\{f_3\}=\{(\frac{-1}{\sqrt{5}},\frac{2}{\sqrt{5}},0)\}$ 
Obviously, $(f)$ is an orthonormal basis for $\mathbb{C^3}$.
Now I represent the canonical vectors $e_1,e_2$ and $e_3$ using this basis, but since I need to project them onto $M$ I only use the parts from vectors $f_1$ and $f_2$, or more specifically, the projection of a vector $x$ will be $$(x,f_1)f_1 + (x,f_2)f_2$$ where $(a,b)$ denotes the standard scalar product.
So, e.g. $$P(e_1)=(\frac{-2}{\sqrt{5}})\cdot f_2$$
Now, what I'm interested in is which basis I'm working in? Let us denote $A(c,d)$ where $A$ is a linear operator on $\mathbb{C}^3$ $c$ is a basis for the codomain and $d$ is a basis for the domain.
The matrix would be, after computing the projections of all canonical vectors:
$$\begin{bmatrix}
    0 & 0 & 1\\
    -2/5 & 1/5 & 0 \\
    0 & 0 & 0 \\
\end{bmatrix}$$
meaning the projection of $e_2$ onto $M$ is $\frac{1}{5}f_2$ and for $e_3$ it's just $f_1$
Now, what I've got is $P(f,e)$, right?
I still need to compute $P(e,e)=I(e,f)*P(f,e)$ to get my final solution?
 A: Since $f_1$ and $f_2$ form an orthonormal basis, then, as you wrote,$$P(x)=\langle x,f_1\rangle f_1+\langle x,f_2\rangle f_2.$$So,$$P(e_1)=\frac2{\sqrt5}f_2=\left(\frac45,-\frac25,0\right),$$$$P(e_2)=-\frac1{\sqrt5}f_2=\left(-\frac25,\frac15,0\right),$$and$$P(e_3)=f_1=(0,0,1).$$Therefore, the matrix of $P$ with respect to the canonical basis is$$\begin{bmatrix}\frac45&-\frac25&0\\-\frac25&\frac15&0\\0&0&1\end{bmatrix}.$$
A: You started out reasonably, but then made some critical errors in constructing $P(f,e)$. You’d already stated earlier that $P(e_1)=-{2\over\sqrt5}f_2$ (which contains a sign error, by the way), i.e., that its coordinates in the $f$-basis are $\left(0,-2/\sqrt5,0\right)^T$, not $(0,-2/5,0)^T$. Similarly, $P(e_2)=-{1\over\sqrt5}f_2$, so the second column of the matrix should be $\left(0,-1/\sqrt5,0\right)^T$, not $(0,1/5,0)^T$. Using the correct matrix for $P(f,e)$ you should then get $$P(e,e) = \begin{bmatrix}0 & {2\over\sqrt5} & {1\over\sqrt5} \\ 0 & -{1\over\sqrt5} & {2\over\sqrt5} \\ 1&0&0\end{bmatrix} \begin{bmatrix}0&0&1 \\ {2\over\sqrt5} & -{1\over\sqrt5} & 0 \\ 0&0&0 \end{bmatrix} = \begin{bmatrix}\frac45 & -\frac25 & 0 \\ -\frac25 & \frac45 & 0 \\ 0&0&1\end{bmatrix}.$$ Note, by the way, that you’ve also made a sign error computing a basis for $M^\perp$.
