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

Fix surjectivity testing for free module morphisms #11552

Closed
rbeezer mannequin opened this issue Jun 28, 2011 · 10 comments
Closed

Fix surjectivity testing for free module morphisms #11552

rbeezer mannequin opened this issue Jun 28, 2011 · 10 comments

Comments

@rbeezer
Copy link
Mannequin

rbeezer mannequin commented Jun 28, 2011

Testing for surjectivity of a free module homorphism is probably just fine for vector spaces, but seems to be broken for modules.

sage: V = ZZ^2
sage: m = matrix(ZZ, [[1,2],[0,2]])
sage: phi = V.hom(m, V)
sage: phi.lift(vector(ZZ, [0, 1]))
---------------------------------------------------------------------------
ValueError                                Traceback (most recent call last)

/sage/dev/devel/sage-main/<ipython console> in <module>()

/sage/dev/local/lib/python2.6/site-packages/sage/modules/free_module_morphism.pyc in lift(self, x)
    375             t = self.domain().linear_combination_of_basis(C)
    376         except TypeError:
--> 377             raise ValueError, "element is not in the image"
    378         assert self(t) == x
    379         return t

ValueError: element is not in the image
sage: phi.is_surjective()
True

Apply:

  1. attachment: trac_11552-module-morphism-surjectivity-v2.patch

CC: @simon-king-jena @robertwb @miguelmarco

Component: linear algebra

Author: Rob Beezer

Reviewer: John Palmieri

Merged: sage-4.7.2.alpha2

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

@rbeezer rbeezer mannequin added this to the sage-4.7.2 milestone Jun 28, 2011
@rbeezer rbeezer mannequin assigned jasongrout and williamstein Jun 28, 2011
@rbeezer
Copy link
Mannequin Author

rbeezer mannequin commented Jun 28, 2011

Author: Rob Beezer

@rbeezer

This comment has been minimized.

@rbeezer rbeezer mannequin added the s: needs review label Jun 28, 2011
@rbeezer

This comment has been minimized.

@rbeezer
Copy link
Mannequin Author

rbeezer mannequin commented Jun 29, 2011

comment:3

Passes all long tests for me on 4.7.1.alpha3 and patchbot is green-lighting it at the moment.

@rbeezer
Copy link
Mannequin Author

rbeezer mannequin commented Jul 6, 2011

comment:4

Attachment: trac_11552-module-morphism-surjectivity-v2.patch.gz

Version 2 patch tests if a morphism is surjective with the .is_submodule() method. Slower, I guess, but a greater chance of being correct. An example from mmarco has been added to illustrate the non-unique echelon basis for the image. The necessity of these changes is detailed on #11579 (and perhaps, see #11553).

@rbeezer

This comment has been minimized.

@jhpalmieri
Copy link
Member

comment:5

Looks good to me.

@jhpalmieri
Copy link
Member

Reviewer: John Palmieri

@rbeezer
Copy link
Mannequin Author

rbeezer mannequin commented Jul 18, 2011

comment:6

Replying to @jhpalmieri:

Looks good to me.

Thanks, John - appreciate you taking the time to look at this. - Rob

@jdemeyer
Copy link

Merged: sage-4.7.2.alpha2

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