# Application of Euler Maclaurin Summation Formula to obtain analytic continuation of Riemann zeta function¶

Reference: Section 14 Zeta's scenary, "Exploring Euler's Mathematics", S.Kurokawa, Springer Japan, 2007

In [1]:
install_github("YasuakiHonda","euler-maclaurin-sum","master");

Out[1]:
$\tag{{\it \%o}_{1}}\left[ \mbox{ /root/quicklisp/dists/quicklisp/archives/euler-maclaurin-sum-master.gz } , \mbox{ /root/quicklisp/local-projects/YasuakiHonda-euler-maclaurin-sum-82043ec/ } \right]$
In [2]:
asdf_load_source("euler-maclaurin-sum");

Out[2]:
$\tag{{\it \%o}_{2}}\#$
In [3]:
assume(M>N); assume(N>0); assume(M>1);assume(s>1);

Out[3]:
$\tag{{\it \%o}_{3}}\left[ M>N \right]$
Out[3]:
$\tag{{\it \%o}_{4}}\left[ N>0 \right]$
Out[3]:
$\tag{{\it \%o}_{5}}\left[ M>1 \right]$
Out[3]:
$\tag{{\it \%o}_{6}}\left[ s>1 \right]$
In [4]:
ems;

Out[4]:
$\tag{{\it \%o}_{7}}\sum_{n=N}^{M}{f\left(n\right)}=\sum_{k=1}^{K-1}{\frac{\left(-1\right)^{k+1}\,B_{k+1}\,\left(\left.\frac{d^{k}}{d\,x^{k}}\,f\left(x\right)\right|_{x=M}-\left.\frac{d^{k}}{d\,x^{k}}\,f\left(x\right)\right|_{x=N}\right)}{\left(k+1\right)!}}+\frac{\left(-1\right)^{K+1}\,\int_{N}^{M}{\overline{B}_{K}\left(x\right)\,\left(\frac{d^{K}}{d\,x^{K}}\,f\left(x\right)\right)\;dx}}{K!}+\int_{N}^{M}{f\left(x\right)\;dx}+\frac{f\left(N\right)}{2}+\frac{f\left(M\right)}{2}$
In [5]:
renz:ems,f(n):=n^(-s),K=4,nouns;

Out[5]:
$\tag{{\it \%o}_{8}}\sum_{n=N}^{M}{\frac{1}{n^{s}}}=\frac{\left(-s-3\right)\,\left(-s-2\right)\,\left(-s-1\right)\,s\,\int_{N}^{M}{x^{-s-4}\,\overline{B}_{4}\left(x\right)\;dx}}{24}+\frac{N}{N^{s}\,s-N^{s}}-\frac{M}{M^{s}\,s-M^{s}}-\frac{N^{-s-3}\,\left(-s-2\right)\,\left(-s-1\right)\,s-M^{-s-3}\,\left(-s-2\right)\,\left(-s-1\right)\,s}{720}+\frac{N^{-s-1}\,s-M^{-s-1}\,s}{12}+\frac{1}{2\,N^{s}}+\frac{1}{2\,M^{s}}$
In [6]:
renz1:subst(inf,M,lhs(renz))=map(lambda([exp],factor(limit(exp,M,inf))),rhs(renz));

Out[6]:
$\tag{{\it \%o}_{9}}\sum_{n=N}^{\infty }{\frac{1}{n^{s}}}=-\frac{s\,\left(s+1\right)\,\left(s+2\right)\,\left(s+3\right)\,\left(\lim_{M\rightarrow \infty }{\int_{N}^{M}{x^{-s-4}\,\overline{B}_{4}\left(x\right)\;dx}}\right)}{24}-\frac{N^{-s-3}\,s\,\left(s+1\right)\,\left(s+2\right)}{720}+\frac{N^{-s-1}\,s}{12}+\frac{N^{1-s}}{s-1}+\frac{1}{2\,N^{s}}$
In [7]:
zeta(s)=sum(n^(-s),n,1,N)+sum(n^(-s),n,N,inf)-N^(-s);

Out[7]:
$\tag{{\it \%o}_{10}}\zeta\left(s\right)=-\frac{1}{N^{s}}+\sum_{n=N}^{\infty }{\frac{1}{n^{s}}}+\sum_{n=1}^{N}{\frac{1}{n^{s}}}$
In [8]:
renz2:%,renz1;

Out[8]:
$\tag{{\it \%o}_{11}}\zeta\left(s\right)=-\frac{s\,\left(s+1\right)\,\left(s+2\right)\,\left(s+3\right)\,\left(\lim_{M\rightarrow \infty }{\int_{N}^{M}{x^{-s-4}\,\overline{B}_{4}\left(x\right)\;dx}}\right)}{24}-\frac{N^{-s-3}\,s\,\left(s+1\right)\,\left(s+2\right)}{720}+\frac{N^{-s-1}\,s}{12}+\frac{N^{1-s}}{s-1}-\frac{1}{2\,N^{s}}+\sum_{n=1}^{N}{\frac{1}{n^{s}}}$
In [9]:
renz3:lhs(renz2)=limit(rhs(substpart(0,renz2,2,1)),N,inf);

Out[9]:
$\tag{{\it \%o}_{12}}\zeta\left(s\right)=\lim_{N\rightarrow \infty }{-\frac{N^{-s-3}\,s\,\left(s+1\right)\,\left(s+2\right)}{720}+\frac{N^{-s-1}\,s}{12}+\frac{N^{1-s}}{s-1}-\frac{1}{2\,N^{s}}+\sum_{n=1}^{N}{\frac{1}{n^{s}}}}$
In [10]:
rhs(renz3),s=0;

Out[10]:
$\tag{{\it \%o}_{13}}-\frac{1}{2}$
In [11]:
rhs(renz3),s=-1;

Out[11]:
$\tag{{\it \%o}_{14}}\lim_{N\rightarrow \infty }{\sum_{n=1}^{N}{n}-\frac{N^2}{2}-\frac{N}{2}-\frac{1}{12}}$
In [12]:
%,simpsum:true,ratsimp;

Out[12]:
$\tag{{\it \%o}_{15}}-\frac{1}{12}$
In [13]:
rhs(renz3),s=-2;

Out[13]:
$\tag{{\it \%o}_{16}}\lim_{N\rightarrow \infty }{\sum_{n=1}^{N}{n^2}-\frac{N^3}{3}-\frac{N^2}{2}-\frac{N}{6}}$
In [14]:
%,simpsum:true,ratsimp;

Out[14]:
$\tag{{\it \%o}_{17}}0$
In [15]:
rhs(renz3),s=-1/2;

Out[15]:
$\tag{{\it \%o}_{18}}\lim_{N\rightarrow \infty }{\sum_{n=1}^{N}{\sqrt{n}}-\frac{2\,N^{\frac{3}{2}}}{3}-\frac{\sqrt{N}}{2}-\frac{1}{24\,\sqrt{N}}+\frac{1}{1920\,N^{\frac{5}{2}}}}$
In [16]:
part(%,1);

Out[16]:
$\tag{{\it \%o}_{19}}\sum_{n=1}^{N}{\sqrt{n}}-\frac{2\,N^{\frac{3}{2}}}{3}-\frac{\sqrt{N}}{2}-\frac{1}{24\,\sqrt{N}}+\frac{1}{1920\,N^{\frac{5}{2}}}$
In [17]:
%,N:20,nouns,numer;

Out[17]:
$\tag{{\it \%o}_{20}}-0.2078862248259483$
In [18]:
zeta(-1/2),numer;

Out[18]:
$\tag{{\it \%o}_{21}}-0.2078862249773546$
In [ ]: