# Discrete PI Controller with Integral Anti-Windup

Discrete-time PI control with integral anti-windup

**Library:**Simscape / Electrical / Control / General Control

## Description

The Discrete PI Controller with Integral Anti-Windup block implements discrete PI control with internal anti-windup. The figure shows the equivalent circuit for the controller with internal anti-windup.

### Equations

The block calculates the control signal using the backward Euler discretization method:

$u(k)=\text{sat}\left({K}_{p}\text{e}\left(\text{k}\right)+\text{sat}\left({K}_{i}\frac{{T}_{s}z}{z-1}\text{e}\left(\text{k}\right),\text{A},\text{B}\right),A,B\right),$

$sat(x,A,B)=\mathrm{min}\left(\mathrm{max}\left(x,\text{A}\right),B\right),$

where:

*u*is the control signal.*K*is the proportional gain coefficient._{p}*e*is the error signal.*K*is the integral gain coefficient._{i}*T*is the sampling period._{s}*A*is the lower limit for saturation.*B*is the upper limit for saturation.

## Ports

### Input

### Output

## Parameters

## Model Examples

## References

[1] *IEEE Recommended Practice for Excitation System Models for Power
System Stability Studies.* IEEE Std 421.5/D39. Piscataway, NJ: IEEE-SA,
2015.

## Extended Capabilities

## Version History

**Introduced in R2017b**