```python
# Symbols
from sympy import *
from sympy.plotting import plot_parametric
import numpy as np
import scipy
import scipy.special

init_printing(use_unicode=True)

x,y,z,t,mu,nu=symbols('x y z t mu nu')
k,m,n=symbols('k m n', integer=True)
f,g,h=symbols('f g h', cls=Function)

R=S.Reals
C=S.Complexes

i=sqrt(-1)
```


```python
from matplotlib import animation, rc
from IPython.display import HTML
import matplotlib.pyplot as plt
%config InlineBackend.figure_formats = ['svg']
%matplotlib inline
```


```python
plt.rcParams['figure.autolayout'] = False
plt.rcParams['figure.figsize'] = 11, 11
```


```python
from mpmath import * 
from colorsys import hsv_to_rgb
```

## Visualizing the complex function


```python
def PerFract(x, t, m, M):
    x=x/t
    return m+(M-m)*(x-floor(x)) 

def color_clines(fz):# this is the color function that replaces the 
                     #default  color function implemented in mpmath.cplot
    if isinf(fz):
        return (0, 0, 1.0)#hsv code
    if isnan(fz):
        return (0., 0., 0.5)

    n=15#n is the number of rays drawn in a cycle
    
    h = (float(arg(fz)) + pi) / (2*pi) #hue
    h = (h - 0.5) % 1.0

    Phc=PerFract(h, 1.0/n, 0.6, 1) #  set brightness between 0.6 and 1,
                                   #in order to avoid too dark colors   
    modul=fabs(fz)
    Logm=log(modul)
    s = 0.9 #saturation
      
    Modc=PerFract(Logm, 2*pi/n, 0.6, 1)
    v=Modc*Phc 
     
    return  hsv_to_rgb(h,s, v)
```


```python
cplot(zeta, re=[-15, 15], im=[-30, 30], color=color_clines, verbose=False, points=200000, file='riemann-zeta-[-15,15]-[-30,30].svg')
```


    

    



```python
cplot(zeta, re=[-3,3], im=[-3,3], color=color_clines, verbose=False, points=200000, file='riemann-zeta-[-3,3]-[-3,3].svg')
```


    

    


A view around the trivial zeroes $s = -2n$:


```python
cplot(zeta, re=[-8.5,0.5], im=[-0.5,0.5], color=color_clines, verbose=False, points=200000, file='riemann-zeta-[-8.5,0.5]-[-0.5,0.5].svg')
```


    

    


A view around the critical strip $\operatorname{Re}(s)\in\left(0,1\right)$:


```python
cplot(zeta, re=[-0.1,1.1], im=[-3,3], color=color_clines, verbose=False, points=200000, file='riemann-zeta-[-0.1,1.1]-[-3,3].svg')
```


    

    



```python
cplot(zeta, re=[-0.1,1.1], im=[-30,30], color=color_clines, verbose=False, points=200000, file='riemann-zeta-[-0.1,1.1]-[-30,30].svg')
```


    

    


Portions of this file are derived from [https://github.com/empet/Math/blob/d9a2187faaa06db53220ef6ff16f062f9ce4f3e1/Riemann-Zeta.ipynb](https://github.com/empet/Math/blob/d9a2187faaa06db53220ef6ff16f062f9ce4f3e1/Riemann-Zeta.ipynb).  See the LICENSE file in the root of this repository for details.


```python

```

990b11e9743b1cf13357ec540b33fed891002617
ipynb
Jupyter Notebook
series/riemann-zeta.ipynb
madvay/math-explorations
b41afe57514df39125049b1af0506efddd615c0a
BSD-3-Clause
2020-07-18T03:32:43.000Z
2020-07-18T03:32:43.000Z
series/riemann-zeta.ipynb
madvay/math-explorations
b41afe57514df39125049b1af0506efddd615c0a
BSD-3-Clause
series/riemann-zeta.ipynb
madvay/math-explorations
b41afe57514df39125049b1af0506efddd615c0a
BSD-3-Clause
Qwen/Qwen-72B
1. YES
2. YES