i write this program in matlab M file but it is not working can nay body help me how i can change from real positive integer values to negative values because my answer is -5.02 and work space is not showing that
정보
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
이전 댓글 표시
ht= input('transmitter anteena hight= ');
wa= input('the value of wavelength= ');
hr= input('the value of mobile receiver anteena hight= ');
df= (1/wa((16*ht.^2*hr.^2)-wa.^2*(ht.^2+hr^2)+(wa.^4+16))^1/2)
and the error is
Subscript indices must either be real positive integers or logicals.
kindly help me in this
댓글 수: 0
답변 (1개)
Wayne King
2013년 12월 10일
편집: Wayne King
2013년 12월 10일
You should show us what kind of inputs you expect. I think the problem you have is that I think you are missing a * operator
df= (1/wa*((16*ht.^2*hr.^2)-wa.^2*(ht.^2+hr^2)+(wa.^4+16))^1/2)
You just have 1/wa((....)) but wa is just a scalar.
댓글 수: 0
이 질문은 마감되었습니다.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!