Short Answer: Yes, you are correct.
Long Answer:
In this case, we know we need to find the lines tangent to the curve that go through some point, so I would begin by using the elementary point-slope equation to figure out the equation for y in the original function that meets those conditions.
$$y - y_1 = m(x - x_1)$$
The derivative is the slope at some x on the curve, so plug its function in for m. Use the points given in the problem for $x_1$ and $y_1$ respectively:
$$y - (-3) = (2x + 1)(x - 2)$$
Simplify:
$$y + 3 = 2x^2 - 3x - 2$$
Solve for y:
$$y = 2x^2 - 3x - 5$$
Now that we have what y must be in relation to x for the tangent line to meet the conditions given, we can plug it in to the original equation to find the desired values of x on the curve:
$$2x^2 - 3x - 5 = x^2 + x$$
Subtract $x^2 + x$ from both sides:
$$x^2 - 4x - 5 = 0$$
From the quadratic formula, we know that:
$$x = \frac{4 ± \sqrt{36}}{2}$$
Therefore $x = 5$ and $x = -1$, which when plugged into your original function, gives the points you calculated in your answer.
Hint:
Using your approach, note that ,if $Q=(x_Q,y_Q)$ is the point of tangency than the slope of the line is:
$$
m=\frac{y_Q-5}{x_Q-5}
$$
Since $Q$ is point of the parabola, we have $y_Q=x_Q^2-2x_Q-1$, and we want that this slope is the same as the derivative of the function at $x_Q$, so we have the equation:
$$
\frac{f(x_Q)-5}{x_Q-5}=f'(x_Q)
$$
that is:
$$
\frac{x_Q^2-2x_Q-1-5}{x_Q-5}=2x_Q-2
$$
solve this equation and find $x_Q$, so you can find the point $Q$ and the slope of the tangent.
But you can use also another approach that does not require derivatives.
The lines passing for the given point are:
$$
y-5=m(x-5)
$$
and we want the line that is tangent to the parabola, this means that this line has only one common point with the parabola, so, write the system:
$$
\begin {cases}
y-5=m(x-5)\\
y=x^2-2x-1
\end{cases}
$$
and find for what values of $m$ it has only one solution, i.e. for what $m$ the discriminant of the system is equal to 0. This is the slope of the tangent.
Best Answer
The derivative of the function is $4x^3 - 12x$, so the slope of the tangent line through the point $(x_0, f(x_0))$ will be exactly $4x_0^3 - 12x_0$. We may actually write the line in slope-intercept form as
$$y - f(x_0) = (4x_0^3 - 12x_0)(x - x_0)$$
or alternatively,
$$y = (4x_0^3 - 12x_0)(x - x_0) + x_0^4 - 6x_0^2$$
So the question is asking under what conditions on $x_0$ the point $(0, 3)$ lies on this curve. Substituting the values, we find that
$$3 = (4x_0^3 - 12x_0)(0 - x_0) + x_0^4 - 6x_0^2$$
Rearranging, this leads to
$$-3x_0^4 +6x_0^2 - 3 = 0$$
Dividing by $-3$ leads to
$$x_0^4 - 2x_0^2 + 1 = 0 \implies (x_0^2 - 1)^2 = 0$$
Hence, we see that $x_0^2 = 1$, so that $x_0 = \pm 1$.