Sign in to follow this  
Followers 0
BobLfoot

PID Loop Implementation

56 posts in this topic

Is that feed Forward into the PID Output Bias something I do with a once and then return output bias to zero or do I leave Output Bias at say 15 when the machine is running?

Share this post


Link to post
Share on other sites
One way to do it, is with a timer, the value of the timer will depend on your process. When the equipment is started move a value to the output bias, and run a timer, when the timer is done, move a zero back. It will take a little while to get the right timer and bias values. OR you can remove the bias after system has responded (my preferred method). Example: System is at steady state with an output of 50%. Equipment is started and a value of 15 is moved to the bias, output is now 65%, but the PV has not yet changed. Once the PV changes by some value then your PID will have an error to work with. Once the pid responds to the error you can slowly decrease the bias, untill it reaches zero again. You want to increase the cooling with the bias, then once your system responds to the upset, remove the bias. I'm not a good teacher, and usually muddle my way through PID setups/tuning, but I hope you get the gist of it.

Share this post


Link to post
Share on other sites
On second thought, you may not need the feedforward, it all depends on your application. If starting equipment causes a minor error, that you can tolerate, no need. If you get a major deviation, and the system takes a long time to respond, then feedforward is needed.

Share this post


Link to post
Share on other sites
Plenty Clear Ken and I'll play with it once my cpntrol valve is replaced and functional.

Share this post


Link to post
Share on other sites
I think I am going to have to disagree with Ken here... The bias represents a known load on the system. It should remain until the known load is removed. That way you can avoid the upset when the equipment starts AND when it stops. If you want to get fancy, you can add a time delay after the equipment starts before you add the bias and another time delay after the equipment stops before you remove the bias. The equipment doesn't dump heat into the room immediately on start and it keeps dumping heat after you turn it off. You may not need any of this. Observation of the system should tell you if you do or not. If the feed forward is set perfectly, there would be no upset at all to the PID loop (and the PID's job is made very easy). Of course in the real world it won't be perfect and that's not the goal. The goal is to keep the change in PV within acceptable limits. If a plain PID can't do that, then feed forward will make a big difference. Removing the bias while the load is still present just causes another upset to the PID loop. If it's all in one shot or it's ramped out doesn't really matter. If the loop has settled and the PV is stable, why would you mess with it then?

Share this post


Link to post
Share on other sites
I read through most of the posts here and have information overload! I might recommend using some interactive loop control if you can come up with a concept that will allow the equipment to run and not tear itself up. I've controlled a valve providing waste gas to be bruned first with a temperature controller and secondary control with a pair of over riding loops. I have temperature available, pressure available and flow available. The head pressure has to stay within parameters, the flow needs to stay above a certain rate and the temperature is controlled between 1600 and 1900 deg F. The temperature actually has two control loops involved. One controls temperature to 1625 deg F, the second (the one in this scenario) controls the temperature to 1650 deg F. Basically we want the waste gas valve to be 100% open at all times. If the Quench loop cannot keep the temperatrue controlled at 1625 deg the secondary loop begins closing down the valve. This is where the flow and pressure come into play. When the pressure falls below the window the loop for pressure starts decreasing the output form the loop, this value is compared with the flow control loop for which is the lower value and that value is then dropped into the Omax for the temperature control loop. As they go down the Omax reacts, as they go back up the Omax reacts. I'll have to get back to you to let you know if the concept actually works. Startup is on Nov 14. In the lab and on my desk top I've been able to simulate all signals and the program control for this all works. Tuning will be the fun part. Flow and pressure control is typically a quick reacting control and temperature is quite a bit slower in comparison. Just to cover all bases I have taken the advice from those that put good time into their posts and added their comments to a library of information I have going. Good luck with your system.

Share this post


Link to post
Share on other sites
Hi, Dont know if this helps totally, but I had a temp control application, where the PV was fluctuating and had spikes. In RSLogix5000, I worked out 3 ways to compensate for this: 1. Used an MAVE (Moving Average) block in FBD to condition the input signal for giving an average value taken at 100ms intervals over a 10 sec period. You can also program the logic for this block in Ladder using STI / Timer etc. This enabled me to smoothen the PV. 2. Used a rate limiter to cut out spikes. You can also program this block in ladder but would take a slightly more complicated program to convert the Rate Limiter block in ladder. 3. I used some manual over rides or interlocks to over ride the PID CV in extreme conditions like if the temp fell below 10% of acceptable range then to completely open the temp valve, etc. These 3 steps helped me and the application worked fine. But in my experience with PID loops, you would also need to investigate more parameters like response time etc. of system and check out trends to see if you can spot any patterns that you can modify your ladder to download recipes in the system. For the correct set points though, it is always hit and trial. Rockwell does have an auto-tune software but i have not been able to check it out so far, maybe it might help in your case, as Rockwell does claim it would.

