MATLAB Answers

0

for loop continued fraction

Asked by mozzi gi on 29 May 2019
Latest activity Answered by James Tursa
on 29 May 2019
i want use for loop this problem
the problem is
what do i do?
x(n)=1+1/x(n-1) ?
i'm in tutorial line, so please explain easy

  2 Comments

What exactly is happening in each iteration? The picture is a bit confusing.
are you trying to do 1 + (1/1+n)?
Use the deconv (link) function.
Experiment with it to get the result you want.

Sign in to comment.

1 Answer

Answer by James Tursa
on 29 May 2019

Yes, you can use the formula x(n) = 1 + 1/x(n-1) if you want to use a loop. Just start with x(1) = 1.

  0 Comments

Sign in to comment.