\section{Effective coefficients}\label{sec:coefficients} Theorem~\ref{thm:rounding} needs, for each $\beta$, certified tables for $L_j$ $(j\le\beta)$, $I_k$ $(1\le k\le\beta)$ and $E$: in total $O(\beta^2)$ Gaussian integers of $O(\beta)$ bits, each within distance $2$ of $2^p$ times a node $z_\ell$ or a residue $h(z_\ell)(z_\ell-c)$; after division by $2^p$ the error is at most $2\cdot2^{-p}$, as in Definition~\ref{def:table}. \begin{theorem}\label{thm:generator} There is an algorithm that, given $\beta$ in unary, outputs certified tables at precision $\beta$ for all of the functions above in time polynomial in $\beta$. \end{theorem} The algorithm computes only with Gaussian rationals: it evaluates truncated power series for $\pi$, $\log2$, $\exp$ and $\Log$ with explicit tails, and rounds to the grid $2^{-p}\Z[i]$ only at the end. \subsection{Exact arithmetic and rounding} A triple $[a,b;d]$ with $a,b\in\Z$ and $d\in\N$, $d\ge1$, represents the Gaussian rational $(a+bi)/d$. Sums, products and inverses are formed by \begin{gather*} [a,b;d]+[a',b';d']=[ad'+a'd,bd'+b'd;dd'],\quad [a,b;d]\cdot[a',b';d']=[aa'-bb',ab'+ba';dd'],\\ [a,b;d]^{-1}=[ad,-bd;a^2+b^2]\quad\text{if }(a,b)\ne(0,0), \end{gather*} and these rules commute with the map to $\C$. No fraction is ever reduced, so no greatest common divisor is computed. For $m\in\N$ let \[ T^{\exp}_m(z)=\sum_{km}(-1)^{n+1}w^n/n$ has absolute value at most $\abs w^{m+1}/\bigl((m+1)(1-\abs w)\bigr)\le4(\frac34)^{m+1}$. \end{proof} Lean: \lean{CertifiedSeries.\allowbreak piRat\_error} for (1), and for (2) and (3) \lean{CertifiedGaussianRat.\allowbreak expTaylor\_large\_error} and \lean{logTaylor\_error}, which rest on Mathlib's \lean{Complex.exp\_bound'} and \lean{Complex.norm\_log\_sub\_logTaylor\_le}. The offset $31$ in (2) lets one Taylor polynomial serve the whole disc $\abs z\le16$, without argument reduction or repeated squaring. For $n\in\N$ put \[ \hat\lambda_n=-T^{\log}_{4n+1}\bigl(-\tfrac12\bigr) =\sum_{k=1}^{4n}\frac{2^{-k}}{k},\qquad \hat\Lambda_n(z)=\hat\lambda_n+T^{\log}_{4n+1}\bigl(\tfrac z2-1\bigr). \] \begin{corollary}\label{gen:log} For every $n\in\N$, $\abs{\hat\lambda_n-\log2}\le4\cdot2^{-n}$, and $\abs{\hat\Lambda_n(z)-\Log z}\le8\cdot2^{-n}$ for every $z\in D_R$. \end{corollary} \begin{proof} Since $(\frac34)^4<\frac12$, we have $(\frac34)^{4n+1}\le2^{-n}$. The first bound is Lemma~\ref{gen:series}(3) with $w=-\frac12$, because $\log2=-\Log(1-\frac12)$. For $z\in D_R$ we have $z\ne0$ by Lemma~\ref{lem:three}, so $\Log z=\log2+\Log(z/2)$, and $w=z/2-1=(z-c)/2-\frac14$ satisfies $\abs w\le\frac7{16}+\frac14<\frac34$. Lemma~\ref{gen:series}(3) and the first bound give the second. \end{proof} Lean: \lean{CertifiedGaussianRat.\allowbreak logTwo\_error} and \lean{logScaled\_error}, with \lean{CertifiedGenerator.\allowbreak geometric\_log\_rate}. \subsection{The generator} For the rest of this section fix $\beta$, write $p,M$ for $p_\beta,M_\beta$, and put \[ \nu=p+\beta+256,\qquad \eta=2^{-\nu},\qquad \varepsilon=2^{128}\eta=2^{-(p+\beta+128)}. \] The tolerance $2\cdot2^{-p}$ of Definition~\ref{def:table} is spent half on the final rounding and half on the analytic approximation. Of the $\beta+256$ guard bits beyond $p$, $\beta$ bits absorb the amplitude $j\le\beta$ of $L_j$, and the rest absorb fixed constants. \begin{definition}\label{gen:def} For $0\le\ell\beta^2$ entries. In the application $\beta\le b(N)+1$. \begin{proposition}\label{gen:time} Let $b$, $j$ and $\ell$ be functions of an input $x$, with $b$ given in unary and $j$, $\ell$ computable in polynomial time. Then the entries $P_\ell$, $R^{L_j}_\ell$, $R^{I_j}_\ell$ and $R^E_\ell$ of Definition~\ref{gen:def}, at $\beta=b(x)$, $j=j(x)$ and $\ell=\ell(x)$, are computable from $x$ in polynomial time. \end{proposition} \begin{proof} The orders $\nu$, $31+\nu$, $4\nu+1$, the precision $p$ and $M$ are linear in $\beta$, hence given in unary. Integer ring operations, floor division, the rules for triples, binomial expansions, factorials, sums of $m$ terms, $\hat\pi_m$ and $\operatorname{nr}_p$ are computable in polynomial time when $m$, $k$ and $p$ are given in unary. Definition~\ref{gen:def} composes a fixed number of them, independent of $\beta$, and compositions of polynomial-time functions are polynomial-time. (Since triples are never reduced, a Taylor polynomial of order $O(\beta)$ multiplies the bit length of its argument by $O(\beta)$. For the indices used in the application, $j\le\beta$ for $L_j$, $1\le j\le\beta$ for $I_j$, and $\ell