How can I do this iteration?
1 ビュー (過去 30 日間)
Hi, I have a simple question related to a problem.
I have to make an iterative code which updates values of some hypothesized vectors, until I reach convergence.
To simplify, I have two vectors a,b with initial assumed values, then the cycle updates their values until it stops when:
, where "i" is the iteration index.
I think this can be solved with an easy code, maybe with a while cicle?
Thank you for your help!
回答 (1 件)
ANKUR KUMAR 2021 年 7 月 11 日
編集済み: ANKUR KUMAR 2021 年 7 月 11 日
Here is the sample code using random data
threshold=0.5; % You need to change it to 1e-6 and use original data
out= -9999; % setting random data