I need a explanation and steps how I can expand this equation:
$$(x−p)^2+(mx+c−q)^2=r$$
into this one:
$$(m^2+1)x^2+2(mc−mq−p)x+(q^2−r+p^2−2cq+c^2)=0$$
Thank you for your time.
I need a explanation and steps how I can expand this equation:
$$(x−p)^2+(mx+c−q)^2=r$$
into this one:
$$(m^2+1)x^2+2(mc−mq−p)x+(q^2−r+p^2−2cq+c^2)=0$$
Thank you for your time.
What is $(x-p)^2$? See:
$$(x-p)^2=(x-p)(x-p)=x^2-2xp+p^2$$
Now what is $(mx+c-q)^2$? See:
\begin{align} (mx+c-q)^2=(mx+c-q)(mx+c-q)&=m^2x^2+mcx-mqx+mcx+c^2-cq-mqx-cq+q^2 \\ &=m^2x^2+2mcx-2mqx-2cq+c^2+q^2 \\ &=m^2x^2+2(mc-mq)x-2cq+c^2+q^2 \end{align}
Now combine:
\begin{align} (x-p)^2+(mx+c-q)^2 &= x^2-2xp+p^2+m^2x^2+2(mc-mq)x-2cq+c^2+q^2 \\ &=(m^2+1)x^2+2(mc-mq-p)x+p^2+c^2+q^2-2cq \end{align}
Now this equals $r$ by assumption, so we can substract $r$ on both sides and get:
\begin{align} (m^2+1)x^2+2(mc-mq-p)x+p^2+c^2+q^2-2cq &= r \\ \iff (m^2+1)x^2+2(mc-mq-p)x+p^2+c^2+q^2-r-2cq&=0 \end{align}