Info
이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.
problem in solve command
조회 수: 1 (최근 30일)
이전 댓글 표시
we are trying to solve symboically two algebric equations in a loop using solve command. After the entire loop gets completed the solution for the last iteration only is getting stored. But I want to store every iteration solution value. How to store the value after every iterations in the loop and to get the out put in the form of a(i,j) for all i and j values as matrix
댓글 수: 0
답변 (1개)
KSSV
2020년 5월 27일
% If you have two loops
m = 10 ; % rows
n = 5 ; % columns
iwant = zeros(m,n) ; % initialization
% loop start
for i = 1:m
for j = 1:n
iwant(i,j) = rand ; % your calculation goes here
end
end
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!