Dirichlet L-Series

Author

Eric W. Weisstein
September 1, 2008

This notebook downloaded from http://mathworld.wolfram.com/notebooks/NumberTheoreticFunctions/DirichletL-Series.nb.

For more information, see Eric's MathWorld entry http://mathworld.wolfram.com/DirichletL-Series.html.

©2008 Wolfram Research, Inc. except for portions noted otherwise

Initialization

<<Utilities`Simplify`

Usage

?DirichletL

?PrimitiveQ

?*LSeries

Primitive Series

Select[Range[-100,100],PrimitiveQ]

Periods of Kronecker Symbol

Positive

Table[Period[Table[KroneckerSymbol[d,n],{n,2000}]],{d,20}]

Position[Equal@@@MapIndexed[{#1,#2[[1]]}&,%],True]//Flatten

Negative

Table[Period[Table[KroneckerSymbol[-d,n],{n,2000}]],{d,20}]

Position[Equal@@@MapIndexed[{#1,#2[[1]]}&,%],True]//Flatten

Special Cases

(Subscript[L, -4])(1)

(1/1)-(1/3)+(1/5)-(1/7)

Sum[(1/(4n-3))-(1/(4n-1)),{n,∞}]

LSeries[-4,1]//FunctionExpand

Total[Table[KroneckerSymbol[-4,n](n^(-1)),{n,10000}]]//N//Timing

l=Table[KroneckerSymbol[-4,n],{n,4}]

sums=MapIndexed[((#1)/(4k-4+#2[[1]]))&,l]

Sum[Evaluate[Total[DeleteCases[sums,0]]],{k,∞}]

(Subscript[L, -6])(1)

Total[Table[KroneckerSymbol[-6,n](n^(-1)),{n,10000}]]//N//Timing

l=Table[KroneckerSymbol[-6,n],{n,24}]

terms=MapIndexed[((#1)/(24k-24+#2[[1]]))&,l]

Sum[Evaluate[Total[DeleteCases[terms,0]]],{k,∞}]//FullSimplify

(Subscript[L, 5])(1)

N[Sum[KroneckerSymbol[5,n](n^(-1)),{n,1000}],10]

LSeries[5,1]//FullSimplify

N[%]

(Subscript[L, -7])(2)==(∫_(π/3)^(π/2))log(((tan(x)+(Sqrt[7]))/((Sqrt[7])-tan(x))))dx

N[LSeries[-7,2],50]

Plot[Log[Abs[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))]],{x,π/3,π/2},PlotStyle->Red]

(24/(7(Sqrt[7])))NIntegrate[Log[Abs[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))]],{x,π/3,ArcTan[(Sqrt[7])],π/2},WorkingPrecision->50,MaxRecursion->20]

(24/(7(Sqrt[7])))Integrate[Log[Abs[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))]],{x,π/3,π/2}]//Timing

Integrate[Log[((Tan[x]+(Sqrt[7]))/(-Tan[x]+(Sqrt[7])))],{x,π/3,π/2}]//Timing

(i1=Integrate[Log[((Tan[x]+(Sqrt[7]))/(-Tan[x]+(Sqrt[7])))],{x,π/3,ArcTan[(Sqrt[7])]}])//Timing

i1//N

NIntegrate[Log[((Tan[x]+(Sqrt[7]))/(-Tan[x]+(Sqrt[7])))],{x,π/3,ArcTan[(Sqrt[7])]}]

(i2=Integrate[Log[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))],{x,ArcTan[(Sqrt[7])],π/2}])//Timing

NIntegrate[Log[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))],{x,ArcTan[(Sqrt[7])],π/2}]

i2//N

(24/(7(Sqrt[7])))(i1+i2)//N

FullSimplify[(24/(7(Sqrt[7])))(i1+i2)]

PolyGamma

expr1=LSeries[-7,2]

(v1=SetPrecision[expr1,5000])//Timing

PolyLog

expr2=-(1/(7 (Sqrt[7])))(4 (9 ArcCot[(Sqrt[7])] Log[2]+(π-6 ArcCot[(Sqrt[7])]) Log[-(Sqrt[3])+(Sqrt[7])]-π Log[(Sqrt[3])+(Sqrt[7])]+3 I (PolyLog[2,((-(Sqrt[3])+(Sqrt[7]))/(-I+(Sqrt[7])))]-PolyLog[2,((-(Sqrt[3])+(Sqrt[7]))/(I+(Sqrt[7])))]-PolyLog[2,((-I+(Sqrt[7]))/((Sqrt[3])+(Sqrt[7])))]+PolyLog[2,((I+(Sqrt[7]))/((Sqrt[3])+(Sqrt[7])))])));

SetPrecision[expr2,100]//Timing

(v2=SetPrecision[expr2,5000])//Timing

NIntegrate

(v3=(24/(7(Sqrt[7])))NIntegrate[Log[Abs[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))]],{x,π/3,ArcTan[(Sqrt[7])],π/2},WorkingPrecision->200,MaxRecursion->20])//Timing

