Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use coercion instead of pushout in matrix actions #17859

Closed
videlec opened this issue Feb 26, 2015 · 10 comments
Closed

Use coercion instead of pushout in matrix actions #17859

videlec opened this issue Feb 26, 2015 · 10 comments

Comments

@videlec
Copy link
Contributor

videlec commented Feb 26, 2015

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

Component: coercion

Author: Jeroen Demeyer

Branch/Commit: 9da3db6

Reviewer: Travis Scrimshaw

Issue created by migration from https://trac.sagemath.org/ticket/17859

@videlec videlec added this to the sage-6.6 milestone Feb 26, 2015
@videlec

This comment has been minimized.

@jdemeyer jdemeyer changed the title Wrong coercion between QQ and finite rings Remove action of Z/nZ matrices on QQ vectors Mar 2, 2015
@jdemeyer jdemeyer changed the title Remove action of Z/nZ matrices on QQ vectors Use coercion instead of pushout in matrix actions Mar 2, 2015
@jdemeyer
Copy link

jdemeyer commented Mar 2, 2015

Author: Jeroen Demeyer

@jdemeyer
Copy link

jdemeyer commented Mar 2, 2015

@jdemeyer
Copy link

jdemeyer commented Mar 2, 2015

Commit: 437c4e8

@jdemeyer
Copy link

jdemeyer commented Mar 2, 2015

New commits:

437c4e8Use coercion instead of pushout for matrix actions

@tscrim
Copy link
Collaborator

tscrim commented Mar 2, 2015

Reviewer: Travis Scrimshaw

@tscrim
Copy link
Collaborator

tscrim commented Mar 2, 2015

comment:6

LGTM, but could you add a linebreak to the doctest you added? Thanks.

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Mar 2, 2015

Changed commit from 437c4e8 to 9da3db6

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Mar 2, 2015

Branch pushed to git repo; I updated commit sha1. New commits:

9da3db6Add line breaks in long doctest

@vbraun
Copy link
Member

vbraun commented Mar 3, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants