Documentation Center

  • Trial Software
  • Product Updates

FOR Loops

This example shows the use of flow charts in Stateflow® to create C or MATLAB statements such as the FOR loop. This particular example shows how you can create a simple FOR Loop that defines an array variable. The equivalent statements in MATLAB® are as follows:

for i=1:10 output = 2 * i; end

Was this topic helpful?