Help with PID for Blending water

Holmzy

Member
Join Date
Jan 2006
Location
Cambridge Ontario
Posts
26
I have an application that is to mix two water sources. I have City water that is 800 -1300 mmhos and I am blending RO that is 80 to 100mmhos with it to get a target 0f 230 - 250 mmhos.
I was wondering if anyone had an example of a PLC program useing PID to control the blend

I am using a logixs 5000 processor but any example would be nice.

Attached is a layout of the valving
 
Holmzy said:
I have an application that is to mix two water sources. I have City water that is 800 -1300 mmhos and I am blending RO that is 80 to 100mmhos with it to get a target 0f 230 - 250 mmhos.
I was wondering if anyone had an example of a PLC program useing PID to control the blend

I am using a logixs 5000 processor but any example would be nice.
Attached is a layout of the valving

I have heard of blended whiskey
WHY blended water ?? To go with blended whiskey perhaps??

Using RO water to knock down the conductivity of city for boiler feed water??

How much water are you talking about ie gallons per minute hour or?

Dan Bentler
 
I did something similar years ago to make potable water from RO and raw water.
I suggest you ratio the city water flow to the RO water flow.
You can probably calculate the ratio based on the figures you give.
The Ratio Setpoint can be adjusted manually or if you want to get real fancy use a conductivity controller to change the ratio setpoint between limits.
I was unable to download the bitmap could you send it by pdf to roy_matson at yahoo.ca

Regards
Roy
 
I don't know your level of experience but even well educated engineers have difficulty with the PID function on instrumentation since it is based in calculus. Most control work is done proportionately using simpler math.

It is my understanding that the PID function allows you to use Proportional control, Integral control and Differential control to control a variable.

My limited knowledge of it, was that if I was trying to heat up an oven for example I could hit my target temperature OK with proportional control but the temp would overshoot then come back under and after oscillating around the temp it would slowly settle in on the desired setpoint. The valve doesn't know how fast the oven is heating up and can't anticipate hitting its setpoint.

By using integral control the processor can calculate the instantaneous slope of the line and compensate for the approach to the setpoint thereby giving you a smoother settle-in to the setpoint temperature. Proportional control can do a little of this by using the difference between your setpoint and your current point to control how far the valve is opened and reduce the valve position as it approaches the setpoint to avoid overshoot that occurs with simpler on-off control of a valve.

The differential function is even more rarely needed but my understanding is it allows you to program for quick changes in the load i.e. putting a fully loaded pallet onto a conveyor and maintaining the speed of the conveyor as the load is quickly increased (or decreased).

Your application sounds like it would not need the PID control. You really only need 1 analog reference signal coming back to the PLC from the output of the mixing valve. Then you need to do some math in the program to control the analog output to the RO water valve to achieve your desired mmhos. Just subtract the setpoint from the current value and output the difference to the RO valve. As the mmhos goes down your RO water valve should close down proportionately and cutoff entirely at the low point of your scale.

If you want to monitor the input mmhos and the RO water mmhos you can add a couple more analog inputs but they are not needed for a simple feedback loop.

You may also want to buffer the output by taking samples every few seconds or something to keep the valve from oscillating with any little change.

(I tried to download your zip but all I got was a folder called "Start Menu" with some other files.)
 
This may be a bit simplified but the solution should be an easy one. From what I understand you want to reduce the mmhos (conductivity) of the city water using RO water.

You need to be able to measure the actual mmhos PV at the point of blending, you have a Setpoint SP in the range 230-250mmhos. This gives you your PV and SP terms of your P&ID. The output OP of the P&ID should then be used to control the flow of the RO Water. i.e. If the PV is higher than the SP, the OP will increase therefore adding more RO water to the blend. If the PV is lower than the SP, the OP will decrease therefore reducing the amount of RO water to the blend.

This way when more RO water is added the mmhos will reduce.

Hope this helps.
 
Please do not listen to Archon's comments. They show little understanding of system dynamics, PID control, and control theory in general. Archon very much shows a "limited knowledge of it." There are plenty of good threads describing PID and its applications on this site, however, this is not one of them. I hate to do what I'm about to do to another member, but I cannot have such an erroneous description of PID control leading members astray.

Archon said:
I don't know your level of experience but even well educated engineers have difficulty with the PID function on instrumentation since it is based in calculus. Most control work is done proportionately using simpler math.
Not true. Well-educated engineers have a thorough understanding of calculus and understand the PID function quite well.

Archon said:
My limited knowledge of it, was that if I was trying to heat up an oven for example I could hit my target temperature OK with proportional control but the temp would overshoot then come back under and after oscillating around the temp it would slowly settle in on the desired setpoint. The valve doesn't know how fast the oven is heating up and can't anticipate hitting its setpoint.
Proportional control in a non-integrating system will not settle in on the desired setpoint.

