PID Control Input Filter VI
- Updated2023-02-21
- 3 minute(s) read
PID Control Input Filter VI
Owning Palette: PID VIs
Requires: Full Development System
Applies a fifth-order lowpass finite impulse response (FIR) filter to the input value. Filter cut-off frequency is designed to be 1/10 of the sample frequency of the input value. Use this VI to filter measured values, such as the process variable, in control applications. Use the DBL instance of this VI to implement a single control loop. Use the DBL Array instance to implement parallel multi-loop control.
To ensure that the filter does not attenuate useful measurement information, set the sampling rate of the control system at least 10 times faster than the fastest time constant of the physical system.
PID Control Input Filter (DBL)

![]() |
input specifies the unfiltered measured input value. |
![]() |
reinitialize? specifies whether to reinitialize the output to the current input value. |
![]() |
output returns the filtered input value. |
PID Control Input Filter (DBL Array)

![]() |
input specifies the unfiltered measured input value. |
![]() |
reinitialize? specifies whether to reinitialize the output to the current input value. |
![]() |
output returns the filtered input value. This VI determines the length of the output array from the size of the input array. |
PID Control Input Filter Details
You can use the DBL Array instance of this polymorphic VI in multi-loop PID control applications. In this case, the length of input determines the length of the output array. Other input arrays do not necessarily need to be the same length as input. This VI resizes other input arrays to the same length as input as follows:
- If the input array is longer than input, the input array is truncated to the length of input. Additional values in the array are not used.
- If the input array is shorter than input, the last value of the input array is repeated until the size matches that of input.
In this manner, an input value that must be used for each output calculation does not need to be specified repeatedly in the array passed into this VI. Instead, the array can consist of a single value that is used for each output calculation.
![]() | Note You also can use Filters PtByPt VIs if the application requires more flexible filtering options. Refer to the example VI linked in the following section for more information about using these VIs. |
Example
Refer to the PID with Noise Plant VI in the labview\examples\control\PID directory for an example of using the PID Control Input Filter VI.





