# Compute the matrix representation of a linear map with respect to a basis

I'm trying to solve this exercise but I'm stuck:

Let $$V$$ be a vector space over $$K$$ and let $$\mathcal{B} = \{v_1, v_2, v_3, v_4\}$$ be a basis of $$V$$. Let $$f: V \rightarrow V$$ be a linear map such that:

$$f(v_1) = v_2 - v_3, \quad f(v_2) = 3v_1 - 2v_4, \quad f(v_3) = v_3, \quad f(v_4) = v_1 + v_4.$$

Calculate the matrix $$A$$ which represents $$f$$ in the basis $$\mathcal{B}$$. (Extra: is $$A$$ nilpotent?)

I tried multiple things. Intuitively, I thought the answer would look something like this:

$$\begin{bmatrix}\mid&\mid&\mid&\mid\\\ v_2-v_3&3v_1-2v_4&v_3&v_1+v_4\\\ \mid&\mid&\mid&\mid\end{bmatrix}$$

Which of course works for our usual basis vectors $$e_1, e_2, e_3, e_4$$, but unfortunately not for other basis vectors.

What I tried next was to calculate the matrix by hand in the case of a $$2 \times 2$$ matrix and then a specific example with some made-up numbers for a $$3 \times 3$$ matrix but I wasn't able to see any easy patterns. Surely the intention here is not to solve multiple, big systems of equations to figure out all the entries in the matrix one by one, right? What am I missing here?

Oh and for the extra, my guess is that $$A$$ is not nilpotent, since no matter how many times we apply $$A$$, we will always get $$v_3$$ for $$v_3$$ and never the zero vector. Is this correct?

Thanks to a comment I came to this solution:

$$A = \begin{bmatrix} 0 & 3 & 0 & 1 \\ 1 & 0 & 0 & 0 \\ -1 & 0 & 1 & 0 \\ 0 & -2 & 0 & 1 \end{bmatrix}$$, and I see that this works with the basis $$e_1, e_2, e_3, e_4$$.

But if I try it with other vectors, obviously it doesn't work. For example, let $$v_1 = \begin{pmatrix} 1\\\ 1\\\ 1\\\ 1\end{pmatrix}, \quad v_2 = \begin{pmatrix} 1\\\ 1\\\ 1\\\ 0\end{pmatrix}, \quad v_3 = \begin{pmatrix} 1\\\ 1\\\ 0\\\ 0\end{pmatrix}, \quad v_4 = \begin{pmatrix} 1\\\ 0\\\ 0\\\ 0\end{pmatrix}$$

But then $$Av_1 = \begin{pmatrix} 4\\\ 1\\\ 0\\\ -1\end{pmatrix} \neq v_2 - v_3$$

What am I not understanding here? Shouldn't the solution have to be in terms of the given vectors? Doesn't the solution change if you have different specific vectors?

• Your matrix should contain the coefficients $0,1,-1,-2,3$ at the right places, and not the basis vectors (the entries of a matrix are numbers from the field and not vectors). Then it is obvious that the trace is $0+0+1+1=2$. So the matrix can't be nilpotent. Commented Jan 28, 2023 at 16:18
• I hope my notation wasn't confusing. What I meant with my idea is that the first column of the matrix is the column vector you get from v2 - v3, the second column is the vector 3v1 - 2v4, and so on. Commented Jan 28, 2023 at 16:29
• You should really write down your matrix explicitly - as I said, with integer entries even! Commented Jan 28, 2023 at 16:59
• But how? I don't know the integer entries. That is the problem. Commented Jan 28, 2023 at 17:36
• Oh, that is easy. For $f(v_1)=v_2-v_3$, the first column of the matrix is $(0,1,-1,0)^T$, corresponding to $0\cdot v_1+1\cdot v_2+(-1)\cdot v_3+0\cdot v_4$. The basis doesn't play any role. You can assume $v_i=e_i$, the standard basis. Commented Jan 28, 2023 at 17:59

You're looking for a linear map $$M$$ such that

$$M\begin{pmatrix}v_1&v_2&v_3&v_4\end{pmatrix}=\begin{pmatrix}v_2-v_3&3v_1-2v_4&v_3&v_1+v_4\end{pmatrix}$$ Which is exactly, if we denote the former equality by $$MV_1=V_2$$

$$M=V_2V_1^{-1},$$ assuming a well-defined inverse. Maybe this helps.

• This helps but I'm not sure how I'm supposed to find the inverse of V1 if I don't know the specific vectors v1, v2, v3, and v4. Commented Jan 28, 2023 at 16:27
• @Kajice that's true. So you want to think of the matrix columns as representing vectors in the basis $\mathcal B$, and then convert that to the original basis $e_k.$ Commented Jan 29, 2023 at 3:17
• @Kajice you can also figure it out on a column by column basis, as in Dietrich Burde's comment. Commented Jan 29, 2023 at 3:18

Here is definition of coordinate vector (don’t skip this part). Matrix Representation of $$f$$ with respect to ordered basis $$B$$ is $$A=[f]_B=\begin{bmatrix}\mid&\mid&\mid&\mid\\\ [f(v_1)]_B & [f(v_2)]_B &[f(v_3)]_B&[f(v_4)]_B\\\ \mid&\mid&\mid&\mid\end{bmatrix}.$$

Since $$f(v_1) = v_2 - v_3$$, $$f(v_2) = 3v_1 - 2v_4$$, $$f(v_3) = v_3$$, $$f(v_4) = v_1 + v_4$$, we have $$[f(v_1)]_B=\begin{pmatrix} 0\\ 1\\ -1\\ 0\\ \end{pmatrix}, \quad[f(v_2)]_B = \begin{pmatrix} 3\\ 0\\ 0\\ -2\\ \end{pmatrix}, \quad [f(v_3)]_B = \begin{pmatrix} 0\\ 0\\ 1\\ 0\\ \end{pmatrix}, \quad [f(v_4)]_B = \begin{pmatrix} 1\\ 0\\ 0\\ 1\\ \end{pmatrix}.$$ Thus $$A= \begin{bmatrix} 0 & 3 & 0 & 1 \\ 1 & 0 & 0 & 0 \\ -1 & 0 & 1 & 0 \\ 0 & -2 & 0 & 1 \end{bmatrix}.$$

We are working in general vector space $$V$$ with $$\dim (V)=4$$. So saying $$\{e_1,e_2,e_3,e_4\}$$ is basis of $$V$$ don’t make sense, unless $$V=F^4$$.