Archon said:
By using integral control the processor can calculate the instantaneous slope of the line and compensate for the approach to the setpoint thereby giving you a smoother settle-in to the setpoint temperature. Proportional control can do a little of this by using the difference between your setpoint and your current point to control how far the valve is opened and reduce the valve position as it approaches the setpoint to avoid overshoot that occurs with simpler on-off control of a valve.
Calculating the instantaneous slope of the error is the derivative function, not the integral function.

Archon said:
The differential function is even more rarely needed but my understanding is it allows you to program for quick changes in the load i.e. putting a fully loaded pallet onto a conveyor and maintaining the speed of the conveyor as the load is quickly increased (or decreased).
Derivative control will add large changes in control output as the variable it acts on changes rapidly. This may or may not be a good thing, since it can amplify noise or cause rapid jumps during step changes in setpoint. Disturbances in load can generally better be compensated for by feedforward control.

Archon said:
Your application sounds like it would not need the PID control. You really only need 1 analog reference signal coming back to the PLC from the output of the mixing valve. Then you need to do some math in the program to control the analog output to the RO water valve to achieve your desired mmhos. Just subtract the setpoint from the current value and output the difference to the RO valve. As the mmhos goes down your RO water valve should close down proportionately and cutoff entirely at the low point of your scale.
This is simply describing proportional control, and since the process is not an integrating process, will result in a steady-state condition that is not equal to the setpoint.

Archon said:
You may also want to buffer the output by taking samples every few seconds or something to keep the valve from oscillating with any little change.
This is undersampling, and if the system dynamics change rapidly, the valve may operate more smoothly but the system variability may increase and the process variable may exceed control limits. The sampling period should be based on the dynamics of the system, not the requirements of the actuator. Filtering can always be added.

Listen to the posters above who advocated using ratio control. They've given you better advice.
 
Mixing Water Project

leitmotif said:
I have heard of blended whiskey
WHY blended water ?? To go with blended whiskey perhaps??

Using RO water to knock down the conductivity of city for boiler feed water??

How much water are you talking about ie gallons per minute hour or?

Dan Bentler

Dan,



What I am doing is taking RO water that has too low a conductivity and therefore is having a detrimental effect on the Media in my Air Supply House's evaporative cooling/humidification and blending city water that has too high a conductivity. This will do two things save me money by reducing the RO usage and correct the current condition of the media collapsing because of the aggressiveness of the water.



What I plan to do is regulate the pressure of the water to below 80 psia nd measure the conductivity upstream and control the addition of the RO water into the City Water with a proportional valve.



This is what I want to control with the PID from the processor.

 
How much does the conductivity of your city water change? I don't imagine that it changes much over short periods of time but the change is more likely to be seasonal. Same with the RO system, how much does it change? I just wondering if its even necessary to have an active controller and instrumentation on it, set the mix valve and check a sample every few months to see if it needs to be tweaked or not.
 
This may be a bit simplified but the solution should be an easy one. From what I understand you want to reduce the mmhos (conductivity) of the city water using RO water.

You need to be able to measure the actual mmhos PV at the point of blending, you have a Setpoint SP in the range 230-250mmhos. This gives you your PV and SP terms of your P&ID. The output OP of the P&ID should then be used to control the flow of the RO Water. i.e. If the PV is higher than the SP, the OP will increase therefore adding more RO water to the blend. If the PV is lower than the SP, the OP will decrease therefore reducing the amount of RO water to the blend.

This way when more RO water is added the mmhos will reduce.

Hope this helps.

I agree. This isn't ratio control per se. You could remove those conductivity probes on the inlet piping altogether in this application.

Tomorrow AM in the shower see how easy it is to set your water temperature to just how you like it - without needing to know how "cold" your cold water is, and how "hot" your hot water is. Measuring these values would give us insight to be able to "feedforward" to respond more quickly to sudden variations in the cold or hot streams. But if those streams aren't prone to sudden variations (toilet flush), normal PID should work fine. Hehe, hope everyone like analogies.đź““

Use your PID to control your mixing valve based on the "mixed" conductivity you measure.

As for programming, it's one PID block and any related scaling for your I/O.

In fact, a stand alone Process Controller with comms I/F to your existing PLC system may be the most economical approach.

I modified your drawing (Paintbrush) and attached it.

YMMV

mixmod1.jpg
 

Similar Topics

Hello all, I have an issue with a PID block in RsLogix 5000. The parameters are P: 3.25 I: 0.11 D: 0.01 The Set Point is 71 psi This loop...
Replies
63
Views
14,663
hey guys - I'm a novice PLC enthusiast, so this may be a simple one. I'm running a PID on a Micrologix 1200 PLC and I want to change the Gain for...
Replies
18
Views
4,216
I need a little help with a project I have been thinking about. We have a belt line that is fed by a gravity door (pretty much a hydraulic...
Replies
14
Views
2,682
Hi all, I have a request from client as follows, There's one PID for Control valve which would be controlling on basis of temperature. One...
Replies
1
Views
1,502
Hi, I am trying to automatically regulate a process ( liquid ) in a tube using an ultrasonic sensor, differential level meter, control valve...
Replies
3
Views
3,072
Back
Top Bottom