Пример #1
0
        DiscreteKalmanFilter(
            Matrix x0,
            Matrix P0
            )
        {
            KalmanFilter.CheckInitialParameters(x0, P0);

            this.x = x0;
            this.P = P0;
        }
        InformationFilter(
            Matrix x0,
            Matrix P0
            )
        {
            KalmanFilter.CheckInitialParameters(x0, P0);

            this.J = P0.Inverse();
            this.y = this.J * x0;
            this.I = Matrix.Identity(this.y.RowCount, this.y.RowCount);
        }
        SquareRootFilter(
            Matrix x0,
            Matrix P0
            )
        {
            KalmanFilter.CheckInitialParameters(x0, P0);

            // Decompose the covariance matrix
            Matrix[] UDU = UDUDecomposition(P0);
            this.U = UDU[0];
            this.D = UDU[1];
            this.x = x0;
        }
        InformationFilter(
            Matrix state,
            Matrix cov,
            bool inverted
            )
        {
            KalmanFilter.CheckInitialParameters(state, cov);

            if (inverted)
            {
                this.J = cov;
                this.y = state;
            }
            else
            {
                this.J = cov.Inverse();
                this.y = this.J * state;
            }
            this.I = Matrix.Identity(state.RowCount, state.RowCount);
        }