필터 지우기
필터 지우기

how to write these two equations

조회 수: 2 (최근 30일)
Sultan Al Harthy
Sultan Al Harthy 2020년 3월 24일
댓글: Sultan Al Harthy 2020년 4월 3일
  댓글 수: 1
Adam Danz
Adam Danz 2020년 3월 24일
Is this a duplicate question or are you looking for answers to both questions?

댓글을 달려면 로그인하십시오.

답변 (1개)

David Hill
David Hill 2020년 3월 24일
Not sure what Tj means in the equation.
for k=1:K
for j=1:K
if j~=K
R(j,k)=B/2*log2(1+(h(k)*a(j))^2/(sum((h(k)*a(j+1:K)).^2)+e*sum((h(k)*a(1:j-1)).^2)+1/rho));
else
R(j,k)=B/2*log2(1+(h(K)*a(K))^2/(e*sum((h(K)*a(1:j-1)).^2)+1/rho));
end
end
end
  댓글 수: 12
David Hill
David Hill 2020년 4월 1일
I assume you are trying to get numeric solutions; therefore, your arrays of (h) and (a) need to be numeric and you need to assign a values to B, K, e, and rho before the above loops can be entered. Additionally, you will want to preallocate R:
R=zeroes(K,K);
Sultan Al Harthy
Sultan Al Harthy 2020년 4월 3일
i am confused

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by