(v3=(24/(7(Sqrt[7])))NIntegrate[Log[Abs[((Tan[x]+(Sqrt[7]))/(Tan[x]-(Sqrt[7])))]],{x,π/3,ArcTan[(Sqrt[7])],π/2},WorkingPrecision->500,MaxRecursion->20])//Timing

Comparison

v1-v2

(Subscript[L, 5])(2)

N[Sum[KroneckerSymbol[5,n](n^(-2)),{n,1000}],10]

LSeries[5,2]//FullSimplify

N[%]

(Subscript[L, 5])(3)

N[Sum[KroneckerSymbol[5,n](n^(-3)),{n,2000}],10]

LSeries[5,3]//FullSimplify

N[%,10]

(Subscript[L, 5])(4)

N[Sum[KroneckerSymbol[5,n](n^(-4)),{n,2000}],10]

LSeries[5,4]//FullSimplify

N[%,10]

(Subscript[L, -4])(2)

N[Sum[KroneckerSymbol[-4,n](n^(-2)),{n,1000}],10]

LSeries[-4,2]//FullSimplify

N[%]

Primitive

(Subscript[L, d])(1)

(Subscript[L, -20])(1)

PrimitiveQ[-20]

LSeries[-20,1]

N[%]

Table[KroneckerSymbol[-20,n](n^(-1)),{n,20}]

Total[Table[KroneckerSymbol[-20,n](n^(-1)),{n,1000}]]//N

(Subscript[L, -7])(1)

PrimitiveQ[-7]

LSeries[-7,1]

N[%]

Table[KroneckerSymbol[-7,n](n^(-1)),{n,20}]

Total[Table[KroneckerSymbol[-7,n](n^(-1)),{n,1000}]]//N

(Subscript[L, 1])(1)

PrimitiveQ[1]

LSeries[1,1]

Table[KroneckerSymbol[1,n](n^(-1)),{n,20}]

Total[Table[KroneckerSymbol[1,n](n^(-1)),{n,1000}]]//N

