Ticket #12415: 12415_doctest_review.patch

File 12415_doctest_review.patch, 24.1 KB (added by jdemeyer, 7 years ago)
  • doc/en/tutorial/interfaces.rst

    # HG changeset patch
    # User Jeroen Demeyer <jdemeyer@cage.ugent.be>
    # Date 1360957832 -3600
    # Node ID e93a74429ba284fd1a8de375d12fd5b4914b8124
    # Parent  5173e5d858897ac023e1fca0f8c8dcaec7fe1147
    Further fixes for the new doctesting framework
    
    diff --git a/doc/en/tutorial/interfaces.rst b/doc/en/tutorial/interfaces.rst
    a b  
    304304Finally, we give an example of using Sage to plot using ``openmath``.
    305305Many of these were modified from the Maxima reference manual.
    306306
    307 A 2D plot of several functions (do not type the ``...``):
     307A 2D plot of several functions (do not type the ``...``)::
    308308
    309 ::
    310 
    311     sage: maxima.plot2d('[cos(7*x),cos(23*x)^4,sin(13*x)^3]','[x,0,1]',\
    312     ...   '[plot_format,openmath]') # not tested
     309    sage: maxima.plot2d('[cos(7*x),cos(23*x)^4,sin(13*x)^3]','[x,0,1]',  # not tested
     310    ....:     '[plot_format,openmath]')
    313311
    314312A "live" 3D plot which you can move with your mouse (do not type
    315 the ``...``):
     313the ``...``)::
    316314
    317 ::
     315    sage: maxima.plot3d ("2^(-u^2 + v^2)", "[u, -3, 3]", "[v, -2, 2]",  # not tested
     316    ....:     '[plot_format, openmath]')
     317    sage: maxima.plot3d("atan(-x^2 + y^3/4)", "[x, -4, 4]", "[y, -4, 4]",  # not tested
     318    ....:     "[grid, 50, 50]",'[plot_format, openmath]')
    318319
    319     sage: maxima.plot3d ("2^(-u^2 + v^2)", "[u, -3, 3]", "[v, -2, 2]",\
    320     ...   '[plot_format, openmath]') # not tested
    321     sage: maxima.plot3d("atan(-x^2 + y^3/4)", "[x, -4, 4]", "[y, -4, 4]",\
    322     ...   "[grid, 50, 50]",'[plot_format, openmath]') # not tested
     320The next plot is the famous Möbius strip (do not type the ``...``)::
    323321
    324 The next plot is the famous Möbius strip (do not type the ``...``):
     322    sage: maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)), y*sin(x/2)]",  # not tested
     323    ....:     "[x, -4, 4]", "[y, -4, 4]", '[plot_format, openmath]')
    325324
    326 ::
     325The next plot is the famous Klein bottle (do not type the ``...``)::
    327326
    328     sage: maxima.plot3d("[cos(x)*(3 + y*cos(x/2)), sin(x)*(3 + y*cos(x/2)),\
    329     ...   y*sin(x/2)]", "[x, -4, 4]", "[y, -4, 4]",\
    330     ...   '[plot_format, openmath]') # not tested
    331 
    332 The next plot is the famous Klein bottle (do not type the ``...``):
    333 
    334 ::
    335 
    336     sage: maxima("expr_1: 5*cos(x)*(cos(x/2)*cos(y) + sin(x/2)*sin(2*y)+ 3.0)\
    337     ...   - 10.0")
     327    sage: maxima("expr_1: 5*cos(x)*(cos(x/2)*cos(y) + sin(x/2)*sin(2*y)+ 3.0) - 10.0")
    338328    5*cos(x)*(sin(x/2)*sin(2*y)+cos(x/2)*cos(y)+3.0)-10.0
    339329    sage: maxima("expr_2: -5*sin(x)*(cos(x/2)*cos(y) + sin(x/2)*sin(2*y)+ 3.0)")
    340330    -5*sin(x)*(sin(x/2)*sin(2*y)+cos(x/2)*cos(y)+3.0)
    341331    sage: maxima("expr_3: 5*(-sin(x/2)*cos(y) + cos(x/2)*sin(2*y))")
    342332    5*(cos(x/2)*sin(2*y)-sin(x/2)*cos(y))
    343     sage: maxima.plot3d ("[expr_1, expr_2, expr_3]", "[x, -%pi, %pi]",\
    344     ...   "[y, -%pi, %pi]", "['grid, 40, 40]",\
    345     ...   '[plot_format, openmath]') # not tested
     333    sage: maxima.plot3d ("[expr_1, expr_2, expr_3]", "[x, -%pi, %pi]",  # not tested
     334    ....:     "[y, -%pi, %pi]", "['grid, 40, 40]", '[plot_format, openmath]')
  • sage/calculus/test_sympy.py

    diff --git a/sage/calculus/test_sympy.py b/sage/calculus/test_sympy.py
    a b  
    112112    sage: f = e.series(x, 0, 10); f
    113113    1 + 3*x**2/2 + 11*x**4/8 + 241*x**6/240 + 8651*x**8/13440 + O(x**10)
    114114
    115 And the pretty-printer::
     115And the pretty-printer.  Since unicode characters aren't working on
     116some archictures, we disable it::
    116117
     118    sage: from sympy.printing import pprint_use_unicode
     119    sage: prev_use = pprint_use_unicode(False)
    117120    sage: pprint(e)
    118        1   
    119     ───────
    120        3   
     121       1
     122    -------
     123       3
    121124    cos (x)
    122125
    123126    sage: pprint(f)
    124            2       4        6         8           
    125         3⋅x    11⋅x    241⋅x    8651⋅x           
    126     1 + ──── + ───── + ────── + ─────── + O(x**10)
    127          2       8      240      13440           
     127           2       4        6         8
     128        3*x    11*x    241*x    8651*x
     129    1 + ---- + ----- + ------ + ------- + O(x**10)
     130         2       8      240      13440
     131    sage: pprint_use_unicode(prev_use)
     132    False
    128133
    129134And the functionality to convert from sympy format to Sage format::
    130135
  • sage/categories/groups.py

    diff --git a/sage/categories/groups.py b/sage/categories/groups.py
    a b  
    5050            sage: Groups().example()
    5151            General Linear Group of degree 4 over Rational Field
    5252        """
    53         from sage.rings.rational_field import QQ 
     53        from sage.rings.rational_field import QQ
    5454        from sage.groups.matrix_gps.general_linear import GL
    5555        return GL(4,QQ)
    5656
  • sage/combinat/partition_algebra.py

    diff --git a/sage/combinat/partition_algebra.py b/sage/combinat/partition_algebra.py
    a b  
    757757        132
    758758
    759759        sage: P3.first() #random
    760         {{1, 2, 3, -1, -3, -2}} 
     760        {{1, 2, 3, -1, -3, -2}}
    761761        sage: P3.last() #random
    762762        {{-1}, {-2}, {3}, {1}, {-3}, {2}}
    763763        sage: P3.random_element() #random
  • sage/interfaces/tachyon.py

    diff --git a/sage/interfaces/tachyon.py b/sage/interfaces/tachyon.py
    a b  
    66- John E. Stone
    77"""
    88
     9#*****************************************************************************
     10#       Copyright (C) 2006 John E. Stone
     11#
     12#  Distributed under the terms of the GNU General Public License (GPL)
     13#  as published by the Free Software Foundation; either version 2 of
     14#  the License, or (at your option) any later version.
     15#                  http://www.gnu.org/licenses/
     16#*****************************************************************************
    917
    1018from sage.misc.pager import pager
    1119from sage.misc.misc import tmp_filename
    1220from sage.misc.sagedoc import format
    1321import os
     22import sys
    1423
    1524class TachyonRT:
    1625    """
     
    98107            sage: import os
    99108            sage: t(tgen.str(), outfile = os.devnull)
    100109            tachyon ...
     110            Tachyon Parallel/Multiprocessor Ray Tracer...
    101111        """
    102112        modelfile = tmp_filename(ext='.dat')
    103113        open(modelfile,'w').write(model)
     
    130140
    131141        if verbose:
    132142            print cmd
     143        # One should always flush before system()
     144        sys.stdout.flush()
     145        sys.stderr.flush()
    133146        os.system(cmd)
    134147
    135148    def usage(self, use_pager=True):
  • sage/libs/lcalc/lcalc_Lfunction.pyx

    diff --git a/sage/libs/lcalc/lcalc_Lfunction.pyx b/sage/libs/lcalc/lcalc_Lfunction.pyx
    a b  
    404404            sage: L._print_data_to_standard_output() # tol 1e-15
    405405            -----------------------------------------------
    406406            <BLANKLINE>
    407             Name of L_function: 
     407            Name of L_function:
    408408            number of dirichlet coefficients = 5
    409409            coefficients are periodic
    410410            b[1] = 1
     
    532532            sage: L._print_data_to_standard_output() # tol 1e-15
    533533            -----------------------------------------------
    534534            <BLANKLINE>
    535             Name of L_function: 
     535            Name of L_function:
    536536            number of dirichlet coefficients = 5
    537537            coefficients are periodic
    538538            b[1] = 1
     
    666666            sage: L._print_data_to_standard_output() # tol 1e-15
    667667            -----------------------------------------------
    668668            <BLANKLINE>
    669             Name of L_function: 
     669            Name of L_function:
    670670            number of dirichlet coefficients = 5
    671671            coefficients are periodic
    672672            b[1] = (1,0)
  • sage/libs/mwrank/interface.py

    diff --git a/sage/libs/mwrank/interface.py b/sage/libs/mwrank/interface.py
    a b  
    218218            Looking for quartics with I = 48, J = -432
    219219            Looking for Type 2 quartics:
    220220            Trying positive a from 1 up to 1 (square a first...)
    221             (1,0,-6,4,1)        --trivial
     221            (1,0,-6,4,1)        --trivial
    222222            Trying positive a from 1 up to 1 (...then non-square a)
    223223            Finished looking for Type 2 quartics.
    224224            Looking for Type 1 quartics:
    225225            Trying positive a from 1 up to 2 (square a first...)
    226             (1,0,0,4,4) --nontrivial...(x:y:z) = (1 : 1 : 0)
     226            (1,0,0,4,4) --nontrivial...(x:y:z) = (1 : 1 : 0)
    227227            Point = [0:0:1]
    228             height = 0.051111408239968840235886099756942021609538202280854
     228                height = 0.0511114082399688402358
    229229            Rank of B=im(eps) increases to 1 (The previous point is on the egg)
    230230            Exiting search for Type 1 quartics after finding one which is globally soluble.
    231231            Mordell rank contribution from B=im(eps) = 1
     
    235235            Selmer  rank contribution from A=ker(eps) = 0
    236236            Sha     rank contribution from A=ker(eps) = 0
    237237            Searching for points (bound = 8)...done:
    238             found points of rank 1
    239             and regulator 0.051111408239968840235886099756942021609538202280854
     238              found points which generate a subgroup of rank 1
     239              and regulator 0.0511114082399688402358
    240240            Processing points found during 2-descent...done:
    241             now regulator = 0.051111408239968840235886099756942021609538202280854
    242             Saturating (bound = -1)...done:
    243             points were already saturated.
     241              now regulator = 0.0511114082399688402358
     242            Saturating (with bound = -1)...done:
     243              points were already saturated.
    244244        """
    245245        self.__verbose = verbose
    246246
     
    999999            375.42919921875
    10001000            sage: EQ.saturate(2)  # points were not 2-saturated
    10011001            saturating basis...Saturation index bound = 93
    1002             WARNING: saturation at primes p > 2 will not be done; 
     1002            WARNING: saturation at primes p > 2 will not be done;
    10031003            ...
    10041004            Gained index 2
    10051005            New regulator =  93.857300720636393209
     
    10101010            93.8572998046875
    10111011            sage: EQ.saturate(3)  # points were not 3-saturated
    10121012            saturating basis...Saturation index bound = 46
    1013             WARNING: saturation at primes p > 3 will not be done; 
     1013            WARNING: saturation at primes p > 3 will not be done;
    10141014            ...
    10151015            Gained index 3
    10161016            New regulator =  10.4285889689595992455
     
    10211021            10.4285888671875
    10221022            sage: EQ.saturate(5)  # points were not 5-saturated
    10231023            saturating basis...Saturation index bound = 15
    1024             WARNING: saturation at primes p > 5 will not be done; 
     1024            WARNING: saturation at primes p > 5 will not be done;
    10251025            ...
    10261026            Gained index 5
    10271027            New regulator =  0.417143558758383969818
     
    10331033            sage: EQ.saturate()   # points are now saturated
    10341034            saturating basis...Saturation index bound = 3
    10351035            Checking saturation at [ 2 3 ]
    1036             Checking 2-saturation 
     1036            Checking 2-saturation
    10371037            Points were proved 2-saturated (max q used = 11)
    1038             Checking 3-saturation 
     1038            Checking 3-saturation
    10391039            Points were proved 3-saturated (max q used = 13)
    10401040            done
    10411041            (True, 1, '[ ]')
     
    12061206
    12071207            sage: EQ.saturate(2)  # points were not 2-saturated
    12081208            saturating basis...Saturation index bound = 93
    1209             WARNING: saturation at primes p > 2 will not be done; 
     1209            WARNING: saturation at primes p > 2 will not be done;
    12101210            ...
    12111211            Gained index 2
    12121212            New regulator =  93.857300720636393209
     
    12201220
    12211221            sage: EQ.saturate(3)  # points were not 3-saturated
    12221222            saturating basis...Saturation index bound = 46
    1223             WARNING: saturation at primes p > 3 will not be done; 
     1223            WARNING: saturation at primes p > 3 will not be done;
    12241224            ...
    12251225            Gained index 3
    12261226            New regulator =  10.4285889689595992455
     
    12341234
    12351235            sage: EQ.saturate(5)  # points were not 5-saturated
    12361236            saturating basis...Saturation index bound = 15
    1237             WARNING: saturation at primes p > 5 will not be done; 
     1237            WARNING: saturation at primes p > 5 will not be done;
    12381238            ...
    12391239            Gained index 5
    12401240            New regulator =  0.417143558758383969818
     
    12501250            sage: EQ.saturate()   # points are now saturated
    12511251            saturating basis...Saturation index bound = 3
    12521252            Checking saturation at [ 2 3 ]
    1253             Checking 2-saturation 
     1253            Checking 2-saturation
    12541254            Points were proved 2-saturated (max q used = 11)
    1255             Checking 3-saturation 
     1255            Checking 3-saturation
    12561256            Points were proved 3-saturated (max q used = 13)
    12571257            done
    12581258            (True, 1, '[ ]')
     
    12771277            sage: EQ.saturate()
    12781278            saturating basis...Saturation index bound = 3
    12791279            Checking saturation at [ 2 3 ]
    1280             Checking 2-saturation 
     1280            Checking 2-saturation
    12811281            Points were proved 2-saturated (max q used = 11)
    1282             Checking 3-saturation 
     1282            Checking 3-saturation
    12831283            Points were proved 3-saturated (max q used = 13)
    12841284            done
    12851285            (True, 1, '[ ]')
    12861286
    1287         The preceding command produces the following output as a
    1288         side-effect.  It proves that the index of the points in their
    1289         saturation is at most 3, then proves saturation at 2 and at 3,
    1290         by reducing the points modulo all primes of good reduction up
    1291         to 11, respectively 13::
    1292 
    1293             saturating basis...Saturation index bound = 3
    1294             Checking saturation at [ 2 3 ]
    1295             Checking 2-saturation
    1296             Points were proved 2-saturated (max q used = 11)
    1297             Checking 3-saturation
    1298             Points were proved 3-saturated (max q used = 13)
    1299             done
     1287        Note the output of the preceding command: it proves that the
     1288        index of the points in their saturation is at most 3, then
     1289        proves saturation at 2 and at 3, by reducing the points modulo
     1290        all primes of good reduction up to 11, respectively 13.
    13001291        """
    13011292        ok, index, unsat = self.__mw.saturate(int(max_prime), odd_primes_only)
    13021293        return bool(ok), int(str(index)), unsat
  • sage/libs/mwrank/mwrank.pyx

    diff --git a/sage/libs/mwrank/mwrank.pyx b/sage/libs/mwrank/mwrank.pyx
    a b  
    883883            sage: EQ.process([494, -5720, 6859]) # 3 times another point
    884884            sage: EQ.saturate(sat_bd=2)
    885885            Saturation index bound = 10
    886             WARNING: saturation at primes p > 2 will not be done; 
     886            WARNING: saturation at primes p > 2 will not be done;
    887887            points may be unsaturated at primes between 2 and index bound
    888888            Failed to saturate MW basis at primes [ ]
    889889            (0, 1, '[ ]')
     
    12611261            Sha     rank contribution from A=ker(eps) = 0
    12621262            sage: D2.saturate()
    12631263            Searching for points (bound = 8)...done:
    1264               found points of rank 3
     1264              found points which generate a subgroup of rank 3
    12651265              and regulator 0.417143558758383969817119544618093396749810106098479
    12661266            Processing points found during 2-descent...done:
    12671267              now regulator = 0.417143558758383969817119544618093396749810106098479
     
    13081308            Sha     rank contribution from A=ker(eps) = 0
    13091309            sage: D2.saturate()
    13101310            Searching for points (bound = 8)...done:
    1311               found points of rank 3
     1311              found points which generate a subgroup of rank 3
    13121312              and regulator 0.417143558758383969817119544618093396749810106098479
    13131313            Processing points found during 2-descent...done:
    13141314              now regulator = 0.417143558758383969817119544618093396749810106098479
     
    13561356
    13571357            sage: D2.saturate()
    13581358            Searching for points (bound = 8)...done:
    1359               found points of rank 3
     1359              found points which generate a subgroup of rank 3
    13601360              and regulator 0.417143558758383969817119544618093396749810106098479
    13611361            Processing points found during 2-descent...done:
    13621362              now regulator = 0.417143558758383969817119544618093396749810106098479
  • sage/misc/cython.py

    diff --git a/sage/misc/cython.py b/sage/misc/cython.py
    a b  
    693693        sage: f.write(s)
    694694        sage: f.close()
    695695        sage: cython_create_local_so('hello.spyx')
     696        Compiling hello.spyx...
    696697        sage: sys.path.append('.')
    697698        sage: import hello
    698699        sage: hello.hello()
  • sage/misc/interpreter.py

    diff --git a/sage/misc/interpreter.py b/sage/misc/interpreter.py
    a b  
    185185            sage: os.WIFEXITED(status) and os.WEXITSTATUS(status) != 0
    186186            True
    187187            sage: shell.system_raw('R --version')
     188            R version ...
    188189            sage: status = shell.user_ns['_exit_code']
    189190            sage: os.WIFEXITED(status) and os.WEXITSTATUS(status) == 0
    190191            True
  • sage/misc/preparser.py

    diff --git a/sage/misc/preparser.py b/sage/misc/preparser.py
    a b  
    16711671
    16721672    EXAMPLES:
    16731673
    1674     Note that .py files are *not* preparsed::
    1675    
    1676         sage: t=tmp_filename(ext='.py'); open(t,'w').write("print 'hi',2/3; z=-2/9")
    1677         sage: sage.misc.preparser.load(t,globals())
     1674    Note that ``.py`` files are *not* preparsed::
     1675
     1676        sage: t = tmp_filename(ext='.py')
     1677        sage: open(t,'w').write("print 'hi', 2/3; z = -2/7")
     1678        sage: z = 1
     1679        sage: sage.misc.preparser.load(t, globals())
    16781680        hi 0
    16791681        sage: z
    16801682        -1
    16811683
    1682     A .sage file *is* preparsed::
    1683    
    1684         sage: t=tmp_filename(ext='.sage'); open(t,'w').write("print 'hi',2/3; s=-2/7")
    1685         sage: sage.misc.preparser.load(t,globals())
     1684    A ``.sage`` file *is* preparsed::
     1685
     1686        sage: t = tmp_filename(ext='.sage')
     1687        sage: open(t,'w').write("print 'hi', 2/3; z = -2/7")
     1688        sage: z = 1
     1689        sage: sage.misc.preparser.load(t, globals())
    16861690        hi 2/3
    1687         sage: s
     1691        sage: z
    16881692        -2/7
    16891693
    16901694    Cython files are *not* preparsed::
    1691    
    1692         sage: t=tmp_filename(ext='.pyx'); open(t,'w').write("print 'hi',2/3; z=-2/9")
    1693         sage: z=0; sage.misc.preparser.load(t,globals())
     1695
     1696        sage: t = tmp_filename(ext='.pyx')
     1697        sage: open(t,'w').write("print 'hi', 2/3; z = -2/7")
     1698        sage: z = 1
     1699        sage: sage.misc.preparser.load(t, globals())
     1700        Compiling ...
    16941701        hi 0
    16951702        sage: z
    16961703        -1
  • sage/misc/session.pyx

    diff --git a/sage/misc/session.pyx b/sage/misc/session.pyx
    a b  
    244244        - creates a file
    245245
    246246    EXAMPLES:
     247
    247248    For testing, we use a temporary file, that will be removed as soon
    248249    as Sage is left. Of course, for permanently saving your session,
    249     you should choose a permanent file.::
     250    you should choose a permanent file. ::
    250251   
    251252        sage: a = 5
    252253        sage: tmp_f = tmp_filename()
     
    257258        5
    258259
    259260    We illustrate what happens when one of the variables is a function.::
     261
    260262        sage: f = lambda x : x^2
    261263        sage: save_session(tmp_f)
    262264        sage: save_session(tmp_f, verbose=True)
     
    268270   
    269271        sage: g = cython_lambda('double x', 'x*x + 1.5')
    270272        sage: save_session(tmp_f, verbose=True)
    271         Saving...
    272273        Not saving g: g is a function, method, class or type
    273274        ...
    274275    """
  • sage/modular/modform/cuspidal_submodule.py

    diff --git a/sage/modular/modform/cuspidal_submodule.py b/sage/modular/modform/cuspidal_submodule.py
    a b  
    359359        O(q^1)
    360360    """
    361361    pass
     362
    362363    #def _repr_(self):
    363364    #    A = self.ambient_module()
    364365    #    return "Cuspidal subspace of dimension %s of Modular Forms space with character %s and weight %s over %s"%(self.dimension(), self.character(), self.weight(), self.base_ring())
    365    
    366366
    367367
    368368def _convert_matrix_from_modsyms(symbs, T):
  • sage/numerical/backends/glpk_backend.pyx

    diff --git a/sage/numerical/backends/glpk_backend.pyx b/sage/numerical/backends/glpk_backend.pyx
    a b  
    12371237            sage: p.add_linear_constraint([[0, 1], [1, 2]], None, 3)
    12381238            sage: p.set_objective([2, 5])
    12391239            sage: p.write_mps(os.path.join(SAGE_TMP, "lp_problem.mps"), 2)
     1240            Writing problem data to...
     1241            17 records were written
    12401242        """
    12411243        glp_write_mps(self.lp, modern, NULL,  filename)
    12421244
     
    17421744            sage: import sage.numerical.backends.glpk_backend as backend
    17431745            sage: p.solver_parameter(backend.glp_simplex_or_intopt, backend.glp_simplex_only)
    17441746            sage: p.print_ranges()
    1745             ...
     1747            glp_print_ranges: optimal basic solution required
    17461748            1
    17471749            sage: p.solve()
    17481750            0
    17491751            sage: p.print_ranges()
     1752            Write sensitivity analysis report to...
    17501753            GLPK ... - SENSITIVITY ANALYSIS REPORT                                                                         Page   1
    17511754            <BLANKLINE>
    1752             Problem:   
     1755            Problem:
    17531756            Objective:  7.5 (MAXimum)
    17541757            <BLANKLINE>
    17551758               No. Row name     St      Activity         Slack   Lower bound       Activity      Obj coef  Obj value at Limiting
    17561759                                                      Marginal   Upper bound          range         range   break point variable
    17571760            ------ ------------ -- ------------- ------------- -------------  ------------- ------------- ------------- ------------
    1758                  1              NU       3.00000        .               -Inf         .           -2.50000        .     
     1761                 1              NU       3.00000        .               -Inf         .           -2.50000        .
    17591762                                                       2.50000       3.00000           +Inf          +Inf          +Inf
    17601763            <BLANKLINE>
    17611764            GLPK ... - SENSITIVITY ANALYSIS REPORT                                                                         Page   2
    17621765            <BLANKLINE>
    1763             Problem:   
     1766            Problem:
    17641767            Objective:  7.5 (MAXimum)
    17651768            <BLANKLINE>
    17661769               No. Column name  St      Activity      Obj coef   Lower bound       Activity      Obj coef  Obj value at Limiting
     
    17751778            End of report
    17761779            <BLANKLINE>
    17771780            0
    1778 
    1779 
    17801781        """
    17811782
    17821783        from sage.misc.all import SAGE_TMP
  • sage/numerical/mip.pyx

    diff --git a/sage/numerical/mip.pyx b/sage/numerical/mip.pyx
    a b  
    18561856            sage: b = p.get_backend()
    18571857            sage: b.solver_parameter("simplex_or_intopt", "simplex_only")
    18581858            sage: b.solver_parameter("verbosity_simplex", "GLP_MSG_ALL")
    1859             sage: p.solve() # tol 0.00001
     1859            sage: p.solve()  # tol 0.00001
     1860            GLPK Simplex Optimizer, v4.44
     1861            2 rows, 2 columns, 4 non-zeros
     1862            *     0: obj =   7.000000000e+00  infeas =  0.000e+00 (0)
     1863            *     2: obj =   9.400000000e+00  infeas =  0.000e+00 (0)
     1864            OPTIMAL SOLUTION FOUND
    18601865            9.4
    1861 
    18621866        """
    18631867        return self._backend
    18641868
  • sage/schemes/toric/variety.py

    diff --git a/sage/schemes/toric/variety.py b/sage/schemes/toric/variety.py
    a b  
     1# -*- coding: utf-8 -*-
    12r"""
    23Toric varieties
    34
  • sage/structure/parent_old.pyx

    diff --git a/sage/structure/parent_old.pyx b/sage/structure/parent_old.pyx
    a b  
    6666        sage: MatrixSpace(GF(3), 1, 1).list()
    6767        [[0], [1], [2]]
    6868        sage: DirichletGroup(3).list()
    69         [Dirichlet character modulo 3 of conductor 1 mapping 2 |--> 1, 
     69        [Dirichlet character modulo 3 of conductor 1 mapping 2 |--> 1,
    7070        Dirichlet character modulo 3 of conductor 3 mapping 2 |--> -1]
    7171        sage: K = GF(7^6,'a')
    7272        sage: K.list()[:10] # long time