Info
This question is closed. Reopen it to edit or answer.
How can I compute the following formular recursive ?
1 view (last 30 days)
Show older comments
x1=b(1)+ b(2)*x0+resrd2(1,:); % b1 and b2 are scalars x(0) also resrd2 is a matrix of 743x1
x2=b(1)+ b(2)*x1+resrd2(2,:);
x3=b(1)+ b(2)*x2+resrd2(3,:);
How can I solve this ? My Problem here is, that the x values should change recursively and that I want to get the fitting values from the resrd2. In the end the goal is to get a matrix of 743x1. Can somebody please help me here ?
3 Comments
Pavithra Ashok Kumar
on 21 Jan 2016
%Call this function with x(n)
function out = x(index)
if index == 1
return x(0);
else
out = a+b*x(index-1) + resrd(index-1);
end
Collecting the out values will give the array you are looking for. Hope this helps.
Answers (0)
This question is closed.
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!