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

Braid group creates elements in wrong class #16458

Closed
miguelmarco opened this issue Jun 8, 2014 · 17 comments
Closed

Braid group creates elements in wrong class #16458

miguelmarco opened this issue Jun 8, 2014 · 17 comments

Comments

@miguelmarco
Copy link
Contributor

Right now we have this inconsistency.

sage: B=BraidGroup(4)
sage: b=B([1,2,3])
sage: type(b)
<class 'sage.groups.braid.Braid'>
sage: type(b*b)
<class 'sage.groups.braid.BraidGroup_class_with_category.element_class'>

Both should be in the same class.

CC: @vbraun

Component: group theory

Keywords: braid

Author: Miguel Marco

Branch/Commit: 446e41d

Reviewer: Vincent Delecroix

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

@miguelmarco miguelmarco added this to the sage-6.3 milestone Jun 8, 2014
@miguelmarco
Copy link
Contributor Author

Branch: u/mmarco/ticket/16458

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

Commit: 4e332f3

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

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

4e332f3Changed `_element_constructor_` on Braid groups

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

comment:3

Hello Miguel,

The TestSuite is here to detect this kind of things...

sage: B = BraidGroup(3)
sage: TestSuite(B).run()

The tests are run on elements that are obtained from the method an_element or some_elements. Right now it uses a generic method which does not rely on _element_constructor_. But as you can see (with the old version)

sage: TestSuite(B([1,2])).run()
Traceback (most recent call last):
...
The following tests failed: _test_category

Please, implement in BraidGroup_class:

  • a method an_element that return a braid
  • a method some_elements that return some braids (built in different ways)
    And then put the TestSuite test in the __init__.

Vincent

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

Changed commit from 4e332f3 to e77666a

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

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

e77666aAdded an_element, some_elements and a TestSuite doctest to braid groups

@miguelmarco
Copy link
Contributor Author

comment:5

Thanks, Vincent, done.

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

comment:7

Great. Just a little typo: you wrote EXAMMPLES instead of EXAMPLES.

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

Changed commit from e77666a to 446e41d

@sagetrac-git
Copy link
Mannequin

sagetrac-git mannequin commented Jun 8, 2014

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

446e41dCorrected typo

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

comment:9

Thanks

Vincent

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

Reviewer: Vincent Delecroix

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

Author: ​Miguel Marco

@videlec
Copy link
Contributor

videlec commented Jun 8, 2014

Changed keywords from none to braid

@vbraun
Copy link
Member

vbraun commented Jun 8, 2014

Changed author from ​Miguel Marco to Miguel Marco

@vbraun
Copy link
Member

vbraun commented Jun 8, 2014

comment:11

Invisible space deleted...

@vbraun
Copy link
Member

vbraun commented Jun 14, 2014

Changed branch from u/mmarco/ticket/16458 to 446e41d

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

3 participants