フィルターのクリア

Info

この質問は閉じられています。 編集または回答するには再度開いてください。

problem in solve command

1 回表示 (過去 30 日間)
guru k
guru k 2020 年 5 月 27 日
閉鎖済み: MATLAB Answer Bot 2021 年 8 月 20 日
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

回答 (1 件)

KSSV
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

この質問は閉じられています。

Community Treasure Hunt

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

Start Hunting!

Translated by