\documentclass{article}
\usepackage{amssymb,amsmath, amsthm}
\usepackage[english]{babel}
%\usepackage{color}

\newtheorem{theorem}{Theorem}
\newtheorem{conjecture}{Conjecture}
\newtheorem{corollary}{Corollary}
\newtheorem{proposition}{Proposition}
\newtheorem{lemma}{Lemma}
\newtheorem{definition}{Definition}
\newcommand{\Z}{\mathbb Z}
\newcommand{\Q}{\mathbb Q}
\newcommand{\R}{\mathbb R}
\newcommand{\Co}{\mathbb C}
\DeclareMathOperator{\Li}{Li}
\DeclareMathOperator{\Proj}{{\mathbb P}^1(\R)}
\DeclareMathOperator{\V}{\mathcal V}
\DeclareMathOperator{\W}{\mathcal W}
\DeclareMathOperator{\HH}{\mathcal H}
\DeclareMathOperator{\OO}{ O}
\DeclareMathOperator{\z}{\zeta}

\DeclareMathOperator{\A}{\mathcal A}
\DeclareMathOperator{\B}{\mathcal B}
\DeclareMathOperator{\F}{\mathcal F}
\DeclareMathOperator{\D}{{\mathcal D}}
\DeclareMathOperator{\LL}{{\mathcal L}}
\DeclareMathOperator{\PP}{\mathcal P}

\DeclareMathOperator{\Img}{Im}
\DeclareMathOperator{\Rea}{Re}
\DeclareMathOperator{\Ker}{Ker}
\DeclareMathOperator{\sign}{sign}
\DeclareMathOperator{\Red}{Red}
\DeclareMathOperator{\Redw}{Red_{w}}

