On Tue, Oct 8, 2019, 8:18 PM Robert Samal <robert.sa...@gmail.com> wrote:

> I am trying to solve a rather large linear systems of equations of GF(3).
> As the matrices are sparse, I thought that adding "sparse=True" to the
> constructor of the matrix could be of help. However, I ran to a strange
> error message.
>
> B=matrix(GF(3), 2,2,[1,0,1,0], sparse=True)
> v=vector(F, [1,1])
> B.solve_right(v)
>
> The above code yields the following
>

What is F (in the line defining v)?


TypeError: Cannot convert
sage.matrix.matrix_modn_sparse.Matrix_modn_sparse to
sage.matrix.matrix_integer_sparse.Matrix_integer_sparse
>
>
> I am hesitant to paste the whole error message here, but it ends with 
> reference to file
> SageMath/local/lib/python2.7/site-packages/sage/matrix/matrix_modn_sparse.pyx 
> in
> sage.matrix.matrix_modn_sparse.Matrix_modn_sparse._solve_matrix_linbox
> (build/cythonized/sage/matrix/matrix_modn_sparse.cpp:11633).
>
> I am using Sage 8.9, but the same issue was on 8.7 as well.
>
> Few other observations:
> -- works as expected for dense matrices -- or for sparse ones over integers
> -- the same issue occurs whether y is a vector or a matrix
>
>
-- It behaves the same for systems with no solution.
>
> Is there some hidden limitation of sparse matrices over finite fields?
> I.e., is it a bug or feature? :-)
> I tried to RTFM, but couldn't find this discussed. The page for sparse 
> matrices over
> finite fields does not exactly promise the solve method, but it does not 
> mention it
> would not work either. Is it possible to achieve what I want by other means 
> (in Sage).
>
> Thanks.
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "sage-support" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to sage-support+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/sage-support/e8912161-212e-4e6f-aa69-a7461b2f6c09%40googlegroups.com
> <https://groups.google.com/d/msgid/sage-support/e8912161-212e-4e6f-aa69-a7461b2f6c09%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sage-support/CAEQuuAXABMowo8zgScxcOrRpZK-7PDasoJjeEVyT_WQkFaxXxg%40mail.gmail.com.

Reply via email to