## `polylog` -- the polylogarithm function

#### Introduction

`polylog``(n,x)` represents the polylogarithm function Li(n, x) of index n at the point x.

#### Call(s)

`polylog(n, x)`

#### Parameters

`n` | - | an arithmetical expression representing an integer
`x` | - | an arithmetical expression

#### Returns

an arithmetical expression.

### Overloadable:

`x`

#### Side Effects

When called with a floating point argument `x`, the function is sensitive to the environment variable `DIGITS` which determines the numerical working precision.

#### Related Functions

`dilog`, `ln`

#### Details

- For a complex number x of modulus |x|<1, the polylogarithm function of index n is defined as

      polylog(n,x)=sum(x^k/k^n, k=1..infinity).

  This function is extended to the whole complex plane by analytic continuation.
- If `n` is an integer and `x` a floating point number, then a floating point result is computed.
- If `n` is an integer <=1, then an explicit expression is returned for any input parameter `x`. If `n` is an integer >1 or if `n` is a symbolic expression, then an unevaluated call of `polylog` is returned, unless `x` is a floating point number. If `n` is a numerical value, but not an integer, then an error occurs.
- Some special values for n=2 are implemented (cf. `dilog`). The values polylog(n,0)=0 and polylog(n,1)=zeta(n) are implemented for any n. Furthermore, polylog(n,-1)=(2^(1-n)-1)*zeta(n) for any n<>1.
- polylog(n,x) has a singularity at the point x=1 for indices n<=1. For indices n>=1, the point x=1 is a branch point. The branch cut is the real interval [1,infinity). A jump occurs when crossing this cut. Cf. example 2.
- Mathematically, `polylog``(2,x)` coincides with `dilog``(1-x)`.

#### Example 1

Explicit results are returned for integer indices n<=1:

    >> polylog(-5, x), polylog(-1, x), polylog(0, x), polylog(1, x)

                    2       3       4    5
            x + 26 x  + 66 x  + 26 x  + x      x        x
            ------------------------------, --------, -----, -ln(1 - x)
                              6                    2  1 - x
                       (1 - x)              (1 - x)

An unevaluated call is returned if the index is an integer n>1 or a symbolic expression:

    >> polylog(2, x), polylog(n^2 + 1, 2), polylog(n + 1, 2.0)

                                      2
              polylog(2, x), polylog(n  + 1, 2), polylog(n + 1, 2.0)

Floating point values are computed for integer indices n and floating point arguments x:

    >> polylog(-5, -1.2), polylog(10, 100.0 + 3.2*I)

                    -0.2326930882, 104.9131863 + 11.44600047 I

An error occurs if n is a numerical value, but not an integer:

    >> polylog(5/2, x)

          Error: first argument must be an integer [polylog]

Some special symbolic values are implemented:

    >> polylog(4, 1), polylog(5, -1), polylog(2, I)

                          4                              2
                        PI     15 zeta(5)              PI
                        ---, - ----------, I CATALAN - ---
                        90         16                  48

    >> assume(n <> 1): polylog(n, -1)

                                              1 - n
                              - zeta(n) (1 - 2     )

    >> unassume(n): polylog(n, -1)

                                  polylog(n, -1)

#### Example 2

For indices n>=1, the real interval [1,infinity) is a branch cut. The values returned by `polylog` jump when crossing this cut:

    >> polylog(3, 1.2 + I/10^1000) - polylog(3, 1.2 - I/10^1000)

                                  0.1044301529 I

#### Example 3

The functions `diff`, `float`, `limit`, and `series` handle expressions involving `polylog`:

    >> diff(polylog(n, x), x), float(polylog(4, 3 + I))

                  polylog(n - 1, x)
                  -----------------, 3.177636803 + 1.859135861 I
                          x

    >> series(polylog(4, sin(x)), x = 0)

                          2       3       4         5
                         x    25 x    13 x    1523 x       6
                     x + -- - ----- - ----- + ------- + O(x )
                         16    162     768    405000

#### Background

- The polylogarithms are characterized by diff(polylog(n,x),x) = polylog(n-1,x)/x in conjunction with polylog(n,0)=0 and polylog(0,x)=-ln(1-x). polylog(n,x) is a rational function in x for n<=0.
- polylog(n,x) has a branch cut along the real interval [1,infinity) for indices n>=1. The value at a point x on the cut coincides with the limit ``from below'':

              polylog(n,x)
               =limit(polylog(n,x+eps*I), eps=0, Right)
               =limit(polylog(n,x+eps*I), eps=0, Left) - 2*PI*I*ln(x)^(n-1)/(n-1)!.

- Reference: L. Lewin, ``Polylogarithms and Related Functions'', North Holland (1981). L. Lewin (ed.), ``Structural Properties of Polylogarithms'', Mathematical Surveys and Monographs Vol. 37, American Mathematical Society, Providence (1991).

#### Changes

- new function

Do you have questions or comments?
Copyright © SciFace Software GmbH & Co. KG 2000