syms x n y z a;
n=input('enter number of int');
for y=1:n;
z=x^2;
a=int(z);
z=a;
end
like i want to int x^2 two time the answer will be x^4/12 but in matlab but i cant get the int to intgrate the new value of z

 採用された回答

David Wilson
David Wilson 2020 年 5 月 7 日

1 投票

Remove the z=x^2 from the loop.
syms x n y z a;
n= 5
z=x^2;
for y=1:n
z=int(z)
end

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeTime Series Objects についてさらに検索

質問済み:

2020 年 5 月 7 日

編集済み:

Rik
2020 年 5 月 7 日

Community Treasure Hunt

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

Start Hunting!

Translated by