3

I'm trying to understand how we got to the "citardauq" formula   (note: "quadratic", reversed)

I found this question here, first answer by Andre says

Multiply "top" and "bottom" by $-b\mp\sqrt{b^2-4ac}$. After the smoke clears, we obtain $$\frac{2c}{-b \mp \sqrt{b^2-4ac}}.$$

Question is, how does the smoke actually clear? I was able to get to the final result by just distributing and canceling out terms but I wasn't sure I went about it the right way, the $\mp$ confused me a bit. How do you multiply $\pm \sqrt{b^2-4ac}$ with $\mp \sqrt{b^2-4ac}$?

vexe
  • 199
  • $\frac{-b\pm\sqrt{b^{2}-4ac}}{2a}\cdot\frac{-b\mp\sqrt{b^{2}-4ac}}{-b\mp\sqrt{b^{2}-4ac}}=\frac{b^{2}-b^{2}+4ac}{2a}\cdot\frac{1}{-b\mp\sqrt{b^{2}-4ac}}=\frac{2c}{-b\mp\sqrt{b^{2}-4ac}}$ – user71352 Dec 26 '16 at 07:06
  • Doesn't really help. You're skipping the step that I'm asking about. – vexe Dec 26 '16 at 08:27
  • 2
    Sorry, I was confused about what you didn't understand. You can split the multiplication $(-b\pm\sqrt{b^{2}-4ac})(-b\mp\sqrt{b^{2}-4ac})$ into two cases where you choose a plus in the first factor and a minus in the second factor and vice versa. Let's deal with the scenario where the first factor has a plus and the second has a minus. In this case we have: $(-b+\sqrt{b^{2}-4ac})(-b-\sqrt{b^{2}-4ac})=(-b)^{2}-b\sqrt{b^{2}-4ac}+b\sqrt{b^{2}-4ac}-(\sqrt{b^{2}-4ac})^{2}=b^{2}-(b^{2}-4ac)=4ac$. The second case is similar. – user71352 Dec 26 '16 at 08:36
  • $\pm\cdot\mp=-$. –  Dec 26 '16 at 08:36
  • @user71352 this is what I was basically doing splitting them up into two cases, but then I sum up the result and end up with 4ac+4ac=8ac – vexe Dec 26 '16 at 08:46
  • @YvesDaoust if that's the case, then why do we need two cases to distribute? – vexe Dec 26 '16 at 08:47
  • @vexe Could you explain how you got a second factor of $4ac$? In my previous comment the two middle terms cancel so all I see left are $b^{2}$ and $-b^{2}+4ac$. These should not sum to $8ac$. – user71352 Dec 26 '16 at 08:49
  • @vexe: sorry, I don't get your question. –  Dec 26 '16 at 08:52
  • @user71352 I'm just not sure how to handle the $\mp$ when distributing. Let's just call the terms X and Y. Here's what I'm doing: $(X \pm Y) * (X \mp Y) = X^2 - XY + XY + YX - YX - Y^2 - Y^2 = X^2 - 2Y^2$ So we get $b^2 - 2 * (b^2 - 4ac) = b^2 - 2b^2 + 8ac = -b^2 + 8ac$ :( – vexe Dec 26 '16 at 09:04
  • 3
    @vexe The expression $(X\pm Y)(X\mp Y)$ is a shorthand for two separate cases which are $(X+Y)(X-Y)$ and $(X-Y)(X+Y)$. These two cases do not interact at all. Notice that both multiplications result in $X^{2}-Y^{2}$. – user71352 Dec 26 '16 at 09:09
  • 1
    Distribute as usual, $$(x\pm y)(x\mp y)=x^2\pm xy\mp xy\pm(\mp y^2).$$ –  Dec 26 '16 at 10:23

2 Answers2

6

By Vieta's formula, the product of the roots is the ratio of the independent term and the quadratic coefficient.

$$r_0r_1=\frac ca.$$

Then

$$r_1=\frac c{ar_0}.$$


This formula is useful for the accurate evaluation of the roots, as it trades a difference for a sum, and avoids catastrophic cancellation (https://en.wikipedia.org/wiki/Loss_of_significance).


You can read the original equation as

$$0=\frac{ax^2+bx+c}{x^2}=a+\frac bx+\frac c{x^2}=a+by+cy^2$$ where $y=1/x$.

The solution of this quadratic equation is

$$y=\frac{-b\pm\sqrt{b^2-4ca}}{2c}$$ or

$$x=\frac{2c}{-b\pm\sqrt{b^2-4ca}}.$$


Regarding the "smoke" method, the computation is

$$\frac{-b\pm\sqrt{b^2-4ac}}{2a}=\frac{-b\pm\sqrt{b^2-4ac}}{2a}\frac{-b\mp\sqrt{b^2-4ac}}{-b\mp\sqrt{b^2-4ac}}=\frac{b^2-b^2+4ac}{2a(-b\mp\sqrt{b^2-4ac})}.$$

  • Oh that's neat, less confusing and more straight-forward. I'll accept although I'd still like to know how to distribute $\mp$ correctly lol – vexe Dec 26 '16 at 09:07
  • @vexe: you should ask a separate question about that. –  Dec 26 '16 at 10:24
  • Oh sorry I mean my question was how to do the +- distribution but you provided a better way to think about it. But yours and @user71352's comments above answered my distribution question. – vexe Dec 26 '16 at 17:59
1

Basically the thing is we have to multiply $-b \pm \sqrt{b^2-4ac}$ with $-b \mp \sqrt{b^2-4ac}$. Consider the terms $-b = \alpha$ and $\sqrt{b^2-4ac} = \beta$. Then our requirement reduces to multiplying $\alpha + \beta$ and $\alpha -\beta$.

The thing to remember is that we have to multiply $-b + \sqrt{b^2-4ac}$ with $-b -\sqrt{b^2-4ac}$ and not square it. The same argument goes for the term with the negative sign as well. Hope it helps.

  • Wait so is there a difference between $\mp$ and $\pm$? – vexe Dec 26 '16 at 08:04
  • 1
    Yes obviously, when one term takes + the other takes - signs and vice versa. –  Dec 26 '16 at 08:06
  • Excuse my thick head it's 3:30AM. I'm just not doing it right. Multiplying $\pm \sqrt{b^2-4ac}$ with $\mp \sqrt{b^2-4ac}$ I keep getting $-b^2 + 8ac$ – vexe Dec 26 '16 at 08:26
  • The thing is consider $\sqrt{b^2-4ac}$ as $a_1$. So then obviously $-\sqrt{b^2-4ac}$ is $-a_1$. What do you get multiplying $a_1$ and $-a_1$? We get $-a_1^2$. Express this as $-(\sqrt{b^2-4ac})^2 = (-1)(\sqrt{b^2-4ac})^2 = (-1)(b^2-4ac) = -b^2 + 4ac$. Hope it is clear now. –  Dec 26 '16 at 08:34
  • OK, so what you just did is $\mp$ times $\pm$ is equal to $-$ times $-$ ? i.e. it's just a single distribution, not multiple ones? – vexe Dec 26 '16 at 08:42
  • Yes you are right. –  Dec 26 '16 at 08:47
  • @Rohan: no, he is wrong. $-$ times $-$ is $+$, which is not $\mp$ times $\pm$. –  Dec 26 '16 at 17:09