\DeclareMathOperator{\From}{\leftarrow}
\def\sump{\sideset{}{'}\sum}
\def\sums{\sideset{}{^*}\sum}

\def\be{\begin{equation}}
\def\ee{\end{equation}}
\def\lb{\label}

\def\bal{\begin{aligned}}
\def\eal{\end{aligned}}

\def\={\;=\;}
\def\+{\,+\,}
\def\-{\,-\,}
\def\SL{{\rm SL}}
\def\GL{{\rm GL}}
\def\PSL{{\rm PSL}}
\def\PGL{{\rm PGL}}

%\DeclareMathOperator{\partx}{\frac {\partial}{\partial x}}
%\DeclareMathOperator{\party}{\frac {\partial}{\partial y}}
%\DeclareMathOperator{\partt}{\frac {\partial}{\partial t}}
\def\partx{\frac {\partial}{\partial x}}
\def\party{\frac {\partial}{\partial y}}
\def\partt{\frac {\partial}{\partial t}}
\newcommand{\partz}{\frac{\partial}{\partial z}}
\newcommand{\partzc}{\frac{\partial}{\partial \bar z}}

\title{Higher Kronecker ``limit" formulas for real quadratic fields}
\author{Maria Vlasenko, Don Zagier}

\begin{document}
\maketitle
\abstract{For every integer $k \ge 2$ we introduce an analytic
function of a positive real variable and give a universal formula
expressing the values $\zeta(\B, k)$ of the zeta functions of narrow
ideal classes in real quadratic fields in terms of this function and its
derivatives up to order $k-1$ evaluated at reduced real quadratic
irrationalities associated to $\B$. We show that our functions satisfy
functional equations and use these to deduce explicit formulas for
the rational numbers $\zeta(\B, 1-k)$. We also give an interpretation
of our formula for $\zeta(\B,k)$ in terms of cohomology groups of
$\text{SL}(2,\Z)$ with analytic coefficients, describe a ``twisted"
extension of the main formula that allows one to treat zeta values of
zeta functions of ray classes rather than just ideal classes.
Finally, we use our formulas to compute some zeta-values
numerically and test that they are expressible as combinations of
higher polylogarithm functons evaluated at algebraic arguments.

MSC classes: 11R42,20G10,11G55,19F27
}

%11R42    	Zeta functions and $L$-functions of number fields
%20G10    	Cohomology theory
%11G55    	Polylogarithms and relations with $K$-theory
%19F27    	Etale cohomology, higher regulators, zeta and $L$-functions


\section*{Introduction}

Let $K=\Q(\sqrt{D})$ be a real quadratic field of discriminant $D$ and $\B \in Cl^+(K)$ be a narrow ideal class.
 The $\zeta$-function of $\B$ is defined for $\Rea (s) > 1$ as
\[
\zeta(\B, s) = \sum_{\frak a \in \B} \frac 1{N(\frak a)^s},
\]
where the summation is over all integral ideals in the class $\B$. This function can be continued to a meromorphic
function on the whole of $\Co$ with its only singularity at $s=1$, where it has a simple pole with residue
$D^{- \frac 1 2} \log(\varepsilon)$. Here $\varepsilon$ is the smallest totally positive unit of $K$ with the
property $\varepsilon > 1$. The Kronecker limit formula (hereafter abbreviated as KLF) for real quadratic fields
is an expression for the 0th Laurent coefficient of $\zeta(\B, s)$ at $s=1$. (The original KLF, of course, was for
imaginary quadratic fields.)  Such a formula was given in~\cite{Zagier}: there is an analytic function $P(x,y)$ of $x>y>0$
such that for all narrow ideal classes in all real quadratic fields
\begin{equation}\label{Kronecker_limit_formula}
\lim_{s \to 1} \left( D^{s/2} \zeta(\B, s) - \frac{\log(\varepsilon)}{s-1} \right) = \sum_{w \in \Red(\B)} P(w, w').
\end{equation}
Here $\Red(\B)$ is the set of larger roots $w=\frac{-B+\sqrt{D}}{2A}$ of all reduced quadratic forms $Q(X,Y) = A X^2 + B XY + C Y^2$
($A, C > 0$, $A + B + C < 0$) of discriminant $D$ which belong to the class $\B$. Recall that narrow ideal classes
correspond to $\PSL(2,\Z)$-orbits on the set of integer quadratic forms: if $\frak b = \Z w_1 + \Z w_2 \in \B$
with $\frac{w_1 w_2' - w_2 w_1'}{\sqrt{D}} > 0$, then the quadratic form $Q(X,Y) = \frac{N(X w_1 + Y w_2)}{N(\frak b)}$ is in the corresponding
orbit. The set $\Red(\B)$ is obviously finite and every $w \in \Red(\B)$ satisfies $w > 1$, $1 > w' > 0$. Sometimes we
identify $\Red(\B)$ with the set of reduced forms themselves and write $Q \in \Red(\B)$ for such a form. We denote
$l(\B) = \# \Red(\B)$ in the sequel.

The function $P(x,y)$ mentioned above is defined as
\[
P(x,y)=\F(x)-\F(y)+\Li_2\Bigl(\frac yx\Bigr) - \frac{\pi^2}6 + \Bigl(\log\frac xy\Bigr)\Bigl(\gamma-\frac 12 \log(x-y) + \frac 14 \log\frac xy\Bigr)\,,
\]
where $\gamma$ is Euler's constant, $\Li_2(z)= \sum\limits_{n=1}^\infty \dfrac {z^n}{n^2}$ ($|z|<1$) is the dilogarithm function, and
\be\lb{Fx}
\F(x) = \sum\limits_{p=1}^\infty \dfrac{\psi(p x)-\log(p x)}p \;,
\ee
with $\psi(x)=\Gamma'(x)/\Gamma(x)$ (digamma function). The sum defining $\F$ converges since $\psi(x)=\log x+\OO(1/x)$
as $x\to\infty$, and defines an analytic function on $\R_{+}$ that satisfies the functional equations
\be\lb{FE}
\begin{aligned} \F(x)+\F\left( \frac1x \right)
 &=-\frac{\pi^2}6 \left(x+\frac1x\right)+\frac12 \log^2x +C \;, \\
\F(x) - \F(x-1)+\F\left(\frac{x-1}x\right)
 &=-\text{Li}_2\left(\frac1x\right)-\frac{\pi^2}6+\frac 12 \; C \;\;\;\;\; (x>1),
\end{aligned}
\ee
with the real constant $C \approx 1.45738783\cdots$ given explicitly in terms of the derivative of $\zeta(s)-(s-1)^{-1}$
at $s=1$. In~\cite{Zagier} these functional equations were used to deduce Meyer's theorem from the Kronecker limit
formula~\eqref{Kronecker_limit_formula}, namely
\be\lb{Meyer}
\lim_{s \to 1} \bigl(\zeta(\B, s) - \zeta(\B^*, s) \bigr) = \frac {\zeta(2)}{\sqrt D}\,\bigl(l(\B)-l(\B^*)\bigr)\,,
\ee
where $\B^*$ is the class of any ideal $\alpha \frak b$ with any $\frak b \in \B$ and $\alpha \in K$, $\alpha \alpha' < 0$.

In the present paper we generalize formulas~\eqref{Kronecker_limit_formula} and \eqref{Meyer} to the higher zeta values $\zeta(\B, 2), \zeta(\B, 3), \dots$.  We begin by generalizing the function~\eqref{Fx}.

\begin{definition} For every integer $k>2$ and real number $x>0$ let
\be \label{F_def} \F_k(x) \= \sum\limits_{p=1}^\infty \frac{\psi(px)}{p^{k-1}}\;. \ee
\end{definition}

Here we do not need to subtract $\log(px)$ from $\psi(px)$ since the
estimate $\psi(x)=\OO(\log x)$ suffices for (absolute) convergence, and
the functions $\F_k$ are analytic on $\R_{+}$. They already occurred  incidentally
in~\cite{ZagierKyoto}. We also introduce a collection of differential operators $\D_n$ ($n=0,\,1,\,2,\dots$) that turn
differentiable functions of one variable into differentiable functions of two variables:
\[\bal (\D_0\!F)(x,y) &\= F(x)-F(y) \\
 (\D_1\!F)(x,y) &\= F'(x)+F'(y)\- 2 \, \frac{F(x)-F(y)}{x-y}\\
 (\D_2\!F)(x,y) &\= \frac{F^{(2)}(x)-F^{(2)}(y)}2 \- 3\,\frac{F'(x)+F'(y)}{x-y} \+ 6\,\frac{F(x)-F(y)}{(x-y)^2} \\
 &\quad \vdots \eal\]
% \[ (\D_0  F)(x,y) \= F(x)-F(y)\,, \]
% \[ (\D_1 F)(x,y) \= F'(x)+F'(y)\- 2 \, \frac{F(x)-F(y)}{x-y}\,,\]
% \[ (\D_2 F)(x,y)\= \frac{F^{(2)}(x)-F^{(2)}(y)}2 \- 3\,\frac{F'(x)+F'(y)}{x-y} \+ 6\,\frac{F(x)-F(y)}{(x-y)^2}\;,\]
% \[ \vdots \]
where the coefficients, given explicitly in Definition~\ref{diff_op} below, are chosen so that $\D_n$ kills polynomials of degree $\le 2n$ and sends $F(x)=x^{2n+1}$ to $(x-y)^{n+1}$. Then we have

\begin{theorem}\label{higher_formula} For any narrow ideal class $\B \in Cl^+(K)$ and integer $k \ge 2$, 
\be
D^{k/2}\,\zeta(\B, k) \=  \sum_{w \in \Red(\B)} P_k(w, w')
\ee
where $P_k(x,y)$ is the function of two variables $x,y > 0$ defined by
\be \lb{P_k}
P_k(x,y) = \bigl(\D_{k-1} \F_{2k}\bigr)  (x, y) \;.
\ee
\end{theorem}


We call this formula the higher Kronecker ``limit" formula because it has a form similar to~\eqref{Kronecker_limit_formula}.
The reason for the quotes is that for $k \ge 2$ no limit is involved, since the series defining $\zeta(\B, k)$ converges.

\bigskip

For any differentiable function $F$ on $\R$ one can also consider the two-variable function $\D_nF$ as a homogeneous
function of degree $-n-1$ on the space $\mathcal Q^+$ of real quadratic forms with positive discriminant by setting
\be \label{DnFQ}
 (\D_n\!F)(Q) \= D^{-\frac{n+1}2}\,(\D_n\!F) \biggl(\frac{-B +\sqrt D}{2 A},\,\frac{-B-\sqrt D}{2A}\biggr)
\ee
for $Q(X,Y)=AX^2+BXY+CY^2$ with $B^2-4AC=D>0$. (This is defined whenever $F$ is smooth near the roots of $Q$.) Here $\sqrt D$
denotes the positive square root and $D^{-(n+1)/2}$ is defined as $(\sqrt D)^{-n-1}$, but because $\D_nF$ is $(-1)^{n+1}$-symmetric
the right-hand side of (\ref{DnFQ}) is actually independent of the choice of square root. By Proposition~\ref{diff_operator_properties}
below we have the equivariance property
 $$\D_n\bigl(F\big|_{-2n}g\bigr)(Q)\=(\det g)^{2n+1}\,(\D_nF)(Q\circ g)\qquad\Bigl(\,\forall\;g \in \GL(2,\R)\,\Bigr),$$
where $|_w$ for $w\in\Z$ is  defined as usual by
$\bigl(F|_w\,\bigl(\begin{smallmatrix} a&b\\c&d\end{smallmatrix}\bigr)\bigr)(x)=(cx+d)^{-w}\,F\bigl(\frac{ax+b}{cx+d}\bigr)$.
With this notation, Theorem~\ref{higher_formula} can be rewritten in the form
\[
\zeta(\B,k) \= \sum_{Q\in\Red(\B)}\bigl(\D_{k-1}\F_{2k}\bigr)(Q)\;.
\]

\bigskip
\begin{center} \line(1,0){100} \end{center}
\bigskip

In the first part of the paper we prove Theorem~\ref{higher_formula} and study the functions $\F_k$. In particular
we show that they (and their derivatives) can be computed easily to high accuracy and satisfy functional equations analogous to~\eqref{FE}.
These functional equations turn out to be sufficient to deduce from our higher KLF explicit formulas, analogous to~\eqref{Meyer}, for the
numbers $\,\z(\B,k)+(-1)^k\z(\B^*,k)\in\pi^{2k}D^{-1/2}\Q$, or
equivalently, if one uses the functional equations for $\z(\B,s)\pm\z(\B^*,s)$, for the numbers $\z(\B,1-k)\in\Q$, where the rationality statement is the well-known theorem of Klingen and Siegel. One of the formulas we obtain was already proved in~\cite{ZagierAsterisque}.

The second part of the paper is devoted to the interpretation of the higher KLF in terms of (co)homology of $\PSL(2,\Z)$. We
construct a cocycle class $[\phi_k] \in H^1(\PSL(2,\Z), \V_{2k})$ with coefficients in the space
$\V_{2k}$ of continuous functions of weight $2k$ on the projective real line and use the functional
equations satisfied by $\F_{2k}$ to show (Theorem~\ref{gen_eisenstein_cocyle}) that $[\phi_k]$ has rational image
\[
\mathfrak I ([\phi_k])\;\in\;H^1(\PSL(2,\Z), \pi^{2k} V_{2k-2}(\Q))
\]
under the integral map $\mathfrak I : f \mapsto \int f(x) (X-x)^{2k-2} dx$ from $\V_{2k}$ to the space
$V_{2k-2}$ of real polynomials of degree $\le 2k-2$. These $[\phi_k]$ and $\mathfrak I ([\phi_k])$ turn
out to be the two periods of the nonholomorphic Eisenstein series according to the definition given in~\cite{LewisZagier, BruggemanLewisZagier}. The class $\mathfrak I ([\phi_k])$ itself is the well known Eisenstein cohomology class studied e.g. in~\cite{Sczech2} and for the general linear group of degree $n$ in~\cite{Nori,Sczech}. That is why we call our $[\phi_k]$ the generalized Eisenstein cocycle class. Further, for each narrow ideal
class $\B$ we define a cycle class $\eta_{\B} \in H_1(\PSL(2, \Z), \V_{2-2k})$ and show that evaluating
$[\phi_k]$ on it gives the value $\zeta(\B, k)$ (Theorem~\ref{homological_zeta_value}). Then the rationality
of $\mathfrak I ([\phi_k])$ implies the Siegel-Klingen theorem again.

In the third part of our paper we consider the twisted version of our functions $\F^{\chi}_{k}$ for a Dirichlet
character $\chi$ and $k \ge 2$. Such twisted functions can be used to compute zeta values
for ray classes. We should mention that a KLF was given for ray classes in real quadratic fields in
full generality by Yamamoto~\cite{Yamamoto}, but even for this case ($k=1$) our formulas are different.
We do not present everything in
 complete detail but consider a particular example, where we compute Stark's unit and  its ``higher''
version (for $k=2$), which involves dilogarithms instead of logarithms.

\bigskip
\begin{center} \line(1,0){100} \end{center}
\bigskip

We mention that there are similar ``higher Kronecker limit formulas" also for imaginary quadratic fields. Let $K$ be an imaginary 
quadratic field of discriminant $D<-4$ and $\B$ an ideal class of $K$.  Then $\z(\B, s) = |D/4|^{-s/2} E\big(w, s \big)$, where $w$ is the root in the upper half-plane of any quadratic form of discriminant $D$ in the $\rm PSL(2,\Z)$-orbit corresponding to $\B$ and
\be\lb{nhe}
E(z, s) = \frac 12 \, \sump_{m,n \in \Z} \frac {y^s}{|m z + n|^{2s}} \qquad (z=x+i y \in \frak H)
\ee 
is the non-holomorphic Eisenstein series. For $k \in \Z_{\ge 2}$ we have
\[
E(z, k) = (2 i)^{-k} \,\bigl(\D_{k-1} \mathcal C_{2k}\bigr)(z,\bar z)
\]
where $\D_{k-1}$ is the same differential operator as in Theorem~\ref{higher_formula} and
\[
\mathcal C_{h}(z) = \z(h) z^{h-1} - \pi \sum_{p=1}^{\infty} \frac{\cot(\pi p z)}{p^{h-1}} \qquad \bigl(z \in \Co \smallsetminus \R\bigr) \, .
\]
Therefore $|D/4|^{k/2} \z(\B,k) = \D_{k-1} \mathcal C_{2k} \bigl(w, \overline{w}\bigr)$. The relation between $\mathcal C_h$ and $\F_h$ (which is  defined in all of $\Co \smallsetminus (-\infty;0]$ by the sum~\eqref{F_def}) is simply
\[
\F_h(z) - \F_h(-z) = \z(h) \big( z^{h-1} + 1/z \big) - \mathcal C_h(z) \, .
\]
(This is an immediate consequence of $\psi(x)-\psi(-x) = \pi \cot(\pi x) + x^{-1}$.) The reason that the real quadratic case is more complicated 
than the imaginary quadratic case is that there one has to work with 
``half-Eisenstein series,'' i.e. sums over lattice points in a quadrant rather than a whole lattice. This is discussed in \S 2.

\section{The functions $\F_k$ and zeta values}

\subsection{Properties of the functions $\F_k$}

We begin by giving the expansions of the functions $\F_k(x)$ defined in~\eqref{F_def} near $x = \infty$, $0$ and~$1$. The result will
involve the double zeta values
\[
\z(m,n) \= \sum \limits_{p>q>0} \frac 1{p^m q^n}, \;\;\;\; (m \ge 2, n \ge 1).
\]
They satisfy the well known shuffle relations
\begin{equation}\label{shuffle_2}\bal
&\qquad \z(m,k-m)\,+\,\z(k-m,m) \= \z(m)\z(k-m)-\z(k), \\
&\sum_{n=1}^{k-1} \biggl( \binom{n-1}{m-1}\+\binom{n-1}{k-m-1} 
\biggr)\z(n,k-n) \= \z(m)\z(k-m) \eal
\end{equation}
for each $m=1,\dots,k-1$. Here and everywhere below the divergent values $\zeta(1)$ and $\zeta(1,k-1)$
are to be interpreted as $\gamma$ (Euler's constant) and $\zeta(k-1,1)+\zeta(k)-\gamma \zeta(k-1)$ respectively.
We denote by $B_n$ the $n$th Bernoulli number, defined by the expansion
$\dfrac x{e^x - 1} = \sum \limits_{n=0}^{\infty} B_n \dfrac {x^n}{n!}$,
or alternatively by $B_0=1$ and $B_n=(-1)^{n-1}n\z(1-n)$ for $n\ge1$.

\begin{proposition}\label{asymp_exp} The function $\F_k(x)$ has the asymptotic expansions\footnote{By
an asymptotic expansion $f(x) \sim \sum \limits_{n=n_0}^{\infty} a_n (x-a)^n$ as $x \to a$ we mean that
$f(x) - \sum \limits_{n=n_0}^{N-1} a_n (x-a)^n = \OO((x-a)^N)$ when $x \to a$ for every $N$. (We do not require that the series be convergent in any neighborhood of $a$.) For $a=\infty$ one replaces $x-a$ by $1/x$.}
\[
\F_k(x) \; \sim \; \z(k-1) \log x \- \z'(k-1) \+ \sum_{r=1}^{\infty} \frac{\z(1-r) \z(k+r-1)}{x^r}
\]
as $x \to \infty$,
\[
\F_k(x) \; \sim \, \-\frac{\z(k)}x  \+ \sum \limits_{r=1, r \ne k-1}^\infty (-1)^r \z(r) \z(k-r) x^{r-1}
\]
\[
\qquad\qquad \+ (-1)^{k-1} \bigl[\z(k-1) (\gamma - \log x) \- \z'(k-1)\bigr] x^{k-2}
\]
as $x \to 0$, and
$$ \bal \F_k(x) \;&\sim \; - \sum_{r=1}^{k-1} \bigl[\z(r,k-r)+\z(k)\bigr] (1-x)^{r-1} \\
& \qquad\- \sum_{r=k}^{\infty} \biggl[ \frac 1{r-k+1} \sum_{l=0}^{r-k} (-1)^l \binom{r-k+1} l B_l \z(k+l-1) \biggr] (1-x)^{r-1} \eal$$
as $x \to 1$.
\end{proposition}
\begin{proof}
The standard asymptotic expansion of the digamma function at infinity, 
\[
\psi(x) \sim \log x + \sum \limits_{r=1}^{\infty} \frac{\zeta(1-r)}{x^r} \qquad (x \to \infty)
\]
(the derivative of Stirling's formula), immediately gives the first asymptotic expansion for $\F_k$.
For the second, we use the expansion
\[
\psi(x) \= -\frac 1x - \gamma + \sum \limits_{r=2}^{\infty} (-1)^r \zeta(r) x^{r-1} \qquad (0 < x < 1)
\]
and apply the Euler-Maclaurin summation formula following the method explained in detail in~\cite{ZagierAppendix}
(see Proposition 6.5 of~\cite{ZagierAppendix} and the second remark after it). When $x \to 1$ we use the
recursion $\psi(x+1)=\psi(x)+x^{-1}$ and the expansion of $\psi$ near 0 again.
\end{proof}


\begin{proposition}\label{func_eq_thm}
The function $\F_k(x)$ satisfies the two functional equations
\be\label{func_eq_1}
\F_k(x) + (-x)^{k-2} \F_k\Bigl( \frac1x \Bigr)
\= A_k(x) + \zeta(k) \Bigl((-x)^{k-1} - \frac 1x \Bigr)\,
\ee
and
\begin{equation}\label{func_eq_2}
\F_k(x) - \F_k(x+1) + (-x)^{k-2} \F_k\Bigl(\frac{x+1}x \Bigr) = B_k(x) + \zeta(k)\Bigl( \frac {(-x)^{k-1}}{x+1} - \frac 1x \Bigr)\,.
\end{equation}
where $A_k(x)$ and $B_k(x)$ are the polynomials of degree $k - 2$ given by
\[
A_k(x) \= - \sum_{r=1}^{k-1} \zeta(r) \zeta(k-r) (-x)^{r-1},\quad\;
B_k(x) \= - \sum_{r=1}^{k-1} \zeta(k-r,r) (-x)^{r-1}\;.
\]
and related by
\be\label{BA}\bal
B_k(x) + (-x)^{k-2}B_k\Bigl( \frac1x \Bigr)
&\= A_k(x) + \zeta(k) \Bigl((-x)^{k-1} - \frac 1x \Bigr)\;,\\
B_k(x) + B_k(x+1) &\= (-x)^{k-2} A_k \left( \frac{x+1}x \right)\;.
\eal\ee
\end{proposition}


\begin{proof} From $\psi(x)=\sum \limits _{q=0}^{\infty} \Bigl(\dfrac1{1+q}-\dfrac1{x+q} \Bigr)$ we get
$\dfrac{(-1)^k}{(k-1)!} \psi^{(k-1)}(x) =  \sum \limits _{q=0}^{\infty} \dfrac1{(x+q)^k}$ and hence
\[
\frac{(-1)^k}{(k-1)!} \F_k^{(k-1)}(x) \=  \sum_{p \ge 1,\;q \ge 0} \frac 1{(px + q)^k}\;.
\]
From this we find that
\[
\dfrac{(-1)^k}{(k-1)!} \Bigl( \F_k^{(k-1)}(x) - \frac 1{x^k} \F_k^{(k-1)} \bigl(\dfrac1x\bigr) \Bigr)
\]
\[
\= \Bigl( \sum_{p>0,\;q\ge0} - \sum_{p\ge0,\;q>0} \Bigr) \frac1{(p x+q)^k} \= \zeta(k)\Bigl( \frac 1{x^k}-1 \Bigr)
\]
and
$$ \bal
& \frac{(-1)^k}{(k-1)!} \Bigl(\F_k^{(k-1)}(x) - \F_k^{(k-1)}(x+1) - \frac 1{x^k} \F_k^{(k-1)} \Bigl(\frac{x+1}{x}\Bigr) \Bigr) \\
& \= \Bigl(\,\sum_{p>0,\;q\ge0} - \sum_{q\ge p > 0} - \sum_{p \ge q > 0}\,\Bigr)\,\frac1{(p x+q)^k}
\= \z(k) \Bigl(\frac 1{x^k} - \frac 1{(x+1)^k}\Bigr)\,.
\eal $$
Integrating these equations $k-1$ times\footnote{Here we use Bol's identity to write $x^{-k}\F_k^{(k-1)}(c+1/x)$ as
$(-d/dx)^{k-1}\bigl(x^{k-2}\F_k(c+1/x)\bigr)\,.$} we obtain formulas~\eqref{func_eq_1} and \eqref{func_eq_2} for {\it some} polynomials $A_k$ 
and $B_k$ of degree $k-2$, whose coefficients are then determined by the asymptotic expansions given in Proposition~\ref{asymp_exp}.
The relations~\eqref{BA} between $B_k$ and $A_k$ are equivalent to the
shuffle relations~\eqref{shuffle_2}, and also follow easily from equations~\eqref{func_eq_1},~~\eqref{func_eq_2} and~\eqref{func_eq_1} with $x$ replaced by~$1/x$.
\end{proof}

Finally, we would like to mention that, although the series in~\eqref{F_def} converges only polynomially quickly, we can compute
values of the function $\F_k(x)$ (or its derivatives) to high accuracy with little effort. To this end, for integers $M, N\ge 1$
we define
\[ \bal
\F_{k,N,M}(x)&\= \sum_{p=1}^N\frac{\psi(px)-\log(px)}{p^{k-1}} 
\,-\,\z'(k-2)\,+\,\z(k-1)\,\log x\\
&\qquad\+ \sum_{m=1}^M\frac{\zeta(1-m)}{x^m}\biggl(\z(k+m-1)\-\sum_{p=1}^N\frac 1{p^{k+m-1}}\biggr)\;, \eal
\]
which can be computed in time $\OO(MN)$, the calculation of the digamma and zeta functions being standard. Then
\[
\Big|\F_k(x) - \F_{k,N,M}(x)\Big| \= \Bigg|\sum_{p=N+1}^{\infty} \frac 1{p^{k-1}}
\biggl(\psi(px)\-\log(px)\-\sum_{m=1}^M\frac{\z(1-m)}{(px)^m}\biggr)\Bigg|
\]
\[
\le  \sum \limits_{p=N+1}^\infty \frac 1{p^{k-1}} \frac {C_M}{(px)^{M+1}}\;<\;\frac { (k+M-1)\, C_M} {x^{M+1} \; N^{k+M-1}}
\]
with $C_M = |\z(1-M)| = \OO \left( M^{-\frac 12} (\frac M{2 \pi e})^M \right)$ by Stirling's formula. From this we
find that for a given time $T = M N$ the best accuracy is $\OO \bigl(T^{\frac 54 -\frac k2}\,e^{- \sqrt{8\pi xT/e}}\bigr)$,
achieved by choosing $e M \approx 2 \pi x N$.


\subsection{The functions $\F_k$ and polylogarithms}

For $m, n \ge 1$ consider the function of $x > 0$
\begin{equation}\label{polylog_int}
F_{m,n}(x)= (-x)^n \int_0^{\infty} \Li_m(e^{-x t})\,\Li_n(e^{-t})\,dt\;,
\end{equation}
where $\Li_m(x)=\sum_{n=1}^\infty x^n/n^m$ is the $m$th polylogarithm
function. Integrating by parts and using $x\Li_m'(x)=\Li_{m-1}(x)$, we obtain
\[
F_{m+1,n}(x) = - (-x)^n \int_0^{\infty} \Li_{m+1}(e^{-x t}) \; d \Li_{n+1}(e^{-t})
\]
\[
\= (-x)^n \z(m+1) \, \z(n+1) \+ F_{m, n+1}(x)\;.
\]
Hence if one fixes the sum $m+n$ then there is essentially one such function up to a polynomial. Let us set for $k \ge 3$
\[
F_k(x) \= F_{k-2,1}(x)\;.
\]
Then $F_{m,n}(x) = F_k(x) - \sum_{r=2}^{n} \z(r)\z(k-r) (-x)^{r-1}$ with $k=m+n+1$. Substituting $t \to \frac t x$
in the integral~(\ref{polylog_int}) we get the equality
\[
F_{m,n}(x) + (-x)^{n+m-1} F_{n,m}\Bigl(\frac 1 x \Big) \= 0\;.
\]
Expressing $F_{m,n}$ and $F_{n,m}$ in terms of the function $F_k$ yields
\begin{equation}\label{func_eq_1_again}
F_k(x) \+ (-x)^{k-2} F_k\Bigl(\frac 1 x \Bigr) \= \sum_{r=2}^{k-2} \z(r)\,\z(k-r)\,(-x)^{r-1}.
\end{equation}
This functional equation is very similar to~\eqref{func_eq_1}. And indeed, $F_k$ is the same as our old $\F_k$ up to sign and the addition of simple functions:
\begin{proposition}\label{F_k_polylog} For $k > 2$ one has
\[
F_k(x) \= -\F_k(x) \- \gamma\z(k-1) \- \frac{\z(k)}x\;.
\]
\end{proposition}
\begin{proof} From $\psi(x)=\int_0^{\infty}\bigl(\frac{e^{-t}}t - \frac{e^{-x t}}{1-e^{-t}}\bigr)\,dt$ and
$\gamma = \int_0^{\infty}\bigl(\frac1{1-e^{-t}}\-\frac 1t\bigr) e^{-t}\,dt$ (\cite{WW}) we get
$\psi(x)+\gamma+\frac 1x = \psi(x+1)+\gamma = \int_0^{\infty} \frac{1-e^{-x t}}{e^t-1}\,dt = -\int_0^\infty\bigl(1-e^{-xt}\bigr)\,d \Li_1(e^{-t})$.
Therefore
 $$ x\int_0^{\infty} e^{-xt} \Li_1(e^{-t}) dt = \psi(x)+\gamma+\frac 1x\,, $$
so $F_k(x)= -x \int\limits_0^{\infty} \sum\limits_{p=1}^{\infty} \frac{e^{-xtp}}{p^{k-2}} \Li_1(e^{-t}) dt
= -\sum\limits_{p=1}^{\infty} \frac{\psi(px)}{p^{k-1}}-\gamma \z(k-1) - \frac{\z(k)}x$.
\end{proof}

This proposition together with~\eqref{func_eq_1_again} gives an alternative proof of~\eqref{func_eq_1}. Let us also
sketch a similar proof of the second functional equation~\eqref{func_eq_2}. The double polylogarithm functions
(\cite{Goncharov,GanglGoncharovLevin}) are defined for $|z_i| < 1$ by the series
\[
\Li_{m,n}(z_1, z_2) \= \sum_{0<p<q} \frac{z_1^p}{p^m} \frac {z_2^q}{q^n}.
\]
Let us consider again for $m, n \ge 1$ and $x>-1$
\[
G_{m,n}(x) \= (-x)^n \int_0^{\infty} \Li_{m,n}(e^{-x t}, e^{-t})\,dt\;.
\]
This integral is also convergent for $m=0$ and $n \ge 2$. Integrating for $m \ge 0$, $n \ge 1$ the equality
\[
\frac {d}{dt} \Li_{m+1,n+1}(e^{-x t}, e^{-t}) \= - x \Li_{m, n+1}(e^{-x t}, e^{-t}) - \Li_{m+1, n}(e^{-x t}, e^{-t})
\]
we get the relation
\[
G_{m+1,n}(x) \= (-x)^n \z(n+1, m+1)\ + G_{m, n+1}(x).
\]
So, there is one such function $G_{m,n}$ up to a polynomial for a fixed sum $m+n$. We claim this function is again
$F_{m+n+1}$. Let $k = m+n+1$. Careful integration (paying attention to the singularity at $t=0$) of the equality
\[
\Li_{k-1,0}(e^{- x t}, e^{-t}) = \Li_{k-1}(e^{- (x+1) t}) \Li_0(e^{-t})
\]
yields $G_{k-2,1}(x) = F_{k}(x+1)+\z(k-1,1)+\z(k)$. Hence $G_{m,n}(x)=F_k(x+1)$ $+\gamma\z(k-1)-\sum_{r=1}^{n}\z(r,k-r)(-x)^{r-1}\,$.
Now expressing everything in the equality
\[\bal
 F_{m,n}(x) &\= \sum_{p,q \ge 1} (-x)^n \int_0^{\infty} \frac{e^{-t(p x + q)}}{p^m \; q^n} dt = \sum_{p<q} \;+\; \sum_{q<p} \;+\; \sum_{p=q} \\
 &\= G_{m,n}(x) \- (-x)^{m+n-1} G_{n,m}\left(\frac 1x\right) \+ \zeta(m+n+1) \frac{(-x)^n}{x+1}
\eal\]
in terms of $F_k$ gives the functional  equation
\[\bal & F_k(x) \- F_k(x+1) \+ (-x)^{k-2} F_k \Bigl( \frac{x+1}x \Bigr) \\
 &\qquad\= \sum_{r=1}^{k-1} \z(k-r, r) (-x)^{r-1} \+ \frac {\z(k)}{x+1} \- \gamma \z(k-1) (-x)^{k-2}\;,
\eal \]
which, together with Proposition~\ref{F_k_polylog}, yields~\eqref{func_eq_2}.


\subsection{The differential operator $\D_n$}


\begin{definition}\label{diff_op}
Let $\D_n$ for every integer $n \ge 0$ be the differential operator from functions of one variable to functions of two variables defined by
\[
(\D_n F)(x,y) \=\sum_{i=0}^{n} \binom{2n-i}n\,\dfrac{F^{(i)}(x) \- (-1)^i F^{(i)}(y)}{i!\;(y-x)^{n-i}}\;.
\]
\end{definition}

This can be written as $\left( \D_n F \right) (x,y) = (\D_n^+ F) (x,y) + (-1)^{n+1} (\D_n^+ F) (y,x)$, where
\be \label{Dn+}
(\D_n^+ F)(x,y) \= \sum_{i=0}^{n} \binom{2n-i}n\,\dfrac{F^{(i)}(x)}{i!\;(y-x)^{n-i}} \;.
\ee
(The operator $\D_n^+$ will be also used later in the paper.) However,
note that, unlike $\D_nF$, the function $\D_n^+F$ is not differentiable,
because it has an $n$th order pole along the diagonal $x=y$, whereas,
as we shall see, $(\D_nF)(x,y)$ and even $(\D_nF)(x,y)/(x-y)^{n+1}$ 
remain finite near $x=y$.


\begin{proposition}\label{diff_operator_properties}
\begin{enumerate}
\item[(i)] For any matrix $g = \begin{pmatrix} a&b\\c&d\\ \end{pmatrix}\,\in\,GL(2,\R)$ and any smooth function $F$ we have
\[
\biggl(\D_n^+\,\Bigl[(c x + d)^{2n} F\Bigl(\frac{ax+b}{cx+d}\Bigr)\Bigr]\biggr)(x,y) \= (\det g)^n (\D_n^+ F) \Bigl(\frac{ax+b}{cx+d},\,\frac{ay+b}{cy+d}\Bigr)\;,
\]
and similarly with $\D_n^+$ replaced by $\D_n$.   

\item[(ii)] For any $T \in \Co$ we have
\[
(-1)^n \binom{2n}{n} \left( \frac{(T-x)(T-y)}{x-y}\right)^n = \sum_{m=0}^{2n} (-1)^m \binom{2n}{m} \D_n^{+} \left(x^m \right) \; T^{2n-m} \;.
\]

\item[(iii)] For all integers $m \ge 0$ we have
\be\lb{D_poly}
\D_n\bigl(x^m \bigr) \= (x-y)^{n+1} \sum_{r + s = m-1} \binom{r}{n} \binom{s}{n} x^{r-n} y^{s-n} \;.
\ee
In particular, $\D_n\bigl(P) = 0$ for all polynomials $P$ of degree $\le 2n$ and
\be \label{x2n+1}
\D_n\bigl(x^{2n+1}\bigr) \= (x-y)^{n+1}/;.
\ee

\item[(iv)] For any $T$ we have
\[
\D_n \left(\frac 1 {T - x} \right) = \left( \frac{x-y}{(T-x)(T-y)}\right)^{n+1} \;.
\]

\item[(v)] If $F$ is continuously differentiable $2n+1$ times between $x$ and $y$ then
\be \label{int_formula}
(\D_n\!F) (x,y) = \frac 1{n!^2} \int_y^x \left(\frac{(x-t)(t-y)}{x-y}\right)^n F^{(2n+1)}(t) dt \;.
\ee
\end{enumerate}
\end{proposition}
\begin{proof}
All of the parts of the proposition follow from the machinery of differential operators given in the appendix. (See the remark after Proposition~\ref{diff_op_properties_2}.) Here we give more direct proofs.

(i) The formula
\begin{equation}\label{D_delta}
\D_n^+ = \frac 1{n!} \left( \partx + \frac{2}{y-x} \right) \left( \partx + \frac{4}{y-x} \right) \dots \left( \partx + \frac{2n}{y-x} \right)
\end{equation}
can be verified by induction. The intertwining property~(i) for $\D_n^+$, and hence also for $\D_n$, follows immediately since the operator $\partx + \frac{k}{y-x}$ intertwines between weights $-k$ and weight $2-k$ in the variable~$x$. 

(ii) From~\eqref{Dn+} one has obviously $\D_n^{+} (1) = \binom{2n}{n} (y-x)^{-n}$. Applying~(i) with $F(x)=1$ and $g=\begin{pmatrix}0&1\\1&-T\\ \end{pmatrix}$ we get 
\[
\D_n^{+} \; (T-x)^{2n} = (-1)^n \binom{2n}{n} \left( \frac{(T-x)(T-y)}{x-y}\right)^n,
\]
which is equivalent to~(ii). 

(iii), (iv) We first prove the special case~\eqref{x2n+1}. Directly from the definition of $\D_n$ we find 
\[
\frac{n!^2}{(2n+1)!} (x-y)^{-n-1} \D_n(x^{2n+1}) = g_n \bigg(\frac x{x-y}\bigg) + g_n \bigg(\frac {-y}{x-y}\bigg)
\]
with 
\[
g_n(u)=\sum _{i=0}^n (-1)^i \binom{n}{i} \frac{u^{2n+1-i}}{2n+1-i} \; .
\]
Since $g_n'(u)=u^n (1-u)^n$ is symmetric under $u \leftrightarrow 1-u$ the expression $g_n(u)+g_n(1-u)$ is constant. Its value is given by $g_n(0)+g_n(1)=0+\int_0^1 u^n (1-u)^n du = \dfrac{n!^2}{(2n+1)!}$ (beta integral). This gives~\eqref{x2n+1}. Now~(iv) follows using~(i) with $F(x)=x^{2n+1}$ and $g=\begin{pmatrix}0&1\\1&-T\\ \end{pmatrix}$. To get~(iii) one lets $T \to \infty$ and expands both sides of~(iv) as series in $1/T$.   

Finally, for (v) we note that equation \eqref{int_formula} can be rewritten as
\[
(\D_nF)(x,y)\=\frac{(x-y)^{n+1}}{n!^2}\, 
\int_0^1 t^n\,(1-t)^n\,F(tx+(1-t)y)\,dt
\]
(proving the divisibility by $(x-y)^{n+1}$ mentioned above). This formula
is true if $F$ is a polynomial by~\eqref{D_poly} and the beta integral,
and then in the general case by polynomial approximation.
\end{proof}


\subsection{The higher Kronecker limit formula}

\begin{proof}[Proof of Theorem~\ref{higher_formula}]
The proof is almost immediate from Proposition~\ref{diff_operator_properties} and the results of~\cite{Zagier}, where it was shown
that the partial zeta function $\z(\B,s)$ has the decomposition
\be \lb{dec}
\zeta(\B, s) = D^{-s/2} \sum_{w \in \Red(\B)} Z_s(w, w')\, ,
\ee
where $Z_s(x,y)=\sum \limits_{p>0,\,q\ge 0} \Bigl( \dfrac{x-y}{(p x + q) (p y + q)} \Bigr)^s$.  In~\cite{Zagier}, the function $P(w,w')$ from the Kronecker limit formula~\eqref{Kronecker_limit_formula} was obtained as the limiting value of $Z_s(w,w')$ after its pole has been removed. Here there is no pole and we can simply set $s=k$. By part~(iv) of Proposition~\ref{diff_operator_properties},
\[
\left( \frac{x-y}{(p x + q) (p y + q)} \right)^k = - \D_{k-1} \Bigl(\frac 1 {p^{2 k-1} (p x+q)} \Bigr)\, ,
\]
and since
\[
\F_{2k}(x) = \sum_{p>0, q \ge 0} \frac 1{p^{2k-1}} \left(\frac 1{1+q} - \frac 1{px + q}\right)
\]
we find that $Z_k(x,y) = \left(\D_{k-1} \F_{2k}\right)(x,y)$.
\end{proof}

\bigskip

We illustrate the theorem with a numerical example. The field $K = \Q(\sqrt{3})$ has two narrow classes, $\B_0$ and $\B_1$, with the corresponding sets of reduced quadratic irrationalities being
\[
\Red(\B_0) = \left\{ 2+\sqrt{3} \right\}, \qquad \Red(\B_1) = \left\{ 1+\frac 1{\sqrt{3}} \; , \; \frac{3+\sqrt{3}}2 \right\}.
\]
Recall that we can compute the values of $\F_k$ and its derivatives with high accuracy. In the table below we give the values involved in the higher KLF for $\z(\B_i, 2)$.

\vskip 0.1 pc

\begin{table}[!h]
\centering
\begin{tabular}{c|r|r}
$x \;\;$ & $\F_4(x) \;\qquad\qquad$ & $\F_4'(x)\;\qquad\qquad$\\ [1ex]
\hline
$2+\sqrt{3}$ &
1.6300186927097819021\dots &
0.3642242838863980846\dots \\
$2-\sqrt{3}$ &
$-4.1957798770335434426\dots$ &
16.6663730167640755318\dots \\
$1+1/{\sqrt{3}}$ &
0.3693130036419609196\dots &
1.0208418261452850428\dots \\
$1- 1/{\sqrt{3}}$ &
$-2.4934462840079526270\dots$ &
7.3791974289140308912\dots\\
$(3+\sqrt{3})/2$ &
0.9894426455775365625\dots&
0.6173597187715989196\dots\\
$(3-\sqrt{3})/2$ &
$-1.3887304669486036967\dots$&
3.7664407174461445334\dots\\
\end{tabular}
\end{table}

With this table we compute the zeta values at $k=2$ by Theorem~\ref{higher_formula}:
\[
\z(\B_0, 2) = 1.1389225773470523300\dots
\]
\[
\z(\B_1, 2) = 0.4232764484862273545\dots
\]
\vskip 1pc
Similarly, to compute $\z(\B_i, 3)$ we need the following values:

\vskip 0.5pc

\begin{table}[!h]
\centering
\begin{tabular}{c|r|r|r}
$x \;\;$ & $\F_6(x) \;\qquad\qquad$ & $\F_6'(x)\;\qquad\qquad$ & $\F_6''(x)\;\qquad\qquad$\\[1ex]
\hline
$2+\sqrt{3}$ &
 1.2518745037778042\dots&
 0.3175540356781837\dots&
 $-0.0965606430551642\dots$\\
$2-\sqrt{3}$ &
$-3.9986990011103493\dots$&
15.4134269703386953\dots&
$-107.1707338224315422\dots$\\
$1+1/{\sqrt{3}}$ &
 0.1460504335512779\dots&
 0.9019022568593455\dots&
 $-0.7493154998661828\dots$\\
$1-1/{\sqrt{3}}$ &
$-2.4317204973004163\dots$&
 6.7529054090681804\dots&
$-27.9768290236134814\dots$\\
$(3+\sqrt{3})/2$ &
 0.6918347553446228\dots&
 0.5414072943018742\dots&
 $-0.2773058112199031\dots$\\
$(3-\sqrt{3})/2$ &
$-1.4261182127652868\dots$&
 3.4079868563585469\dots&
 $-8.6985660821795807\dots$\\
\end{tabular}
\end{table}


Therefore
\[
\z(\B_0, 3) = 1.0233279526833285\dots
\]
\[
\z(\B_1, 3) = 0.1667564870865704\dots
\]
With the zeta values computed above one can check numerically that
\be \label{ex_k_2}
\zeta(\B_0, 2) + \zeta(\B_1, 2) = \frac{\pi^4}{18 \, \sqrt{12}}
\ee
and
\be  \label{ex_k_3}
\zeta(\B_0, 3) - \zeta(\B_1, 3) = \frac{\pi^6}{324 \, \sqrt{12}} \; .
\ee
One sees that the combinations $\z(\B, k) + (-1)^k \z(\B^*, k)$ in both cases belong to $\pi^{2k} \sqrt{D} \; \Q$. This statement is true in general and is equivalent to the Siegel-Klingen theorem by the functional equations for L-functions. We now show how to deduce explicit formulas for such rational combinations from our higher KLF.

\subsection{Rational zeta values}

Let us briefly recall the relation between ideal classes and continued fractions given in~\cite{Zagier}. Any real quadratic irrationality $w$ has a continued fraction expansion
\[
w = b_1 - \dfrac 1 {b_2 -  \dfrac 1{\ddots}}
\]
with $b_i \in \Z$ (all $i$), $b_i \ge 2$ ($i \ne 1$) and $\{ b_i \}$ eventually periodic. The condition of being a root of the quadratic form in a given class $\B$ fixes the ``tail'' of $\{ b_i \}$. The condition of being a larger root of a reduced quadratic form, i.e.
\begin{equation}\label{w_condition}
w > 1, \;\;\; 1 > w' > 0,
\end{equation}
is equivalent to $\{ b_i \}$ being purely periodic. Let us denote by $(b_1, \dots, b_l)$ the period of the continued fraction expansion. It is actually defined up to a cyclic shift, so we will say it is a cycle of integers. Then the numbers in~$\Red(\B)$ are exactly
\[
w_i = b_i - \dfrac 1 {b_{i+1} -  \dfrac 1{\ddots}} \;, \;\;\; i \in \Z / l \Z,
\]
where $b_i$ with $i \in \Z$ stands for $b_{i\;(\text{mod $l$})}\,$.

Wide ideal classes $\A \in Cl(K)$ correspond to $\GL(2,\Z)$ orbits on the space of integer quadratic forms of discriminant $D$, where 
$\bigl(\begin{smallmatrix}a&b\\c&d\end{smallmatrix}\bigr)\in\GL(2,\Z)$ acts on $\mathcal Q^+$ by $\,Q(X,Y)\,\mapsto\pm\,Q(aX+bY,cX+dY)$ 
if $ad-bc=\pm1$. The quadratic form $Q = A X^2 + B X Y + C Y^2$ is said to be reduced in the wide sense if $A>0$, $C<0$ and $|A+C|<-B$ or, equivalently, when its root $x=\frac{-B+\sqrt{D}}{2A}$ satisfies
\begin{equation}\label{x_condition}
x > 1, \;\;\; 0 > x' > -1.
\end{equation}
As in the case of narrow classes, the condition of being a root of the quadratic form in the class $\A$ fixes the ``tail'' of $\{ a_i \}$ in the ordinary continued fraction expansion
\[
x = a_1 + \dfrac 1 {a_2 + \dfrac 1{\ddots}}, \qquad  a_i \in \Z, \;\;a_i \ge 1 \; (i \ne 1),
\]
while the condition~\eqref{x_condition} is equivalent to $\{ a_i \}$ being purely periodic. Thus to $\mathcal A$ there corresponds a cycle of integers $(a_1, \dots, a_m)$ with $a_i \ge 1$ and a cycle of numbers
\[
x_i = a_i + \dfrac 1 {a_{i+1} + \dfrac 1{\ddots}} \;, \;\;\; i \in \Z / m \Z,
\]
just in the same way as $(b_1, \dots, b_l )$ with $b_i \ge 2$ and $w_1, \dots, w_l$ were assigned to a narrow ideal class. Further, since $x_1$ satisfies~\eqref{x_condition} then $w_1=1+x_1$ satisfies~\eqref{w_condition} and $w_1>2$, so $w_1$ has a purely periodic ``minus'' continued fraction $w_1 = b_1 - \frac 1 {b_2 - \dots}$ with $b_1 = a_1+2 \ge 3$. The narrow ideal class $\B$ corresponding to $w_1$ then lies in the wide class $\A$ corresponding to $x_1$ (since both contain the ideal $\Z x_1 + \Z = \Z w_1 + \Z$) and we can reproduce all the numbers $(b_1, \dots, b_l)$ as follows. We consider the minimal {\it even} period $(a_1,\dots,a_{2r})$, where $r=m$ if $m$ is odd and $r=m/2$ if $m$ is even. The $b$'s and $a$'s are related by
\be \label{b_a}
\begin{aligned}
b_1 = a_1+2, &\qquad b_2=\dots=b_{a_2}=2,\\
b_{a_2+1}=a_3+2,  &\qquad b_{a_2+2}=\dots=b_{a_2+a_4}=2,\\
 &\;\,\vdots\\
b_{l-a_{2r}}=a_{2r-1}+2, &\qquad b_{l-a_{2r}+1}=\dots=b_{l}=2,\\
\end{aligned}
\ee
i.e.
\[
(b_1, \dots,b_l)\=(\,a_1+2,\underbrace{2,\dots,2}_{a_2-1},a_3+2,\underset{a_4-1}{\underbrace{2,\dots,2}},\,\dots,\,a_{2r-1}+2,\underset{a_{2r}-1}{\underbrace{2,\dots,2}} \,)\,.
\]
In particular, $l(\B) = a_2 + a_4 + \dots + a_{2r}$. 
If we started with the cyclic shift $(a_2, a_3, \dots, a_{2r}, a_1)$, we would get instead the cycle 
\[
(\,a_2+2,\underset{a_3-1}{\underbrace{2,\dots,2}},\,\dots,\,a_{2r}+2,\underset{a_{1}-1}{\underbrace{2,\dots,2}} \,)\,.
\]
This cycle corresponds to the conjugate narrow class $\B^*$ and $l(\B^*)=a_1 + a_3 + \dots + a_{2r-1}$. In particular, we have $l(\B)+l(\B^*)=\sum_{i=0}^{2r} a_i$. Notice that if the minimal period length $m$ is odd, then $\B=\B^*$; this happens if and only if the fundamental unit of $K$ has negative norm.   

 

Let us denote by $\Redw(\B)$ for a narrow ideal class $\B$ the set of those larger roots of the quadratic forms in $\B$ reduced in the wide sense. (Equivalently, $\Redw(\B)$ consists of the numbers $w-1$ where $w\in\Red(\B)$, $w>2$.) Then in the notations above we have $\Redw(\B) = \{ x_1, x_3, \dots \}$ and $\Redw(\B^*) = \{ x_2, x_4, \dots \}$.  We will also write $Q \in \Redw(\B)$ for such a form.

\begin{lemma}\label{wide_class_sum} Let $\B \mapsto \mathcal I (\B)$ be an invariant of narrow ideal classes defined by
\be \lb{Isum}
\mathcal I (\B) = \sum \limits_{w \in \Red(\B)} F(w,w')
\ee
for some function $F :\mathcal \R \times \R \to \Co$. Suppose $F$ has the form
\begin{equation}\label{useful_form}
F(x,y) \= G(x-1,y-1) \,-\, G\Bigl(\frac{x-1}x, \frac{y-1}y\Bigr)
\end{equation}
for some function $G$. Then

(i) For any narrow ideal class $\B$ we have
\[
\mathcal I (\B) \= \sum \limits_{x \in \Redw(\B)} G (x,x') \quad -
\quad \sum \limits_{x \in \Redw(\B^*)} G \Bigl(\frac 1x \,,\;\frac 1{x'}\Bigr).
\]

(ii) If $G(x,y)$ has the form $H_1(x-y)+H_2\bigl(\frac 1x - \frac 1y\bigr)$ for some functions $\,H_1,\,H_2: \R \to \Co$, then $\mathcal I(\B)=0$ for
all classes $\B$. 
\end{lemma}

\begin{proof} From~\eqref{b_a} we have
\[
w_1 = x_1 + 1 \= a_1 + 2 - \frac 1{w_2}\,,
\]
\[
w_2 \= 2 - \frac 1{w_3}\,,\quad \dots\,,\quad
w_{a_2} \= 2 - \frac 1{w_{a_2+1}},
\]
\[
w_{a_2+1} \= x_3 + 1 \= a_3 + 2 - \frac 1{w_{a_2+2}}
\]
and therefore
\be\bal
\sum_{j=2}^{a_2+1} &F(w_j,w_j') \= \sum_{j=2}^{a_2+1} \left[ G(w_j-1, w_j'-1) - G\Big(1-\frac 1{w_j},1-\frac 1{w_j'} \Big) \right]\\
&\quad\= G(w_{a_2+1}-1, w_{a_2+1}'-1) - G\Big(1-\frac 1{w_2},1-\frac 1{w_2'} \Big)\\ 
&\quad\= G(x_3, x_3')  - G \Big(\frac 1{x_2}\,,\,\frac 1{x_2'} \Big)\;.
\eal\ee
Summing this cyclically gives statement (i). For statement~(ii) we observe
that if $G$ has the form given then $F(x,y)=H_1(x-y)-H_1(-1/x+1/y)$.
Now from $w_i-w_i'=-1/w_{i+1}+1/w'_{i+1}$ it follows that  
$\sum_{i\!\mod l}F(w_i,w'_i)=0$.
\end{proof}


\vskip 1pc 
\noindent {\bf Corollary.} {\it Let the notations be as above. Then
\[
\mathcal I(\B) \; \pm \; \mathcal I (\B^*) \; = \Biggl(\sum \limits_{x \in \Redw(\B)}\;
  \pm \;\sum \limits_{x \in \Redw(\B^*)}\Biggr)\, G^{\mp}(x,x')
\]
with $G^{\mp} (x,y) = G(x,y) \mp G\bigl(\frac 1x, \frac 1y\bigr)$.}
\vskip 1pc

This corollary is  useful because in the application to the following
theorem the relevant function $G$ will be transcendental but either
$G^+$ or $G^-$ (depending on the parity of $k$)  will be a rational function.

\begin{theorem}\label{rationality_thm} For every narrow ideal class $\B$ and integer $k \ge 2$,
\[
D^{\frac k 2} \,\bigl( \z(\B, k) + (-1)^k \z(\B^*, k) \bigr)
\= \Biggl(\sum \limits_{x \in \Redw(\B)} \;+\;\,(-1)^k\!\!\sum \limits_{x \in \Redw(\B^*)} \Biggr)\,W_k(x,x'),
\]
where $W_k(x,y) = \D_{k-1}\Bigl( - \sum \limits_{r=0}^k \z(2r) \z(2k-2r) |x|^{2r-1} \Bigr)$.
\end{theorem}

{\bf Remark.} In the definition of $W_k$, the absolute value signs are necessary, since $\D_{k-1}$ kills polynomials of degree $\le 2k-2$, but the restriction of $W_k$ to $\{ x > 0 > y\}$, which is all that is used in the theorem, is a rational function (in fact, a polynomial in $x^{\pm 1}$, $y^{\pm1}$ and $(x-y)^{-1}$).

\begin{proof} We define two functions of one variable by
\[ V_0(x)\=-\,x^{2k-2}\,\F_{2k}(1/x)\,-\,
 \frac{\z(2k)}4\,\Bigl(\frac1x\,+\,x^{2k-1}\Bigr) \qquad(x>0)
\]
and 
\[
V(x)\=V_0(|x|)\,-\,\frac{\z(2k)}2\Bigl(\frac1x\,+\,x^{2k-1}\Bigr)
\qquad (x \in \R \smallsetminus \{0\}).
\]
From Proposition~\ref{func_eq_thm} we get, after a straightforward but
lengthy computation (one has to distinguish the three cases $x>1$, $0<x<1$ and $x<0$ and to use the functional equations~\eqref{func_eq_1}--\eqref{BA} repeatedly),
\[
\F_{2k}(x) \= V(x-1) \,-\, V\Bigl( \frac{x-1}x \Bigr) \,+\,
\bigl(\text{polynomial of degree $\le 2k-2$}\bigr) 
\]
and hence, since $\D_{k-1}$ is equivariant and kills polynomials
of low degree (parts (i) and (iii) of Proposition~\ref{diff_operator_properties}),
\[
\bigl(\D_{k-1}\F_{2k}\bigr)(x,y)\=\bigl(\D_{k-1}V\bigr)(x-1,y-1)
\,-\,\bigl(\D_{k-1}V\bigr)\Big(\frac{x-1}x,\frac{y-1}y\Big) 
\]
for $x>1>y>0$. Therefore, by Theorem~1, the conditions of the lemma above are satisfied for $\mathcal I(\B) = D^{k/2}\z(k,\B)$ and
$G=\D_{k-1} V$. Moreover, since $\D_{k-1}\bigl(x^{2k-1}\bigr) = (x-y)^k$ and $\D_{k-1} \bigl(1/x\big) = - \bigr(-1/x+1/y \bigr)^k$ by 
Proposition~\ref{diff_operator_properties},
part~(ii) of Lemma~\ref{wide_class_sum} tells us that we can
replace $G$ by $G_0(x,y)=\D_{k-1}\bigl(V_0(|x|)\bigr)$.  Finally, from the functional equation~\eqref{func_eq_1} we get
\[\bal
& V_0\bigl(|x|\bigr) \,+\,x^{2k-2}\,V_0\bigl(1/|x|\bigr) 
\=-A_{2k}(|x|)\,+\,\frac{\z(2k)}2\bigl(1/|x|+{|x|}^{2k-1}\bigr) \\
&\qquad\= - \sum \limits_{r=0}^k \z(2r) \z(2k-2r) |x|^{2r-1}
\,+\,(\text{polynomial of degree $\le 2k-2$})\,,\eal
\]
so $G_0(x,y)+(-1)^{k-1}G_0(1/x,1/y)=W_k(x,y)$.  The theorem now follows
immediately from the corollary to Lemma~\ref{wide_class_sum}.
\end{proof}

\bigskip
We illustrate the theorem (for $k=2$ and $k=3$) using the example from the previous section. We have $\Redw(\B_0) = \big\{ 1+\sqrt3\big\}$, $\B_0^*=\B_1$, $\Redw(\B_1) = \big\{ (1+\sqrt3)/2 \big\}$. One can easily compute    
\[
W_2(x,y)\=\frac{\pi^4}{180}\, \frac
{x+y}{x^2y^2(x-y)} \,\bigl((x^2y^2+1)(x^2-4xy+y^2)+10x^2y^2\bigr)\,,
\]
for $x>y>0$, so $\z(\B_0, 2) + \z(\B_1, 2)$ equals
\[
\frac 1{12} \Bigl( W_2 (1+\sqrt3,1-\sqrt3) + W_2 \Bigl( \frac{1+\sqrt3}2,\frac{1-\sqrt3}2 \Bigr) \Bigr) = \dfrac{\pi^4}{18 \, \sqrt{12}}\,,
\]
in accordance with our numerical computation~\eqref{ex_k_2}. Similarly,
using the rather long formula  
\[
\begin{aligned}
W_3(x,y)=\frac{\pi^6}{1890} \frac{x+y}{x^3y^3(x-y)^2}\bigl(&
(x^3y^3+1)(x^4-6x^3y+16x^2y^2-6xy^3+y^4) \\
&\qquad -\,21\,(xy+1)\,x^3y^3\bigr) \qquad (x>y>0),\\
\end{aligned}
\]
we find that $\z(\B_0, 3) - \z(\B_1, 3)$ equals
\[
\frac 1{12\sqrt{12}} \Bigl( W_3 (1+\sqrt3,1-\sqrt3) - W_3\Bigl( \frac{1+\sqrt3}2,\frac{1-\sqrt3}2 \Bigr)\Bigr) \= \dfrac{\pi^6}{324 \, \sqrt{12}}\;,
\]
in agreement with~\eqref{ex_k_3}.

\bigskip

We end by discussing the relation of Theorem~2 with the Klingen-Siegel theorem and with the functional equations of $\z(\B,s)\pm\z(\B^*,s)$.  Consider, for $k\ge2$, the rational function
\[
\PP_k(x)\=\sum_{r=0}^{2k}\frac{B_r\,B_{2k-r}}{r!\,(2k-r)!}\,x^{r-1}
\=\frac4{(2\pi i)^{2k}}\,\sum_{r=0}^k\z(2r)\,\z(2k-2r)\,x^{2r-1}\,,
\]
where $B_r$ are the Bernoulli numbers. This function appeared in the literature (e.g. in~\cite{ZagierInventiones}) as a generalized period polynomial associated to the Eisenstein series of weight $2k$. It satisfies the relations
\be \label{fe_P}
\PP_k(x) = x^{2k-2} \PP_k \left(\frac 1x \right), \;\;\; \PP_k(x)-\PP_k(x-1)+x^{2k-2} \PP_k \left(\frac{x-1}x \right) = 0.
\ee
For $k\ge2$ define $\widetilde W_k(x,y)\,\in\,\Q\bigl[x^{\pm1},y^{\pm1},(x-y)^{-1}\bigr]$ by 
\[
\widetilde W_k(x,y) \= (-1)^{k-1} \frac{(k-1)!^2}2 \,\Bigl((\D_{k-1}^+ \PP_k)(x,y) \,+\,(-1)^{k-1}\,(\D_{k-1}^+ \PP_k)(y,x)\Bigr)\;.
\]
The function $\widetilde W_k$ is related to the function $W_k$ of Theorem~2 by
\be\lb{WW}
W_k(x,y) = \frac{(2 \pi)^{2k}}{2\,(k-1)!^2 } \widetilde W_k(x,y) \quad \text{if} \;\; x > 0 > y \; .
\ee
Moreover, since $\widetilde W_k$ is $(-1)^{k-1}$-symmetric in $x$ and $y$, 
the number defined by
\[
\widetilde W_k(Q) := D^{\frac{k-1}2} \widetilde W_k \left( \frac{-B+\sqrt{D}}{2 A}, \frac{-B-\sqrt{D}}{2 A}\right)
\]
for an integer quadratic form $Q=A X^2 + B X Y + C Y^2$ 
is rational. Note that the normalization here is different from the one in~\eqref{DnFQ}, reflecting the different symmetry. Now we can formulate the following

\vskip 1pc
{\bf Corollary.} {\it For any narrow ideal class $\B$ and integer $k \ge 2$,
\[
\zeta(\B, 1-k) = \Biggl(\sum \limits_{Q \in \Redw(\B)} \+ (-1)^k\!\!\sum \limits_{Q \in \Redw(\B^*)} \Biggr) \widetilde W_k(Q) \;= \sum_{Q \in \Red(\B)} \widetilde W_k(Q) \,.
\]
}
\vskip 1pc
%As we remarked above, all numbers $\widetilde W_k(Q)$ are rational and therefore we get $\zeta(1-k, \mathcal B) \in \Q$.

\begin{proof}
From the functional equations
\be\lb{fez}
\pi^{-s} \, \Gamma\bigl( \frac{s+\varepsilon}2\bigr)^2 \, D^{{\bf+} s/2}\,
\Bigl(\z(\B,s) \+ (-1)^{\varepsilon}\z(\B^*,s)\Bigr) \= \text{same with $s \mapsto 1-s$}
\ee
($\varepsilon=0,\,1$) we have $\z(\B, 1-k) = (-1)^k\z(\B^*, 1-k)$
and
\[
D^{k/2} \,\Bigl( \z(\B, k) \+ (-1)^k \z(\B^*, k) \Bigr) 
\= \frac{(2 \pi)^{2k}}{4 (k-1)!^2} \, D^{(1-k)/2} \, \times
\]
\[
\times \, \Big( \z(\B, 1-k) 
\+ (-1)^k \z(\B^*, 1-k) \Big)
\= \frac{(2 \pi)^{2k}}{2 (k-1)!^2} \, D^{(1-k)/2} \, \zeta(\B, 1-k).
\]
Combining the latter with Theorem~\ref{rationality_thm} and using~\eqref{WW} give
\[
\zeta(\B, 1-k) \= \, D^{(k-1)/2} \, \Biggl(\sum \limits_{x \in \Redw(\B)} \+ (-1)^k\!\!\sum \limits_{x \in \Redw(\B^*)} \Biggr)\,\widetilde W_k(x,x'),
\]
what is exactly the second statement of the corollary. Further, using the equivariance property of $\D_{k-1}$ (Proposition~\ref{diff_operator_properties}, (i)) we get from~\eqref{fe_P}
\[\bal
\widetilde W_k (x,y) &\= (-1)^{k-1} \widetilde W_k \Big(\frac 1 x \,, \, \frac 1 y \Big) \,,\\
\widetilde W_k(x,y) &\- \widetilde W_k (x-1,y-1) \+ \widetilde W_k \Big(\frac {x-1} x \,, \, \frac {y-1} y \Big)  \= 0 \,.
\eal\]
From Lemma~1 and its corollary with $G(x,y) = \widetilde W_k(x,y)$  it follows that 
\[ \mathcal I(\B) \,:=\, \sum_{w \in Red(\B)} \widetilde W_k(w,w') \=
(-1)^k \; \mathcal I(\B^*) \]
\[ \= \Biggl(\sum \limits_{x \in \Redw(\B)} \;+\;\,(-1)^k\!\!\sum \limits_{x \in \Redw(\B^*)} \Biggr)\,\widetilde W_k(x,x'),
\]
since $\widetilde W_k^{\pm} = 2 \, \widetilde W_k$ when $\pm 1 = (-1)^{k-1}$. Therefore $\z(\B, 1-k) = D^{(k-1)/2} \, \mathcal I(\B) = \sum_{Q \in Red(\B)} \widetilde W_k(Q)$.
\end{proof}

\vskip 1pc
Let us compute the rational values $\z(\B, 1-k)$ explicitly. If we define homogenous polynomials $d_{r,n}(A,B,C)$ and $f_n(A,B,C)$ by
\[
(A X^2 + B X Y + C Y^2)^n = \sum_{r=0}^{2n} d_{r,n}(A,B,C) X^{2n-r}(-Y)^r,
\]
\[
f_n(A,B,C) = \sum_{r=0}^n (-1)^r \frac{(n-r)!}{r! (2n+1-2r)!} A^r B^{2n+1-2r} C^r,
\]
then for $Q=A X^2 + B X Y + C Y^2$ we have
\[
D^{n/2} \D_n^+(x^r) \left( \frac{-B+\sqrt{D}}{2 A}, \frac{-B-\sqrt{D}}{2 A}\right) \= (-1)^n \frac{r! (2n-r)!}{n!^2} \, d_{r,n}(A,B,C) \, ,
\]
\[
D^{n/2} \D_n\left( \frac 1 {|x|}\right) \left( \frac{-B+\sqrt{D}}{2 A}, \frac{-B-\sqrt{D}}{2 A}\right) \= - \frac{(2n+1)!}{n!} \; \frac{f_n(A,B,C)}{C^{n+1}}
\]
and hence
\be\lb{neg_val}\bal
\widetilde{W}_k(Q) \= & \sum_{r=1}^{2k-1} \frac {B_r B_{2k-r}}{r(2k-r)} d_{r-1,k-1}(A,B,C)\\
& \+ \frac{(-1)^k (k-1)! B_{2k}}{4k} \left( \frac{f_{k-1}(A,B,C)}{C^{k}} + \frac{f_{k-1}(C,B,A)}{A^{k}}  \right).
\eal\ee

{\bf Example.} Let us once more go back to the example from the previous section and compute $\z(\B_0, 1-k)$ and $\z(\B_1, 1-k)$ for $k = 2, 3$. From~\eqref{neg_val}
\[
\widetilde W_2 (Q) = -\frac B{144} \Biggl( 1 + \frac 1{10} \Bigl(\frac{B^2}{C^2} + \frac{B^2}{A^2} \Bigr) - \frac 3{5} \Bigl( \frac A C + \frac C A\Bigr) \Biggr).
\]
In $\B_0$ there is only one reduced quadratic form $Q_0=X^2 - 4 X Y + Y^2$ and in $\B_1$ there are two reduced forms $Q_1 = 3 X^2 - 6 XY + 2 Y^2$ and $Q_2 = 2 X^2 - 6 XY + 3 Y^2$. Therefore
\[\bal
&\z( \B_0, -1) \= \widetilde W_2 (Q_0) \= \frac 1 {12}\,,\\
&\z( \B_1, -1) \= \widetilde W_2 (Q_1) \+ \widetilde W_2 (Q_2)  \= \frac 1 {24} \+ \frac 1 {24} \= \frac 1 {12} \,.\eal\]
For the Dedekind zeta function we then have $\z_{\Q(\sqrt 3)}\,(-1) = 1 / 6$. When $k=3$
\[
\widetilde W_3 (Q) \= \frac{B(A+C)}{720}-\frac1{252} \Bigl(\frac{B^5}{60}-\frac{A B^3 C}6+\frac{A^2 B C^2}2 \Bigr)\, \Bigl(\frac1{A^3}+\frac1{C^3}\Bigr)
\]
and
\[\bal
&\z( \B_0, -2) \= \widetilde W_3 (Q_0) \= \frac 1 {18}\,,\\
&\z(\B_1, -2) \= \widetilde W_3 (Q_1) \+ \widetilde W_3 (Q_2)  \= -\frac 1 {36} \- \frac 1 {36} \= - \frac 1 {18} \,,\eal\]
in accordance with the fact that the Dedekind zeta function $\z_{\Q(\sqrt 3)}\,(s)$ has zero (of the second order) at $s=-2$.

\vskip 1pc

{\bf Remark.} The right-hand side of~\eqref{neg_val} already appeared in~\cite{ZagierAsterisque}. To formulate the statement given there, let us first rewrite the decomposition~\eqref{dec} as
\be\lb{dec_1}
\z(\B, s) \= \sum_{Q \in Red(\B)} Z_Q(s) \qquad \text{ for } \qquad \Rea(s) > 1,
\ee
where 
\[ Z_{Q}(s) \,= \, D^{-s/2} Z_{s}\left( \frac{-B+\sqrt{D}}{2 A}, \frac{-B-\sqrt{D}}{2 A}\right) \,.\]
Theorem~2 from~\cite{ZagierAsterisque} states that $Z_{Q}(s)$ can be continued to a meromorphic function on the whole of $\Co$ with its only pole at $s=1$ and, in our notations
\footnote{Our notations slightly differ from~\cite{ZagierAsterisque}, namely our polynomial $d_{r,n}$ is $d_{2n-r,n}$ there and our $Z_Q$ is $Z_{\widetilde Q}$ where $\widetilde Q = C X^2 - B X Y + A Y^2$.}, one has 
\[
Z_Q(1-k)= \widetilde W_k(Q) \,.
\]
One of the statement of our corollary follows from this and we now see that the individual terms $\widetilde W_k(Q)$ come from analytic continuation of zeta functions of reduced quadratic forms $Z_Q(s)$ in the decomposition~\eqref{dec_1}. Another way to say this is that the
results of this paper and the results of~\cite{ZagierAsterisque} 
together give a proof of the functional equations~\eqref{fez}
as a consequence of functional equations for the ``cone zeta functions"
$Z_Q(s)$ at integer arguments.  It would be interesting to see whether
one can give a proof of the functional equations for arbitrary~$s$
in the same way (i.e., by writing the difference of the right and left
sides of~\eqref{fez} as an invariant of the form
$I(\B)=\sum F(w,w')$ and showing that $F$ has the form required in
Lemma~1 to force $I\equiv0$), but we did not succeed in doing this.

\section{Homological aspects}

One may notice that the values $\D_{k-1}(\F_{2k})(w,w')$ in the higher KLF depend only on the $(2k-1)$st derivative of $\F_{2k}$ (see~\eqref{int_formula}). In this section we construct a cocycle class using this derivative and represent our formula as a homological pairing.

\subsection{Functional equations and cohomology of modular group}

Recall that the modular group $\Gamma={\PSL}(2,\Z)$ is freely generated by the two
elements
\[
S=\pm \begin{pmatrix}0&-1\\1&0\end{pmatrix}, \; U= \pm \begin{pmatrix} 1&-1\\1&0\end{pmatrix}
\]
of orders 2 and 3 correspondingly. A 1-cocycle on $\Gamma$ with coefficients in some
$\Gamma$-module $M$ is a function $\phi:\Gamma\to M$ satisfying the relation
\begin{equation}\label{cocycle_condition}
\phi(gh)=g\phi(h)+\phi(g)\quad\text{for any }g,h\in\Gamma.
\end{equation}
Hence, if $m_{1}=\phi(S)$ and $m_{2}=\phi(U)$ then
\begin{equation}\label{generator_conditions}
\begin{aligned}
(1+S)m_{1} &=0,\\
(1+U+U^2)m_{2} &=0.\\
\end{aligned}
\end{equation}
And conversely, as soon as the two elements $m_1,m_2\in M$ are given such that
the conditions~\eqref{generator_conditions} are satisfied, the map $\phi(S)=m_1$ and $\phi(U)=m_2$ can be
uniquely extended to a 1-cocycle on $\Gamma$ by~\eqref{cocycle_condition}.


Let us now take for $M$ the space of functions on $\Proj$ with the action of
$\Gamma$ in weight $2k$. Then a 1-cocycle $\phi$ is the same as a pair of functions
$F=\phi(S)$ and $G=\phi(U)$ satisfying
\begin{equation}\label{gen_cond_1}
F(x)+\frac 1{x^{2k}} F\left( - \frac 1 x \right) =0,
\end{equation}
\[
G(x)+\frac 1{(1-x)^{2k}} G\left(\frac{1}{1-x}\right)+ \frac 1{x^{2k}} G\left(\frac{x-1}{x}\right) =0.
\]
Consider $T=\pm \begin{pmatrix} 1&1\\0&1\end{pmatrix}$. Then $U=TS$ and therefore $G(x)=F(x-1)+\phi(T)(x)$. Using this and the first of above equations we rewrite the second one as
\begin{equation}\label{gen_cond_2}
F(x)-F(x+1)+\frac 1{x^{2k}} F\left(- \frac{x+1}{x}\right) = B(x),
\end{equation}
where $B=-T^{-1}(1+U+U^2)\phi(T)$. Equations~\eqref{gen_cond_1} and~\eqref{gen_cond_2} remind us correspondingly of equations~\eqref{func_eq_1} and~\eqref{func_eq_2} for the function $\F_{2k}$. And indeed, one can observe that the proof of Proposition~\ref{func_eq_thm} is based on the fact that similar equations are satisfied by the $(k-1)$st derivative of $\F_k$. Consider the function
\[
\psi_{2k}(x) =  \sign(x) \sums_{p,\,q \ge 0} \frac 1{(p \; |x|+q)^{k}},
\]
where here and below ``$*$'' on the summation sign means that we omit the term with $p=q=0$ and take the ``boundary'' terms (where either $p=0$ or $q=0$) with the coefficient $\frac{1}{2}$. For positive arguments $\psi_{2k}(x)$ equals $\frac 1{(2k-1)!} \left(\frac d{dx}\right)^{2k-1} \left( \F_{2k}(x) + \frac{\z(2k)}2 \left(\frac 1x + x^{2k-1}\right) \right)$. This function satisfies~\eqref{gen_cond_1} and~\eqref{gen_cond_2} with $B \equiv 0$. Therefore we have the following

\begin{lemma}\label{coc_def} For every $k \ge 2$ the map
\[
\phi_k(S)=\psi_{2k},\quad\phi_k(T)=0
\]
can be uniquely extended to a 1-cocycle for $\Gamma$ with coefficients in the space of
functions on $\Proj$ with the action in weight $2k$.
\end{lemma}


Let us give $\phi_k(g)$ for $g \in \Gamma$ explicitly. To this end let us consider for $\alpha \ne \beta \in \Proj$ the function on 
$\Proj\backslash \{\alpha, \beta\}$ defined by
\be\lb{pseudo_measure}
f_{\alpha,\beta}(x) = \begin{cases}
\phantom-\underset{\frac p q \in [\alpha,  \beta]}\sums \frac 1 {(q x - p)^{2k}},\; & x \in (\beta, \alpha)\\
- \underset{\frac p q \in \; [\beta, \alpha]}\sums \frac 1 {(q x - p)^{2k}}, \; & x \in (\alpha, \beta)\,,\\
\end{cases}
\ee
where $[\alpha,\beta]$, $[\beta,\alpha]$, $(\beta,\alpha)$, $(\alpha,\beta)$ are to be taken on $\Proj$, e.g., $[\alpha,\beta]$ has its usual meaning if $-\infty \le \alpha < \beta \le \infty$ but means $[\alpha,\infty]\cup(-\infty,\beta]$ if $-\infty < \beta < \alpha \le \infty$.

Then with the convention that $f_{\alpha,\alpha} \equiv 0$, we have the equality
\[
f_{\alpha, \beta}(x) + f_{\beta, \gamma}(x) = f_{\alpha, \gamma}(x), \;\;\; x \in \Proj \backslash \{\alpha, \beta,\gamma\}.
\]
Also there is an equivariance $f_{g \alpha, g \beta}(x) = \left( g f_{\alpha, \beta} \right)(x)$ for $g \in \Gamma$. Therefore for
any $\alpha\in \Proj$ the map
\begin{equation}\label{coc_gen}
g\mapsto f_{\alpha,g\alpha}
\end{equation}
is a 1-cocycle. Since $\phi_k(S)= \psi_{2k}(x) = f_{\infty,S\infty}$ and $\phi_k(T)=0=f_{\infty,T\infty}$, we have $\phi_k(g)=f_{\infty,g\infty}$ for any $g \in \Gamma$. And for any $\alpha \in \Proj$ the cocycle~\eqref{coc_gen} is homologous to $\phi_k$.

Finally, we remark that the properties of $f_{\alpha, \beta}$ given above mean exactly that the map $(\alpha, \beta) \mapsto f_{\alpha, \beta}$ is a modular pseudo-measure on $\Proj$ in the sense of~\cite{ManinMarcolli} taking values in the space $\V_{2k}^0$ defined in the next section. 

\subsection{The generalized Eisenstein cocycle class}

\begin{definition} \label{V_2k_def} For $k \in \Z$, let $\V_{2k}$ be the space of continuous functions $f:\R \to \R$ such
that the limit $\underset{x\to\infty} \lim x^{2k} f(x)$ exists and is finite.
\end{definition}

This is a representation of $\SL(2,\R)$ with the action in weight $2k$.
\footnote{There is a more symmetric definition of this representation as the space of those continuous functions $F:\R^2\backslash\{0\} \to \R$ which are homogenous of degree $-2k$, i.e. $F(\lambda x, \lambda y) = \lambda^{-2k} F(x,y)$. Then the right action of $\SL(2,\R)$ is given by $(F g)(x,y) = F(a x + b y, c x + d y)$, and $f(x)=F(x,1)$ is an element of $\V_{2k}$ from Definition~\ref{V_2k_def}. One can find several other presentations for $\V_{2k}$ in~\cite{BruggemanLewisZagier}.}

Let $V_{2k-2}$ be the space of real polynomials of degree $\le 2k-2$. This is a
finite-dimensional representation of ${\SL}(2,\R)$ (with the action in weight $2-2k$, so $V_{2k-2} \subset \V_{2-2k}$) and there is an equivariant map $\mathfrak I : \V_{2k}\to V_{2k-2}$ given on $f\in \V_{2k}$ by
\begin{equation}\label{integral_map}
({\mathfrak I} f)(X) = \int_{-\infty}^{+\infty} f(x)(X-x)^{2k-2}dx.
\end{equation}

\begin{definition} Let $\V_{2k}^\circ$ be the space of functions $f:\R \to \R$ continuous at all
but a finite number of points with the action of ${\SL}(2,\R)$ in weight $2k$.
\end{definition}

The spaces $\V_{2k}\subset \V_{2k}^\circ$ are representations of $\Gamma$, and the 1-cocycle $\phi_k$ from
Lemma~\ref{coc_def} takes values in $\V_{2k}^\circ$ since $\psi_{2k} \in \V_{2k}^\circ$.  The next theorem shows
that $\phi_k$ can be modified by a coboundary to a $\V_{2k}$-valued cocycle with a rational
image under the map~\eqref{integral_map}. Before formulating it, let us notice that in the long exact sequence
\[
\dots \to H^0(\Gamma, \V_{2k}^\circ / \V_{2k}) \to H^1(\Gamma,\V_{2k}) \to H^1(\Gamma,\V_{2k}^\circ) \to \dots
\]
the term $H^0(\Gamma, \V_{2k}^\circ / \V_{2k})$ vanishes (since a $\Gamma$-invariant function can't have a finite nonzero number of  points of discontinuity), and therefore $H^1(\Gamma,\V_{2k})$ is a subspace of $H^1(\Gamma,\V_{2k}^\circ)$.

\begin{theorem}\label{gen_eisenstein_cocyle} Let $[\phi_k]\in H^1(\Gamma,{\mathcal V}_{2k}^\circ)$ be the cohomology class of the 1-cocycle $\phi_k$ from Lemma~\ref{coc_def}. Then $[\phi_k]\in H^1(\Gamma,{\mathcal V}_{2k})$, and ${\mathfrak I}\;[\phi_k] \in H^1(\Gamma,\pi^{2k} V_{2k-2}(\Q))$, where $V_{2k-2}(\Q) \subset V_{2k-2}$ is the subspace of polynomials with rational coefficients. Namely, ${\mathfrak I} \; [\phi_k]$ is the class of the 1-cocycle
\begin{equation}\label{eisenstein_coc}
\begin{aligned}
T & \mapsto - \frac{\z(2k)}{2k-1}\left(X^{2k-1} - (X-1)^{2k-1} \right), \\
S & \mapsto - \frac 2{2k-1} \sum_{r=1}^{k-1} \z(2r)\z(2k-2r) X^{2r-1}.\\
\end{aligned}
\end{equation}
\end{theorem}
\begin{proof} From the asymptotic expansion of $\F_{2k}$ at infinity we conclude that
\[
\psi_{2k}(x) = \frac{\z(2k)}2 + \frac{\z(2k-1)}{2k-1}\frac 1{x^{2k-1}} + O\left(\frac 1 {x^{2k+1}} \right), \qquad x \to +\infty.
\]
Let $f: \R \to \R$ be any continuous function such that the limit
\begin{equation}\label{f_expansion}
\underset{x\to\infty} \lim \; x^{2k} \; \left(f(x) + \frac{\zeta(2k)}{2} \sign(x)  + \frac{\zeta(2k-1)}{2k-1} \frac 1{x^{2k-1}}\right)
\end{equation}
exists and is finite. Then from the equivariance property of the functions $f_{\alpha, \beta}$ in the previous section it follows that $\phi_k(g) + (1-g) f \in \V_{2k}$ for any $g \in \Gamma$. Hence, $\phi_k + \partial f$ is a $\V_{2k}$-valued cocycle, so  $[\phi_k]\in H^1(\Gamma,{\mathcal V}_{2k})$.

Let $F$ be any smooth function on $\R$ with $F(x) = - \zeta(2k-1) \log|x| - \frac{\zeta(2k)}{2}|x|^{2k-1} + \frac 1{x^2} C(1/x)$ as $x \to \infty$ with $C$ smooth near 0. Then the limit~\eqref{f_expansion} for $f(x) = \frac 1{(2k-1)!} \left(\frac{d}{dx}\right)^{2k-1} F(x)$ equals 0, and using the asymptotic expansion of $\F_{2k}$ near $0$ we check that the function
\[
\F_{2k}(|x|)+\frac{\z(2k)}2 \left( \frac 1{|x|} + |x|^{2k-1} \right) - A_{2k}(|x|) + (1-S) F(x)
\]
is continuously differentiable $2k-1$ times on $\R$ (including $x=0$). Its $(2k-1)$st derivative is obviously $\psi_{2k}(x)+(1-S) f$ times $(2k-1)!$ With this, by the formula~\eqref{J_comp} from the appendix we find that
\[
{\mathfrak I}\Big( \psi_{2k}(x)+(1-S) f \Big) = \frac 1{2k-1} \left( -A_{2k}(X) + A_{2k}(-X) \right)
\]
\[
= - \frac 2{2k-1} \sum_{r=1}^{k-1} \z(2r)\z(2k-2r) X^{2r-1}
\]
and
\[
{\mathfrak I} \Big((1-T)f \Big) = -\frac{\zeta(2k)}{2k-1} \left(X^{2k-1}-(X-1)^{2k-1}\right)\,,
\]
veryfying that the cocycle ${\mathfrak I}(\phi_k+\partial f) \in Z^1(\Gamma,\V_{2k})$ is given by equation~\eqref{eisenstein_coc}.
\end{proof}


\subsection{Two periods of the non-holomorphic Eisenstein series}

The cocycle~\eqref{eisenstein_coc} is (a rational multiple of) the representative of the cohomological class which corresponds to the holomorphic Eisenstein series
\[
E_{2k}(z)=\sump_{m,n} \frac 1{(m z + n)^{2k}}
\]
under the Eichler-Shimura isomorphism between $M_{2k}\oplus \overline S_{2k}$ and $H^1(\Gamma, V_{2k-2}(\Co))$. Let us briefy explain the relation of our theory to the Eisenstein series. The nonholomorphic Eisenstein series~\eqref{nhe} is a Maass form in a sense that it is $\Gamma$-invariant function in the upper halfplane satisfying the Laplace equation $\Delta_z E(z,s) = s(1-s) E(z, s)$ where $\Delta_z = (z-\bar z)^2 \frac{\partial^2}{\partial z \partial \bar z}$. Following~\cite{LewisZagier, BruggemanLewisZagier} one can define the two ``periods'' $\psi_1 \in H^1(\Gamma, \V_{2k})$ and $\psi_2 \in H^1(\Gamma, V_{2k-2})$ of $E(z,k)$. Representatives of $\psi_1$ and $\psi_2$ are defined by
\[
g \mapsto \int_{z_0}^{g z_0}  \Big[ E(z,k), \left( \frac{|X-z|^2}{y}\right)^{-k} \Big], \qquad g \mapsto \int_{z_0}^{g z_0}  \Big[ E(z,k), \left( \frac{|X-z|^2}{y}\right)^{k-1} \Big]
\]
correspondingly, where $z_0$ is an arbitrary point in the upper halfplane and the bracket $[\cdot, \cdot]$ is Green's form, $[u(z),v(z)] = \frac{\partial u}{\partial z} v dz + u \frac{\partial v}{\partial \bar z} d \bar z$. The Green form has the following properties:
\begin{itemize}
\item[(i)] $[u, v]$ is closed if both $u$ and $v$ are eigenfunctions of $\Delta$ with the same eigenvalue;
\item[(ii)] If $z \mapsto g(z)$ is any holomorphic change of variables, then $[u \circ g, v \circ g] = [u,v] \circ g$.
\end{itemize}
For every fixed $X$ both $\left( \frac{|X-z|^2}{y}\right)^{-k}$ and $\left( \frac{|X-z|^2}{y}\right)^{k-1}$ are eigenfunctions of $\Delta$ with the eigenvalue $k (1-k)$. Therefore both Green forms above are closed due to (i). Notice that $z \to \left( \frac{|X-z|^2}{y}\right)^{-k}$ and $z \to \left( \frac{|X-z|^2}{y}\right)^{k-1}$ are $\SL(2,\R)$-equivariant maps from the upper halfplane to $\V_{2k}$ and $V_{2k-2}$ correspondingly. Thus it follows from (ii) that both forms are $\Gamma$-equivariant (with values in the corresponding spaces), so the above integrals indeed define 1-cocycles. Furthemore, one can check that for every fixed $z$
\[
\mathfrak I \left(\dfrac{|X-z|^2}y \right)^{-k} = \frac{(2k-3)!!}{(2k-4)!!} \; \pi \; \left(\dfrac{|X-z|^2}y \right)^{k-1},
\]
so the periods are related by
\begin{equation}\label{rel_pds}
\mathfrak I \psi_1 = \frac{(2k-3)!!}{(2k-4)!!} \; \pi \; \psi_2.
\end{equation}

We claim that $\psi_1 = i \frac k 2 \frac{(2k-1)!!}{(2k)!!} \; \pi \; [\phi]$, where $[\phi]$ is the cocycle class from Theorem~\ref{gen_eisenstein_cocyle}. Indeed, let us take the representative of $\psi_1$ given above and let $z_0 \to \infty$. Then the limiting 1-cocycle sends $T \mapsto 0$ and
\[
S \mapsto \int_{\infty}^0 \Big[ E(z,k), \left( \frac{|X-z|^2}{y}\right)^{-k} \Big] = i k X \int_0^{\infty} \frac {t^k}{(X^2+t^2)^{k+1}} E(i t, k) dt
\]
\[
= i \frac k 2 \frac{(2k-1)!!}{(2k)!!} \; \pi \; \sign(X) \sums_{p, q \ge 0} \frac 1{(p \; |X|+q)^{2 k}},
\]
and we see it is a multiple of the cocycle $\phi$ from Lemma~\ref{coc_def}. Here the first equality is proven in~\cite{LewisZagier} and the second calculation is due to Chang and Mayer~\cite{ChangMayer, LewisZagier}.

So far from~\eqref{rel_pds} we have that $\mathfrak I [\phi] = \frac{i(2k-1)}{4} \; \psi_2$. We now use this to show the following:
\begin{proposition}
For $k \in \Z_{\ge 2}$ we have
\begin{equation}\label{coc_equiv}
\Big[ E(z,k), \left( \frac{|X-z|^2}{y}\right)^{k-1} \Big]
\;\equiv\; \alpha_k \; i \; E_{2k}(z) (X-z)^{2k-2} dz,
\end{equation}
with $\alpha_k = 2^{2k-1}\,(1-2k) \in \Q$, where $\omega_1 \equiv \omega_2$ for $\Gamma$-equivariant $V_{2k-2}$-valued {\bf 1-forms} $\omega_1$ and $\omega_2$ means that they differ by the full differential of a $\Gamma$-equivariant $V_{2k-2}$-valued function.
\end{proposition}

This proposition implies that $\mathfrak I [\phi]$ is a rational multiple of the class of $E_{2k}(z) (X-z)^{2k-2} dz$, so we get an alternative proof of Theorem~\ref{gen_eisenstein_cocyle}.

\begin{proof}
The operators
\[
\delta_w = \partz + \frac w{z-\bar z}, \;\;\; \bar\delta = (z-\bar z)^2\partzc
\]
intertwine the action of $\PSL(2,\R)$ on the functions in the upper halfplane in weights $w$, $w+2$ and $w$, $w-2$ correspondingly. Then $\bar\delta \delta_w - \delta_{w-2} \bar\delta = w$. Let $\Delta_w = \bar\delta \delta_w$, and denote by $\HH_{w,\lambda} = \{ u \mid \Delta_w u = \lambda u \}$ the space of eigenfunctions in weight $w$. Then
\[
\delta_w: \HH_{w, \lambda} \to \HH_{w+2, \lambda+w+2}, \qquad
\bar\delta: \HH_{w, \lambda} \to \HH_{w-2, \lambda-w}.
\]
For $u \in \HH_{w, \lambda}$ and $v \in \HH_{-w, \lambda-w}$ we introduce the generalized Green form as
\[
[u, v]_w = \delta_w (u) \; v \; dz + u \; \bar\delta (v) \; \frac{d \bar z}{(z-\bar z)^2} = \delta_w (u) \; v \; dz + u \; \partzc (v) \; d \bar z.
\]
It is a closed form, and for $g \in \PSL(2,\R)$ one has $[g u, g v] = g [u,v]$. Also
\[
[u,v]_w + [v,u]_{-w} = (\delta_w (u) \; v + \delta_{-w} (v) \; u)dz + \partzc(u v) d \bar z
\]
\[
= (\partz(u v) + \frac w{z-\bar z}u v - \frac w{z-\bar z}u v) dz  + \partzc(u v) d \bar z = d(uv)
\]
and
\[
[\bar\delta v, \delta_w u]_{-w-2} = \delta_{-w-2} \bar\delta v \; \delta_w u \; dz + \bar\delta v \; \bar\delta \delta_w u \frac{d \bar z}{(z-\bar z)^2}
\]
\[
= \lambda v \delta_w u \; dz + \bar\delta v \lambda u \frac{d \bar z}{(z-\bar z)^2} = \lambda [u, v]_w.
\]
Therefore we have proven that
\[
[u,v]_w \equiv -\frac 1 {\lambda} [\delta_w u, \bar\delta v]_{w+2} \quad\quad (u \in \HH_{w,\lambda},\quad v\in \HH_{-w,\lambda-w} )\,.
\]
If we apply this transformation $k-1$ times to the functions
\[
u = E(z,k), \;\;\; v=\left( \frac{|X-z|^2}{y}\right)^{k-1} \; \in \HH_{0,k(1-k)}.
\]
we get~\eqref{coc_equiv} since
\[
\delta_{0}^{k} E(z, k) = (- 2 i)^k \frac{(2k-1)!}{(k-1)!} E_{2k}(z)
\]
and
\[
(\bar\delta)^{k-1} \left( \frac{|X-z|^2}{y}\right)^{k-1} = (2 i)^{k-1} (k-1)! (X-z)^{2k-2}.
\]
\end{proof}.

\subsection{Homological formulation of the higher ``Kronecker limit formula''}

Notice that there is an $\SL(2,\R)$-equivariant pairing $\V_{2k} \otimes \V_{2-2k} \to \R$ given by
\[
\langle f \; ,\; g \rangle = \int_{\R} f(t) g(t) dt.
\]
If $g \in V_{2k-2} \subset \V_{2-2k}$ is a polynomial then we have $\left\langle f , g \right\rangle = \bigl( {\mathfrak I} f , g \bigr)$ where ${\mathfrak I}$ is the map~\eqref{integral_map} and the $\SL(2,\R)$-equivariant pairing on polynomials is given by the formula
\[
\Bigl( \,\sum_{i=0}^{2k-2} a_iX^i, \; \sum_{i=0}^{2k-2} b_iX^i \,\Bigr)=\sum_{i=0}^{2k-2} (-1)^i\>\frac{a_i \, b_{2k-2-i}}{\binom{2k-2}{i}}.
\]
We denote by the same brackets the pairings on homology and cohomology
\[
\bigl\langle \; \cdot \; ,\; \cdot \; \bigr\rangle \; : \; H^1\left(\Gamma,\V_{2k}\right) \otimes H_1(\Gamma,\V_{2-2k}) \to \R,
\]
\[
\bigl( \; \cdot \; , \; \cdot \; \bigr) \; : \; H^1\left(\Gamma,V_{2k-2}\right) \otimes H_1(\Gamma,V_{2k-2}) \to \R.
\]


Let $Q = AX^2 + B XY + C Y^2$ be an integer quadratic form of discriminant $D$. We also denote by $Q$ the function $Q(x,1)$ of $x \in \R$. Then $Q^{k-1} \in V_{2k-2}$. The stabilizer of $Q$ in $\Gamma$ is isomorphic to $\Z$, and we pick that generator $\gamma_Q \in \rm Stab_{\Gamma} Q$ for which $\gamma_Q(x)<x$ whenever $Q(x)<0$. With this condition we then have $\gamma_{g Q} = g \gamma_Q g^{-1}$, and therefore the class of the 1-cycle $\gamma_Q \otimes Q^{k-1}$ in $H_1(\Gamma, V_{2k-2})$ depends only on the $\Gamma$-orbit of $Q$. Since $\Gamma$-orbits correspond to narrow ideal classes, we can give the following definition.

\begin{definition} Let for a narrow class of ideals $\B$ the elements $\xi_{\B} \in H_1(\Gamma, V_{2k-2})$ and $\eta_{\B} \in H_1(\Gamma,\V_{2-2k})$ be the classes of 1-cycles $\gamma_Q \otimes Q^{k-1}$ and $\gamma_Q \otimes Q^{k-1} \mathbf{1}_{\{Q < 0\}}$ correspondingly, where $Q$ is any integer quadratic form in $\B$.
\end{definition}

Notice that $-Q$ corresponds to $\B^{\dagger} = \B'^*$ if $Q$ corresponds to $\B$, and $\gamma_{-Q} = \gamma_Q^{-1}$. Therefore $\xi_{\B^{\dagger}} = (-1)^k \xi_{\B}$ and
\begin{equation}\label{narrow_comb}
\eta_{\B} + (-1)^k \eta_{\B^{\dagger}} = \xi_{\B}.
\end{equation}

\begin{theorem}\label{homological_zeta_value} Let $[\phi_k]$ be the cocycle class from Theorem~\ref{gen_eisenstein_cocyle}. Then for every narrow ideal class $\B$
\[
\Big \langle [\phi_k] \;,\; \eta_{\B} \Big\rangle = (-1)^{k-1} \frac{(k-1)!^2}{(2k-2)!} D^{k-\frac 12} \; \zeta(\B, k).
\]
\end{theorem}

\begin{proof}
Let us pick a form $Q$ in the class $\B$ and a number $\alpha$ such that $Q(\alpha) > 0$. Due to Theorem~\ref{gen_eisenstein_cocyle} there exists an $f \in \V_{2k}^{\circ}$ such that the 1-cocycle 
\be\lb{coca}
g \mapsto f_{\alpha, g \alpha} + (1-g) f
\ee
(with $f_{\alpha,\beta}$ defined by~\eqref{pseudo_measure}) is $\V_{2k}$-valued. Notice, that we can choose $f$ so that it vanishes outside of any small neighbourhood of $\alpha$. The 1-cocycle~\eqref{coca} is a representative of $[\phi_k]$, and pairing it with $\gamma_Q \otimes Q^{k-1} \mathbf{1}_{\{Q < 0\}}$ gives
\[
\bigl \langle [\phi_k] \;,\; \eta_{\B} \bigr\rangle \= \int \limits_{Q < 0} Q(x)^{k-1} \sums_{\alpha < \frac p q < \gamma_Q(\alpha)}\frac 1{(q x - p)^{2k}} dx.
\]
Notice that~\eqref{int_formula} can be rewritten as
\[
\D_n F(Q) \= \frac{(-1)^n \sign(A)}{n!} \int \limits_{\frac{Q}A < 0} Q(x)^n  F^{(2n+1)}(x) dx
\]
and together with~(iv) of Proposition~\ref{diff_operator_properties} it gives the formula
\[
 \int \limits_{Q<0} \frac{Q(x)^n}{(x-T)^{2n+2}} dx \= (-1)^n \frac{n!^2}{(2n)!} \frac{D^{n+\frac 12}}{Q(T)^{n+1}}.
\]
Therefore
\[
(-1)^{k-1} \frac{(2k-2)!}{(k-1)!^2} D^{\frac 12-k} \; \bigl \langle [\phi_k] \;,\; \eta_{\B} \bigr\rangle \= \sums_{\alpha < \frac p q < \gamma_Q(\alpha)} \frac 1{Q(p,q)^{k}} dx
\]
\[
\= N(\frak b)^k \; \sum \limits_{\lambda \in \frak b \slash \varepsilon, \; \lambda \gg 0} \frac 1{N(\lambda)^k}
\= \z(\B', k) \= \z(\B, k).
\]
Here $b$ is any ideal in the class $\B$, and the last equality is true because the zeta functions of $\B$ and $\B'$ coincide.
\end{proof}

Notice that together with~\eqref{narrow_comb} this statement yields
\be\lb{Scz}
\zeta(\B, k) + (-1)^k \z(\B^{\dagger}, k)   = (-1)^{k-1} \frac{(2k-2)!}{(k-1)!^2} D^{\frac 12-k} \; \bigl( \mathfrak I [\phi_k] \; , \; \xi_{\B} \bigl),
\ee
which gives the Siegel-Klingen theorem again, since $\zeta(\B^{\dagger}, s)=\zeta(\B^*, s)$ and both classes on the right are rational, the cocycle $\mathfrak I [\phi_k]$ being given explicitly by equation~\eqref{eisenstein_coc}. Equality~\eqref{Scz} is very similar to Theorems~5 in~\cite{Sczech2}, where values of L-functions over the real quadratic fields are also given as a homological pairing at those points where the values are rational. The main difference between the two results is that, although both the cycle and the cocycle occurring are the same (we omit the calculation showing this in the case of the
cocycle), the explicit descriptions of the Eisenstein cocycle as a
rational class (Theorem~3 of~\cite{Sczech2} and Theorem~3 of our
paper) look quite different.

The relation of the above theorem to the higher KLF (Theorem~\ref{higher_formula}) is a consequence of the following proposition.

\begin{proposition} Let $\Red(\B) = \{ w_1, \dots, w_{l(\B)}\}$ with $w_i = b_i - 1/w_{i+1}$ and $Q_i$ be the integer quadratic form of discriminant $D$ with a root $w_i$. Then   
\[
\xi_{\B}\=\Bigl[\,\sum_i T^{b_i}S \otimes Q_i^{k-1}
\Bigr]  \quad \text{and} \quad \eta_{\B}\=\Bigl[\,\sum_{i} T^{b_i}S \otimes Q_i^{k-1}\cdot
\mathbf{1}_{\{Q_i < 0\}}\,\Bigr].
\]
\end{proposition}
\begin{proof} Since $T^{b_i} S \, Q_i = Q_{i+1}$, one needs to observe that 
\[
\gamma_{Q_1} = T^{b_{l(\B)}} S \, T^{b_{l(\B)-1}} S \cdots T^{b_1} S
\]
and therefore the 1-cycle $\gamma_{Q_1} \otimes Q_1^{k-1}$ is homologous to $\sum_i T^{b_i}S \otimes Q_i^{k-1}$. In the same way $\gamma_{Q_1} \otimes Q_1^{k-1}\cdot \mathbf{1}_{\{Q_1 < 0\}}$ is homologous to the other 1-cycle given in the proposition.
\end{proof}

\section{Twists of $\F_k$ and applications}

In this final section we consider the twisted version of the function $\F_k$ defined by the series
\[
\sum \limits_{p=1}^{\infty} \frac{\chi(p) \psi(p x)}{p^{k-1}} \qquad ( x \in \R_+, \; k \ge 2),
\]
where $\chi$ is a nontrivial Dirichlet character. Notice that here we do not have to subtract $\log(px)$ from $\psi(p x)$ to get convergence when $k=2$, because $\sum \limits_{p=1}^{\infty} \dfrac{\chi(p) \log(px)}{p}$ converges (to $L(1,\chi) \log(x) - L'(1,\chi)$). Instead of inserting a character we could have imposed congruence conditions on $p$. Therefore the new functions are relevant when one wants to study zeta functions for ray classes rather than ordinary ideal classes.

\subsection{The twisted function $\F^{\chi}_k$}

\begin{definition}
For a nontrivial Dirichlet character $\chi : \Z \to \Co$ and an integer $k \ge 2$ we define
\[
\F_{k}^{\chi}(x) = \sum_{p=1}^{\infty} \frac {\chi(p) \psi_0(p x)}{p^{k-1}}, \;\;\; x > 0
\]
where $\psi_0(x) = \psi(x)+\frac 1{2x}$.
\end{definition}

Here we replace $\psi$ by $\psi_0$ in order to have the formula
\begin{equation}\label{D_k_twisted}
\left( \D_{k-1} \F_{2k}^{\chi} \right) (x,y) =  \sums_{p, q \ge 0}  \chi(p) \left( \frac {x-y}{(p x+q)(p y + q)}\right)^k \; .
\end{equation}
(Recall that $*$ on the summation sign means counting the boundary terms with the coefficient $\frac 1 2$.) As in Theorem~\ref{func_eq_thm}, we immediately get
\[
\F_k^{\chi}(x) \; \sim  \; L(k,\chi) \log(x) - L'(k,\chi) + \sum \limits_{r=2}^{\infty} \frac{\z(1-r) L(k+r-1,\chi)}{x^r}
\]
as $x \to \infty$, and
\[
\F_k^{\chi}(x) \; \sim  \;  -\frac{L(k,\chi)}{2x} + \sum \limits_{r=1}^{\infty} (-1)^r \z(r) L(k-r,\chi) x^{r-1}
\]
as $x \to 0$. Concerning the functional equations, there are now many of them and the theory in general depends on the conductor of $\chi$. Instead of studing the picture in full generality, let us consider a particular and probably the simplest example $\chi = \left( \dfrac{\cdot}{3}\right)$. To get the functional equation for
\[
\psi_k^{\chi}(x) := \frac{(-1)^k}{(k-1)!} \left(\frac{d}{dx}\right)^{k-1} \F_k^{\chi}(x) = \sums_{\frac p q \in [0, \infty ]} \frac{\chi(p)}{(p x + q)^k}
\]
(here and below, the summation is taken over {\it all} fractions $\frac p q$, not necessarily reduced, but with $q \ge 0$) we break up the quadrant of summation as
\be \label{cones}
\frac p q \;\in\; \Big[0, \infty \Big] \= \Big[0, 1 \Big] \cup \Big[1, \frac 3 2\Big] \cup \Big[\frac 32, 2 \Big] \cup \Big[2, 3 \Big] \cup \Big[3, \infty \Big]\;.
\ee
The condition $\dfrac c d \le \dfrac p q \le \dfrac a b$, where $\begin{pmatrix} a & b\\ c& d\\ \end{pmatrix}$ is a matrix in $\SL(2,\Z)$ with nonnegative entries, can be written as $(p \quad q) = (P \quad Q) \begin{pmatrix} a & b\\ c& d\\ \end{pmatrix}$ with $P, Q \ge 0$, and the intervals $[0,1]$, \dots, $[3,\infty]$ in the decomposition~\eqref{cones} have been chosen so that either $3 | a$ or $3 | c$ in each case. Now using
\[
\sums_{\frac c d \le \frac p q \le \frac a b} \dfrac{\chi(p)}{(p x + q)^{k}} = \sums_{P,Q \ge 0} \dfrac{\chi(p)}{((a P + c Q) x + b P + d Q)^{k}}
\]
\[
=  \sums_{P,Q \ge 0} \dfrac{\chi(a P + c Q)}{(P (a x + b) + Q(c x + d))^{k}}
=\begin{cases}
\frac{\chi(a)}{(c x + d)^k} \; \psi_k^{\chi} \left(\frac{a x + b}{c x + d} \right), \text{ if} \;\; 3 | c,\\
\frac{\chi(c)}{(a x + b)^k} \; \psi_k^{\chi} \left(\frac{c x + d}{a x + b} \right)), \text{ if} \;\; 3 | a\\
\end{cases}
\]
and summing over the five intervals in~\eqref{cones}, we obtain
\[
\psi_k^{\chi} (x) = \psi_k^{\chi}(x+1)+\frac 1{(3 x + 2)^k} \; \psi_k^{\chi}\left(\frac{x + 1}{3 x + 2} \right) - \frac 1{(3 x + 2)^k}  \; \psi_k^{\chi}\left(\frac{2 x + 1}{3 x + 2} \right)
\]
\begin{equation}\label{func_eq_3}
-\frac 1{(3 x + 1)^k} \; \psi_k^{\chi}\left(\frac{2 x + 1}{3 x + 1} \right)+\frac 1{(3 x + 1)^k} \; \psi_k^{\chi}\left(\frac{x}{3 x + 1} \right).
\end{equation}
Integrating this equation $k-1$ times gives the 6-term functional equation for $\F_k^{\chi}$ with an unknown polynomial of degree $k-2$, whose coefficients can be found using the asymptotic expansions. For example, when $k=2$ we have
\[
\F_2^{\chi}(x) +\F_2^{\chi} \left(\frac{x + 1}{3 x + 2} \right) + \F_2^{\chi}\left(\frac{2 x + 1}{3 x + 2} \right)
\]
\[
= \F_2^{\chi}(x+1) + \F_2^{\chi}\left(\frac{2 x + 1}{3 x + 1} \right)+ \F_2^{\chi}\left(\frac{x}{3 x + 1} \right).
\]
(In this case there is no additive correction term.)

\vskip 2pc

{\bf Remark.} Actually, one can define 1-cocycles for $\Gamma_1(3)$ using the sums $\sum \limits^{\qquad \star}_{p / q \in [\alpha, \beta]} \dfrac{\chi(p)}{(p x + q)^{k}}$ as above. Let $\W_k^\circ$ be the space of functions $f : \R \to \R$ continuous at all but finite number of points with the action of $g = (\begin{smallmatrix}a&b\\c&d\end{smallmatrix}) \in \SL(2,\R)$ given by
\[
(f \,|\, g)\, (x) = \frac{\sign(c x + d)}{|c x + d|^k} \; f \Bigl(\frac{a x + b}{c x + d}\Bigr).
\]
Analogously to~\eqref{pseudo_measure}, the formula
\[
f_{\alpha,\beta}(x) = \begin{cases}
\phantom-\underset{\frac p q \in [\alpha,  \beta]}\sums \frac {\chi(p) \; \sign (q x - p)} {|q x - p|^{k}},\; & x \in (\beta, \alpha)\\
- \underset{\frac p q \in \; [\beta, \alpha]} \sums \frac {\chi(p) \; \sign (q x - p)} {|q x - p|^{k}}, \; & x \in (\alpha, \beta)\,\\
\end{cases}
\]
defines a $\Gamma_1(3)$-equivariant pseudo-measure on $\Proj$ with values in $\W_k^\circ$, hence we get a cocycle class in $H^1(\Gamma_1(3), \W_k^\circ)$.

\subsection{Computation of Stark's units and Stark-Gross regulators}
We now show how to apply our formulas to verifications of Stark's conjecture and its higher weight analogs. Stark's conjecture describes the special values at $s=1$ of Artin L-functions $L(s,\rho)$ in terms of logarithms of units in the appropriate abelian extension $H$ of the base field $F$. A generalization was given by Gross~(\cite{Gross}) in which the values $L(k,\rho)$ for $k \ge 1$ are given in terms of Borel regulators on the $K$-groups $K_{2k-1}(H)$. Combining this with the conjecture of the second author expressing Borel regulators in terms of higher polylogarithms~(\cite{Texel}), one is led to the conjecture that all values $L(k,\chi)$ of Artin L-functions at positive integer arguments can be written in terms of the $k$th polylogarithm function $Li_k(x)$ evaluated at algebraic arguments $x$ (again belonging to the same abelian extension $H$ of the base field). For the case of imaginary quadratic fields, where the corresponding Kronecker limit formula is the one described briefly in the introduction, this was discussed in detail in~\cite{GanglZagier}. Here we give the corresponding discussion for real quadratic fields using the twisted Kronecker limit formula. Our examples will be for $k=1$ (the case of the original Stark conjecture) and $k=2$, where the polylogarithms become dilogarithms and the $K$-group $K_{2k-1}(H)=K_3(H)$ is simply the Bloch group $B(H)$, for whose definition we again refer to~\cite{Texel} or~\cite{GanglZagier}.    

Let $\mathcal O$ be the ring of integers in the real quadratic field $K$. We need an ideal $\frak f$ of $\mathcal O$ such that the condition $\varepsilon \equiv 1 \pmod {\frak f}$, $\varepsilon$ a unit, implies $\varepsilon' > 0$. Then there are characters on the ray class group modulo $\frak f$ ramified at only one of the two infinite places of $K$. We will choose $K=\Q(\sqrt {13})$ and $\frak f = \left( \frac {1-\sqrt{13}} 2 \right)$.
Then $\mathcal O^\times = \langle \pm \varepsilon_0 \rangle$ with $\varepsilon_0 = \frac{3+\sqrt {13}}2$, and $\varepsilon_0 \equiv -1 \pmod {\frak f}$. Therefore the condition $\varepsilon \equiv 1 \pmod {\frak f}$ is equivalent to $\varepsilon \in (- \varepsilon_0)^{\Z} = (\varepsilon_0')^{\Z}$, hence $\varepsilon' > 0$.

For each ray class $\frak C$ modulo $\frak f$, choose a representative $\frak a$ of $\frak C$ (so $(\frak a, \frak f) = 1$ and we can change $\frak a$ to $\lambda \frak a$ with $\lambda \equiv 1 \pmod {\frak f}$) and pick an ideal $\frak b$ in the (ordinary) inverse ideal class to $\frak a$ and a generator $\alpha$ of $\frak a \frak b$. Then
\[
L(\frak C, s) = N(\frak b)^s \sign(\alpha) \underset{\begin{smallmatrix}\beta \in \frak b / \varepsilon_0',\\ \beta \equiv \alpha (\rm mod \; \frak b \frak f) \end{smallmatrix}} \sum \frac{\sign \beta'}{|N(\beta)|^s}
\]
depends only on $\frak C$ and $\exp \Big(\z'(\frak C, 0)\Big)$ is expected to be a unit. In our example, choose simply $\frak a = \frak b = \mathcal O$ and $\alpha = 1$. Then
\[
L(\mathcal O, s) = \underset{\begin{smallmatrix}\beta \in \mathcal O / \varepsilon_0',\\ \beta \equiv 1 (\rm mod \; \frak f) \end{smallmatrix}} \sum \frac{\sign \beta'}{|N(\beta)|^s} = \sums_{p,q \ge 0} \left[ \frac{\chi(p)+\chi(p-q)}{(p^2+5 pq + 3 q^2)^s} - \frac{\chi(p)}{(3 p^2+7 pq + 3 q^2)^s}\right]
\]
with $\chi = \left( \dfrac{\cdot}{3}\right)$, and
\[
\sums_{p,q \ge 0}  \frac{\chi(p-q)}{(p^2+5 pq + 3 q^2)^s} = \sums_{p \ge q \ge 0} + \sums_{q \ge p \ge 0}
\]
\[
=  \sums \limits_{p,q \ge 0} \left[ \frac{\chi(p)}{(p^2+7 pq + 9 q^2)^s} - \frac{\chi(p)}{(3 p^2 + 11 pq + 9 q^2)^s} \right] \;,
\]
where we made substitutions $(p, q) \mapsto (p+q,q)$ and $(p, q) \mapsto (q,p+q)$ in the first and the second sums correspondingly. Hence for $k \ge 1$ we get using~\eqref{D_k_twisted} that
\[
{13}^{\frac k2} L(\mathcal O, k) = \D_{k-1} (\F_{2 k}^{\chi} ) \left(\frac{5+\sqrt{13}}6, \frac{5-\sqrt{13}}6 \right) + \D_{k-1} (\F_{2 k}^{\chi} ) \left(\frac{7+\sqrt{13}}{18}, \frac{7-\sqrt{13}}{18} \right)
\]
\[
- \D_{k-1} (\F_{2 k}^{\chi} ) \left(\frac{11+\sqrt{13}}{18}, \frac{11-\sqrt{13}}{18} \right) - \D_{k-1} (\F_{2 k}^{\chi} ) \left(\frac{7+\sqrt{13}}{6}, \frac{7-\sqrt{13}}{6} \right).
\]

\vskip 2pc

Let us compute $L(\mathcal O, 1)$ and $L(\mathcal O, 2)$. From the tables of values

\begin{table}[!h]
\centering
\begin{tabular}{c|r|r}
$x$ & $\F_2^{\chi}(x)\qquad\qquad$ & $\F_2^{\chi}(x')\qquad\qquad$ \\[1ex]
\hline
$(5+\sqrt{13})/6$ & $-0.221258722400679\dots$ & $-2.087528683598576\dots$\\
$(7+\sqrt{13})/18$ & $-0.901613498337444\dots$ & $-2.501022141187798\dots$\\
$(11+\sqrt{13})/18$ & $-0.631117746987411\dots$ & $-1.269461158816449\dots$\\
$(7+\sqrt{13})/6$ & $-0.083545973555317\dots$ & $-0.939154027903259\dots$\\
\end{tabular}
\end{table}

\begin{table}[!h]
\centering
\begin{tabular}{c|r}
$x$ & $\D_1 \F_4^{\chi}(x, x')\qquad\qquad$ \\[1ex]
\hline
$(5+\sqrt{13})/6$ & 6.253557907531478\dots\\
$(7+\sqrt{13})/18$ & 6.143437556837824\dots\\
$(11+\sqrt{13})/18$ & 0.700242692864336\dots\\
$(7+\sqrt{13})/6$ & 0.758740696880221\dots\\
\end{tabular}
\end{table}


we find
\[
L(\mathcal O, 1) = 0.546858715139901\dots
\]
and
\[
L(\mathcal O, 2) = 0.841385544201903\dots
\]
(For $k=2$ we do not give all 16 values $\F_4^\chi(w_i)$, 
$\F_4^\chi(w'_i)$,
$(\F_4^\chi)'(w_i)$ and $(\F_4^\chi)'(w'_i)$ separately, but only tabulate the combinations $\D_1\F_4^\chi(w_i,w_i')$.)





\vskip 2pc

Since ${39}^{\frac s 2} \frac{\Gamma(s)}{(2 \pi)^s} L(\mathcal O, s)$ is symmetric with respect to $s \longleftrightarrow 1-s$, we have
\[
L'(\mathcal O, 0) = \frac{\sqrt{39}}{2 \pi} L(\mathcal O, 1) = 0.543535072497869\dots
\]
This equals numerically to $\log(\alpha)$, where 
\[
\alpha = \frac 1 2 \Biggl( \frac{1+\sqrt{13}}2 + \sqrt{\frac{-1+\sqrt{13}}2}\;\Biggr)
\]
is a real solution of $x^4-x^3-x^2-x+1=0$, therefore a unit in accordance with Stark's conjecture (which can be proven in this case).


Let $H = \Q(\alpha)$, an extension of $K$ of order 2. It has two real places and a complex one. Therefore its Bloch group $B_2(H)$ has rank 1. The element
\[
\xi_2 \= \- 2 \, [\alpha] \+ 2 \, [ \alpha^3] \+ [\alpha (1-\alpha)^2] 
\]
then generates $B_2 (H)$ up to torsion, and we check numerically that
\be\label{dilog_eq}
L(\mathcal O,2) \= \frac{ 16 \, \pi^2}{{39}^{3/2}} \; \rm D(\sigma( \xi_2))
\ee
where $\sigma: H \to \Co$ is the complex embedding in which $\Img \sigma(\alpha) > 0$
and ${\rm D}(z) = \Img (\Li_2(z) + \log |z| \log(1-z))$ is the Bloch-Wigner dilogarithm function. This particular identity
can be proved rigorously
(because $L(\mathcal O,s)=\zeta_H(s)/\zeta_K(s)$ and it is known how
to express values of Dedekind zeta functions at $s=2$ in terms of
dilogarithms), but the numerical method illustrated here would also
work for fields $K$ with $h(K)>1$ or for $s=k\ge3$, where the corresponding identities would in general only be conjectural.
For instance, for the $L$-function treated in this subsection we
find after some computation
\[
L(\mathcal O,3) \= 0.948978902888892\cdots  \= \frac{16 \,\pi^3}{39^{5/2}} \LL_3(\xi_3)
\]
and
\[
L(\mathcal O,4) \= 0.983924877405875\cdots = \frac{128 \, \pi^{4}}{ 3 \cdot {39}^{7/2}} \LL_4 \bigl(\sigma(\xi_4)\bigr)
\]
with
\[\bal
\xi_3 &\= 7\,[1-\alpha^{-1}] \- 7 \, [1-\alpha] \+ [\alpha^{-3} (1-\alpha)^2] \- [\alpha \,(1-\alpha)^2]  \\
&\+ 3 \, [\alpha \,(\alpha-1) ] \- 3 \, [\alpha^{-2} (1-\alpha)]\; ,
\eal\]
% This element gives L_3(\xi_3)/12:
%1 [1, 1, 0] [1, -1, 0] 
%1 [1, 3, 0] [1, -3, 0]
%-1 [1, 0, -1] [-1, 1, -1]
%-1 [1, 2, -1] [-1, -1, -1]
%-1 [-1, 1, -1] [1, 0, -1]
%1 [-1, 1, 1] [1, -2, 1]
%1 [1, 2, 0] [1, -2, 0]
%3 [1, 1, -1] [-1, 0, -1]
%1 [1, 2, -2] [1, 0, -2]
%-1 [1, 3, -1] [-1, -2, -1]
%2 [-1, 0, -1] [1, 1, -1]
%-1 [-1, 1, -2] [-1, 1, -2]
% where c [a_1,b_1,c_1] [a_2,b_2,c_2] --> c [a_1 e^b_1 (1-e)^c_1] - c [a_2 e^b_2 (1-e)^c_2]
\[
\xi_4 \= \- 75 [\alpha]  \- 102 [\alpha^2] \- 81 [-\alpha^3] \- 39 [-\alpha^4] \- 21 [-\alpha^7] \+ 4 [-\alpha^9] \+ 3 [\alpha^{11}]
\]
and $\LL_m(z) = \Rea_m \Bigl( \sum \limits_{k=0}^{m-1} \dfrac{2^k \, B_k}{k!} \log(|z|)^k \Li_{m-k}(z) \Bigr)$ for $m \ge 2$, where $\Rea_m$  
denotes $\Img$ or $\Rea$ according $m$ is even or odd. We have checked that the elements $\xi_3$ and $\xi_4$ indeed belong to the higher Bloch groups $B_3(H)$ and $B_4(H)$ correspondingly. Since the ${\rm Gal}(H / K)$-conjugate to $\alpha$ is $1/\alpha$ one easily sees that $\xi_3$ is antiinvariant with respect to the Galois involution. 
Similarly, we find 
\[
L(\mathcal O,5) \= 0.994927260665932\cdots = \frac{160 \, \pi^{5}}{ 3 \cdot {39}^{9/2}} \LL_5 \bigl(\xi_5)
\]
and
\[
L(\mathcal O,6) \= 0.998386179720050\cdots = \frac{512 \, \pi^{6}}{ 15 \cdot {39}^{11/2}} \LL_6 \bigl(\xi_6)
\]
for elements of the higher Bloch groups $B_5(H)$ and $B_6(H)$, namely, 
\[\bal
\xi_5 &\= -294[\alpha (1-\alpha)^2]\+602[\alpha (\alpha-1)]\+6[\alpha^3(\alpha-1)^5]\+468[\alpha-1]\\
&\+375[\alpha (1-\alpha)]\+4[(\alpha-1)^3]\+117[\alpha^2(\alpha-1)]\+60[\alpha^3(1-\alpha)]\\
&\+24[\alpha^3(1-\alpha)^2]\+8[\alpha^3(1-\alpha)^3]\-81[\alpha^2(\alpha-1)^3]\-13[\alpha^4(\alpha-1)]\\
&\-354[-\alpha (1-\alpha)^2]\+2[-\alpha^3(1-\alpha)^6]\-6[-\alpha^5(1-\alpha)^2]\+240[1-\alpha]\\
&\qquad\qquad\qquad\qquad \- \quad \text{(Galois conjugate)}\,,
\eal
\]
\[\bal
\xi_6 &\= -3409[\alpha]\-1068[\alpha^3]\-835[\alpha^{11}]\+1405[-\alpha^4]\+1608[\alpha^5]\+4015[\alpha^2]\\
&\-1455[\alpha^4]\-1047[\alpha^6]\-653[\alpha^8]\-34[\alpha^{10}]\+48[\alpha^{12}]\-29[\alpha^{20}]\+3503[-\alpha]\\
&\-4059[-\alpha^2]\+1017[-\alpha^3]\-1623[-\alpha^5]\+1044[-\alpha^6]\+77[-\alpha^7]\-2509[-\alpha^9]\\
&\+20[-\alpha^{10}]\+373[-\alpha^{15}]\+13[-\alpha^{18}]\-96[\alpha^7]\+3[\alpha^{14}].
\eal\]                   

\section*{Appendix: Differentiation and integration operators}

In this appendix we study differentiation and integration operators which allow us, in particular, to pass back and forth between cocycles
in weight $2k$ and in weight $2-2k$.


The matrix $g = \begin{pmatrix} a&b\\c&d\\ \end{pmatrix} \in \GL(2,\R)$ acts on functions of two real variables in weight $(m,n)$ by the formula
\[
\bigl( F \big|_{(m,n)} \; g \bigr) (x,y) = (c x + d)^{-m} (c y + d)^{-n} F \left( \frac{a x + b}{c x + d} , \frac{a y + b}{c y + d}\right).
\]
Then $g F = F \Big|_{(m,n)} g^{-1}$ is the left group action, and we denote the space of smooth functions of two variables equipped with this action by $\W_{m,n}$. The operator
\[
\delta_m = \partx + \frac m {x-y} \; : \; \W_{m,n} \to \W_{m+2,n},
\]
satisfies $\delta_m \circ g  = (\det g) \;g \circ \delta_m$ for every $g \in \GL(2,\R)$. Let us try to invert $\delta_m$. For $b \in\Z$, we denote by $\W_{m,n}^b \subset \W_{m,n}$ the subspace of functions $F$ such that for every $y$ the expression $(x-y)^b F(x,y)$ is bounded as $x$ tends to $y$. Consider
\[
I_m : \W_{m,n} \to \W_{m-2,n}, \qquad ( I_m F )\, (x,y) = \int_y^x \left( \frac{t-y}{x-y}\right)^{m-2} F(t,y) dt.
\]
This operator is well defined on $\W^b_{m,n}$ when $b <  m-1$ and $I_m (\W^b_{m,n}) \subset \W^{b-1}_{m-2,n}$. Also it satisfies $I_m \circ g  = (\det g)^{-1} \;g \circ I_m$ for every $g \in \GL(2,\R)$ and
\[
I_{m+2} \; \delta_m \; F \; (x,y) = \int_y^x \partt \left( \left( \frac{t-y}{x-y}\right)^m  F(t,y)\right) dt
\]
\[
= F(x,y) - \frac{\lim_{t \to y} (t-y)^m F(t,y)}{(x-y)^m} = F(x,y)
\]
when $F \in W^{b}_{m,n}$ with $b<m$. Notice that $\delta_{m-2} I_m  F = F$ whenever $I_m F$ is defined. We denote  by $\delta_m^r $ and $I_m^r$ $(r \ge 0)$ the iterated operators $\delta_{m+2r-2} \circ \dots \circ \delta_{m+2} \circ \delta_m$ and $I_{m-2r+2} \circ \dots \circ I_{m-2} \circ I_m$, respectively.

\vskip 1pc

From now on we restrict to the case when the weight in $y$ is 0. We denote $\W_{m,0}$ by $\W_m$ and  $\W^b_{m,0}$ by $\W^b_m$. Then the first interesting identity is
\[
\delta^{2n+1}_{-2n} = \left(\partx \right)^{2n+1} : \W_{-2n} \to \W_{2n+2}.
\]
One can easily check it using induction. Suppose we are given the function of one variable $F(x)$, and we consider it as an element of $\W_{-2n}$. Then its $(2n+1)$st derivative $F^{(2n+1)}(x)$ belongs to $\W_{2n+2}^{0}$. Thus $I^{2n+1}_{2n+2} F^{(2n+1)} \in \W_{-2n}^{-2n-1}$. Since
\[
F(x) - \sum_{i=0}^{2n} \frac{F^{(i)}(y)}{i!} (x-y)^i \in \W_{-2n}^{-2n-1}
\]
and the $(2n+1)$st derivative of this expression in $x$ is $F^{(2n+1)}(x)$ again, we have proved the following statement.

\begin{lemma}\label{formula_preparation} For every $0 \le m \le 2n+1$
\[
\delta^{m}_{-2n} \left( F(x) - \sum_{i=0}^{2n} \frac{F^{(i)}(y)}{i!} (x-y)^i\right) = I^{2n+1-m}_{2n+2} F^{(2n+1)}.
\]
\end{lemma}

Let us write a formula for the iterate $I_{2n+2}^{m}$. To this end, and also for other applications, we consider the simple rational functions of three variables $x, y$ and $T$
\[
(T-x)^a (T - y)^b (x-y)^c.
\]
This function is equivariant in $(x,y,T)$ with triple weight
$(-a-c, -b-c, -a-b)$ and one can easily check that
\begin{equation}\label{delta_rat}
\delta_{-a-c} (T-x)^a (T - y)^b (x-y)^c = \left(\partx - \frac{a+c}{x-y} \right) (T-x)^a (T - y)^b (x-y)^c
\end{equation}
\[
= -a (T-x)^{a-1} (T - y)^{b+1} (x-y)^{c-1}.
\]
It has weight $(-a-c+2, -b-c, -a-b)$ as expected. Then
\[
\delta_{2(n-m)}^{m} \; \left(\frac{T-y}{x-y} \right)^{2n-m} (T-x)^{m}
= (-1)^m \; m! \; \left(\frac{T-y}{x-y} \right)^{2n},
\]
and the following lemma easily follows.

\begin{lemma}\label{multiple_int} For $0 \le m \le 2n$
\[
I^{m+1}_{2n+2} \; F \; (x,y) \; = \; \frac 1{m!} \int_y^x \left(\frac{t-y}{x-y} \right)^{2n-m} (x-t)^{m} F(t,x) dt.
\]
\end{lemma}

\vskip 2pc

We would like also to have an explicit formula for $\delta_{-2n}^m$. Consider the operation
\[
\delta^{-} = (x-y)^2 \party \; : \; \W_{m} \to \W_{m-2}.
\]
It intertwines the group action decreasing the weight in the variable $x$ by 2. The following operator 
\[
\xi_m: \W_m \to \W_{-m}, \qquad (\xi_m F)(x,y) = (x-y)^m F(y,x)
\]
is also equivariant and satisfies $\xi_{-m} \circ \xi_m = (-1)^m$. The operators $\delta$ and $\bar\delta$ are dual with respect to $\xi$, namely
$\xi_{m+2} \circ \delta_m = \bar\delta_{} \circ \xi_m \; : \; \W_m \to \W_{-m-2}$.

\begin{lemma}\label{duality} For every $0 \le m \le 2n$
\[
\delta^{m}_{-2n} \Bigl( \, \sum \limits_{i=0}^{2n} \frac{F^{(i)}(y)}{i!} (x-y)^i \Bigr) \= (-1)^m \frac{m!}{(2n-m)!} \left(\delta^{-} \right)^{2n-m} \Bigl(\frac{F(y)}{(x-y)^{2n}}\Bigr)\;.
\]
\end{lemma}
\begin{proof}
The left-hand side can be computed easily since
\[
\delta^{m}_{-2n} (x-y)^i = (i-2n) (i-2n+1) \cdots (i-2n+m-1) (x-y)^{i-m}.
\]
Thus the statement is true for $m = 2n$. Other cases follow from this because $f(x,y) = \sum \limits_{i=0}^{2n} \dfrac{F^{(i)}(y)}{i!} (x-y)^i$ satisfies the equation $\bar\delta \delta_{-2n} f = - 2n f$ and $\delta_m$ transforms the eigenfunctions of $\bar\delta \delta_{m}$ to the eigenfunctions of $\bar\delta \delta_{m+2}$ (since $\delta^{-} \delta_m = \delta_{m-2} \delta^{-} + m$).
\end{proof}

\vskip 2pc

\begin{proposition}\label{diff_op_properties_2}
\begin{itemize}
\item[{\rm(i)}]\quad 
$\delta_{-2n}^m \= \dfrac{m!}{(2n-m)!} \sum \limits_{i=0}^m \dfrac{(2n-i)!}{i! (n-i)!} \dfrac 1{(y-x)^{m-i}} \Bigl(\dfrac\partial{\partial x}\Bigr)^i$.

\item[(ii)] For a function of one variable $F(x)$ we have
\[
(2n-m)! (\delta^{m}_{-2n} F) (x,y) + (-1)^{m-1} \; m! \; (x-y)^{2(n-m)} (\delta_{-2n}^{2n-m} F) (y,x)
\]
\[
= \int_y^x \left(\frac{t-y}{x-y} \right)^{m} (x-t)^{2n-m} F^{(2n+1)}(t) dt.
\]
\end{itemize}
\end{proposition}
\begin{proof} (i) can be easily checked by induction (one can guess the formula directly from Lemma~\ref{duality}), and (ii) immediately follows from the three lemmas above.
\end{proof}

\bigskip

Let us now apply these statements to prove Proposition~\ref{diff_operator_properties}. From the first part of Proposition~\ref{diff_op_properties_2} we see that $\delta_{-2n}^n = n! \, \D_n^+$, which proves~(i) there. From~\eqref{delta_rat}  
\[
\frac 1{n!} \, \delta_{-2n}^n \bigl( (T-x)^{2n} \bigr) \= (-1)^n \binom{2n}{n} \Bigl( \frac{(T-x)(T-y)}{x-y}\Bigr)^n,
\]
whence~(ii) follows. In order to prove~(iv) we observe that
\[
D_n \left( \frac 1 {T-x}\right) \= \frac 1{n!} \;  \delta^n_{-2n} \left( \frac 1{T-x} - \sum \limits_{i=0}^{2n} \frac{(x-y)^i}{(T-y)^{i+1}} \right)
\]
\[
\= \frac 1{n!} \; \delta^n_{-2n} \left( \frac 1{T-x} \left(\frac{x-y}{T-y}\right)^{2n+1} \right) \=  \left(\frac{x-y}{(T-x)(T-y)}\right)^{n+1},
\]
the latter equality being a consequence of~\eqref{delta_rat}. And~(v) is a special case of the second part of Proposition~\ref{diff_op_properties_2}.

\vskip 3pc
As another application, we would like to compute the integral
\[
\mathfrak I f (X) = \int_{\R} (X-t)^{2k-2} f(t) dt
\]
for $f \in \V_{2k}$ (see Definition~\ref{V_2k_def}). 
\begin{proposition}
For $f \in \V_{2k}$ let $F$ be any function on ${\mathbb R}$ such that $f(t)=\frac{1}{(2k-2)!}F^{(2k-1)}(t)$ and define $P_{\pm}$ as the two polynomials of degree at most $2k-2$ such that $F(t)=P_{\pm}(t)+\OO(1/t)$ as $t \to \pm \infty$. Then $\mathfrak I f (X) = P_+(X)-P_-(X)$.
\end{proposition}

Notice that, since $F$ is defined up to a polynomial of degree at most $2k-2$, the difference $P_+(X)-P_-(X)$ is independent of the choice of $F$. 

\begin{proof}
If we apply $\bar\delta$ to the statement of Lemma~\ref{duality} with $n=k-1$ and $m=0$ we get
\[
(x-y)^2 \party \,\Bigl(\, \sum \limits_{i=0}^{2k-2} \frac{F^{(i)}(y)}{i!} (x-y)^i \Bigr) \= \frac 1{(2k-2)!} \left(\delta^{-} \right)^{2k-1} \Bigl(\frac{F(y)}{(x-y)^{2k-2}}\Bigr)
\]
\[
\= \frac 1{(2k-2)!} \, (x-y)^{2k} \, \bigl(\delta^{2k-1} F \bigr)(y,x) \= (x-y)^{2k} f(y).
\]
Hence
\begin{equation}\label{J_comp}
\mathfrak I f (X) \= \sum \limits_{i=0}^{2n} \frac{F^{(i)}(t)}{i!} (X-t)^i \; \Big|_{t=-\infty}^{t=+\infty} \= P_+(X)-P_-(X).
\end{equation}
\end{proof}

\bibliographystyle{plain}
\bibliography{biblio}

\vskip 5 pc
Maria Vlasenko, Max Planck Institute for Mathematics, masha.vlasenko@gmail.com
\vskip 1 pc
Don Zagier, Max Planck Institute for Mathematics and Coll\`{e}ge de France, don.zagier@mpim-bonn.mpg.de

\end{document}