Size input must be scalar error while using rand
조회 수: 6 (최근 30일)
이전 댓글 표시
I'm trying to run the code:
k = 2:5;
A = rand(k, 4);
disp(rref(A));
It keeps giving me the error "size input must be scalar." I don't know what to change... Thank you in advance.
댓글 수: 0
채택된 답변
Stephen23
2017년 1월 30일
The syntax you use does not work because k is a vector. Taking a wild stab in the dark:
for k = 2:5
A = rand(k,4);
... your code
end
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Octave에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!