Design a fuzzy logic controller using MATLAB fuzzy logic toolkit, based on the experience gained at the last step.

Develop a closed-loop control system with the model of the single-tank system and the fuzzy logic controller.

Analyse the performance of the closed-loop control system in terms of rise time and stability.

## Types of Analog Controller

The basic control process is where single input and single output is present known as SISO system. Here the task is also formulated as SISO system other process known as Multiple Input Multiple Output (MIMO) system where the manipulating and disturbance parameters are more than one. Most of industrial controller are relying on the concept of PID, in process industry almost 95% of the controllers are PID. The key reason wide acceptance of PID controller is, its design based only simplicity and the structure based on applicability to different processes.

The whole concept of the controller depends on the manipulating the process error. Ultimately the error is the difference of control variable and the desired value.

Err=PV-SP

There are variety of combination of the controller are involved which varies upon the type of application for process industry below list shows the combination and frequency of use

P |
Sometimes use |

PI |
Mostly use |

PD |
Rarely use |

PID |
Most often use |

The purpose of the controller is to provide the signal that will cause the process to be modified in such a way as to keep the set point (reference) and the process variable (actual output) equal.

Any change in set point or the loads on the process should cause a change in the controller’s output to assure that the PV tracks SP.

Types of analog controller

- simple ON/OFF controller (cycling or chatter)
- proportional controller
- Proportional Integral controller
- PID controller (good transient & Steady state control)

The most important block in an analog controller is the ERROR AMPLIFIER

P controller widely use in the first order system to stabilize the unstable process. It helps in decreasing the steady state error. with increase in gain of the system the steady state error reduces. With high value of P it gives smaller amplitude and phase margin also reduce noise signal

The error can’t be eliminated completely. To reduces the error, the controller must raise its output. But to raise its output, the controller must have some error. This residual error can be reduced by increasing the gain but too much gain will cause the system to oscillate.

Integral control doesn’t provide capability to predict the future error of the system, so the response is very normal even after the changes occur in set point (reference). The use of derivative controller can avoid such issues by predicting the future response of the error signal. The output of the plant or process dependent on the rate of change of the error signal with time and whole things multiplied by the D-constant.

To eliminate the residual system error, the controller’s response must be changed. In proportional controller the output was proportional to the system error.

## Proportional Controller

PID:

PID controller helps in optimal control with no steady state error, zero oscillations, good stability and fast response. With PI controller use of Derivative helps in eliminate the overshoot and oscillations of the system of the output response. It also having advantage of can be implemented for higher order system.

The dynamics of process need to be controlled with the use of PID controller, each term of PID controller have their own characteristics and properties. Without tuning PID controller the response of the system may cause very high deviation and instability of the system. Various tuning methods are used in field of control engineering namely few are trial and error method, process reaction curve, Ziegler Nichols method and modern meta heuristic based tuning. One of the best suitable method is fuzzy controller.

The open loop response first recorded based on that PID controller is installed after that tuning is the important process. In this method the parameter of PID are set to zero and increase the value of Kp till the response attain oscillations. After oscillations occurs Integral value also adjusted and finally Derivative to obtain the quick response.

Ultimately, it’s the open loop method. The input is step unit signal and the response of the system is recorded. Than from the slope of the curve we can find the value of P,I and D parameters.

Normally the process in engineering may contains number of input and output variables. Though only one or two of the parameters are needed to control the whole process of the plant model. Such controlling parameters are known as manipulating variable, and other may be uncontrollable which are known as the disturbance parameters. Generally, the controller has the feedback system where output of system is taken and compared with the desired or set value if any deviation found in the comparison, corrective action is taken

Normally the process in engineering may contains number of input and output variables. Though only one or two of the parameters are needed to control the whole process of the plant model. Such controlling parameters are known as manipulating variable, and other may be uncontrollable which are known as the disturbance parameters. Generally, the controller has the feedback system where output of system is taken and compared with the desired or set value if any deviation found in the comparison, corrective action is taken correspondingly.