Share this post


Link to post
Share on other sites
A bias or feed foward would need to have the ability to adjust as the load changes to have any affect on how well the PID will keep the temperature error small. A simple offset like bias would not help here. Actually, I don't think a bias will make any difference unless it can change as the load changes. A time delay is not the answer. You are close. What is the answer? It is simple.

Share this post


Link to post
Share on other sites
It looks like my last post stumped everyone. Mellis brought up a good point. When the equipment is turned on there is a 'delay' ni the heat being 'felt' by the PID, but there are two components. The energy heats the machinery. The temperature would rise exponentially like this 1-exp(-t/Tc) and there could be some dead time too. If there are many such machines then each would add its own 'disturbance' or change in load to the system D1*(1-exp(-t/Tc1)+ D2*(1-exp(-t/Tc2)+D3*(1-exp(-t/Tc3). The D? represent the magnitude of the disturbance and Tc? is the time constant of each machine. All of this is too difficult to calculate for most installations and computing how much bias would be needed as a function of the load would be difficult. The calculations for this would look like summing many low pass filters. One would have to model each contribution to the total load one at a time. The point is that the load will not change that quickly because of the time constants of the loads. If the load doesn't change faster than the PID response I don't see a need for the bias or feed forward unless there must be no error between the SP and the PV. Think about it.

Share this post


Link to post
Share on other sites
Here I am Four (4) months later and finally can play with and tune this loop. The High Point Facts are as follows: 1. Air Handler with Glycol Filled Coils is to Chill Air to Maintian Room Temp. 2. AHU Fan runs at 30 Hz until machinery in room {producing heat} comes on and then shifts to 60 hz. 3. Need to maintian room temp of 50 degrees and use return air no coldder than 38 degrees. How I implemented this with PID COntrol. PID One - Uses Return Air Temp as Process Value and Glycol Valve Position as Control Value. Temps run 0 to 1000 1/10's of a degree and Valve Position is 0 to 4095 units. Setpoint for PID 1 comes from a subtraction equation. Kp = 20 ; Ki = 0.1 ; Kd = 1 Subtraction Equation - Takes the Control Value of PID Two and the 50 degree setpoint to produce a floating setpoint for PID 1 between 38 and 50 degrees. PID 2 - Uses Room Temp as Process value and Sends a number between 0 and 12 to the Subtraction Equation. Setpoint fot PID 2 is 50 degrees. Kp = 10 ; Ki = 0.1 and Kd = 0 I am quite sure that I lack correct volume of air at this time. For the last six hours we ahve been pushing 38 degree air into the room and only able to recover from 56 down to 52 bewteen machine cycles. Room has never reached 50. Thoguhts - Guru's?

Share this post


Link to post
Share on other sites
With the 38 degree limitation, your only means of increasing the cooling is to increase the air flow. What is the glycol valve position when the outlet is 38? The valve position will give an indication of the amount of capacity remaining in the system. If the valve is near 100%, more air will not have much effect. If the valve has substantial travel left, then when air flow is increased, the valve can open more to get back to 38.

Share this post


Link to post
Share on other sites
Just so happens that the valve iss at 50% when putting out 38 air. And I can possibly go lower but cannot go below 32 and risk creating ice.

Share this post


Link to post
Share on other sites
Can't you see that the limitation is the lack of heat exchanger. To get energy to transfer from one medium to another one needs more surface area, more flow or a greater difference in temperature. Since the greater difference in temperature is not desired then you need more surface area. And after six months did you fix or add an heat exchanger or piping as I suggested or did you ignore those post? See posts 14,18, and 20. So when are you going to add a heat exchanger? Fix that first. Then we can work on the control. The PID is just a tool that can control the flow of energy within the limits of the system. Your system has some serious heat exchanger limits.

Share this post


Link to post
Share on other sites
Yes Peter I saw your posts and the transfer of heat issue right now is confined by lack of flow. The AHU is supposed to run with 2 fan cages and presently has only one installed. A vibration issue took #2 out of commission and repairs will take another month or so. Let you know how it goes once we have full capacity.

Share this post


Link to post
Share on other sites
I had a doubt sit on my mind for last few year. Hope with this opportunity, all gurus here can given some lesson. "PID Wind Up" - The problem I had is the temperature control with PID loop's CV (control Variable) went to 0% and stay there for 2min++ ,then it start to responce gradually increase CV value. One of the senior told me that, this is due PID wind up.How it happen and how to get away from this issue?

Share this post


Link to post
Share on other sites
Why do you think this is a problem? It may not be a problem. It depends on what kind of system you have. I have simulations where the output goes to zero and the PV still manages to close in on the SP with no over shooot. I bet Ron Beaufort's hotrod controller will have its output drop to 0 if the SP is reduced by 100 degrees or so. We need more inforation. Edited by Peter Nachtwey

Share this post


Link to post
Share on other sites
I agreed,Peter. In normal operation this controller perform very well. I noticed this when the system on statup after maintenance,while the PV is less than SP for long period on auto mode PID; for sure the CV will went to 0%. But when the system back to operation, the PV start rising and above than SP, I expected the CV will responce too but it did not , the value 0% sit there for some period,then after it start responding. The system I attend is Process Cooling Water.

Share this post


Link to post
Share on other sites
When the PID can't control the system, like when under going maintenance, turn the PID off or put it in manual mode. If you leave the PID on when it can't control the PV the integrator will wind up.

Share this post


Link to post
Share on other sites
Thanks,Peter.I note that,future will switch the PID to man mode. Presently the PID instruction in running without condition. What you said, if addin 1 sec on condition in front of this PID. Would it help to reset the integrator?

Share this post


Link to post
Share on other sites
Quote: "Critical to success, is that the process data generated by the bump test be descriptive of actual process behavior. Discussed are the qualities required for "good" dynamic data and methods for modeling the dynamic data for controller design." The above is an excerpt from the article "Model-Based Tuning Methods for PID Controllers", which is a good prelude to the discussions here. Model_Based_Tuning_Methods_for_PID_Controllers_2.pdf Performance_Monitoring_Fundamentals_2.pdf

Share this post


Link to post
Share on other sites
Bin95, who are you? I see you are referencing data from the control guru website and control station ( Doug Cooper and Bob Rice of UCONN ) but I am not familiar with you. In any case you are not addressing the immediate problem. Your post looks like an advertisement rather than a solution to a problem. To the rest. I support have supported the controlguru site because I know what they are doing and how they do it. I even have and article posted there. I have used their techniques to do the auto tuning on the Advanced Control threads on plcs.net. I just want to see what the motivation is for BIN95. Most of you know I do motion control and not process control for a living so I am neutral when it comes to process control and just trying to help. Edited by Peter Nachtwey

Share this post


Link to post
Share on other sites
Hi Peter: I work for Business Industrial Network (BIN95.com), not Control Stations (although we do host some of their seminars and post many of their articles to our site. My job is PLC Training and I was looking over you all's post to see what more I could learn about the PLC side of PID. As I read, I realized many like my self, may not be as well versed in the aspect of PID design. From that point of view, I thought the article from our company website might help those less experienced readers of your post, gain a better understanding. As you might have noticed from my stats, I get very little time now days to post to discussions I read, and tend to act impulsivly. When I used to have time, I was know nto be long winded. My appolagies if my short post was an intrusion in your niche. Oh, I like smilies too, did you notice? :>)

Share this post


Link to post
Share on other sites
Your post does not answer either of the two topics and looked like an add. I am always skeptical when I see information copied from other sites. It is easy to copy material . I have seen other sites copy material from plcs.net and mrplcs.com. Copying Control Station material is another matter because it is much more technical than the average PLC site. Understanding PID and other forms of control is a different matter. I have been fooled before. Now I am more skeptical. TW vouched for you. I don't consider this my niche. I let Ron Beaufort take all the AB PID setup questions. I get involved when I see people flailing around with asking or answering questions. The thread had many posts suggesting this or that until I pointed out that the system isn't designed right and no amount of tuning will make it work. CTsoft had a question occurs in motion control too. People turn off the power and leave the controller on so it will windup. Then when power is applied they are surprised that the system takes off or just sits there while the PID unwinds. I am actually a motion control person who gets into process control just to widen my horizons. A lot of the problems and solutions look different but are mathematically the same.

Share this post


Link to post
Share on other sites
Greetings BIN95 ... and welcome to the forum ...

Share this post


Link to post
Share on other sites
The "REPAIRS" are made and I have some data. They have fixed the fans so I have full air flow. THe following data was taken after the room warmed to 62 degrees and the return air to 61 degrees with the gylcol turned off and only the AHU fan running. Neither machine was running during this test it is static room only. 001 is the room temp PID Loop which adjusts the 002 Return Air temp loop. Zip Files contain the RSTune Data and an Ascii Version of the same. SUGAR001.zip SUGAR002.zip Ron, Peter and company - knock away.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0