# Tagged Questions

Questions on the functionality operating on polynomials

7k views

### Finding real roots of negative numbers (for example, $\sqrt[3]{-8}$)

Say I want to quickly calculate $\sqrt[3]{-8}$, to which the most obvious solution is $-2$. When I input $\sqrt[3]{-8}$ or Power[-8, 3^-1], Mathematica gives the ...
1k views

### Funny behaviour when plotting a polynomial of high degree and large coefficients

I am trying to plot a polynomial of degree $29$ on the domain $[0,1]$, with fairly large coefficients: ...
2k views

### How do I reassign canonical ordering of symbols?

I have a big polynomial that evaluates to: $$A^2 e^2 \phi ^- \phi ^++A e \phi ^- \phi ^+ c_{2 w} g_Z+\frac{1}{2} A e g h W^- \phi ^+ +\ll13\gg,$$ which is supposed to represent some terms in the ...
1k views

### How to keep Collect[] result in order?

For example, Collect[(1 + x + Cos[s] x^2)^3, x] gives the result ...
203 views

### Undocumented fourth parameter of Collect; how long has it been there?

While tinkering with How to get a list of monomials of a polynomial without coefficients? on a whim I tried a fourth argument in Collect and found: ...
2k views

### Computing the genus of an algebraic curve

How-to compute the genus of an algebraic curve in Mathematica ? In my case the algebraic curve is explicitly defined by a polynomial.
344 views

### What are Root objects with multiple polynomials?

In Mathematica 9 a new flavor of Root object with multiple polynomials was introduced. For example, ...
637 views

### Decomposing a matrix with polynomial elements into a polynomial with matrix coefficients

Let's say I have a matrix, $\mathbf{M}$, that is polynomially dependent on a single variable, such as M = {{15 + a^2, a + 5 a^2}, {a - 5 a^2, 2}} and I want to ...
3k views

### Is there a way to Collect[] for more than one symbol?

Oftentimes you find yourself looking for polynomials in multiple variables. Consider the following expression: a(x - y)^3 + b(x - y) + c(x - y) + d as you can ...
179 views

### What's going on here? Some kind of rationalization “under the covers”?

