### Table of Contents

### Introduction

A **feedback controller** is a type of control system that compares a desired output (also called setpoint) with the actual output (measured by a sensor) and adjusts the system (via a control signal) accordingly in order to achieve the desired output. It does this by using a feedback loop that continuously monitors the output of the system and compares it to the desired output, then adjusts the system’s inputs in order to bring the output closer to the desired value. This allows the system to automatically adjust to changes in conditions and maintain a stable output even when the output deviates from the setpoint due to external or internal perturbations.

There are various types of feedback controllers, including proportional (P), integral (I), and derivative (D) controllers, or a combination between them (PI, PD or PID), which each use different methods for adjusting the system based on the feedback loop.

A **proportional controller (P-controller)** is a type of feedback control system that adjusts the control signal of a system * u(t)* in proportion to the error

*calculated between the*

**e(t),***and the actual output*

**setpoint***. This type of controller is commonly used in closed-loop control systems to ensure that the output of the system remains as close as possible to the setpoint.*

**y(t)**The **plant**, which is the controlled system, can be any type of system, for example a mechanical, electrical or hydraulic system. In simulations, the plant can be describe as a set of differential equation, state-space matrices or transfer function.

### Equation

Proportional controller are the most basic form of controllers used in feedback control systems. They are still widely used do to their simplicity of implementation and tuning.

The basic equation for a proportional controller is as follows:

\[ u(t) = K_{p} \cdot e(t) \tag{2} \]where:

u(t) – control signal (output of the controller)

e(t) – error signal (input to the controller)

K_{p} – proportional gain

As you can see the control and error signals are variables, function of time, while K_{p} is a constant parameter.

The **proportional gain** and determines how quickly the controller responds to changes in the setpoint or actual output. The higher the proportional gain the faster the response of the controller. Usually the proportional gain is constant but it can also be implemented as a lookup table function of one or more variables.

### System response

Before we dive into the details and behaviour of a proportional controller, let’s define some key parameters related to the response of a system to a step input.

The **system response of a system** is defined as the output of the system, when it is subjected to a particular input. In other words, it’s a measure of how the system responds to different stimuli, and can be used to understand the behaviour and performance of the system. The response of a system can be characterized by various parameters, such as the **rise time**, **settling time**, **overshoot**, and **steady-state error**.

In the image above we can see the system response of a second order system (Plant) to a **step input**.

The **rise time** is a measure of the time it takes for the system’s output to transition from a specified low value to a specified high value. It is typically defined as the time it takes for the output to go from 10% to 90% of the final value in response to a step input. The rise time is a measure of the speed at which the system’s output changes in response to a step input, and is often used to characterize the dynamics of the system.

The **peak time** is the time at which the peak value of the step response occurs. In other words, it is the time at which the output of the system reaches its maximum (**Peak**) value after a step input is applied.

The **overshoot** is the amount by which the system output exceeds the final or steady-state value in a transient response to a step input. In other words, it is the maximum deviation of the system output from the steady-state value, and it’s expressed as a percentage of the steady-state value (e.g. 20%).

The **transient time** of the step response of a second order system refers to the time it takes for the system to reach steady state after a step input has been applied. The transient time is an important performance metric in control systems as it determines how quickly the system can respond to a change in the input and reach a stable operating point.

The **settling time** is the time it takes for the output of a control system to reach and stay within a specified error tolerance around the final setpoint value after a disturbance or change in setpoint. It is a measure of how quickly the system can return to normal operation after a disturbance. In a step response, the settling time is the time it takes for the output to reach and stay within a specified error tolerance around the final value after the step input.

The **max and min error** are threshold which define if the response has reached a steady-state value and are used as references to calculate the transient time.

### Example

For a better understanding of the system response, we are going to investigate the response of a RLC circuit, where the step input applies to the supply voltage and the output is the voltage across the capacitor.

The RLC circuit contains a **supply voltage u _{IN}(t) [V]**, which is the input in the system, a resistor with the

**resistance R [Ω]**, an inductor with the

**inductance L [H]**and a capacitor with the

**capacitance C [F]**. As mentioned, the output of the system is the

**voltage across the capacitor u**, which we’ll observe when there is a step change of the input voltage.

_{C}(t) [V]The step response of the RLC circuit above is basically the variation in time of the voltage across the capacitor, when there is a step change of the input voltage.

To analyse the response of the RLC circuit to a step input, we are going to use its transfer function defined below. For a detailed explanation on how the transfer function is determined, please read the article Mathematical models and simulation of electrical systems.

