In the following equation do i perform the sum first or the power of 2 first?
(sum(k.*cos(b)).^2)

 채택된 답변

Roger Stafford
Roger Stafford 2015년 2월 27일
편집: Roger Stafford 2015년 2월 27일

1 개 추천

As it stands, the summation occurs first, followed by taking the square of that sum. You should be able to determine that from the parentheses.
In case 'b' is more than a one-dimensional array, there will of course be many sums and the square of each one is taken.

추가 답변 (0개)

카테고리

도움말 센터File Exchange에서 MATLAB에 대해 자세히 알아보기

태그

질문:

2015년 2월 27일

편집:

2015년 2월 27일

Community Treasure Hunt

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

Start Hunting!

Translated by