Interested in linking to "It's the Resolution, Stupid! Part 2"?
You may use the Headline, Deck, Byline and URL of this article on your Web site. To link to this article, select and copy the HTML code below and paste it on your own Web site.
By Cecil L. Smith, PE
From Part One: The traditional use of current loops as inputs to control systems is being replaced by measurement devices and/or input systems that provide the measured value in engineering units. In the era of digital technology, this is indeed appropriate. But unfortunately, the resolution of the digital values is often less than what became the norm for current loop inputs, specifically, a resolution of approximately 1 part in 4000.
Normally such a resolution is far beyond what is required on displays to the process operator, management reports, etc. The value chosen for the resolution is usually based on two factors:
This article examines this issue from the perspective of regulatory control, or more specifically, the impact of the resolution of the measured value on the performance of the proportional-integral-derivative (PID) controller. Control calculations often need a greater resolution than is required for data presented to humans. Furthermore, the performance of regulatory control actually depends on the repeatability of the measurement device, not its accuracy.
The impact of poor resolution on the three modes is as follows:
Proportional mode: Causes the output to change abruptly from one value to another.
Integral or reset mode: Not significantly affected by resolution.
Derivative mode: Causes pulses or "bumps" to appear in the controller output.
Part Two: When the input for the measured variable is the result of an analog-to-digital (A/D) conversion, the result (called the "raw value") is stored in a 16-bit integer format. As more "smarts" are incorporated into either the measurement device or into the input module, the "raw value" can be in engineering units. How does one incorporate this capability into systems whose original architecture contemplated the use of A/D converters?
A common answer: represent the engineering units value in a 16-bit integer word. Let's illustrate this "solution" for temperature inputs. For thermocouples and RTDs, input cards are available that perform the linearization and, for thermocouples, the cold junction compensation to give the temperature in either °C or °F (a configuration option). The result is typically the temperature to the nearest 0.1°, which can be stored in an integer word.
For example, the upper limit of the type J thermocouple is about 1320°F. This would be represented as 13200, which can be stored in a 16-bit integer word. The lower limit is typically -200°F. This would be represented as -2000, which can also be stored in a 16-bit integer word.
Unless one resorts to custom calibration or other methods, representing the temperature to 0.1°F is superior to the accuracy of thermocouples. With RTDs, the current technology provides an accuracy approaching 0.1°F. From an accuracy standpoint, this appears to be a perfectly satisfactory approach. In most applications, it is. However, there are a few exceptions.
As noted previously, the parameter of importance for control applications is repeatability, not accuracy. While 0.1°F is probably adequate for thermocouples in high temperature applications, it is not adequate for RTDs. In applications such as reactor temperature control, the sensor of choice is an RTD. Furthermore, in applications such as reactor temperature control, the derivative mode is frequently used. Today, product chemists expect the reactor temperature to be maintained within 0.5°C of set point, so control performance is of utmost importance.
If one considers the entire measurement range of the type J thermocouple, the input range is -2000 to +13200. The resolution over this input range is 1 part in 15200. For the A/D converters used in most industrial applications, the resolution is approximately 1 part in 4000 (some are slightly better; some are not quite this good). Over the entire input range, the integer representation of the engineering value is superior to what can be achieved with an A/D converter.
In control applications, the question is not the resolution over the entire possible input range; instead, the question is the resolution over the range required for control. For example, applications such as fermentation involve water under atmospheric pressure. The maximum possible input range is from 32°F or 0°C (the freezing point of water) to 212°F or 100°C (the boiling point of water). Over this range, the resolution is as follows:
If the field transmitter is set to output 4 mA at 32°F or 0°C and 20 mA at 212°F or 100°C, the resolution from the A/D converter would be superior. This issue is compounded by the fact that derivative is normally used in the temperature control loop in applications such as fermentation reactors.
Even when the input range of the measured value is 0°C to 100°C, the effective control range is sometimes much less. In a continuous plant, issues suchas start-up can dictate an input range that is much wider than required for control. In a batch plant, different products require different processing conditions, which impose an input range much wider than required for control of a given batch.
Let's give an example from a batch plant. Some batches are "cold batches" and run with a temperature set point of 20°C. Some batches are "hot batches" and are run with a temperature set point of 80°C. To accommodate this spread, the range of the measured value is 0°C to 100°C. However, for a given batch, a measured variable span of 20°C would be sufficient.
The consequence of this is a large value for the controller gain. With a measured variable span of 20°C, the value of the controller gain of 5%/% would be a reasonable value for a temperature controller. But with a measured variable span of 100°C, the value of the controller gain would be 25%/%. Such large values for the controller gain are occasionally encountered in control loops, and in most cases, this is the result of a measured variable span that is wider than required for control.
In any loop with a large value for the controller gain, careful attention must be paid to the resolution. Consider the following for a temperature control application:
The smallest change in the measured input is 0.1°C, which is 0.1% of the input span of the measured variable. With a controller gain of 25%/%, a change of 0.1°C in the temperature would cause the controller output to change by 2.5%. In reactor temperature control applications, this is likely to attract some attention. Figure 1 illustrates the performance of a PI controller for a disturbance to a temperature loop. The resolution on the temperature measurement is 0.1°F, which is 0.1% of the measurement span of 100°F. With a controller gain of 2.6%/%, a temperature change of 0.1°F (also 0.1% of span) causes the controller output to change by 2.6%. Such abrupt changes are clearly visible in the controller output, but otherwise the resolution has little impact on the performance of the loop.
However, the impact of the resolution is much greater on the performance of the PID controller illustrated in Figure 2. The addition of derivative has reduced the maximum departure from set point (150°F) from 2.3°F with PI to 1.2°F with PID, which in applications such as reactor temperature control is very appealing. The tuning coefficients are reasonable:
However, there are numerous distinct "bumps" in the controller output. It is also evident from Figure 2 that the bumps are associated with 0.1°F changes in the temperature. The controller has a derivative mode smoothing factor of 0.1 (which is a derivative gain limit of 10).
The following changes will reduce the"bumps," but at the expense of performance:
The latter is the only viable approach.
Traditional installations relied on current loop inputs. If an A/D converter with a resolution of 1 part in 4000 is applied to a current loop input with a span of 100°F, the resolution in engineering units is 0.025°F. The performance of the PID controller is illustrated in Figure 3. The bumps are still present, but they are much smaller.
The customary industrial practice with A/D converters gives resolutions such as the following:
There are a number of other factors that go into the decision as to which approach to use. But for purposes here, let's consider the resolution to be 1 part in 4000 for an input range of 4 to 20 ma.
A number of inexpensive modules are available that convert the input from a thermocouple or RTD to a 4 to 20 mA signal. Most of these products provide linearization and, for thermocouples, reference junction compensation. The measurement range on these modules often reflects the characteristics of the sensor. Consequently, for a type J thermocouple, the lower range value is often -200°F and the upper range value is 1320°F. The resolution of this input is
This is not as good as the input module that provides the input value as the temperature in °F to 0.1°F. To obtain better resolution, a narrower span is required for the module that produces the milliamp signal.
Another input application where the resolution must be examined carefully is for inputs from weight transmitters or load cells.
Modern load cells have very high resolutions. For example, a weight of up to 6,000 kg can be indicated to 0.1 kg. This measurement has a resolution of 1 part in 60,000!
Suppose this weight is provided via a 4-20 mA signal to an input module with a resolution of 1 part in 4000. A change of 1 "count" in the raw value would result in a change in the indicated weight by 6000.0 kg / 4000 = 1.5 kg. The weight indicated by the digital system would not generally agree with the weight indicated at the load cell.
In order that the weight indicated by the digital system agree exactly with the weight indicated at the load cell, approaches such as the following have to be used in lieu of current loop inputs:
In PLC installations, a common approach is to represent the output as an integer value to either 1% or 0.1%. An output value of 0% is represented as 0; an output value of 100% would be represented as either 100 (to 1%) or 1000 (to 0.1%). One advantage of this approach is that the output value can be represented on a graphical display with little or no need for conversion calculations within the graphical display (it only needs to know where to put the decimal point).
If the output value is represented to 1% (output range is 0 to 100), the resolution is 1% or 1 part in 100. Certainly there are valves that cannot be positioned to within 1%, but most can. Any variable speed drive can certainly respond to smaller changes than 1%.
If the output value is represented to 0.1% (output range is 0 to 1000), the resolution is 0.1% or 1 part in 1000. This is beyond the capability of valves installed in industrial facilities. Variable speed drives can probably do better, but 0.1% would be adequate for most applications.
In some PLC applications, a similar approach is used for the set point for the inner loop of a cascade. The output of the controller is expressed in the engineering units of the measured variable for the inner loop. For example, if the inner loop is a flow controller with a range of 0 to 20.0 kg/min, the output would be converted to kg/min and stored as an integer value to 0.1 kg/min. That is, 0 is 0 kg/min and 200 is 20.0 kg/min. The resolution is 1 part in 200.
A similar approach is used for the measured input for the inner loop. Even if the source of the input is a current loop, the raw value from the input module is converted to engineering units in kg/min and represented to 0.1 kg/min. This permits the value for the measured variable to be readily presented on a graphical display. However, flow measurement devices such as Coriolis meters, magnetic flow meters, vortex shedding meters, etc., are capable of far better resolutions.
This approach can be used for the measured variable for any loop, not just the inner loops of cascades. But whenever this is done, the choice for the resolution can potentially have an impact on the performance of the PID controller.
In PLC installations, "registers" traditionally stored 16-bit integer values (or sometimes 4-digit BCD values). In older models, no options were offered. Current models usually provide the option of 32-bit registers for either integer representations or floating-point representations. However, product features often reflect past practices and are slow to change.
In one product (that will not be named), a 16-bit integer register is used to store the reset gain, which is the product of the controller gain (in %/%) and the reset time (in repeats/minute). The reset gain is represented as an integer value expressed to 0.1 (%/%)/minute. A value of zero for the reset gain disables the integral or reset mode. Otherwise, the smallest value for the reset gain is an integer value of 1, which is a reset gain of 0.1 (%/%)/minute. If the controller gain is 1.0%/% (certainly a reasonable value for some loops), the minimum reset rate is 0.1 repeats/min. This translates to a reset time of 10 minutes. An integer value of 2 (the next increment) is a reset gain of 0.2 (%/%)/minute. This translates to a reset time of 5 minutes. If the controller gain is set to 1.0%/%, it is not possible to set the reset time to 7.5 minutes. This may be acceptable for automotive applications, but not in chemical plants.
In another product (which will also not be named), the input processing software provides an option for square root extraction on the input value (to support inputs from head-type flow meters such as orifice meters). The range of the input is 0 to 4096, which is 1 part in 4096 (a reasonable resolution). However, the product simply takes the square root of the integer value. The result has a range of 0 to 64 (642 = 4096). The problem with this approach is a poor resolution for the flow, specifically, a resolution of 1 part in 64. The appropriate approach is as follows:
However, the calculation must be performed with either 32-bit integer arithmetic or floating-point.
This article has illustrated some of the ways that inadequate resolution can impair the performance of a PID controller. There are certainly others. These problems seem to appear more often in applications implemented with PLCs, but they can and do arise in DCS applications as well (the example in Figure 1 was from a DCS application).
The problem here is that those doing the implementation and/or programming are very knowledgeable regarding the systems aspects of the application, but have little or sometimes no experience with PID control. The decisions are made based on ease of programming, compatibility with the features of graphical display devices, ease of troubleshooting, etc. The impact of the decisions on the performance of PID controllers often gets no consideration whatsoever.
Cecil L. Smith, PhD, PE, has a consulting practice devoted exclusively to industrial automation, encompassing both batch and continuous processes. He also teaches continuing education courses on various aspects of process control.