# Finding the values of p and q

• May 31st 2010, 09:20 AM
Mukilab
Finding the values of p and q
$x^2-8x+23-(x-p)^2+q$ for all values of x

find the value of p and q

I did

$(x^2-8x+16)+7=...\rightarrow (x+4)^2+7=(x+p)^2+q$

I'm stuck.. what should I do now, square route the whole thing?

edit:

whittled it down to
$2x*2+23=p^2+q$

what now?
• May 31st 2010, 09:27 AM
Unknown008
The first expression you typed, is it supposed to be an equation?

$x^2-8x+23=(x-p)^2+q$

If so, you can expand on the right hand side.

Giving $x^2-8x+23=x^2 -2px + p^2 + q$

Then, equating the coefficients, you see that:

$-8 = -2p$

and

$23 = p^2+q$

Or, you can take directly from where you reached;

$(x+4)^2+7=(x+p)^2+q$

and equate the coefficients.

:)
• May 31st 2010, 09:33 AM
Mukilab
Thanks, so many people have told me about the coefficient and I've looked on sites but I still don't understand how to calculate it.

All I've learned is that comparing the coefficient is along the lines of ax^2+bx+c=a+b+c
• May 31st 2010, 09:44 AM
Unknown008
Okay, if you have

$ax^2 + bx + c = px^2 + qx + r$

Then, a = p because both a and p are terms in x^2
b = q since both b and q are terms in x,
and c = r since both are independent terms.
• May 31st 2010, 09:53 AM
Mukilab
That's what I was thinking about when I was doing the equation but I was unsure because it seems too perfect. Can you show me a proof?
• May 31st 2010, 10:18 AM
Unknown008
I'm not good at proving things :o

Have you done vector coordinates yet?

If so, you should know, for example that if you have a vector (ai + bj) and another vector (xi + yj)

Given both are the same vectors, mean that ai + bj = xi + yj

Automatically, a will be equal to x and b will be equal to y.

I know, it's not a very convincing way, but I've learned it through practice :o
• May 31st 2010, 10:21 AM
Mukilab
Quote:

Originally Posted by Unknown008
I'm not good at proving things :o

Have you done vector coordinates yet?

If so, you should know, for example that if you have a vector (ai + bj) and another vector (xi + yj)

Given both are the same vectors, mean that ai + bj = xi + yj

Automatically, a will be equal to x and b will be equal to y.

I know, it's not a very convincing way, but I've learned it through practice :o

I hate having to merely accept things >.>

yes I have studied them
• June 1st 2010, 06:34 AM
Unknown008
Ok, I thought more about it during the day. I'll use the method of completing the squares to prove it.

Let's have a look at:

$ax^2 + bx + c= px^2 + qx + r$

I have to prove that a = p, b = q and c = r.

$(a-p)x^2 + (b-q)x + (c-r)= 0$

$(a-p)[x^2 + \frac{(b-q)}{(a-p)}x + \frac{(c-r)}{(a-p)}]= 0$

Now, completing the square;

$(a-p)[(x + \frac{(b-q)}{2(a-p)}x)^2 - (\frac{(b-q)}{2(a-p)})^2 + \frac{(c-r)}{a-p}]= 0$

So far so good.

For the equation to be true, either (a-p) = 0, or $(x + \frac{(b-q)}{2(a-p)}x)^2 - (\frac{(b-q)}{2(a-p)})^2 + \frac{(c-r)}{a-p} = 0$

I solve the first one.

a - p = 0

Therefore, a = p (1st shown)

Using that in the initial equation given,

$ax^2 + bx + c= px^2 + qx + r$

Since a = p,

$bx + c= qx + r$

I put all the terms on the same side again.

$(b - q)x + (c-r)= 0$

$(b - q)[x + \frac{(c-r)}{(b-q)}]= 0$

Hence, b - q = 0, and b = q. (2nd shown)

Again, using this new result in the previous equation,

$bx + c= qx + r$

We get:

c = r

I hope this one satisfies you :)
• June 1st 2010, 11:00 AM
Mukilab
Wow that really is something. Thanks for the effort you put in! It really settles my mind :P