$1/\sqrt{\symNumReg}$ error scaling law. Again, cardinalities up to order $2^{\symPrecision+\symRegRange}\approx\num{4e9}$ can be well estimated, because $\symPrecision+\symRegRange=32$ was kept the same for both investigated configurations. For $\symPrecision=22$ a small oscillating bias becomes apparent, which is caused by approximating the periodic function $\symPowerSeriesFunc$ by a constant (see \[sec:derivation\_raw\_estimator\]).

![Relative error of the improved estimator for $\symPrecision = 22$ and $\symRegRange=10$.[]{data-label="fig:raw_corrected_estimation_error_22_10"}](raw_corrected_estimate_22_10){width="1\columnwidth"}

Maximum Likelihood Estimation {#sec:max_likelihood_estimation}
=============================

We know from \[sec:poisson\_approximation\] that any unbiased estimator for the Poisson parameter is also an unbiased estimator for the cardinality. Moreover, we know that under suitable regularity conditions of the probability mass function the estimator is asymptotically efficient [@Casella2002]. This means, if the number of registers $\symNumReg$ is sufficiently large, the estimator should be unbiased.

The log-likelihood function for given register values $\boldsymbol{\symRegValVariate}$, which are assumed to be distributed according to under the Poisson model, is $$\label{equ:log_likelihood_single}
\log \mathcal{\symLikelihood}(\symPoissonRate\vert\boldsymbol{\symRegValVariate}) = 
\sum_{\symRegVal=1}^{\symRegRange+1}
\log\left(1-e^{-\frac{\symPoissonRate}{\symNumReg 2^{\min(\symRegVal,\symRegRange)}}}\right)
\symCountVariate_\symRegVal
-
\frac{\symPoissonRate}{\symNumReg}\sum_{\symRegVal=0}^{\symRegRange}\frac{\symCountVariate_\symRegVal}{2^\symRegVal}
.$$ After differentiation and multiplying by $\symPoissonRate$ we find that the estimate $\symPoissonRateEstimate$ is the unique root of the monotone decreasing function $$\symFunc(\symPoissonRate)
=
\sum_{\symRegVal=1}^{\symRegRange+1} \frac{\frac{\symPoissonRate}{\symNumReg 2^{\min(\symRegVal,\symRegRange)}}}{e^{\frac{\symPoissonRate}{\symNumReg 2^{\min(\symRegVal,\symRegRange)}}}-1}
\symCountVariate_\symRegVal
-
\frac{\symPoissonRate}{\symNumReg}\sum_{\symRegVal=0}^\symRegRange \frac{\symCountVariate_\symRegVal}{2^\symRegVal}.$$ Since $\symFunc(0)=\symNumReg-\symCountVariate_0\geq 0$ and $\symFunc$ is at least linear decreasing as long as $\symCountVariate_{\symRegRange+1} < \symNumReg$, there exists a 