On this page we have considered polynomials as being compound types being the sum of terms made up of various powers of one or more variables multiplied by constants. Alternatively one or more variables with any permutation of addition and multiplication.
Then, on this page, we have considered consider a polynomial as an element which can be added, subtracted, multiplied and divided just like and other mathematical element like complex numbers or vectors.
We now go on to further investigate the symbolic roots of polynomials.
When we were looking at factoring polynomials all the coeficients are integers, known as a Z-polynomial, and we factored this into other Z-polynomials but the general solution to polynomials is of type: AlgebraicNumber. That is complex numbers whose parts are rationals and roots of rationals and all combinations of these with +, -, * and /.
We will denote AlgebraicNumber as Qalg - The root of a Z-polynomial - A complex number made up more than just radical integers although it is closed under sum, difference, product, quotient and nth root. We discuss number theory (types of numbers) on this page.
Since the solutions are of type AlgebraicNumber then we need to factor into parts which have constant terms of type Qalg. Rather than represent these as floating point numbers which are only approximations we will represent the roots of polynomials using symbols.
There are a number of open source programs that can work with polynomials. I have used Axiom, how to install Axiom here.
We will use the following operations which are built into the program:
|rootOf||aa := rootOf(aa**2+aa+1)||
To generate an AlgebraicNumber from a polynomial (such as x² + x + 1=0) we use the function: rootOf
Here aa represents the symbolic roots of the polynomial.
We can also supply two parameters to rootOf :
Which returns a root of p(x)
|zeroOf||The operation zeroOf is similar to rootOf except that it may return the results as radicals.|
|rootsOf||rootsOf returns all symbolic roots.|
|zerosOf||zerosOf returns all radicals.|
|definingPolynomial||definingPolynomial aa||returns the polynomial that was used to generate the AlgebraicNumber.|
Here is an example of the use of these commands, I have put user input in red:
(1) -> aa := rootOf(aa**2+aa+1)
(1) aa Type: AlgebraicNumber (2) -> p:= (x**3 + aa**2*x +y)*(aa*x**2 +aa*y**2)**2
(2) 5 3 4 2 3 (- aa - 1)y + ((- aa - 1)x + aa x)y + (- 2aa - 2)x y + 5 3 2 4 7 5 ((- 2aa - 2)x + 2aa x )y + (- aa - 1)x y + (- aa - 1)x + aa x Type: Polynomial AlgebraicNumber (3) -> factor(p,[aa]) 3 2 2 2 (3) (- aa - 1)(y + x + (- aa - 1)x)(y + x ) Type: Factored Polynomial AlgebraicNumber
(4) -> factor(x**2+3)
2 (4) x + 3 Type: Factored Polynomial Integer (5) -> factor(x**2 + 3,[aa])
(5) (x - 2aa - 1)(x + 2aa + 1) Type: Factored Polynomial AlgebraicNumber
(6) -> factor(x**6+108,[aa])
3 3 (6) (x - 12aa - 6)(x + 12aa + 6) Type: Factored Polynomial AlgebraicNumber
(7) -> bb:=rootOf(bb**3-2)
(7) bb Type: AlgebraicNumber (8) -> factor(x**6+108,[bb])
2 2 2 2 2 2
(9) (x + (- 2aa - 1)bb)(x + (- aa - 2)bb)(x + (- aa + 1)bb)(x + (aa - 1)bb) * (x + (aa + 2)bb)(x + (2aa + 1)bb) Type: Factored Polynomial AlgebraicNumber