Back to: Index

# Intersection(s) of graph and line

Q: The graph of $$y=\frac 2x$$ and a line through $$[0,4]$$ may intersect.
What slope of the line results in 2,1 or 0 intersections?
Where does the line touch the graph in just 1 point?

#### Graph:

\begin{align} \frac 4x &=mx+4 &|\times x \\ 4 &=mx^2+4x &|-4 \\ mx^2 + 4x - 4 &=0 &|\div m \\ x^2 + \frac 4m x - \frac 4m & =0 \\ \left(x + \frac 2m\right)^2 - \left(\frac 2m\right)^2 - \frac 4m & =0 \\ \left(x + \frac 2m\right)^2 & = \frac{4}{m^2} + \frac 4m & =0 \\ x & = - \frac 2m \pm \sqrt{\frac{4}{m^2} + \frac 4m} \\ x & = - \frac 2m \pm \sqrt{\frac 4m \left(\frac 1m + 1\right)} \\ \end{align} \\
$$\frac 4m \left(\frac 1m + 1 \right) = 0 \text{ results in 1 real solution exactly when } m = -1\\ \frac 4m \left(\frac 1m + 1\right) >0 \text{ results in 2 real solution exactly when } m < -1\\ \frac 4m \left(\frac 1m + 1\right) <0 \text{ results in 0 real solution exactly when } m > -1\\ \text{With }m=-1 \\ x=-\frac{2}{-1} \pm \sqrt{\frac{4}{-1}\left(\frac{1}{-1}+1\right)} \\ x=2 \pm \sqrt{(-4) \times \left(-1+1\right)} \\ x=2 \pm 0 \\ x=2 \\ y=\frac 4x =\frac 42 = 2\\ A=[2,2] \\$$

# Tangents of line on graph

Q: The graph of $$y=x^2-2x+2$$ and a line through $$[2,0]$$ may intersect. What slope(s) of the line results in exactly 1 intersection?
Where do the lines touch the graph in just 1 point?

\begin{align} y & = x^2-2x+2, \text{ and } \\ y & = mx+k, \text{ with } y(+1)=0 \implies 0=m(+1) + k \implies k=-m \implies \\ y & = mx-m \\ \end{align} Graph and line intersect when:
\begin{align} mx-m &= x^2-2x+2 \\ x^2-mx-2x+m+2 &= 0 \\ x^2-(m+2)x+(m+2) &= 0 \\ \left(x-\frac{m+2}{2}\right)^2 - \left(\frac{m+2}{2}\right)^2 + (m+2) &= 0 \\ \left(x-\frac{m+2}{2}\right)^2 &= + \frac{(m+2)^2}{4} -m-2 \\ x-\frac{m+2}{2} &= \pm \sqrt{\frac{m^2 +4m+4}{4} -m-2} \\ x &= \frac{m+2}{2} \pm \sqrt{\frac{m^2 +4m+4}{4} +\frac{-4m-8}{4}}\\ x &= 1+\frac{m}{2} \pm \frac 12 \sqrt{m^2 +4m+4 -4m -8}\\ x &= 1+\frac{m}{2} \pm \frac 12 \sqrt{m^2 -4}\\ A=[2,2] \\ B=[0,2] \\ \end{align} \\
This term has a single solution $$x$$ if
\begin{align} m^2-4 &= 0\\ m^2 &= 4\\ m&=\pm\sqrt{4} \\ m &=\pm 2 \\ m_1 &=2 \\ m_2 &=-2 \\ \end{align} \\ y_1=f_1(x)=+2x-2 \implies x=1+1=2 \implies y(2)=2 \\ y_1=f_1(x)=-2x+2 \implies x=1+(-1)=0 \implies y(0)=2 \\