need help in to write a matlab script

3 ビュー (過去 30 日間)
Sg dg
Sg dg 2012 年 12 月 29 日
how do you write a matlab script to calculate the Sum for the expression?

採用された回答

Sabarinathan Vadivelu
Sabarinathan Vadivelu 2012 年 12 月 29 日
n = 10; % assuming it to be 10
x = 0;
for i = 1 : n
x = ((1/i) + (1/(i+2)*(i+3))) + x;
end

その他の回答 (1 件)

Roger Stafford
Roger Stafford 2012 年 12 月 29 日
ix = 1:n;
s = sum(1./ix+1./((ix+2).*(ix+3)));

カテゴリ

Help Center および File ExchangeGet Started with MATLAB についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by