Here in the given task where single tank with inlet and outlet value for controlling the flow rate of water, and the height of water tank also need to be maintained by controlling the flow rate. Let’s say the valve V1 is the inlet valve which controls the inflow rate and the outlet valve is V2 which controls the outflow rate. Here the inflow rate controlling is done by inlet valve which is manipulating variable. Where the outflow rate affects the height of water in tank so it’s called the disturbance parameters also known as load parameter. Ultimately given problem is single input (manipulating) and single output (water height), called as Single Input Single Output (SISO). If temperature, pressure etc. parameter added into exist problem called as the Multiple Input Multiple Output (MIMO) process.

## Derivative Controller

The first task is to develop the mathematical model of the given task, but most of the physical problems are nonlinear in nature. But for designing and simulation tools we assume process is linear in nature. To do so linearization of the problem is need to be done.

Let’s designate the inlet and outlet flow rate of the give task as F_{i }and F_{o} in m^{3}/s of the tank. Let’s designate water height as, h and the X-sectional area of tank is A. During the functioning of steady state mode F_{i }and F_{o} remains constant and the height of water under the tank also constant. In the case when both are unequal,

Though the valve V2 side the flow rate is depending on height of water inside the tank and with assumption of the output valve V2 as orifice

With one more assumption of the outflow valve V2 doesn’t change during whole operation of the process

Substituting the value of F_{o} in the equation 1

The above term indicates the process is nonlinear in nature due to presence of

Another assumption to make the mode as linearize model we assume that = and the water height inside the tank attains steady state height of Hs and now the flow rate has been changed with very low value

