Help with iterating to get one final value with for loop

조회 수: 1 (최근 30일)
Jim Tom
Jim Tom 2017년 11월 6일
편집: Jim Tom 2017년 11월 6일
if true
% code
end

답변 (1개)

Karan Gill
Karan Gill 2017년 11월 6일
Do not use f1(i). Instead use subs: https://www.mathworks.com/help/symbolic/subs.html to substitute a value.
And you redeclared f1 as symbolic with syms f1. So you lost your initial value of f1. Then you try f1(i) and it errors.

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by