\[ H(s) = \frac{1}{L \cdot C \cdot s^{2} + R \cdot C \cdot s + 1} \tag{2} \]The transfer function H(s) of the RLC circuit is implemented in Scilab/Xcos as a block diagram (see image below). The supply voltage is implemented as a `Step`

input, which takes the value of 12 V when the simulation time is 0.1 seconds. The parameters `R`

, `L`

and `C`

are defined in the Scilab workspace as:

R = 0.9; // [Ohm] C = 0.02; // [F] L = 0.115; // [H]

The simulation is run for 3 seconds and the step input u_{IN}(t) as well as the output, u_{C}(t) is displayed in a Scope.

Summary of the simulation:

- the RLC circuit (Plant) is simulated in open loop without any proportional controller implemented
- the scope is to analyse the response of the system and see if it can be improved with a proportional controller

Looking at the open loop response of the RLC system to a step input, we can draw the following conclusions:

- the rise time is around 0.05 s, with a peak value of 18.5 V
- with a maximum error of ± 2 % the settling time is around 0.8 s

We want to improve the response of the system, by reducing the rise time and settling time with the help of a proportional controller, therefore we’ll modify the Xcos bloc diagram by adding a summation block to calculate the voltage error **e(t)** and a gain block for the proportional gain **K _{p}**.

The signals which are time-variant in the Xcos model are:

**u**: this is the desired values of the voltage across the capacitor, set to 12 V at 0.1 seconds._{Csetpoint}(t)**e(t) = u**: this is the voltage error, calculated as the difference between the desired voltage across the capacitor (setpoint) and the actual voltage across the capacitor (output)_{Csetpoint}(t) – u_{Cmeasured}(t)**u**: this is the control signal, which is output from the controller and input in the plant_{IN}(t) = K_{p}· e(t)**u**: this is the actual (measured) voltage across the capacitor_{Cmeasured}(t)

We’ll run the simulation for 2 s and check what the response of the system (plant) is, when the proportional gain is set to **K _{p} = 10**.

From the image above we can see that the rise time has improved, decreased to 0.025 s. Also the settling time is much shorter that the open loop response. The drawback is that the overshoot has increased to around 20 V and there are more oscillations in the voltage.

Another limitation of the proportional controller is the **steady-state error**, which is the constant difference between the desired final value of the output and the actual final value of the output. In this simulation scenario the steady-state error is around 1.1 V, which means that the output will never reach the desired input.

To see if we improve the response of the system, we’ll increase the proportional gain to **K _{p} = 20** and run the simulation again.

As expected, the rise time, settling time and steady-state error have decreased but the overshoot and number of oscillations have increased. Although the steady-state error has decreased, it can not be eliminated.

### Tuning

A proportional controller can be tuned by adjusting the proportional gain **K _{p}**. The proportional gain is a measure of how aggressively the controller corrects for an error between the desired output and the measured output of the system.

Increasing the proportional gain will result in a faster response and a larger overshoot in the system response. On the other hand, decreasing the proportional gain will result in a slower response and a smaller overshoot.

In the table below you can see a summary of the effects of increasing or decreasing the proportional gain K_{p} on the response of the system.

Parameter | High K_{p} | Low K_{p} |

Rise Time | Decreases | Increases |

Overshoot | Increases | Decreases |

Transient Time | Decreases | Increases |

Settling Time | Decreases | Increases |

It is important to properly tune the proportional gain to achieve the desired performance of the control system. If the gain is set too high, the system may become unstable and oscillate. If the gain is set too low, the system will have a slower response and may not meet performance requirements.

### Conclusions

A proportional controller has the advantage of being able to **continuously adjust the output signal** in order to bring the system to its desired state, rather than just turning the output on or off like an on-off controller. This allows for a more precise control of the system.

Proportional controllers are used in a variety of real-world applications, including **temperature control** in heating and cooling systems, **flow rate control** in chemical processes, and **position control** in manufacturing equipment.

The disadvantages of a proportional controller include that it can **produce oscillations and steady-state errors** in the system response, and it may not be suitable for systems with large time delays.

Alternative controllers that may be more suitable for these types of systems include integral and derivative controllers, or a combination of all three (**PI, PD, PID**). These controllers can often provide more precise control and better handling of system delays and steady-state errors.

### References

[1] Distefano, Joseph. Schaum’s Outline of Feedback and Control Systems, 2nd Edition. US : McGraw-Hill, 2013.

[2] Karl J. Astrom and Tore Hagglund, PID Controllers: Theory, Design and Tuning, 2nd Edition. Instrument Society of America, 1995.