Skip to main content
8 events
when toggle format what by license comment
Jun 20, 2012 at 20:11 history edited Robert Israel CC BY-SA 3.0
added 474 characters in body
Jun 20, 2012 at 19:03 comment added Manu Thanks! This seems to solve basically what I asked, except I guess you can only handle integer exponents this way? It is also not hard to implement. If you make it an answer I'll accept it.
Jun 19, 2012 at 15:27 comment added Robert Israel For trigonometric polynomials in rational multiples of $\pi$ with rational coefficients, equality can be checked algebraically. Let $x = \sum_{j=1}^n a_j \cos(b_j \pi/m)$ where $m$, $a_j$ and $b_j$ are integers, $0 \le b_j < 2 m$. Then if $\omega = e^{i\pi/m}$ we have $x = \sum_{j=1}^n a_j (\omega^{b_j} + \omega^{-b_j})/2$. So $x = 0$ iff the minimal polynomial of $\omega$, which is the cyclotomic polynomial $\Phi_m(z)$, divides $\sum_{j=1}^n a_j (z^{2m+b_j}+z^{2m-b_j})$.
Jun 19, 2012 at 14:22 comment added Manu Thanks, but my question still stands. One can obtain a zero-error "testeq" by trying all random choices. Is this available somewhere? Also, I think this all boils down to bounding the distance from 0 of non-zero expressions -- are there bounds available for expressions involving cos/sin and powers? I am aware of Baker's work on logarithmic forms.
Jun 18, 2012 at 15:40 comment added Jacques Carette testeq is by design probabilistic. If it returns false, it is always correct, if it returns true, there is a very small chance it is wrong. User beware. For certainty, see my comments on my answer.
Jun 18, 2012 at 13:41 comment added Manu Thanks, this looks useful. Is there an implementation of testeq that is always correct but may take a long time?
Jun 18, 2012 at 3:46 history edited Robert Israel CC BY-SA 3.0
added 333 characters in body
Jun 18, 2012 at 3:38 history answered Robert Israel CC BY-SA 3.0