When deciding whether to embed Simulink functions inside a Stateflow® chart, the following conditions make embedding the preferred option. If the Simulink functions
Use only local Chart data.
Use a mixture of local Chart data and inputs from Simulink. OR
Are called from multiple locations within the chart.
Are not called every time step.