All the above-mentioned input and output parameters are presented in the form of deviation from the desired or the steady state. In case the level of Hs changes the model parameter also subjected to change (

With the transfer function designed above and the mathematical representation of various quantities as well as the control dynamics. Here we are controlling the water level (height of water inside the tank) using bottle and tag device. Here by introducing the bottle and tag water level is control by monitoring the tag level. Also, we are already assumed that V2 valve remain unchanged but for variation we assume now it changes which affect the steady state performance of the system. Here we are adding one more parameter which is disturbance into the system D(s).

First the mathematical model of the single tank system with simple valve control was developed later with bottle and tag performance studied mathematically. Than the system performance using computer simulation is tested in open loop and close loop environment. After that fuzzy logic-based controller is implemented to check the performance of the system against overshoot, settling time, rise time etc.

The rise of the system is the value when response attains 95% of its final value here the rise time is very short 0.135 second with the use of fuzzy logic controller.

Settling time : When system achieves 98% of its final value known as settling time, compared with conventional PID tuning using fuzzy logic controller it has gain good response of 0.2 second to reach 98% of its final value.

In open loop, close loop with manual tuning and Fuzzy PID no overshoot is observed.

Conclusion:

From the mathematical model development for the given task the simulation clears doubt related to process of control using close loop schemes. Step by step procedure has been explained in the given assignment for the single tank and two valve control schemes. Firstly, the open loop response of the system has been analyzed which is very sluggish in nature in rise time and the settling time though with zero overshoot. In second stage PID controller is used with comparator and unity gain feedback path which improves the system performance once tuned by trial and error method. Also, it is found that lots of mathematical conventional and modern methods exist to tune the PID of the controller namely Zeigler Nichols method, Cohen coon method, graphical method and modern techniques like fuzzy, PSO, GA can be used to tune the PID. In the last stage fuzzy has been implemented to tune the PID of the controller and the best performance has been found compared to other two cases.

References.

- Sahu, A. and Hota, S.K., 2018, March. Performance comparison of 2-DOF PID controller based on Moth-flame optimization technique for load frequency control of diverse energy source interconnected power system. In Technologies for Smart-City Energy Security and Power (ICSESP), 2018(pp. 1-6). IEEE.
- Karagpur Available at: https://breo.beds.ac.uk/bbcswebdav/pid-2712339-dt-content-rid-5012123_1/courses/16-17TYADCIS020-3/LinearisationCaseStudy.pdf (Accessed: 10 September 2018).
- Pan, I., Das, S. and Gupta, A., 2011. Tuning of an optimal fuzzy PID controller with stochastic algorithms for networked control systems with random time delay. ISA transactions, 50(1), pp.28-36.
- Woo, Z.W., Chung, H.Y. and Lin, J.J., 2000. A PID type fuzzy controller with self-tuning scaling factors. Fuzzy sets and systems, 115(2), pp.321-326.
- Nise, N.S. (2011)Control systems engineering. 6th edn. Oxford, United Kingdom: John Wiley & Sons.
- Tang, K.S., Man, K.F., Chen, G. and Kwong, S., 2001. An optimal fuzzy PID controller. IEEE transactions on industrial electronics, 48(4), pp.757-765.
- Åström, K.J. and Hägglund, T., 2006. Advanced PID control. ISA-The Instrumentation, Systems and Automation Society.
- Truong, D.Q. and Ahn, K.K., 2009. Force control for hydraulic load simulator using self-tuning grey predictor–fuzzy PID. Mechatronics, 19(2), pp.233-246.
- Zhao, Z.Y., Tomizuka, M. and Isaka, S., 1992, September. Fuzzy gain scheduling of PID controllers. In Control Applications, 1992., First IEEE Conference on (pp. 698-703). IEEE.
- Carvajal, J., Chen, G. and Ogmen, H., 2000. Fuzzy PID controller: Design, performance evaluation, and stability analysis. Information sciences, 123(3-4), pp.249-270.
- Panagopoulos, H., Åström, K.J. and Hägglund, T., 2002. Design of PID controllers based on constrained optimisation. IEE Proceedings-Control Theory and Applications, 149(1), pp.32-40.
- Mann, G.K., Hu, B.G. and Gosine, R.G., 1999. Analysis of direct action fuzzy PID controller structures. IEEE Transactions on Systems, Man, and Cybernetics, Part B (Cybernetics), 29(3), pp.371-388.
- Wang, Q.G., Zou, B., Lee, T.H. and Bi, Q., 1997. Auto-tuning of multivariable PID controllers from decentralized relay feedback. Automatica, 33(3), pp.319-330.
- Åström, Karl Johan, and Tore Hägglund. Advanced PID control. ISA-The Instrumentation, Systems, and Automation Society; Research Triangle Park, NC 27709, 2006
- Jantzen, J., 1998. Tuning of fuzzy PID controllers. Technical University of Denmark, Department of Automation, Bldg, 326.
- Tuning for PID controllers (no date) Available at: https://faculty.mercer.edu/jenkins_he/documents/TuningforPIDControllers.pdf (Accessed: 4 March 2017).
- Malki, H.A., Misir, D., Feigenspan, D. and Chen, G., 1997. Fuzzy PID control of a flexible-joint robot arm with uncertainties from time-varying loads. IEEE Transactions on Control Systems Technology, 5(3), pp.371-378.
- El-Nagar, A.M. and El-Bardini, M., 2017. Parallel realization for self-tuning interval type-2 fuzzy controller. Engineering Applications of Artificial Intelligence, 61, pp.8-20.
- Araki and Control, P.M. (2017) ‘PID controller’, in Wikipedia. Available at: https://en.wikipedia.org/wiki/PID_controller (Accessed: 6 March 2017).

**Cite This Work**

To export a reference to this article please select a referencing stye below:

My Assignment Help. (2020). *Designing A Fuzzy Logic Controller Using MATLAB Fuzzy Logic Toolkit*. Retrieved from https://myassignmenthelp.com/free-samples/cis116-6-wireless-embedded-systems/disturbance-parameters.html.

"Designing A Fuzzy Logic Controller Using MATLAB Fuzzy Logic Toolkit." My Assignment Help, 2020, https://myassignmenthelp.com/free-samples/cis116-6-wireless-embedded-systems/disturbance-parameters.html.

My Assignment Help (2020) *Designing A Fuzzy Logic Controller Using MATLAB Fuzzy Logic Toolkit* [Online]. Available from: https://myassignmenthelp.com/free-samples/cis116-6-wireless-embedded-systems/disturbance-parameters.html

[Accessed 14 July 2024].

My Assignment Help. 'Designing A Fuzzy Logic Controller Using MATLAB Fuzzy Logic Toolkit' (My Assignment Help, 2020) <https://myassignmenthelp.com/free-samples/cis116-6-wireless-embedded-systems/disturbance-parameters.html> accessed 14 July 2024.

My Assignment Help. Designing A Fuzzy Logic Controller Using MATLAB Fuzzy Logic Toolkit [Internet]. My Assignment Help. 2020 [cited 14 July 2024]. Available from: https://myassignmenthelp.com/free-samples/cis116-6-wireless-embedded-systems/disturbance-parameters.html.