Question: Find the equation of the straight lines which pass through the point (1,3) and make an angle of 45° with the line x - 3y +4 = 0.

Solution:

Here, equation of line 1 is x -3y +4 = 0.
Slope of line 1 (m_1) = - \frac{coefficient \; of \; x}{coefficient \; of \; y}
= - \frac{1}{-3}
= \frac{1}{3}

For line 2,
Let the slope be represented by m_2.

Angle between line 1 and line 2 is 45°.
Using formula,
tan \theta = \left ( \pm \frac{m_1 - m_2}{1 + m_1×m_2} \right )

tan 45° = \left ( \pm \dfrac{\frac{1}{3} - m_2}{1+ \frac{1}{3}×m_2} \right )

or, 1 = \left ( \pm \dfrac{\frac{1 - 3m_2}{3}} {\frac{3 + m_2}{3} }\right )

or, 1 = \left ( \pm \dfrac{1-3m_2}{3 + m_2} \right )

or, 3 + m_2 = \pm (1-3m_2)

Taking positive sign,
or, 3 + m_2 = 1 - 3m_2
or, 3m_2 + m_2 = 1-3
or, 4m_2 = -2
or, 2×2×m_2 = -2×1
or, 2m_2 = -1
\therefore m_2 = - \frac{1}{2}

Taking negative sign,
or, 3 + m_2 = -(1-3m_2)
or, 3 + m_2 = 3m_2 -1
or, 3+1 = 3m_2 - m_2
or, 4 = 2m_2
or, 2×2 = 2×m_2
\therefore m_2 = 2

Now,
Equation of line 2 when m_2 = - \frac{1}{2} and (1,3) = (x_1,y_1)

or, y - y_1 = m_2 (x - x_1)
or, y - 3 = - \dfrac{1}{2 (x -1)}
or, 2(y -3) = -1(x -1)
or, 2y -6 = 1 - x
or, x +2y -6-1 = 0
or, x +2y -7 = 0 is the required equation.

Also,
Equation of line 2 when m_2 = 2 and (1,3) = (x_1,y_1)

or, y -y_1 = m_2(x -x_1)
or, y -3 = 2(x -1)
or, y -3 = 2x -2
or, 0 = 2x -y -2+3
or, 2x - y +1 = 0 is the required equation.

Therefore, the required equation of the straight line is (x +2y -7 = 0) and (2x -y +1 = 0).