# Help with a linear algebra problem; defining a function with some properties

I'm working on the following problem:

Define a linear transformation $f: \mathbb{R}^3 \to \mathbb{R}^3$ such that:

• $\{x \in \mathbb{R}^3: f(x) = (1, 1, 1)\} = \{x \in \mathbb{R}^3: x_1 + x_2 + x_3 = 1, x_2 - x_3 = 2\}$
• $Im(f) = \langle(1, 2, 3), (0, 1, 2)\rangle$.

Solving the equations for the preimage of $(1,1,1)$, I get that $f^{-1}(1,1,1) = \langle(-2, 1, 0)\rangle + (-1, 2 0)$. In case the notation isn't clear, this represents the line parallel to $(-2,1,0)$ that goes through $(-1,2,0)$. The equation $f(x) = (1,1,1)$ is a non homogeneous linear system. Therefore, $\langle(-2,1,0)\rangle$ must be the solution to $f(x) = 0$, and $f(-1,2,0)$ must be $(1,1,1)$. This tells us right away that the kernel of $f$ is $\langle(-2,1,0)\rangle$. We can begin writing the values of $f$ for some basis of $\mathbb{R}^3$:

\begin{align} f(-2,1,0) &= 0 \\ f(-1,2,0) &= (1,1,1) \end{align}

Now, I would think that the only restriction I have for the third vector is that its image should complete a basis for $Im(f)$. We can use, for example, $(1,3,5)$, because $\langle(1,1,1),(1,3,5)\rangle = \langle(1,2,3),(0,1,2)\rangle = Im(f)$. As for the third element of the basis of $\mathbb{R}^3$, I don't see any particular restriction for it, so I'll just use $(0,0,1)$. We can define $f$ like this, then:

\begin{align} f(-2,1,0) &= 0 \\ f(-1,2,0) &= (1,1,1) \\ f(0,0,1) &= (1,3,5) \end{align}

This looks all right. But if I change to the canonical basis, write the matrix of $f$ and try to solve the system $f(x) = (1,1,1)$, I get something different than what it should be. I even used WolframAlpha to make sure I hadn't messed up when solving the linear systems. What am I doing wrong here?

-

All written seems fine. How did you change to canonical base?

You only need $f(1,0,0)$ and $f(0,1,0)$: $$f(1,0,0) = f\left(\frac{(-1,2,0)-2(-2,1,0)}{3}\right)=\frac13\cdot(1,1,1)$$ $$f(0,1,0) = f\left(\frac{2(-1,2,0)-(-2,1,0)}{3}\right)=\frac23\cdot(1,1,1)$$ So, $[f]=\begin{pmatrix} 1/3 & 2/3 & 1 \\ 1/3 & 2/3 & 3 \\ 1/3 & 2/3 & 5 \end{pmatrix}$.

Did you get these?

Edit: Other possible error: the direction $(-2,1,0)$ seems not be correct, as because of $x_2-x_3=2$ needs to be satisfied, the vector for that line needs to be in form $(a,b,b)$.

-
I got there, but when trying to solve the system $f(x) = (1,1,1)$, I get something different than what it should be. –  Javier Sep 29 '12 at 14:52
Hmm. Are you then sure about this $(-2,1,0)$ direction? –  Berci Sep 29 '12 at 15:02
That's what you get if you solve the equations defining $f^{-1}(1,1,1)$. I don't understand your edit; $(-2,1,0)$ itself doesn't belong to $f^{-1}(1,1,1)$. You have to add $(-1,2,0)$ to it. –  Javier Sep 29 '12 at 15:08
Ok, $(-1,2,0)$ is in there, but then if you add your vector $(-2,1,0)$, then it won't satisfy $x_2-x_3=2$. –  Berci Sep 29 '12 at 15:20
Well, I feel stupid now. It's $(-2,1,1)$. Everything works out now. Thanks! –  Javier Sep 29 '12 at 15:33