Hi everyone
I have a complicated problem but it is difficult to show it all. I wrote another simpler one which has similar principle. Bascially, I need to know how to use excel to complete the iteration below automatically. Please help.
Let a, b be 2 real numbers.
a*b=100
While a has to follow the conditions below:
a=1 for 0<b<2
a=10/b for 2<b<20
a=2 for b>20
1st iteration: let b=10 at first (ignore the conditions first), a=100/10=10
2nd iteration: b=10, 2<b<20, a=10/b=10/10=1
3rd iteration: a=1, b=100/a=100, a=2, b=50
4th iteration: a=2, b=50
The value of a and b finally becomes constant.
What I want is to complete the iteration in one step or one button instead of showing the values of a and b everytime, since in my real problem, there is more than 1000 iteration.
Could anyone help me to solve the problem?
Thank you very much!!
I have a complicated problem but it is difficult to show it all. I wrote another simpler one which has similar principle. Bascially, I need to know how to use excel to complete the iteration below automatically. Please help.
Let a, b be 2 real numbers.
a*b=100
While a has to follow the conditions below:
a=1 for 0<b<2
a=10/b for 2<b<20
a=2 for b>20
1st iteration: let b=10 at first (ignore the conditions first), a=100/10=10
2nd iteration: b=10, 2<b<20, a=10/b=10/10=1
3rd iteration: a=1, b=100/a=100, a=2, b=50
4th iteration: a=2, b=50
The value of a and b finally becomes constant.
What I want is to complete the iteration in one step or one button instead of showing the values of a and b everytime, since in my real problem, there is more than 1000 iteration.
Could anyone help me to solve the problem?
Thank you very much!!