Fungrim entry: 3fe553

$\psi\!\left(\frac{p}{q}\right) = -\gamma - \log\!\left(2 q\right) - \frac{\pi}{2} \cot\!\left(\frac{\pi p}{q}\right) + 2 \sum_{k=1}^{\left\lfloor \left( q - 1 \right) / 2 \right\rfloor} \cos\!\left(\frac{2 \pi k p}{q}\right) \log\!\left(\sin\!\left(\frac{\pi k}{q}\right)\right)$
Assumptions:$q \in \mathbb{Z}_{\ge 2} \;\mathbin{\operatorname{and}}\; p \in \{1, 2, \ldots, q - 1\}$
TeX:
\psi\!\left(\frac{p}{q}\right) = -\gamma - \log\!\left(2 q\right) - \frac{\pi}{2} \cot\!\left(\frac{\pi p}{q}\right) + 2 \sum_{k=1}^{\left\lfloor \left( q - 1 \right) / 2 \right\rfloor} \cos\!\left(\frac{2 \pi k p}{q}\right) \log\!\left(\sin\!\left(\frac{\pi k}{q}\right)\right)

q \in \mathbb{Z}_{\ge 2} \;\mathbin{\operatorname{and}}\; p \in \{1, 2, \ldots, q - 1\}
Definitions:
Fungrim symbol Notation Short description
DigammaFunction$\psi\!\left(z\right)$ Digamma function
ConstGamma$\gamma$ The constant gamma (0.577...)
Log$\log(z)$ Natural logarithm
Pi$\pi$ The constant pi (3.14...)
Sum$\sum_{n} f(n)$ Sum
Cos$\cos(z)$ Cosine
Sin$\sin(z)$ Sine
ZZGreaterEqual$\mathbb{Z}_{\ge n}$ Integers greater than or equal to n
Range$\{a, a + 1, \ldots, b\}$ Integers between given endpoints
Source code for this entry:
Entry(ID("3fe553"),
Formula(Equal(DigammaFunction(Div(p, q)), Add(Sub(Sub(Neg(ConstGamma), Log(Mul(2, q))), Mul(Div(Pi, 2), Cot(Div(Mul(Pi, p), q)))), Mul(2, Sum(Mul(Cos(Div(Mul(Mul(Mul(2, Pi), k), p), q)), Log(Sin(Div(Mul(Pi, k), q)))), For(k, 1, Floor(Div(Sub(q, 1), 2)))))))),
Variables(p, q),
Assumptions(And(Element(q, ZZGreaterEqual(2)), Element(p, Range(1, Sub(q, 1))))))

Topics using this entry

Copyright (C) Fredrik Johansson and contributors. Fungrim is provided under the MIT license. The source code is on GitHub.

2021-03-15 19:12:00.328586 UTC