Based on the setting of the Initial Values parameter, the integrator (I) and derivative (D) components in the PID controller are initialized according to the following table.
Setting

Integrator initType

Derivative initType

none

NoInit

NoInit

steady states

SteadyState

SteadyState

initial states

InitialState

InitialState

initial outputs

NoInit

SteadyState

integrator states

InitialState

NoInit



In many cases, the most useful initial condition is steady states because initial transients are no longer present. If $\mathrm{initType}\=\mathrm{InitPID}\cdot \mathrm{SteadyState}$, then in some cases difficulties might occur. The reason is the equation of the integrator, $\stackrel{\.}{y}\=ku$. The steady state equation, $\stackrel{\.}{x}\=0$ leads to the condition that the input to the integrator is 0. If the input $u$ is already (directly or indirectly) defined by another initial condition, the initialization problem is singular (that is, has none or infinitely many solutions). This situation occurs often in mechanical systems, where, for example, $u\=\mathrm{desiredSpeed}\mathrm{measuredSpeed}$. Because speed is both a state and a derivative, it is natural to initialize it with 0. As sketched, this is not possible. The solution is to not initialize ${u}_{m}$ or the variable that is used to compute ${u}_{m}$ by an algebraic equation. If the parameter Limits At Initial is $\mathrm{false}$, the limits at the output of this component are removed from the initialization problem, which leads to a much simpler equation system. After initialization has been performed, it is checked with an assert whether the output is in the defined limits.