How to store the intermediate values in a for loop
이전 댓글 표시
for i=(1:4) Vmi=[X(i),Z(i)] end [X(i),Z(i)] are known How to store the values as Vm1,Vm2.. Thanks in advance.

댓글 수: 2
Stephen23
2018년 3월 10일
See also the earlier question:
@RAJASEKAR S: use indexing. Indexing is simple and very efficient, unlike what you are trying to do. You can learn about indexing by doing the introductory tutorials:
The introductory tutorials teach basic concepts like using indexing, which is why they are recommended for all beginners. If you want to learn how to use MATLAB effectively then do those tutorials. Do NOT try to create variable names in a loop, unless you want to force yourself into writing slow, complex, buggy code:
RAJASEKAR S
2018년 3월 10일
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Parallel Computing에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!