how to use output as input in same code

1 回表示 (過去 30 日間)
GAURAV DHADSE
GAURAV DHADSE 2019 年 9 月 17 日
コメント済み: GAURAV DHADSE 2019 年 9 月 17 日
h = 2
for I = 1:15
E = 0
for el = 1:20
M = 1 +h
E = E + M
end
end
how can I use the new value of E for each iteration?
  5 件のコメント
KALYAN ACHARJYA
KALYAN ACHARJYA 2019 年 9 月 17 日
編集済み: KALYAN ACHARJYA 2019 年 9 月 17 日
h=2
E=0
for ...
for ...
....
E=E+M % Update E
end
end
Role of I loop ??
GAURAV DHADSE
GAURAV DHADSE 2019 年 9 月 17 日
Dear Walter sir, thanks for the answer, now my code is running properly. Thank you everyone

サインインしてコメントする。

回答 (0 件)

カテゴリ

Help Center および File ExchangeSimulink についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by