# PID tuning (PD/PDF and PD^{2}I) tutorial

Closed loop control algorithms are used to adjust valve responsiveness within Alicat flow or pressure controllers. Modifying the variables within these algorithms allows the user to control how fast a controller reaches a setpoint as well as control stability.

In this article, we will explain some of the theory behind valve tuning and give tips on tuning your own Alicat device.

## When to tune your controller

Before shipping, each controller is tuned for optimal valve performance at the indicated process conditions. For example, if a controller is ordered to flow air at 25 SCCM, then it will be tuned with that in mind. That means if you use your controller for exactly what you configured it for, the valve tuning and therefore control stability should be solid.

However, if process conditions change, for example, if you decide to flow hydrogen instead of air or if you modify the inlet/outlet pressure, you may need to retune your device.

## Valve tuning using PD/PDF and PD^{2}I control algorithms

There are two control algorithms used to tune Alicat controllers:

**PD/PDF tuning**typically for single valve controllers**PD**typically for dual valve controllers (MCDs and PCDs)^{2}I tuning

*Note: You can view your selected control loop by going to MENU > CONTROL > CONTROL LOOP > LOOP TYPE on the front panel of your Alicat controller.*

The PID control algorithm is composed of three terms each playing their part to minimize the error between the setpoint and the measured process variable. They are defined as follows:

**Proportional (P):**The**proportional**term decreases the error between the setpoint and reading.**Derivative (D):**The**derivative**variable dampens the rate of change of the valve position.**Integral (I):**The**integral**variable takes into account the sum of previous errors.

*Note: You can view the current settings for your P, D, and I variables by going to MENU > CONTROL > CONTROL LOOP on the front panel of your Alicat controller.*

## The PD/PDF Algorithm

The PD/PDF algorithm provides a simplified user interface. It only requires the user to work with two variables: P and D. This substantially cuts the user’s level of difficulty.

There are a couple of telltale problems indicating a device is in need of valve tuning:

- You notice oscillation around the setpoint or the control response is unstable.
- Your controller takes too long to get to the setpoint or never achieves the setpoint, but settles to a flow rate or pressure below the setpoint value.

Below are instructions on tuning your device to solve these problems.

### Step-by-step instructions

## The PD^{2}I Algorithm

The PD^{2}I algorithm was developed at Alicat Scientific for the express purpose of obtaining the highest possible performance in pressure control applications. It is also applicable to many flow control applications. As it utilizes proprietary predictive functions, this algorithm does not behave like a standard PID routine. Fortunately, PD^{2}I tuning is simple if you follow a few simple guidelines: