  We propose the Correlation-Locking Optimization SchEme (CLOSE), a real-time
adaptive filtering technique for adaptive optics (AO) systems controlled with
integrators. CLOSE leverages the temporal autocorrelation of modal signals in
the controller telemetry and drives the gains of the integral command law in a
closed servo-loop. This supervisory loop is configured using only a few scalar
parameters, and automatically controls the modal gains to closely match
transfer functions achieving minimum variance control. This optimization is
proven to work throughout the range of noise and seeing conditions relevant to
the AO system. This technique has been designed while preparing the high-order
AO systems for extremely large telescopes, in particular for tackling the
optical gain (OG) phenomenon -- a sensitivity reduction induced by on-sky
residuals -- which is a prominent issue with pyramid wavefront sensors (PWFS).
CLOSE follows upon the linear modal compensation approach to OG, previously
demonstrated to substantially improve AO correction with high order PWFS
systems. Operating on modal gains through multiplicative increments, CLOSE
naturally compensates for the recurring issue of unaccounted sensitivity
factors throughout the AO loop. We present end-to-end simulations of the MICADO
instrument single-conjugate AO to demonstrate the performances and capabilities
of CLOSE. We demonstrate that a single configuration shall provide an efficient
and versatile optimization of the modal integrator while accounting for OG
compensation, and while providing significant robustness to transient effects
impacting the PWFS sensitivity.
