Info

この質問は閉じられています。 編集または回答するには再度開いてください。

Can someone please explain me the code and how can i give my input in it?

1 回表示 (過去 30 日間)
Nana Fernandes
Nana Fernandes 2017 年 4 月 12 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
I want a kalman filter with two inputs and one output port; 1st Input is a excel sheet with 16801x28 and 2nd is a sample of which i want to see how close are the values to the original which again is a excel sheet of 6rows and 28 columns. Can someone please explain the code given below and tell me where can i input my two excel sheet inputs Thanks in advance
numSamples = 4000;
R = 0.02;
src = dsp.SignalSource;
src.Signal = [ones(numSamples/4,1); -3*ones(numSamples/4,1);...
4*ones(numSamples/4,1); -0.5*ones(numSamples/4,1)];
tScope = dsp.TimeScope('NumInputPorts', 3, 'TimeSpan', numSamples, ...
'TimeUnits', 'Seconds', 'YLimits',[-5 5], ...
'ShowLegend', true); % Create the Time Scope
kalman = dsp.KalmanFilter('ProcessNoiseCovariance', 0.0001,...
'MeasurementNoiseCovariance', R,...
'InitialStateEstimate', 5,...
'InitialErrorCovarianceEstimate', 1,...
'ControlInputPort',false); %Create Kalman filter
while(~isDone(src))
trueVal = src();
noisyVal = trueVal + sqrt(R)*randn;
estVal = kalman(noisyVal);
tScope(noisyVal,trueVal,estVal);
end
  1 件のコメント
Nana Fernandes
Nana Fernandes 2017 年 4 月 14 日
how can this be done?

回答 (0 件)

この質問は閉じられています。

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by