Alternative to a PID in a flow control

JulienV

Member
Join Date
Dec 2007
Location
Montreal, Quebec
Posts
52
Hi guys! I would have to tune a PID for a flow loop tomorrow and I have done very few PID tunings in my career. I know about the Ziegler-Nichols method but frankly had little success with it when it was time to implement it in the PLC (Control Logix for instance). Also, opening and closing this 3" valve on oscillation is really bad for the plumbing. So would it be bad practice if I avoided a PID and used simple timers and add/sub to change the opening of my valve? The speed the add/sub operations could change my CV would be simply proportional to the error. Pretty simple and straight forward. What do you guys think?
 
Have you tried autotune option of PIDE in Control Logix, also try www.controlguru.com they have a good explanation on tuning.
I set a PIDE flow loop 3 months ago using a centrifugal pump and pneumatic control valve with no problem, i use flowmeter from endress&hauser, I used 4-20 mA data as PV not from hart.
 
Tell us more about your system

My first impressions is that you have the gains too high. That answer is safe because high gains are is what causes oscillations.

First we must know what you are controlling before we give advice on how to control it.

Do you have valve position feed back?
Do you have flow feed back? I assume so but where is it?
Could the flow feed back be slow or be a source of dead time?
How fast does the valve close?
Does the valve move to a position proportional to the control signal or does the valve open at a rate proportional to the control signal? The later case is much harder to tune and not the same as a FOPDT on the controlguru site.
 
... So would it be bad practice if I avoided a PID and used simple timers and add/sub to change the opening of my valve? The speed the add/sub operations could change my CV would be simply proportional to the error. Pretty simple and straight forward. What do you guys think?

This is called proportional speed floating control and would probably work well.
 
Check my answers at the end of your questions. Thanks!

My first impressions is that you have the gains too high. That answer is safe because high gains are is what causes oscillations.

First we must know what you are controlling before we give advice on how to control it.

Do you have valve position feed back? No
Do you have flow feed back? I assume so but where is it? Yes, downstream. Within a few feets
Could the flow feed back be slow or be a source of dead time? Quick react.
How fast does the valve close? Within 1.5 seconds
Does the valve move to a position proportional to the control signal or does the valve open at a rate proportional to the control signal? The later case is much harder to tune and not the same as a FOPDT on the controlguru site. Not sure what you mean here, but its proportional to the 4-20 mA analog output
 
This is called proportional speed floating control and would probably work well.

Thanks for the terminology, I figure it should work. I'm still weighing if I'm going to go for the PID or the PSFC. I don't deal very oftem with PIDs and I have to relearn every time not to mention it does'nt work the same way from one PLC to another...
 
Have you tried autotune option of PIDE in Control Logix, also try www.controlguru.com they have a good explanation on tuning.
I set a PIDE flow loop 3 months ago using a centrifugal pump and pneumatic control valve with no problem, i use flowmeter from endress&hauser, I used 4-20 mA data as PV not from hart.

I've browsed quickly on the controlguru site. Interesting that he talks about the dimensionless gain (P) in the PLCs. Must admit that's been a big struggle for me trying to figure out what the numbers I was putting in actually meant. I'm going to look deeper into that. Like I said, I'm not sure yet if I'll go for the PID or the Proportional Speed Floating Control s stated by Tom. This would be much easier for me to manage. I think I'll try the PID as much as I can and keep the PSFC method as a backup.
 
So would it be bad practice if I avoided a PID and used simple timers and add/sub to change the opening of my valve? The speed the add/sub operations could change my CV would be simply proportional to the error. Pretty simple and straight forward. What do you guys think?

I do this all the time with PRESSURE control. Mine has 3 variables.

1) The proportional gain. This is a variable by which I multiply the error, before adding or subtracting it from the current analog register. This allows me to make the response faster or slower.

2) The interval. This is the TIME between each sample-and-action cycle. It ALSO allows the response to be faster or slower but is more influenced by the type of equipment being controlled, and the "plant rate" of the process.

3) Error Redux. This is calculated based on how much the error has "reduced" since the last cycle. It is multiplied by a variable and SUBTRACTED from the proportional gain before loading the final change into the analog register. (VFD control)

In YOUR case, once you've calculated the "change" value, depending on how your valve works, you'll still have to write a section that moves the valve to a comparable position (scaled to the minimum and maximum) and hold it there until the next cycle.

