<s>[INST] Line parallel to a plane and have 45 degrees between another I need to find a direction vector for a line parallel to a plane $x+y+z = 0$ and that have $45$ degrees with the plane $x-y = 0$
So, i've assumed the vector $\vec V_r = (a,b,c)$ and since it is parallel to the first plane, the product:
$$(a,b,c)\cdot(1,1,1) = 0$$ 
(where $(1,1,1)$ is the vector normal to the first plane).
And also, using the formula for the angle between a line and a plane, where $n$ is the normal vector for the second plane:
$$\sin(\alpha) = \frac{|\vec V_r\cdot\vec n|}{\|\vec V_r\| \|\vec n\|}$$
so:
$$\sin\Bigl(\frac{\pi}{4}\Bigr) = \frac{\bigl|(a,b,c)\cdot(1,-1,0)\bigr|}{\sqrt{a^2+b^2+c^2}\sqrt{2}}$$
Then I end up with two equations:
$$a + b + c = 0$$
$$\frac{1}{\sqrt{2}} = \frac {|a-b|}{\sqrt{a^2+b^2+c^2}\sqrt{2}}$$
But i'm not able to solve for $(a,b,c)$. Could somebody help me? Thanks :)
 [/INST] After "cross multiplying" and canceling the factor of $\sqrt{2}$ on each side, we have
$$
\sqrt{a^2 + b^2 + c^2} = |a - b|.
$$
Now, square both sides and remove $a^2$ and $b^2$ terms that appear on both sides, yielding
$$
c^2 = -2ab.
$$
From the original equation, we know that $a + b + c = 0$, so
$$
b = -a - c.
$$
At this point, we can make the simplifying assumption that $a = 1$.  Why?  (Hover to reveal the answer after you've tried to answer this yourself.)

As long as $a \ne 0$ and we're looking for a direction vector, we may choose the scale of one coordinate.  How do we know that $a \ne 0$?  If it were true that $a = 0$, then the quadratic equation would give $c^2 = 0$ and so $c = 0$.  From there, the linear equation would give $b = 0$.  Now, $(a, b, c) = (0, 0, 0)$.  No good.

Substitute $b = -1 - c$ into $c^2 = -2b$, producing $c^2 = 2 + 2c$ or $(c - 1)^2 = 3$.  Therefore,
$$
c = 1 \pm \sqrt{3}.
$$
Now,
$$
b = -1 - (1 \pm \sqrt{3}) = -2 \mp \sqrt{3}.
$$
Putting this all together, their are two possible direction vectors:
$$
\vec V_r =
\begin{bmatrix}
a \\ b \\ c
\end{bmatrix}
=
\begin{bmatrix}
1 \\ -2 \mp \sqrt{3} \\ 1 \pm \sqrt{3}
\end{bmatrix}.
$$
</s>