On 2013-03-20, John Cremona <john.crem...@gmail.com> wrote: > In Sage-5.8, we have a matrix M of rationals: > > type(M) ><type 'sage.matrix.matrix_rational_dense.Matrix_rational_dense'> > > M.parent() > Full MatrixSpace of 138 by 179 dense matrices over Rational Field > > but none of M.rank(), M.kernel() or even plain M work, all give the > error message > > IndexError: string index out of range
does this work in terminal? (for it looks like it's nb-related...) > > > The traceback is below. I have no idea why strongs or files are > involved at all. Any ideas? > > verbose 1 (1: , <module>) computing left kernel for 138x179 matrix > verbose 1 (1: , <module>) computing a right kernel for 179x138 matrix > over Rational Field > verbose 1 (1: , <module>) computing right kernel matrix over the > rationals for 179x138 matrix > verbose 1 (1: , <module>) computing null space of 179 x 138 matrix using IML > verbose 1 (1: , <module>) finished computing null space (time = 0.284018) > verbose 1 (1: , <module>) done computing right kernel matrix over the > rationals for 179x138 matrix (time = 0.292018) > verbose 1 (1: , <module>) rational in-place Gauss elimination on 1 x 138 > matrix > verbose 1 (1: , <module>) done with gauss echelon form (time = 0.008) > verbose 1 (1: , <module>) done computing a right kernel for 179x138 > matrix over Rational Field (time = 0.304018) > verbose 1 (1: , <module>) done computing left kernel for 138x179 > matrix (time = 0.32402) > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > File "_sage_input_52.py", line 10, in <module> > exec compile(u'open("___code___.py","w").write("# -*- coding: > utf-8 -*-\\n" + > _support_.preparse_worksheet_cell(base64.b64decode("TS5rZXJuZWwoKQ=="),globals())+"\\n"); > execfile(os.path.abspath("___code___.py")) > File "", line 1, in <module> > > File "/tmp/tmpjcmygY/___code___.py", line 2, in <module> > exec compile(u'M.kernel() > File "", line 1, in <module> > > File "sage_object.pyx", line 154, in > sage.structure.sage_object.SageObject.__repr__ > (sage/structure/sage_object.c:1769) > File > "/usr/local/sage/sage-5.7/local/lib/python2.7/site-packages/sage/modules/free_module.py", > line 6367, in _repr_ > "Basis matrix:\n%s"%self.basis_matrix() > File "matrix0.pyx", line 1718, in > sage.matrix.matrix0.Matrix.__repr__ (sage/matrix/matrix0.c:9229) > File > "/usr/local/sage/sage-5.7/local/lib/python2.7/site-packages/sage/misc/sageinspect.py", > line 1917, in sage_getvariablename > for frame in inspect.stack(): > File "/usr/local/sage/sage-5.7/local/lib/python/inspect.py", line > 1054, in stack > return getouterframes(sys._getframe(1), context) > File "/usr/local/sage/sage-5.7/local/lib/python/inspect.py", line > 1032, in getouterframes > framelist.append((frame,) + getframeinfo(frame, context)) > File "/usr/local/sage/sage-5.7/local/lib/python/inspect.py", line > 1007, in getframeinfo > lines, lnum = findsource(frame) > File "/usr/local/sage/sage-5.7/local/lib/python/inspect.py", line > 528, in findsource > if not sourcefile and file[0] + file[-1] != '<>': > IndexError: string index out of range > -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at http://groups.google.com/group/sage-devel?hl=en. For more options, visit https://groups.google.com/groups/opt_out.