Kalman gain (source code)

= Kalman gain
{c}
{title2=$K_t=P_t^-H_t^\top S_t^{-1}$}

The <Kalman gain> maps an observation <innovation> into a state correction:
$$
K_t=P_t^-H_t^\top S_t^{-1}.
$$
For a scalar state observed directly, it reduces to $K=P^-/(P^-+R)$. With positive <variances>, $0<K<1$, and the <Kalman measurement update> is the <weighted mean> $(1-K)m^-+Ky$. That interpretation belongs to the scalar unit-coefficient case; a general <Kalman gain> is a rectangular <matrix>, not a collection of weights necessarily between zero and one.