Ask Your Question
1

Characteristic polynomial of symbolic matrix of size 7

asked 2018-10-06 08:04:49 +0200

ScreenName gravatar image

updated 2023-01-10 00:01:11 +0200

tmonteil gravatar image

There is a problem when computing the characteristic polynomial of a matrix of size greater than 7 containing a large number of symbolic variables.

a = SR.var('a', 100)
M = identity_matrix(SR, 7)
for i in range(7):
  for j in range(7):
    M[i,j] = a[i*7+j]
print(M.charpoly().degree()) # prints 5

The value it should print is 7. Over $\mathbb{Z}[a_0,a_1,\dots]$, the result is correct.

I use Sage 8.3 (Release Date: 2018-08-03), installed from the official repository of Archlinux. The bug is present both in command line and with sage file.sage (if I copy and paste the code above).

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
2

answered 2018-10-07 19:09:26 +0200

arojas gravatar image

Hi, This should be fixed now with pynac 0.7.22-5

edit flag offensive delete link more

Comments

Thanks for the clarification !

tmonteil gravatar imagetmonteil ( 2018-10-08 00:24:06 +0200 )edit
1

answered 2018-10-06 12:57:52 +0200

tmonteil gravatar image

updated 2018-10-07 16:37:04 +0200

It works for me (Sage 8.4.beta7 complied on Debian stretch 64bit, run from the command line).

Could you please give us some informations so that someone can try to reproduce your problem:

  • which version of Sage did you use ?
  • which OS ?
  • did you install Sage from the binaries, and which ones ?
  • did you compile Sage yourself ?
  • which notebook did you use (Sage notebook or jupyter notebook) ?
  • did you use the command line ?
  • which commands did you type precisely to get the error ?
  • which error message did you get ?
  • ... ?

EDIT thanks for reporting, it seems to be an issue with Archlinux port, since it works well on Sage Cell which also ships 8.3:

http://sagecell.sagemath.org/?z=eJxlz...

Second EDIT: this is now trac ticket 26427, i will contact Archlinux devs about that issue.

edit flag offensive delete link more

Comments

I added information in the original post. I tried to install the 8.4 beta7 version but it failed.

ScreenName gravatar imageScreenName ( 2018-10-07 07:03:05 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2018-10-06 08:04:49 +0200

Seen: 487 times

Last updated: Oct 07 '18