It works for pressure, I don't see why it wouldn't work for flow. That's only assuming you've given up on PID and the help you could get from the others here setting up the PID.

Stationmaster
 
What is it? Spool velocity or position

If the valve position proportional to the control signal.
4ma 0% open or closed
8ma 25% open
12ma 50% open
16ma 75% open
20ma 100% open

There must be a valve controller that is keeping track of the spool position. This would be the easy case. A simple PI controller would do the trick. It should be possible to build a look up table that says that for this flow I want this output and you would be very close.

or

4ma 100% close speed
8ma 50% close speed
12ma 0 speed
16ma 50% open speed
20ma 100% open speed

This is the more difficult case since you don't know where the spool is so it must be moved more slowly so one can wait for the response to keep from over shooting.

Another question. How linear is your valve? If the spool is at 10% open will there be 10% flow? At 50% open is the 50% flow? You may need a look up table to linearize the spool but this will not make any difference if you have the second case where your control output controls the spool velocity.
 
Hi guys! I would have to tune a PID for a flow loop tomorrow and I have done very few PID tunings in my career. I know about the Ziegler-Nichols method but frankly had little success with it when it was time to implement it in the PLC (Control Logix for instance). Also, opening and closing this 3" valve on oscillation is really bad for the plumbing. So would it be bad practice if I avoided a PID and used simple timers and add/sub to change the opening of my valve? The speed the add/sub operations could change my CV would be simply proportional to the error. Pretty simple and straight forward. What do you guys think?

Please describe the process. What are you controlling? I can guess that it's probably some sort of liquid flow, but it's nice to know for sure. Is it simply pumped from one tank to another? Or is it more complicated? What is the control hardware? A Rosemount mag meter? A Fisher control valve?

Basically, the more we know, the better the response.
 
I would like to know why you want to control flow also. A description of the system would be great.

I can see it if you are regulating flow on one side of a heat exhanger to control the temperature of other side in which case you are really controlling the temperature by varying the flow. In this case I would sense temperature and not flow.

Another example could be a hydraulic motor but there you are regulating flow to control the speed. I would sense RPM and not flow.

I would set valve up such that it is never fully open nor fully shut under normal operation - this will reduce your water hammer problems.

Dan Bentler
 
The process is the infeed of a small waste water plant for a pharmaceutical company. They have to treat their water before sending it to the city sewers. The valve I'm controlling is fed by two tanks/pumps which are filled by the plant's waste water. The operator chooses which tank to treat the water from. The operator actually changes the opening of the valve manualy with the HMI (I guess the integrator did'nt finish the job). The problem they have is the more the tanks empty, the less the flow is, so they have to "constantly" open the valve a little more to keep the setpoint of 500 liters/min.
 
This sounds like a perfect application for a simple proprtional feed-back loop.

Subtract 'actual flow' from setpoint,

Multiply the difference by a variable, greater than 1 to make it hotter, .999 or less to cool it down.

Add the product to the current analog output register value. (Adding a negative number will reduce the register value, etc)

Wait for (variable) seconds.

Repeat.

Stationmaster
 
What you proposed in the original post, should work perfect for this.... It doesn't sound like you need fast control, just compensation for the difference in head pressure. I did something similar on a VFD on a Baghouse... As the filters plug up, the VFD slowly speeds up, maintaining flow. Just note, that you may want an initial opening value to be fed to the valve, if you are planning on a slow control.

-MUR
 

Similar Topics

Hello to all, I'm just starting with using CodeSys. Immediately, I have noticed that Codesys doesn't use data blocks like for example S7 does...
Replies
11
Views
178
Greetings All, I recently decided to start freelancing in Controls and Automation part time, most of my experience has been with Rockwell...
Replies
2
Views
166
Recently I have requested a quote from Magnetek for their Impulse Drives but can't raise a response from them. I've requested a quote FOUR TIMES...
Replies
3
Views
1,069
Hello All, Its been a long time since i've been in the trenches actually doing development. When i was developing I used PicsPro extensively for...
Replies
2
Views
1,192
Hello friends, I'm asking a new question here, after thinking a lot about my problem, I wondered if it wouldn't be easier for me to install new...
Replies
0
Views
738
Back
Top Bottom