#17030: Knot Theory as a part of GSoC 2014.
-------------------------------------+-------------------------------------
       Reporter:  amitjamadagni      |        Owner:  amitjamadagni
           Type:  enhancement        |       Status:  needs_work
       Priority:  major              |    Milestone:  sage-6.9
      Component:  algebraic          |   Resolution:
  topology                           |    Merged in:
       Keywords:                     |    Reviewers:  Miguel Marco, Karl-
        Authors:  Amit Jamadagni,    |  Dieter Crisman, Frédéric Chapoton
  Miguel Marco                       |  Work issues:
Report Upstream:  N/A                |       Commit:
         Branch:                     |  06aad784cdd03604d77f9f9c7e6c9332a4982fc6
  public/ticket/17030                |     Stopgaps:
   Dependencies:                     |
-------------------------------------+-------------------------------------

Comment (by mmarco):

 I get tthe following errors:

 {{{

 Running doctests with ID 2015-08-10-14-07-03-076dea73.
 Git branch: ticket/17030
 Using --optional=gdb,mpir,python2,sage,scons,tides
 Doctesting 1 file.
 sage -t --warn-long 59.0 src/sage/knots/link.py
 **********************************************************************
 File "src/sage/knots/link.py", line 1309, in
 sage.knots.link.Link.jones_polynomial
 Failed example:
     L.jones_polynomial()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link.jones_polynomial[1]>", line 1,
 in <module>
         L.jones_polynomial()
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/knots/link.py", line 1323, in jones_polynomial
         poly = self._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 File "src/sage/knots/link.py", line 1312, in
 sage.knots.link.Link.jones_polynomial
 Failed example:
     L.jones_polynomial()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link.jones_polynomial[3]>", line 1,
 in <module>
         L.jones_polynomial()
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/knots/link.py", line 1323, in jones_polynomial
         poly = self._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 File "src/sage/knots/link.py", line 1316, in
 sage.knots.link.Link.jones_polynomial
 Failed example:
     L.jones_polynomial()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link.jones_polynomial[6]>", line 1,
 in <module>
         L.jones_polynomial()
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/knots/link.py", line 1323, in jones_polynomial
         poly = self._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 File "src/sage/knots/link.py", line 1320, in
 sage.knots.link.Link.jones_polynomial
 Failed example:
     L.jones_polynomial()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link.jones_polynomial[9]>", line 1,
 in <module>
         L.jones_polynomial()
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/knots/link.py", line 1323, in jones_polynomial
         poly = self._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 File "src/sage/knots/link.py", line 1342, in
 sage.knots.link.Link._bracket_
 Failed example:
     L._bracket_()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link._bracket_[1]>", line 1, in
 <module>
         L._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 File "src/sage/knots/link.py", line 1345, in
 sage.knots.link.Link._bracket_
 Failed example:
     L._bracket_()
 Exception raised:
     Traceback (most recent call last):
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 496, in _run
         self.compile_and_execute(example, compiler, test.globs)
       File "/home/mmarco/sage/local/lib/python2.7/site-
 packages/sage/doctest/forker.py", line 858, in compile_and_execute
         exec(compiled, globs)
       File "<doctest sage.knots.link.Link._bracket_[3]>", line 1, in
 <module>
         L._bracket_()
       File "sage/misc/cachefunc.pyx", line 1888, in
 sage.misc.cachefunc.CachedMethodCaller.__call__
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:11438)
         w = self._cachedmethod._instance_call(self._instance, *args,
 **kwds)
       File "sage/misc/cachefunc.pyx", line 2544, in
 sage.misc.cachefunc.CachedMethod._instance_call
 (/home/mmarco/sage/src/build/cythonized/sage/misc/cachefunc.c:14884)
         return self._cachedfunc.f(inst, *args, **kwds)
     TypeError: _bracket_() takes exactly 2 arguments (1 given)
 **********************************************************************
 2 items had failures:
    2 of   5 in sage.knots.link.Link._bracket_
    4 of  11 in sage.knots.link.Link.jones_polynomial
     [221 tests, 6 failures, 1.63 s]
 ----------------------------------------------------------------------
 sage -t --warn-long 59.0 src/sage/knots/link.py  # 6 doctests failed
 ----------------------------------------------------------------------
 Total time for all tests: 1.7 seconds
     cpu time: 1.6 seconds
     cumulative wall time: 1.6 seconds
 }}}

 Also, doctest coverage is not complete:

 {{{
 mmarco@mountain ~/sage $ ./sage -coverage src/sage/knots/link.py
 ------------------------------------------------------------------------
 SCORE src/sage/knots/link.py: 93.1% (27 of 29)

 Missing doctests:
      * line 219: def __eq__(self, other)
      * line 233: def __ne__(self, other)
 }}}

 About the splitting of the classes, i think that what should be exposed to
 the user, is a  function that creates a Link or a Knot deppending of the
 input. That is: if the user wants to create a Link that happens to be a
 knot, why shouldn't it have a `arf_invariant`method?

--
Ticket URL: <http://trac.sagemath.org/ticket/17030#comment:127>
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