Ticket #13146: 13146_vs_51b5.patch

File 13146_vs_51b5.patch, 24.5 KB (added by roed, 8 years ago)

Changes to apply against 5.1.beta5

  • doc/en/thematic_tutorials/group_theory.rst

    # HG changeset patch
    # User David Roe <roed.math@gmail.com>
    # Date 1340303167 14400
    # Node ID 48e8f6069c6f6adbd266ab8028e1f720904980a8
    # Parent  32b0b3c412d3b902e5a97da4c0e9b5686be9611a
    #13146: change tabs to spaces in various rst, tex and pxi files
    
    diff --git a/doc/en/thematic_tutorials/group_theory.rst b/doc/en/thematic_tutorials/group_theory.rst
    a b  
    946946          G = direct_product_permgroups([D1,D2])      Abelian, non-cyclic
    947947    8     D1 = CyclicPermutationGroup(2)
    948948          D2 = CyclicPermutationGroup(2)
    949           D3 = CyclicPermutationGroup(2)
     949          D3 = CyclicPermutationGroup(2)
    950950          G = direct_product_permgroups([D1,D2,D3])}  Abelian, non-cyclic
    951951    8     DihedralGroup(4)                            Non-abelian
    952952    8     QuaternionGroup()}                          Quaternions, also DiCyclicGroup(2)
  • doc/en/thematic_tutorials/lie/affine_crystals.rst

    diff --git a/doc/en/thematic_tutorials/lie/affine_crystals.rst b/doc/en/thematic_tutorials/lie/affine_crystals.rst
    a b  
    124124    sage: C = CartanType(['D',n,1]); C.dynkin_diagram()
    125125      0 O   O 5
    126126        |   |
    127         |   |
     127        |   |
    128128    O---O---O---O
    129129    1   2   3   4
    130130    D5~
  • doc/en/thematic_tutorials/lie/crystals.rst

    diff --git a/doc/en/thematic_tutorials/lie/crystals.rst b/doc/en/thematic_tutorials/lie/crystals.rst
    a b  
    895895    sage: B = CrystalOfTableaux(['A',3],shape=[2,1])
    896896    sage: b = B(rows=[[1,2],[3]])
    897897    sage: b.lusztig_involution()
    898     [[2, 4], [3]]       
     898    [[2, 4], [3]]
    899899
    900900For type `A_n`, the Lusztig involution is the same as the Schuetzenberger involution (which in Sage is
    901901defined on tableaux)::
  • doc/en/thematic_tutorials/lie/weyl_groups.rst

    diff --git a/doc/en/thematic_tutorials/lie/weyl_groups.rst b/doc/en/thematic_tutorials/lie/weyl_groups.rst
    a b  
    276276    def find_reflection(u,v):
    277277        bi = W.bruhat_interval(u,v)
    278278        ret = []
    279         for r in ref:
     279        for r in ref:
    280280            if all( r*x in bi for x in bi):
    281281                ret.append(r)
    282282        return ret
    283283
    284284    for v in W:
    285         for u in W.bruhat_interval(1,v):
     285        for u in W.bruhat_interval(1,v):
    286286            if u != v:
    287287                print u,v,find_reflection(u,v)
    288288
  • doc/en/thematic_tutorials/tutorial-objects-and-classes.rst

    diff --git a/doc/en/thematic_tutorials/tutorial-objects-and-classes.rst b/doc/en/thematic_tutorials/tutorial-objects-and-classes.rst
    a b  
    324324        139813642977744
    325325        sage: el1 = el; id(el1) == id(el)
    326326        True
    327         sage: el1 is el
    328         True
     327        sage: el1 is el
     328        True
    329329
    330330    In Python (and therefore in Sage), two objects with the same
    331331    identity will be equal, but the converse is not true in general.
    332332    Thus the identity function is different from mathematical
    333333    identity::
    334334
    335         sage: el2 = Integer(9)
    336         sage: el2 == el1
    337         True
    338         sage: el2 is el1
     335        sage: el2 = Integer(9)
     336        sage: el2 == el1
     337        True
     338        sage: el2 is el1
    339339        False
    340         sage: id(el2) == id(el)
    341         False
     340        sage: id(el2) == id(el)
     341        False
    342342
    343343Summary
    344344-------
  • doc/en/tutorial/appendix.rst

    diff --git a/doc/en/tutorial/appendix.rst b/doc/en/tutorial/appendix.rst
    a b  
    1818Operators                   Description
    1919==========================  =================
    2020or                          boolean or
    21 and                         boolean and
    22 not                         boolean not   
    23 in, not in                  membership
    24 is, is not                  identity test
     21and                         boolean and
     22not                         boolean not
     23in, not in                  membership
     24is, is not                  identity test
    2525>, <=, >, >=, ==, !=, <>    comparison
    2626+, -                        addition, subtraction
    2727\*, /, %                    multiplication, division, remainder
  • doc/en/tutorial/tour_functions.rst

    diff --git a/doc/en/tutorial/tour_functions.rst b/doc/en/tutorial/tour_functions.rst
    a b  
    9494
    9595::
    9696
    97        sage: f = sin   
     97       sage: f = sin
    9898       sage: f.derivative()
    9999       Traceback (most recent call last):
    100100       ...
     
    118118
    119119       sage: def h(x):
    120120       ...       if x<2:
    121        ...           return 0
     121       ...           return 0
    122122       ...       else:
    123        ...           return x-2
     123       ...           return x-2
    124124
    125125The issue: ``plot(h(x), 0, 4)`` plots the line `y=x-2`, not the
    126126multi-line function defined by ``h``.  The reason? In the command
  • doc/fr/tutorial/appendix.rst

    diff --git a/doc/fr/tutorial/appendix.rst b/doc/fr/tutorial/appendix.rst
    a b  
    1818Opérateur                   Description
    1919==========================  =================
    2020or                          ou booléen
    21 and                         et booléen
    22 not                         négation booléenne
    23 in, not in                  appartenance
    24 is, is not                  test d'identité
     21and                         et booléen
     22not                         négation booléenne
     23in, not in                  appartenance
     24is, is not                  test d'identité
    2525>, <=, >, >=, ==, !=, <>    comparaisons
    2626+, -                        addition, soustraction
    2727\*, /, %                    multiplication, division, reste
  • doc/fr/tutorial/tour_algebra.rst

    diff --git a/doc/fr/tutorial/tour_algebra.rst b/doc/fr/tutorial/tour_algebra.rst
    a b  
    303303============== ==================   ================
    304304:math:`a`      :math:`c`            :math:`hf(a,c)`
    305305:math:`a+h`    :math:`c+hf(a,c)`    ...
    306 :math:`a+2h`   ...                   
    307 ...                                 
     306:math:`a+2h`   ...
     307...
    308308:math:`b=a+nh` ???                  ...
    309 ============== ==================   ================ 
     309============== ==================   ================
    310310
    311311
    312312Le but est est de remplir tous les trous du tableau, ligne après ligne,
  • doc/fr/tutorial/tour_functions.rst

    diff --git a/doc/fr/tutorial/tour_functions.rst b/doc/fr/tutorial/tour_functions.rst
    a b  
    9191Il n'est pas possible de dériver la fonction ``sin`` tout court pour
    9292obtenir ``cos`` ::
    9393
    94     sage: f = sin       
     94    sage: f = sin
    9595    sage: f.derivative()
    9696    Traceback (most recent call last):
    9797    ...
     
    111111
    112112    sage: def h(x):
    113113    ...       if x < 2:
    114     ...           return 0
     114    ...           return 0
    115115    ...       else:
    116     ...           return x-2
     116    ...           return x-2
    117117
    118118Problème : ``plot(h(x), 0, 4)`` trace la droite `y = x - 2`, et non pas la
    119119fonction affine par morceaux définie par ``h``. Pourquoi ? Lors de l'exécution,
     
    140140
    141141    sage: def h(x):
    142142    ...       if x < 2:
    143     ...           return 0
     143    ...           return 0
    144144    ...       else:
    145     ...           return x-2
     145    ...           return x-2
    146146    sage: plot(h, 0, 4)
    147147
    148148\5. Constante plutôt que fonction ::
  • sage/ext/python_object.pxi

    diff --git a/sage/ext/python_object.pxi b/sage/ext/python_object.pxi
    a b  
    235235    # pointer of type PyTypeObject*, except when the incremented
    236236    # reference count is needed.
    237237
    238     bint PyObject_TypeCheck(object o, object type) #    object o, PyTypeObject *type)
     238    bint PyObject_TypeCheck(object o, object type) #    object o, PyTypeObject *type)
    239239    # Return true if the object o is of type type or a subtype of
    240240    # type. Both parameters must be non-NULL.
    241241
  • sage/ext/python_string.pxi

    diff --git a/sage/ext/python_string.pxi b/sage/ext/python_string.pxi
    a b  
    4141    # arguments must be C types and must correspond exactly to the
    4242    # format characters in the format string. The following format
    4343    # characters are allowed:
    44     # Format Characters         Type    Comment
    45     # %%        n/a     The literal % character.
    46     # %c        int     A single character, represented as an C int.
    47     # %d        int     Exactly equivalent to printf("%d").
    48     # %u        unsigned int    Exactly equivalent to printf("%u").
    49     # %ld       long    Exactly equivalent to printf("%ld").
    50     # %lu       unsigned long   Exactly equivalent to printf("%lu").
    51     # %zd       Py_ssize_t      Exactly equivalent to printf("%zd").
    52     # %zu       size_t  Exactly equivalent to printf("%zu").
    53     # %i        int     Exactly equivalent to printf("%i").
    54     # %x        int     Exactly equivalent to printf("%x").
    55     # %s        char*   A null-terminated C character array.
     44    # Format Characters  Type           Comment
     45    # %%                 n/a            The literal % character.
     46    # %c                 int            A single character, represented as an C int.
     47    # %d                 int            Exactly equivalent to printf("%d").
     48    # %u                 unsigned int   Exactly equivalent to printf("%u").
     49    # %ld                long           Exactly equivalent to printf("%ld").
     50    # %lu                unsigned long  Exactly equivalent to printf("%lu").
     51    # %zd                Py_ssize_t     Exactly equivalent to printf("%zd").
     52    # %zu                size_t         Exactly equivalent to printf("%zu").
     53    # %i                 int            Exactly equivalent to printf("%i").
     54    # %x                 int            Exactly equivalent to printf("%x").
     55    # %s                 char*          A null-terminated C character array.
    5656
    57     # %p        void*   The hex representation of a C pointer.
     57    # %p        void*   The hex representation of a C pointer.
    5858    #    Mostly equivalent to printf("%p") except that it is guaranteed to
    5959    #    start with the literal 0x regardless of what the platform's printf
    6060    #    yields.
  • sage/gsl/gsl_blas.pxi

    diff --git a/sage/gsl/gsl_blas.pxi b/sage/gsl/gsl_blas.pxi
    a b  
    5656  int  gsl_blas_dtrsv(CBLAS_UPLO_t Uplo, CBLAS_TRANSPOSE_t TransA, CBLAS_DIAG_t Diag, gsl_matrix * A, gsl_vector * x)
    5757
    5858  int  gsl_blas_zgemv (CBLAS_TRANSPOSE_t TransA,  gsl_complex alpha,  gsl_matrix_complex * A,  gsl_vector_complex * X,  gsl_complex beta, gsl_vector_complex * Y)
    59  
     59
    6060  int  gsl_blas_ztrmv (CBLAS_UPLO_t Uplo, CBLAS_TRANSPOSE_t TransA, CBLAS_DIAG_t Diag,  gsl_matrix_complex * A, gsl_vector_complex * X)
    61  
     61
    6262  int  gsl_blas_ztrsv (CBLAS_UPLO_t Uplo, CBLAS_TRANSPOSE_t TransA, CBLAS_DIAG_t Diag,  gsl_matrix_complex * A, gsl_vector_complex *X)
    63                                                                  
     63
    6464  int  gsl_blas_dsymv(CBLAS_UPLO_t Uplo, double alpha, gsl_matrix * A, gsl_vector * x, double beta, gsl_vector * y)
    6565
    6666  int  gsl_blas_dger(double alpha, gsl_vector * x, gsl_vector * y, gsl_matrix * A)
  • sage/gsl/gsl_errno.pxi

    diff --git a/sage/gsl/gsl_errno.pxi b/sage/gsl/gsl_errno.pxi
    a b  
    11cdef extern from "gsl/gsl_errno.h":
    22
    3         ctypedef void gsl_error_handler_t (char * reason, char * file,int line, int gsl_errno)
     3    ctypedef void gsl_error_handler_t (char * reason, char * file,int line, int gsl_errno)
    44
    5         ctypedef void gsl_stream_handler_t (char * label, char * file,int line, char * reason)
     5    ctypedef void gsl_stream_handler_t (char * label, char * file,int line, char * reason)
    66
    77
    8         void gsl_error (char * reason,char * file, int line, int gsl_errno)
     8    void gsl_error (char * reason,char * file, int line, int gsl_errno)
    99
    10         void gsl_stream_printf (char *label, char *file,int line, char *reason)
     10    void gsl_stream_printf (char *label, char *file,int line, char *reason)
    1111
    12         char * gsl_strerror (int gsl_errno)
     12    char * gsl_strerror (int gsl_errno)
    1313
    14         gsl_error_handler_t * gsl_set_error_handler (gsl_error_handler_t * new_handler)
     14    gsl_error_handler_t * gsl_set_error_handler (gsl_error_handler_t * new_handler)
    1515
    16         gsl_error_handler_t * gsl_set_error_handler_off()
     16    gsl_error_handler_t * gsl_set_error_handler_off()
    1717
    18         gsl_stream_handler_t * gsl_set_stream_handler (gsl_stream_handler_t * new_handler)
    19        
    20         FILE * gsl_set_stream (FILE * new_stream)
     18    gsl_stream_handler_t * gsl_set_stream_handler (gsl_stream_handler_t * new_handler)
     19
     20    FILE * gsl_set_stream (FILE * new_stream)
  • sage/gsl/gsl_fft.pxi

    diff --git a/sage/gsl/gsl_fft.pxi b/sage/gsl/gsl_fft.pxi
    a b  
    109109  int gsl_fft_halfcomplex_inverse (double data[],  size_t stride,  size_t n,  gsl_fft_halfcomplex_wavetable * wavetable, gsl_fft_real_workspace * work)
    110110
    111111  int gsl_fft_halfcomplex_transform (double data[],  size_t stride,  size_t n,  gsl_fft_halfcomplex_wavetable * wavetable, gsl_fft_real_workspace * work)
    112                                                                        
     112
    113113  int  gsl_fft_halfcomplex_unpack(double halfcomplex_coefficient[], gsl_complex_packed_array complex_coefficient, size_t stride, size_t n)
    114114
    115115  int gsl_fft_halfcomplex_radix2_unpack ( double halfcomplex_coefficient[], double complex_coefficient[],  size_t stride,  size_t n)
  • sage/gsl/gsl_fit.pxi

    diff --git a/sage/gsl/gsl_fit.pxi b/sage/gsl/gsl_fit.pxi
    a b  
    2828  int gsl_fit_wmul ( double * x,  size_t xstride,
    2929                     double * w,  size_t wstride,
    3030                     double * y,  size_t ystride,
    31                    size_t n, double * c1, double * cov11, double * sumsq)
     31                   size_t n, double * c1, double * cov11, double * sumsq)
    3232 
    3333 
    3434  int gsl_fit_mul_est ( double x, double c1, double c11,
  • sage/gsl/gsl_linalg.pxi

    diff --git a/sage/gsl/gsl_linalg.pxi b/sage/gsl/gsl_linalg.pxi
    a b  
    11cdef extern from "gsl/gsl_linalg.h":
    2  
     2
    33  cdef enum gsl_linalg_matrix_mod_t:
    44    GSL_LINALG_MOD_NONE = 0
    55    GSL_LINALG_MOD_TRANSPOSE = 1
    66    GSL_LINALG_MOD_CONJUGATE = 2
    7            
     7
    88  int gsl_linalg_matmult ( gsl_matrix * A,  gsl_matrix * B, gsl_matrix * C)
    99
    1010  int gsl_linalg_matmult_mod ( gsl_matrix * A, gsl_linalg_matrix_mod_t modA,  gsl_matrix * B, gsl_linalg_matrix_mod_t modB, gsl_matrix * C)
    11  
     11
    1212  int gsl_linalg_exponential_ss(gsl_matrix * A, gsl_matrix * eA, gsl_mode_t mode)
    1313
    1414  # Householder Transformations
    1515  double gsl_linalg_householder_transform (gsl_vector * v)
    16  
     16
    1717  gsl_complex gsl_linalg_complex_householder_transform (gsl_vector_complex * v)
    18  
     18
    1919  int gsl_linalg_householder_hm (double tau,  gsl_vector * v, gsl_matrix * A)
    20  
     20
    2121  int gsl_linalg_householder_mh (double tau,  gsl_vector * v, gsl_matrix * A)
    22                                                                
     22
    2323  int gsl_linalg_householder_hv (double tau,  gsl_vector * v, gsl_vector * w)
    24                                                                
     24
    2525  int gsl_linalg_householder_hm1 (double tau, gsl_matrix * A)
    26                                  
     26
    2727  int gsl_linalg_complex_householder_hm (gsl_complex tau,  gsl_vector_complex * v, gsl_matrix_complex * A)
    2828
    2929  int gsl_linalg_complex_householder_hv (gsl_complex tau,  gsl_vector_complex * v, gsl_vector_complex * w)
    30                                                                                
     30
    3131  # Singular Value Decomposition
    3232  int  gsl_linalg_SV_decomp(gsl_matrix * A, gsl_matrix * V, gsl_vector * S, gsl_vector * work)
    3333
  • sage/gsl/gsl_matrix.pxi

    diff --git a/sage/gsl/gsl_matrix.pxi b/sage/gsl/gsl_matrix.pxi
    a b  
    77    double * data
    88    gsl_block * block
    99    int owner
    10              
     10
    1111  ctypedef struct gsl_matrix_view:
    1212    gsl_matrix matrix
    1313
     
    2222    size_t offset, size_t n1, size_t n2, size_t d2)
    2323
    2424  gsl_matrix * gsl_matrix_alloc_from_matrix (gsl_matrix * m,  size_t k1,  size_t k2,  size_t n1,  size_t n2)
    25  
     25
    2626  gsl_vector * gsl_vector_alloc_row_from_matrix (gsl_matrix * m,  size_t i)
    2727
    2828  gsl_vector * gsl_vector_alloc_col_from_matrix (gsl_matrix * m,  size_t j)
    29  
     29
    3030  void  gsl_matrix_free(gsl_matrix * m)
    3131
    3232  # Views
     
    6161  gsl_vector_const_view  gsl_matrix_const_subdiagonal(gsl_matrix * m, size_t k)
    6262
    6363  gsl_vector_const_view  gsl_matrix_const_superdiagonal(gsl_matrix * m, size_t k)
    64  
     64
    6565  gsl_matrix_const_view  gsl_matrix_const_view_array(double * base, size_t n1, size_t n2)
    6666
    6767  gsl_matrix_const_view  gsl_matrix_const_view_array_with_tda(double * base, size_t n1, size_t n2, size_t tda)
     
    7070
    7171  gsl_matrix_const_view  gsl_matrix_const_view_vector_with_tda(gsl_vector * v, size_t n1, size_t n2, size_t tda)
    7272
    73  
     73
    7474  # Operations
    7575  double  gsl_matrix_get(gsl_matrix * m, size_t i, size_t j)
    7676
     
    137137  int  gsl_matrix_scale(gsl_matrix * a, double x)
    138138
    139139  int  gsl_matrix_add_constant(gsl_matrix * a, double x)
    140  
     140
    141141  int gsl_matrix_add_diagonal (gsl_matrix * a,  double x)
    142  
     142
    143143  # The functions below are obsolete
    144144  int  gsl_matrix_get_row(gsl_vector * v, gsl_matrix * m, size_t i)
    145145
  • sage/libs/ginac.pxd

    diff --git a/sage/libs/ginac.pxd b/sage/libs/ginac.pxd
    a b  
    282282            unsigned int l)
    283283
    284284
    285     GEx g_abs "GiNaC::abs" (GEx x)           except +
    286     GEx g_step "GiNaC::step" (GEx x)         except +  # step function
    287     GEx g_csgn "GiNaC::csgn" (GEx x)         except + # complex sign
    288     # complex conjugation
    289     GEx g_conjugate "GiNaC::conjugate_function" (GEx x) except +
    290     # real part
    291     GEx g_real_part "GiNaC::real_part_function" (GEx x) except +
    292     # imaginary part
    293     GEx g_imag_part "GiNaC::imag_part_function" (GEx x) except +
    294     # square root (not a GiNaC function, rather an alias for
    295     # pow(x, numeric(1, 2)))
    296     GEx g_sqrt "GiNaC::sqrt" (GEx x) except + 
    297     GEx g_sin "GiNaC::sin" (GEx x)      except + # sine
    298     GEx g_cos "GiNaC::cos" (GEx x)      except + # cosine
    299     GEx g_tan "GiNaC::tan" (GEx x)      except + # tangent
    300     GEx g_asin "GiNaC::asin" (GEx x)    except + # inverse sine
    301     GEx g_acos "GiNaC::acos" (GEx x)    except + # inverse cosine
    302     GEx g_atan "GiNaC::atan" (GEx x)    except + # inverse tangent
    303     GEx g_atan2 "GiNaC::atan2" (GEx y, GEx x) except +  # inverse tangent with two arguments
    304     GEx g_sinh "GiNaC::sinh" (GEx x)    except + # hyperbolic sine
    305     GEx g_cosh "GiNaC::cosh" (GEx x)    except + # hyperbolic cosine
    306     GEx g_tanh "GiNaC::tanh" (GEx x)    except + # hyperbolic tangent
    307     GEx g_asinh "GiNaC::asinh" (GEx x)  except + # inverse hyperbolic sine
    308     GEx g_acosh "GiNaC::acosh" (GEx x)  except + # inverse hyperbolic cosine
    309     GEx g_atanh "GiNaC::atanh" (GEx x)  except + # inverse hyperbolic tangent
    310     GEx g_exp "GiNaC::exp" (GEx x)      except + # exponential function
    311     GEx g_log "GiNaC::log" (GEx x)      except + # natural logarithm
    312     GEx g_Li2 "GiNaC::Li2" (GEx x)      except + # dilogarithm
    313     GEx g_Li "GiNaC::Li" (GEx m, GEx x) except + # classical polylogarithm as well as multiple polylogarithm
    314     GEx g_G "GiNaC::G" (GEx a, GEx y)   except + # multiple polylogarithm
    315     GEx g_G2 "GiNaC::G" (GEx a, GEx s, GEx y)   except + # multiple polylogarithm with explicit signs for the imaginary parts
    316     GEx g_S "GiNaC::S" (GEx n, GEx p, GEx x)    except + # Nielsen's generalized polylogarithm
    317     GEx g_H "GiNaC::H" (GEx m, GEx x)           except + # harmonic polylogarithm
    318     GEx g_zeta "GiNaC::zeta" (GEx m)            except + # Riemann's zeta function as well as multiple zeta value
    319     GEx g_zeta2 "GiNaC::zeta" (GEx m, GEx s)    except + # alternating Euler sum
    320     GEx g_zetaderiv "GiNaC::zetaderiv" (GEx n, GEx x)   except + # derivatives of Riemann's zeta function
    321     GEx g_tgamma "GiNaC::tgamma" (GEx x)        except + # gamma function
    322     GEx g_lgamma "GiNaC::lgamma" (GEx x)        except + # logarithm of gamma function
    323     GEx g_beta "GiNaC::beta" (GEx x, GEx y)     except + # beta function (tgamma*tgamma(y)/tgamma(x+y))
    324     GEx g_psi "GiNaC::psi" (GEx x)              except + # psi (digamma) function
    325     GEx g_psi2 "GiNaC::psi" (GEx n, GEx x)      except + # derivatives of psi function (polygamma functions)
    326     GEx g_factorial "GiNaC::factorial" (GEx n)  except + # factorial function n!
    327     GEx g_binomial "GiNaC::binomial" (GEx n, GEx k)     except + # binomial coefficients
    328     GEx g_Order "GiNaC::Order" (GEx x)          except + # order term function in truncated power series
     285    GEx g_abs "GiNaC::abs" (GEx x)                      except + # absolute value
     286    GEx g_step "GiNaC::step" (GEx x)                    except + # step function
     287    GEx g_csgn "GiNaC::csgn" (GEx x)                    except + # complex sign
     288    GEx g_conjugate "GiNaC::conjugate_function" (GEx x) except + # complex conjugation
     289    GEx g_real_part "GiNaC::real_part_function" (GEx x) except + # real part
     290    GEx g_imag_part "GiNaC::imag_part_function" (GEx x) except + # imaginary part
     291    GEx g_sqrt "GiNaC::sqrt" (GEx x)                    except + # square root (not a GiNaC function, rather an alias for pow(x, numeric(1, 2)))
     292    GEx g_sin "GiNaC::sin" (GEx x)                      except + # sine
     293    GEx g_cos "GiNaC::cos" (GEx x)                      except + # cosine
     294    GEx g_tan "GiNaC::tan" (GEx x)                      except + # tangent
     295    GEx g_asin "GiNaC::asin" (GEx x)                    except + # inverse sine
     296    GEx g_acos "GiNaC::acos" (GEx x)                    except + # inverse cosine
     297    GEx g_atan "GiNaC::atan" (GEx x)                    except + # inverse tangent
     298    GEx g_atan2 "GiNaC::atan2" (GEx y, GEx x)           except + # inverse tangent with two arguments
     299    GEx g_sinh "GiNaC::sinh" (GEx x)                    except + # hyperbolic sine
     300    GEx g_cosh "GiNaC::cosh" (GEx x)                    except + # hyperbolic cosine
     301    GEx g_tanh "GiNaC::tanh" (GEx x)                    except + # hyperbolic tangent
     302    GEx g_asinh "GiNaC::asinh" (GEx x)                  except + # inverse hyperbolic sine
     303    GEx g_acosh "GiNaC::acosh" (GEx x)                  except + # inverse hyperbolic cosine
     304    GEx g_atanh "GiNaC::atanh" (GEx x)                  except + # inverse hyperbolic tangent
     305    GEx g_exp "GiNaC::exp" (GEx x)                      except + # exponential function
     306    GEx g_log "GiNaC::log" (GEx x)                      except + # natural logarithm
     307    GEx g_Li2 "GiNaC::Li2" (GEx x)                      except + # dilogarithm
     308    GEx g_Li "GiNaC::Li" (GEx m, GEx x)                 except + # classical polylogarithm as well as multiple polylogarithm
     309    GEx g_G "GiNaC::G" (GEx a, GEx y)                   except + # multiple polylogarithm
     310    GEx g_G2 "GiNaC::G" (GEx a, GEx s, GEx y)           except + # multiple polylogarithm with explicit signs for the imaginary parts
     311    GEx g_S "GiNaC::S" (GEx n, GEx p, GEx x)            except + # Nielsen's generalized polylogarithm
     312    GEx g_H "GiNaC::H" (GEx m, GEx x)                   except + # harmonic polylogarithm
     313    GEx g_zeta "GiNaC::zeta" (GEx m)                    except + # Riemann's zeta function as well as multiple zeta value
     314    GEx g_zeta2 "GiNaC::zeta" (GEx m, GEx s)            except + # alternating Euler sum
     315    GEx g_zetaderiv "GiNaC::zetaderiv" (GEx n, GEx x)   except + # derivatives of Riemann's zeta function
     316    GEx g_tgamma "GiNaC::tgamma" (GEx x)                except + # gamma function
     317    GEx g_lgamma "GiNaC::lgamma" (GEx x)                except + # logarithm of gamma function
     318    GEx g_beta "GiNaC::beta" (GEx x, GEx y)             except + # beta function (tgamma*tgamma(y)/tgamma(x+y))
     319    GEx g_psi "GiNaC::psi" (GEx x)                      except + # psi (digamma) function
     320    GEx g_psi2 "GiNaC::psi" (GEx n, GEx x)              except + # derivatives of psi function (polygamma functions)
     321    GEx g_factorial "GiNaC::factorial" (GEx n)          except + # factorial function n!
     322    GEx g_binomial "GiNaC::binomial" (GEx n, GEx k)     except + # binomial coefficients
     323    GEx g_Order "GiNaC::Order" (GEx x)                  except + # order term function in truncated power series
    329324
    330325    # wrapper around arithmetic to allow "hold"ing results
    331326    GEx g_power_construct "GiNaC::power" (GEx b, GEx p) except +
    332     GEx g_add_construct "GiNaC::add" (GExVector, bint) except +
    333     GEx g_mul_construct "GiNaC::mul" (GExVector, bint) except +
     327    GEx g_add_construct "GiNaC::add" (GExVector, bint)  except +
     328    GEx g_mul_construct "GiNaC::mul" (GExVector, bint)  except +
    334329
    335330    GEx g_ex1_2 "GiNaC::_ex1_2"
    336331
  • sage/misc/notes/bernoulli_mod_p.tex

    diff --git a/sage/misc/notes/bernoulli_mod_p.tex b/sage/misc/notes/bernoulli_mod_p.tex
    a b  
    2424can be rewritten using the identity $2jk = k^2 + j^2 - (k-j)^2$ as
    2525   $$ b_k = g^{k^2} \sum_{j=0}^{(p-3)/2} c_{k-j} d_j,$$
    2626where $c_j = g^{-j^2}$ and $d_j = g^{j^2} a_j$. This last sum is a convolution, and so is tantamount to computing the product of the polynomials
    27         $$ F(X) = \sum_{j=-(p-3)/2}^{(p-3)/2} c_j X^j \quad \text{and} \quad  G(X) = \sum_{j=0}^{(p-3)/2} d_j X^j. $$
     27        $$ F(X) = \sum_{j=-(p-3)/2}^{(p-3)/2} c_j X^j \quad \text{and} \quad  G(X) = \sum_{j=0}^{(p-3)/2} d_j X^j. $$
    2828In fact one checks that $c_{j+(p-1)/2} = (-1)^{(p-1)/2} c_j$, so
    2929   $$ F(X) = 1 + \left(1 + (-1)^{(p-1)/2}X^{-(p-1)/2}\right) \sum_{j=1}^{(p-3)/2} c_j X^j; $$
    3030this observation reduces the problem to multiplying two polynomials of length $(p-1)/2$, which we do using NTL.