Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

Matrix dimensions must agree error

조회 수: 2 (최근 30일)
Asif Rashid
Asif Rashid 2020년 7월 21일
마감: MATLAB Answer Bot 2021년 8월 20일
Sir, I want to find TC where PA and TSR are the matrices of length
1 20
and
1 2
TC=0.08698-(0.003371).*PA-(0.053272).*TSR
where
size (TSR)
ans = 1 2
size (PA)
ans = 1 20
when i write the function TC , i get the error ''Matrix dimensions must agree ''. Please guide me , how to fix this error. Thankyou
  댓글 수: 3
Asif Rashid
Asif Rashid 2020년 7월 21일
Thankyou for your reply Sir. Sir i just updated statement 1 (for RS) of my code . (older statement was RS=750:215.5:3600;) and now the code is running without error . all the matrix dimensions are now 1 20.
RS=750:150:3600;
RR=5;
PA=1:1.25:25;
ws=1:1.25:25;
for ii=1:length(RS)
for i=1:length(ws)
TSR=(RS.*RR)./ws;
for iii=1:length(PA)
TC=0.08698-(0.003371).*PA-(0.053272).*TSR;
end
end
end
Thankyou Sir
Asif Rashid
Asif Rashid 2020년 7월 21일
as in older case (with error) if i need the result in 1 20 dimension. Is it possible ? how may i fix that . Please tell me. Thankyou Sir

답변 (0개)

이 질문은 마감되었습니다.

Community Treasure Hunt

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

Start Hunting!

Translated by