Scope note: This note fits a statistical model to a published series to show how a kernel represents structure. The forecast extrapolates that model. It is not a projection from the physics, ecology or economics of the series, and the series is used as published, without the corrections a domain analysis would apply.
The monthly mean total sunspot number from 1749 comes from WDC-SILSO at the Royal Observatory of Belgium, here thinned evenly to $600$ points. Solar cycles recur near every decade while shifting in amplitude and exact duration. Multiplying a periodic kernel by a squared exponential envelope lets the cycle evolve smoothly over time:
$$ \begin{aligned} k(s,t) ={}& a^2 \exp\!\left(-\frac{2\sin^2\left(\frac{\pi\lvert s-t\rvert}{p}\right)}{\ell_p^2}\right) \\ &\times \exp\!\left(-\frac{(s-t)^2}{2\ell^2}\right) \\ &+ \sigma_\varepsilon^2\,\delta(s,t) , \end{aligned} $$written Per(p, lp, a) * RBF(l) + WN(n) over $p \in [8, 14]$ years with a constant mean. Marginal-likelihood fitting produces a log likelihood of $-2949$ and a BIC of $5936$.
| Name | Symbol | Value | Standard error |
|---|---|---|---|
p | $p$ | $10.45$ years | $0.19$ |
lp | $\ell_p$ | $1.18$ | $0.13$ |
a | $a$ | $61.8$ | $6.4$ |
l | $\ell$ | $9.57$ years | $0.58$ |
n | $\sigma_\varepsilon$ | $24.3$ | $0.84$ |
Run this in µGauss
Open µGauss with this model pre-loaded to inspect the fit, forecast, and parameter sensitivities, or adjust the kernel and refit:
- Open the locally periodic kernel in µGauss ↗
- Open the strictly periodic kernel in µGauss ↗, fitted with
Per(p, lp, a) + WN(n).

Phase memory across cycles
At lag $\tau = p$, the periodic factor equals $1$, so the correlation between consecutive cycles equals the Gaussian envelope at $p$:
$$ \exp\!\left(-\frac{p^2}{2\ell^2}\right) = \exp\!\left(-\frac{10.45^2}{2 \times 9.57^2}\right) = 0.55 . $$After two cycles, correlation falls to $0.092$. Thus the series retains slightly more than half its phase correlation one period ahead and loses nearly all of it by the second period. Letting $\ell \to \infty$ recovers the strictly periodic kernel, which keeps correlation $1$ at every multiple of $p$.
Locally periodic versus strictly periodic cycles
A strictly periodic kernel forces an identical repeating waveform forever, conflicting with shifting solar cycle amplitudes.
| Kernel | Log likelihood | BIC |
|---|---|---|
Per(p, lp, a) + WN(n) | $-3330$ | $6692$ |
Per(p, lp, a) * RBF(l) + WN(n) | $-2949$ | $5936$ |
Adding the Gaussian envelope costs one parameter yet boosts the log likelihood by $381$, cutting the BIC by $756$. The strictly periodic fit also leaves standard errors undefined because its log likelihood is not strictly concave across all parameters at the optimum.
Competing maxima across restarts
µGauss flags the locally periodic fit as fragile because only $1$ of $4$ optimizer restarts reached the global maximum at $-2949$, while the others settled at $-2972$ or lower. Periodicity creates competing maxima across candidate periods. Rerunning with $8$ restarts finds the same $-2949$ maximum $2$ times, confirming the optimum while illustrating why a small restart count can miss it.
Related notes: Quasi-periodic kernels with Gaussian and exponential envelopes, Weekly periodic kernel on daily birth counts. The built-in shorthand for this product is LocalPer, documented in the µGauss reference.