Opened 8 years ago
Closed 8 years ago
#17859 closed defect (fixed)
Use coercion instead of pushout in matrix actions
Reported by:  Vincent Delecroix  Owned by:  

Priority:  major  Milestone:  sage6.6 
Component:  coercion  Keywords:  
Cc:  Merged in:  
Authors:  Jeroen Demeyer  Reviewers:  Travis Scrimshaw 
Report Upstream:  N/A  Work issues:  
Branch:  9da3db6 (Commits, GitHub, GitLab)  Commit:  9da3db64750114e4c230a83e96e2ab6544c3e104 
Dependencies:  Stopgaps: 
Description (last modified by )
There is no coercion between QQ and finite rings
sage: cm = get_coercion_model() sage: cm.get_action(Zmod(2), QQ, operator.mul) is None True
This is right.
But we do have an action of matrices on vectors
sage: M = MatrixSpace(Zmod(2),2) sage: V = VectorSpace(QQ,2) sage: cm.get_action(M,V,operator.mul) Left action by Full MatrixSpace of 2 by 2 dense matrices over Ring of integers modulo 2 on Vector space of dimension 2 over Rational Field
or
sage: M = MatrixSpace(QQ,2) sage: V = VectorSpace(Zmod(2),2) sage: cm.get_action(M,V,operator.mul) Left action by Full MatrixSpace of 2 by 2 dense matrices over Rational Field on Vector space of dimension 2 over Ring of integers modulo 2
And this is wrong!
see also: #12865
Change History (9)
comment:1 Changed 8 years ago by
Description:  modified (diff) 

comment:2 Changed 8 years ago by
Summary:  Wrong coercion between QQ and finite rings → Remove action of Z/nZ matrices on QQ vectors 

comment:3 Changed 8 years ago by
Summary:  Remove action of Z/nZ matrices on QQ vectors → Use coercion instead of pushout in matrix actions 

comment:4 Changed 8 years ago by
Authors:  → Jeroen Demeyer 

comment:5 Changed 8 years ago by
Branch:  → u/jdemeyer/use_coercion_instead_of_pushout_in_matrix_actions 

Commit:  → 437c4e8e481084a2b6414ce2878e2ae12cb98160 
Status:  new → needs_review 
comment:6 Changed 8 years ago by
Reviewers:  → Travis Scrimshaw 

LGTM, but could you add a linebreak to the doctest you added? Thanks.
comment:7 Changed 8 years ago by
Commit:  437c4e8e481084a2b6414ce2878e2ae12cb98160 → 9da3db64750114e4c230a83e96e2ab6544c3e104 

Branch pushed to git repo; I updated commit sha1. New commits:
9da3db6  Add line breaks in long doctest

comment:8 Changed 8 years ago by
Status:  needs_review → positive_review 

comment:9 Changed 8 years ago by
Branch:  u/jdemeyer/use_coercion_instead_of_pushout_in_matrix_actions → 9da3db64750114e4c230a83e96e2ab6544c3e104 

Resolution:  → fixed 
Status:  positive_review → closed 
Note: See
TracTickets for help on using
tickets.
New commits:
Use coercion instead of pushout for matrix actions