Completing the Square: Solving Multivariable Equations

  • Thread starter Ted123
  • Start date
  • Tags
    Square
In summary, to complete the square for a polynomial with more than one variable, you can apply the algorithm that leads to Cholesky factorization of a matrix. First, factor out any perfect squares for the variables in the polynomial. Then, factor out a common term from the remaining "mixed" terms. Finally, use the Cholesky factorization formula to write the polynomial as the sum of squares. The rank and signature of the resulting polynomial depend on the number of positive and negative squares.
  • #1
Ted123
446
0
How do I complete the square for: [tex]x^2 + 2y^2 + 2z^2 + 4xy +4xz + 4yz[/tex]
I can do it for a normal quadratic [itex]ax^2 + bx + c[/itex] but how do I do it for something like this with more than one variable?
 
Physics news on Phys.org
  • #2
Ted123 said:
How do I complete the square for: [tex]x^2 + 2y^2 + 2z^2 + 4xy +4xz + 4yz[/tex]
I can do it for a normal quadratic [itex]ax^2 + bx + c[/itex] but how do I do it for something like this with more than one variable?
I doubt that there is one particular "correct" result for this.

Notice that this polynomial does contain a perfect square for two of the variables, y & z: [itex]2y^2+4yz+2z^2=2(y+z)^2\,. [/itex]

Factor 4x out of the two remaining "mixed" terms.
[itex]x^2+4x(y+z)+2(y+z)^2[/itex]​
I see two ways to finish. You can figure out how many terms of (y+z)2 to add & subtract, or you can figure out how many terms of x2 to add & subtract. The latter way gives a simpler looking answer.
 
  • #3
SammyS said:
I doubt that there is one particular "correct" result for this.

Notice that this polynomial does contain a perfect square for two of the variables, y & z: [itex]2y^2+4yz+2z^2=2(y+z)^2\,. [/itex]

Factor 4x out of the two remaining "mixed" terms.
[itex]x^2+4x(y+z)+2(y+z)^2[/itex]​
I see two ways to finish. You can figure out how many terms of (y+z)2 to add & subtract, or you can figure out how many terms of x2 to add & subtract. The latter way gives a simpler looking answer.

I've got it equal to the sum of squares: [tex]2(x+y+z)^2 - x^2[/tex] What does this mean the rank and signature is? There is 1 positive square and 1 negative square so is the rank 1+1=2 and the signature 1-1=0?
 
  • #4
Ted123 said:
How do I complete the square for: [tex]x^2 + 2y^2 + 2z^2 + 4xy +4xz + 4yz[/tex]
I can do it for a normal quadratic [itex]ax^2 + bx + c[/itex] but how do I do it for something like this with more than one variable?

You can apply (essentially) the algorithm that leads to Cholesky factorization of a matrix. In your example, start by looking at the x-terms, which are [itex] x^2 + 4xz + 4yz .[/itex] These are what you would get if you looked at [itex] (x+2y+2z)^2, [/itex] because that is where you would get terms of the form 4xy and 4xz. Anyway, we have [tex] x^2 + 4xy + 4xz = (x+2y + 2z)^2 - 4y^2 - 4z^2 - 8yz, [/tex], so your function f(x,y,z) is
[tex] (x+2y+2z)^2 -2y^2 - 2z^2 -4yz. [/tex] Now [tex]2y^2+2z^2+4yz = 2(y+z)^2,[/tex]
so we finally have [tex] f(x,y,z) = (x+2y+2z)^2-2(y+z)^2. [/tex]

RGV
 
  • #5
Ray Vickson said:
You can apply (essentially) the algorithm that leads to Cholesky factorization of a matrix. In your example, start by looking at the x-terms, which are [itex] x^2 + 4xz + 4yz .[/itex] These are what you would get if you looked at [itex] (x+2y+2z)^2, [/itex] because that is where you would get terms of the form 4xy and 4xz. Anyway, we have [tex] x^2 + 4xy + 4xz = (x+2y + 2z)^2 - 4y^2 - 4z^2 - 8yz, [/tex], so your function f(x,y,z) is
[tex] (x+2y+2z)^2 -2y^2 - 2z^2 -4yz. [/tex] Now [tex]2y^2+2z^2+4yz = 2(y+z)^2,[/tex]
so we finally have [tex] f(x,y,z) = (x+2y+2z)^2-2(y+z)^2. [/tex]

RGV

So is the rank 2 and the signature 0?
 

Related to Completing the Square: Solving Multivariable Equations

1. What is completing the square?

Completing the square is a mathematical technique used to solve quadratic equations. It involves manipulating the equation so that it takes the form of (x + a)^2 = b, where a and b are constants. This method is useful for finding the roots of a quadratic equation, which are the values of x that make the equation equal to 0.

2. Why is completing the square important?

Completing the square is important because it allows us to solve quadratic equations that cannot be solved by factoring or using the quadratic formula. This technique is also used in calculus and other advanced math concepts.

3. How do you complete the square?

To complete the square, follow these steps:

  1. Write the equation in the form of ax^2 + bx + c = 0, where a, b, and c are constants.
  2. Divide both sides of the equation by a, so that the coefficient of x^2 is 1.
  3. Move the constant term (c) to the right side of the equation.
  4. Take half of the coefficient of x (b/2) and square it. Add this value to both sides of the equation.
  5. Factor the left side of the equation as a perfect square. Simplify the right side if needed.
  6. Solve for x by taking the square root of both sides of the equation.
  7. If there is a + or - in front of the square root, you will have two solutions. If not, you will have one solution.

4. When should I use completing the square?

You should use completing the square when you encounter a quadratic equation that cannot be solved by factoring or using the quadratic formula. This method is also helpful in finding the vertex of a parabola or solving optimization problems.

5. Can completing the square be used for all quadratic equations?

Yes, completing the square can be used for all quadratic equations. However, it may not always be the most efficient method. In some cases, factoring or using the quadratic formula may be quicker and easier. It is important to know all three methods and choose the most appropriate one for a given equation.

Similar threads

Replies
19
Views
2K
  • Calculus and Beyond Homework Help
Replies
18
Views
2K
  • Calculus and Beyond Homework Help
Replies
18
Views
1K
  • Calculus and Beyond Homework Help
Replies
26
Views
1K
  • Calculus and Beyond Homework Help
Replies
4
Views
3K
Replies
4
Views
529
  • Calculus and Beyond Homework Help
Replies
10
Views
1K
  • Precalculus Mathematics Homework Help
Replies
5
Views
699
  • Calculus and Beyond Homework Help
Replies
3
Views
836
  • Calculus and Beyond Homework Help
Replies
7
Views
513
Back
Top