With[{d=1,s=2},KroneckerSymbol[d,#]PolyGamma[s-1,#/Abs[d]]&/@Range[Abs[d]-1]/((-Abs[d])^s (s-1)!)
]

(π^2)/6.

Sum[KroneckerSymbol[1,n](n^(-2)),{n,∞}]//Timing

V6

Sum[KroneckerSymbol[-7,n](n^(-1)),{n,∞}]

Sum[KroneckerSymbol[-7,n](n^(-1)),{n,1000}]//N

N[π/Sqrt[7]]

LSeries[-7,1]

FullSimplify[RootReduce[FunctionExpand[%]]]

LSeries[-7,3]//FullSimplify

FullSimplify[RootReduce[FunctionExpand[%]]]

V7

Sum[KroneckerSymbol[-7,n](n^(-1)),{n,∞}]

Sum[DirichletCharacter[5,3,n](n^(-1)),{n,∞}]

{Sum[DirichletCharacter[5, 3, n]/n, {n, 1000}],2Log[GoldenRatio]/(Sqrt[5])}//N

Sum[KroneckerSymbol[5,n](n^(-1)),{n,∞}]

FunctionExpand[DirichletCharacter[5,3,n]]

FullSimplify[DirichletCharacter[5,3,n]-KroneckerSymbol[5,n],n∈Integers]

Table[DirichletCharacter[4,1,n]-KroneckerSymbol[4,n],{n,-100,100}]//Union

Table[DirichletCharacter[5,3,n]-KroneckerSymbol[5,n],{n,-100,100}]//Union

Table

Print[{#,TimeConstrained[FullSimplify[RootReduce@FunctionExpand[LSeries[#,1]]]/.(3+Sqrt[5])/2:>GoldenRatio^2//LogExpand,120]//Timing}]&/@Select[Range[-20,24],PrimitiveQ];

(Subscript[L, d])(2)

(Subscript[L, -20])(2)

LSeries[-20,2]

N[%]

Sum[KroneckerSymbol[-20,n](n^(-2)),{n,20}]//N

Sum[KroneckerSymbol[-20,n](n^(-2)),{n,∞}]

(Subscript[L, -8])(2)

LSeries[-8,2]

N[%]

FunctionExpand[FullSimplify[%90]]

(1/64) (PolyGamma[1,(1/8)]+PolyGamma[1,(3/8)]-PolyGamma[1,(5/8)]-PolyGamma[1,(7/8)])-(3*Pi^3)/(64*Sqrt[2])//N

(Subscript[L, 1])(2)

PrimitiveQ[1]

LSeries[1,2]

Table[KroneckerSymbol[1,n](n^(-2)),{n,20}]

Total[Table[KroneckerSymbol[1,n](n^(-2)),{n,1000}]]//N

With[{d=1,s=2},KroneckerSymbol[d,#]PolyGamma[s-1,#/Abs[d]]&/@Range[Abs[d]-1]/((-Abs[d])^s (s-1)!)
]

(π^2)/6.

Sum[KroneckerSymbol[1,n](n^(-2)),{n,∞}]//Timing

(Subscript[L, 13])(2)

PrimitiveQ[13]

LSeries[13,2]

FullSimplify[%]

Table[KroneckerSymbol[13,n](n^(-2)),{n,20}]

Total[Table[KroneckerSymbol[13,n](n^(-2)),{n,1000}]]//N

Table

Select[Range[-20,24],PrimitiveQ]

Print[{#,TimeConstrained[FullSimplify[RootReduce@FunctionExpand[LSeries[#,2]]]/.(3+Sqrt[5])/2:>GoldenRatio^2//LogExpand,120]//Timing}]&/@Select[Range[-20,24],PrimitiveQ];

(Subscript[L, d])(3)

Print[{#,TimeConstrained[FullSimplify[RootReduce@FunctionExpand[LSeries[#,3]]]/.(3+Sqrt[5])/2:>GoldenRatio^2//LogExpand,120]//Timing}]&/@Select[Range[-20,24],PrimitiveQ];

Fundamental Units

<<NumberTheory`NumberTheoryFunctions`

Code

Do[Print[Subscript[η,n]," = ",FundamentalUnit[n]],{n,2,100}]

Do[Print[Subscript[η,n]," = ",FundamentalUnit[n]],{n,94,200}]

Do[Print[Subscript[η,n]," = ",FundamentalUnit[n]],{n,95,102}]

d5={((2 Log[(1/2) (1+(Sqrt[5]))])/(Sqrt[5])),((Log[(1/2) (3+(Sqrt[5]))])/(Sqrt[5]))}

FullSimplify[d5.{1,-1}]

d13={2/Sqrt[13]Log[(3+Sqrt[13])/2],1/Sqrt[13]Log[(11+3Sqrt[13])/2]}

FullSimplify[d13.{1,-1}]