//public IAdaptiveQ AdaptiveQ { get; set; }


        //public IAdaptiveR AdaptiveR { get; set; }

        //public int Size { get { return Q.ColumnCount; } }



        public DiscreteInnerWrapper(double[] measurementnoise, double[] processnoise)
        {
            KalmanFilter = DiscreteFactory.Build(processnoise.Length);


            R = MatrixBuilder.Instance.Builder.Diagonal(measurementnoise).Map(_ => Math.Pow(_, 2)); //covariance of measurement
            Q = MatrixBuilder.Instance.Builder.Diagonal(processnoise).Map(_ => Math.Pow(_, 2));     //covariance of process

            //AdaptiveQ = new DefaultAdaptiveQ(q);
            //AdaptiveR = new DefaultAdaptiveR(r);

            F = StateFunctions.BuildTransition(processnoise.Length);

            G = MatrixBuilder.Instance.Builder.Diagonal(processnoise.Length, processnoise.Length, 1); //covariance of process
            H = StateFunctions.BuildMeasurement(processnoise.Length, measurementnoise.Length);
        }