Observe: eq = (.25 a + .5 b + .25 c); CoefficientRules[eq^2] CoefficientRules[eq^2 // Expand] results in {{2, 0, 0} -> 1/16, {1, 1, 0} -> 1/4, {1, 0, 1} ...
6k views

### How do I replace a variable in a polynomial?

How do I substitue z^2->x in the following polynomial z^4+z^2+4? z^4+z^2+4 /. z^2->x ...
730 views

### Factorizing polynomials over fields other than $\mathbb{C}$

I'd like to take a polynomial in $\mathbb{Z}_5[x]$ of the form $ax^2+bx+c$ and factor it into irreducible polynomials. For example: Input... x^2+4 Output... <...
2k views

### How do I find the degree of a multivariable polynomial automatically?

I have a very simple question which appears not to have already been answered on this forum. Is there built-in functionality that returns the degree of a multivariable polynomial? For example if the ...
335 views

### ToNumberField won't recognize Root as an explicit algebraic number

Bug fixed in 10.0.0 In Mathematica 9.0.1, it appears that ToNumberField will not always recognize a Root object as an ...
382 views

### How to replace every possible $A+B$ and $AB$ in expansion of $(A+B)^{10}-A^{10}-B^{10}$ with $x$ and $y$, respectively?

I would like to replace every possible $A+B$ and $AB$ in expansion of $(A+B)^{10}-A^{10}-B^{10}$ with $x$ and $y$, respectively. How to do it with the simplest code in Mathematica? For example, \...
2k views

### Defining a function that completes the square given a quadratic polynomial expression

How can I write a function that would complete the square in a quadratic polynomial expression such that, for example, CompleteTheSquare[5 x^2 + 27 x - 5, x] ...
649 views

### Surprises simplifying simple polynomials

I came across some somewhat surprising behavior of Simplify today, on something very simple. Let's take two cubic polynomials that we know have the same value: <...
9k views

### Factoring polynomials to factors involving complex coefficients

I've run into some problems using Factor on polynomials with complex coefficient factors. Reading the documentation it looks like it only factors over the ...
735 views

307 views

### How can I compute the representation matrices of a point group under given basis functions?

Take the $C_{3v}$ point group for example: ...
352 views

### Does NRoots own an abstract counterpart? If not, can we write one?

We know when solving linear algebra equations, despite its abstract syntax, LinearSolve is much faster compared to Solve: ...
395 views

### Bug: Wrong results from NSolve on coupled polynomials. WorkingPrecision->Automatic fails

OP UPDATE: I received an email from WR on 1-18-2016: "...It does appear that the NSolve function is not behaving properly in this case and I have forwarded an incident report to our developers with ...
546 views

### Any efficient way to make complete homogeneous symmetric functions in Mathematica?

We do have elementary symmetric functions, SymmetricPolynomial[k, {x_1, ..., x_n}] . But I didn't find complete homogeneous symmetric functions. The induction ...
846 views

### Find roots of polynomial in field extension $GF(2^n)$?

How can I find roots of polynomial in extension field $GF(2^n)$?
829 views

### Can Mathematica tell me if a polynomial has all real roots?

I am trying on this polynomial, ...
277 views

304 views

### On the definition of the associated Legendre polynomials

Mathematica computes for n = 1,2,...: (-1)^n (LegendreP[n, -1, -3]/Sqrt[2]) -I, -3 I, -11 I, -45 I, -197 I, ... Maple ...
148 views

### Unexpected behavior using FromDigits to reconstruct polynomial

I have an issue with the reconstruction of a polynomial using FromDigits. The documentation of the function CoefficientList says: Fold the operation for multivariate polynomials: ...
218 views

### Trouble with polynomial multiplication

Bug introduced in 10.1.0 and fixed in 10.4.0 ...
644 views

### How can I plot a Chebyshev spiral?

The Chebyshev polynomials T_n of the first kind are a certain set of orthogonal polynomials. They can be defined by T_n(cos(x))=cos(nx), the first of them are T_0(x) = 1 T_1(x) = x T_2(x) = ...
700 views

### How to express the original ideal elements in the Groebner basis?

Suppose I call GroebnerBasis[{f1, f2, ...}, {x1,x2, ...}] The output is a list {g1,g2,...} For each $g_j$, there should be ...
233 views

### Decomposition of a semialgebraic set into connected components

Is there any built-in function for doing decomposition of a semialgebraic set into connected components? The only way I now can think of is to use ...
237 views

### Speed up MinimalPolynomial

My Mathematica code runs slowly MinimalPolynomial[Sqrt[2] + Sqrt[3]+ Sqrt[5]+ Sqrt[7]+ Sqrt[11]+ Sqrt[13], x] runs slowly, but the Maple version ...
3k views

### Series expansion in terms of Hermite polynomials

I am trying to expand a polynomial in terms of orthogonal polynomials (in my case, Hermite). Maple has a nice built-in function for this, ChangeBasis. Is there a ...
406 views

### Generating a polynomial that's accurate to within an error of no more than 1/10^5

I'm currently stuck on a question for class that asks... "Find a polynomial p[x] that you can use to calculate 6 ArcTan[x] to ...
233 views

### Lowering the degree of an polynomial with an assumption that the polynomial has a factor x^2+ax+b

Let's assume $x^{10}+x^5+1$ has a factor $x^2+ax+b$ Then, If $x^2=-ax-b$, $x^{10}+x^5+1 =0$. If we successively apply $x^2=-ax-b$ to $x^{10}+x^5+1$, we can make $x^{10}+x^5+1$ to degree 1, ...
I am trying to collect all terms with non-negative powers of $x$ in polynomials like $\frac{1}{x^2}\left(a x^2+x^{\pi }+x+z\right)^2$ First expand the polynomial ...