Ticket #10563 (new enhancement)
improve jordan_form over univariate rational expressions
| Reported by: | zimmerma | Owned by: | jason, was |
|---|---|---|---|
| Priority: | minor | Milestone: | sage-5.10 |
| Component: | linear algebra | Keywords: | |
| Cc: | Work issues: | ||
| Report Upstream: | N/A | Reviewers: | |
| Authors: | Merged in: | ||
| Dependencies: | Stopgaps: |
Description
This was reported by Alexandre Casamayou:
sage: R = FractionField(PolynomialRing(RationalField(),'a')) sage: A = matrix(R,[[1,a],[a,1]]) sage: A.jordan_form() --------------------------------------------------------------------------- NotImplementedError Traceback (most recent call last) /localdisk/tmp/c157/<ipython console> in <module>() /usr/local/sage/local/lib/python2.6/site-packages/sage/matrix/matrix2.so in sage.matrix.matrix2.Matrix.jordan_form (sage/matrix/matrix2.c:32527)() /usr/local/sage/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_element.so in sage.rings.polynomial.polynomial_element.Polynomial.roots (sage/rings/polynomial/polynomial_element.c:31227)() /usr/local/sage/local/lib/python2.6/site-packages/sage/rings/ring.so in sage.rings.ring.Ring.is_finite (sage/rings/ring.c:5810)() NotImplementedError:
Change History
comment:2 Changed 2 years ago by rbeezer
Even with a quick-hacked .is_finite() method, this still fails. Getting eigenvalues over an exact ring requires factoring or root-finding, neither of which seems to be implemented over this fraction field. The following uses the same matrix A as above, but with the finiteness check added in:
sage: A.jordan_form() --------------------------------------------------------------------------- NotImplementedError Traceback (most recent call last) /home/sage/sage-4.6.1.rc1/devel/sage-main/<ipython console> in <module>() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/matrix/matrix2.so in sage.matrix.matrix2.Matrix.jordan_form (sage/matrix/matrix2.c:32626)() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_element.so in sage.rings.polynomial.polynomial_element.Polynomial.roots (sage/rings/polynomial/polynomial_element.c:31330)() NotImplementedError: root finding for this polynomial not implemented sage: A.eigenvalues() --------------------------------------------------------------------------- NotImplementedError Traceback (most recent call last) /home/sage/sage-4.6.1.rc1/devel/sage-main/<ipython console> in <module>() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/matrix/matrix2.so in sage.matrix.matrix2.Matrix.eigenvalues (sage/matrix/matrix2.c:22130)() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/matrix/matrix2.so in sage.matrix.matrix2.Matrix.fcp (sage/matrix/matrix2.c:10516)() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_element.so in sage.rings.polynomial.polynomial_element.Polynomial.factor (sage/rings/polynomial/polynomial_element.c:23007)() NotImplementedError:
Note: See
TracTickets for help on using
tickets.

It seems the fraction field does not know if it is finite or infinite. Maybe something else is in the way of getting Jordan form, but this looks like the first obstacle.
sage: T.<a>=QQ[] sage: R=FractionField(T) sage: A = matrix(R,[[1,a],[a,1]]) sage: A.charpoly().roots() --------------------------------------------------------------------------- NotImplementedError Traceback (most recent call last) /home/sage/sage-4.6.1.rc1/devel/sage-main/<ipython console> in <module>() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/rings/polynomial/polynomial_element.so in sage.rings.polynomial.polynomial_element.Polynomial.roots (sage/rings/polynomial/polynomial_element.c:31227)() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/rings/ring.so in sage.rings.ring.Ring.is_finite (sage/rings/ring.c:5810)() NotImplementedError: sage: R.is_finite() --------------------------------------------------------------------------- NotImplementedError Traceback (most recent call last) /home/sage/sage-4.6.1.rc1/devel/sage-main/<ipython console> in <module>() /sage/sage-4.6.1.rc1/local/lib/python2.6/site-packages/sage/rings/ring.so in sage.rings.ring.Ring.is_finite (sage/rings/ring.c:5810)() NotImplementedError: