#18787: Bug with matrice products over Symbolic Ring with modular integers
-----------------------------+------------------------
       Reporter:  tmonteil   |        Owner:
           Type:  defect     |       Status:  new
       Priority:  major      |    Milestone:  sage-6.8
      Component:  symbolics  |   Resolution:
       Keywords:             |    Merged in:
        Authors:             |    Reviewers:
Report Upstream:  N/A        |  Work issues:
         Branch:             |       Commit:
   Dependencies:             |     Stopgaps:
-----------------------------+------------------------
Description changed by jdemeyer:

Old description:

> As reported on [http://ask.sagemath.org/question/27196/multiplying-
> matrices-with-different-parents/ this ask question]
>
> {{{
> sage: _ =var('A,B,C,D')
> sage: S = matrix([[1+3*A,3*B],[3*C,1+3*D]])
> sage: R = Zmod(9)
> sage: g = matrix(R,2,[[2,1],[2,6]])
> sage: gi = matrix(R,2,[[6,8],[7,2]])
> sage: g*S*gi
> [        6*B + 3*D + 1 3*A + 3*B + 6*C + 6*D]
> [            0*A + 0*D         3*A + 0*D + 1]
> }}}
>
> While we have (look at the second line):
>
> {{{
> sage: P.<A,B,C,D> = ZZ[]
> sage: S = matrix([[1+3*A,3*B],[3*C,1+3*D]])
> sage: R = Zmod(9)
> sage: g = matrix(R,2,[[2,1],[2,6]])
> sage: gi = matrix(R,2,[[6,8],[7,2]])
> sage: g*S*gi
> [        6*B + 3*D + 1 3*A + 3*B + 6*C + 6*D]
> [                  6*B         3*A + 3*B + 1]
> }}}

New description:

 As reported on [http://ask.sagemath.org/question/27196/multiplying-
 matrices-with-different-parents/ this ask question]

 {{{
 sage: _ = var('A,B,C,D')
 sage: (B + 3*D)*Zmod(9)(6)
 0*D
 }}}

--

--
Ticket URL: <http://trac.sagemath.org/ticket/18787#comment:2>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to