You are on page 1of 48

Sensors and

Actuators for
Automation
(EE 5210)
Lecture : 3
Logeeshan V. (Ph.D.)
Senior Lecturer

57
Linear Regression
• If measurements of the input stimuli during calibration cannot be
made with high accuracy and large random errors are expected, the
minimal number of measurements will not yield a sufficient
accuracy.

• To cope with random errors in calibration process a method of least


squares could be employed.

58
Computation of Stimulus
• A goal of sensing is to determine a value of the input stimulus s
from the value of the sensor output signal S. This can be done by
two methods.

 From the inverted transfer function or its


approximation.
 From a direct transfer function by use of the
iterative computation.

59
Computation from Linear Piecewise
Approximation
• Both triangles are similar, which
allows us to derive a linear
equation for computing the
unknown stimulus from the
measured value of .

60
Computation from Linear Piecewise
Approximation
• This equation is easy to program and compute by an inexpensive
microprocessor, which keeps in memory a look-up table containing
the knots.

61
Computation from Linear Piecewise
Approximation
• Figure shows a thermistor
temperature sensor with
a pull-up resistor R1
connected to a 12-bit
analog-to-digital (A/D)
converter.

62
Computation from Linear Piecewise
Approximation
• After manipulating, we arrive at the inverted transfer function
which enables us to compute analytically the input temperature
in :

• First, we need to calibrate the sensor at two temperatures


and in order to find out values of the constants and

63
Computation from Linear Piecewise
Approximation
 Assume that a pull-up resistor is selected during design. Let
us select two calibrating temperatures in the middle of the
operating range as and The
thermistor sequentially is immersed into a liquidbath at these two
temperatures and the 12−bit A/D counts are registered
respectively as and Calculate

64
Computation from Linear Piecewise
Approximation
• Since the sensor (thermistor) is
calibrated and its specific transfer
function is known, during the
sensor use, can be used for
computing temperature from any
reasonable A/D count.

65
Computation from Linear Piecewise
Approximation
• Since the sensor (thermistor) is calibrated and its specific transfer
function is known, during the sensor use, can be used for
computing temperature from any reasonable A/D count.

66
Computation from Linear Piecewise
Approximation
 Calculate the temperature using the equation given bellow and find
the difference?

67
Iterative Computation of Stimulus
(Newton Method)
• Since the transfer function can be rewritten as
, numerical iterative methods for finding roots of this
(such as Newton or secant methods [1, 2]3) can also be used for
calculating the unknown stimulus s without the knowledge of the
inverse transfer function.

• The method is based on first guessing an initial reasonable value of


and then applying a Newton algorithm to compute a series
of new values of s converging to the sought stimulus value.
68
Newton Method
• When a difference between two consecutively computed values of
becomes sufficiently small, the algorithm stops, and the last
computed value of is considered a solution of the original
equation and thus the value of the unknown stimulus is found.

• Newton’s method converges remarkably quickly, especially if initial


guess is reasonably close to the actual value of .

69
Newton Method
• To illustrate the Newton method for a 3rd degree polynomial

70
Newton Method

• If, for instance, the measured sensor’s response is and our


initial guess of the stimulus is , then the equation will result
in the following sequence of :

71
Newton Method

• We see that after just the third iteration, the sequence of


converges to 0.716. Hence, at step 4, the Newton algorithm stops,
and the stimulus value is deemed to be .
72
Newton Method
• To check accuracy of this solution, plug this number into the below
equation and obtain , which is within the
resolution error of the actually measured response
.

• It should be noted that the Newton method results in large errors


when the sensor’s sensitivity becomes low.

• In other words, the method will fail where the transfer function
flattens.
73
Span (Full-Scale Full-Scale Input)
• A dynamic range of stimuli that may be converted by a sensor is
called a span or an input full scale (FS).

• It represents the highest possible input value, which can be applied


to the sensor without causing unacceptably large inaccuracy.

• It should be emphasized that decibels do not measure absolute


values, but a ratio of values only.
74
Span (Full-Scale Full-Scale Input)
• By definition, decibels are equal to ten times the log of the ratio of
powers:

• In the similar manner decibels are represented as:

75
Full-Scale Output
• Full-scale output (FSO) is the
algebraic difference
between the electrical
output signals measured
with maximum input
stimulus and the lowest
input stimulus applied.
definition, decibels are
equal to ten times the log of
the ratio of powers:
76
Performance Terms
• Accuracy : Accuracy is the extent to which the value indicated by a measurement system
or element might be wrong.
 For example, a thermometer may have an accuracy of .

• Accuracy is often expressed as a percentage of the full range output or full-scale deflection
(f.s.d).

 For example, a system might have an accuracy of of f.s.d. If the full-scale


deflection is, say, 10 A, then the accuracy is .

• The accuracy is a summation of all the possible errors that are


likely to occur, as well as the accuracy to which the system or
element has been calibrated.

77
Performance Terms
• Error : The term error is used for the difference between the result of the measurement
and the true value of the quantity being measured.

• Thus if the measured value is when the true value is , the error is .

• If the measured value is when the true value is , the error is .

Accuracy is the indicator of how close the value given by a


measurement system can be expected to be to the true value. The
error of a measurement is the difference between the result of the
measurement and the true value of the quantity being measured.

78
Performance Terms
• Error : The term error is used for the difference between the result of the measurement
and the true value of the quantity being measured.

• Thus if the measured value is when the true value is , the error is .

• If the measured value is when the true value is , the error is .

Accuracy is the indicator of how close the value given by a


measurement system can be expected to be to the true value. The
error of a measurement is the difference between the result of the
measurement and the true value of the quantity being measured.

79
Error Types
• Hysteresis error : The term hysteresis error is used for the difference in outputs given
from the same value of quantity being measured according to whether that value has
been reached by a continuously increasing change or a continuously decreasing change.

• Thus, you might obtain a different


value from a thermometer used to
measure the same temperature of a
liquid if it is reached by the liquid
warming up to the measured
temperature or reached by the
liquid cooling down to the
measured temperature.

80
Error Types
• Non-linearity error : The term non-linearity error is used for the error that occurs as a
result of assuming a linear relationship between the input and output over the working
range.

• Linearity error is usually expressed


as a percentage error of full range
or full-scale output.

81
Error Types
• Insertion error : The act of attempting to make the measurement has modified the actual
parameter being measured. This effect is called loading and the consequence as an
insertion error.

82
Performance Terms
• Range: The range of variable of system is the limits between which the input can vary.

83
Performance Terms
• Precision: The term precision is used to describe the degree of freedom of a measurement
system from random errors.

• Thus, a high precision measurement instrument


will give only a small spread of readings if
repeated readings are taken of the same quantity.

84
Performance Terms
• Repeatability: The term repeatability is used for the ability of a measurement system to
give the same value for repeated measurements of the same value of a variable.

• Common cause of lack of repeatability are random


fluctuations in the environment.

• The error arising from repeatability is usually


expressed as a percentage of the full range
output.

• For example, a pressure sensor might be quoted


as having a repeatability of of full range

85
Performance Terms
• Reproducibility: The term reproducibility is used to describe the ability of a system to give
the same output when used with a constant input with the system or elements of the
system being disconnected from its input and then reinstalled.

• The resulting error is usually


expressed as a percentage of the
full range output.

86
Performance Terms

The term precision is used to describe the degree of


freedom of a measurement system from random
errors. The repeatability of a system is its ability to
give the same output for repeated applications of
the same input value, without the system or
element being disconnected from its input or any
change in the environment in which the test is
carried out. The reproducibility of a system is its
ability to give the same output when it and/or
elements of the system are disconnected from the
input and then reinstalled.
87
Performance Terms
• Stability: The stability of a system is its ability to give the same output when used to
measure a constant input over a period of time.

• The term drift is often used to describe the


change in output that occurs over time.

• The drift may be expressed as a percentage of the


full range output.

• The term zero drift is used for the changes that


occur in output when there is zero input.

88
Dynamic Characteristics
• Stability: The dynamic characteristics refer to the behaviour between the time that the
input value changes and the time that the value given by the system or element settles
down to the steady state value.

• The meter pointer oscillates before


settling down to give the steady-
state reading.

89
Dynamic Characteristics
• Response time: This is the time which elapses after the input to a system or element is
abruptly increased from zero to a constant value up to the point at which the system or
element gives an output corresponding to some specified percentage.

• E.g. 95%, of the value of the input.

90
Dynamic Characteristics
• Rise time: This is the time taken for the output to rise to some specified percentage of the
steady-state output.

• Often the rise time refers to the


time taken for the output to rise
from 10% of the steady-state value
to 90 or 95% of the steady-state
value.

91
Dynamic Characteristics
• Settling time: This is the time taken for the output to settle to within some percentage.

• E.g. 2% of the steady state value.

92
Reliability
• The probability of a particular event occurring is defined as being.

• The probability of the coin landing standing on edge can be considered to be zero, since
the number of occurrences of such an event is zero.

• The closer the probability is to 1, the more


frequent an event will occur; the closer it is to
zero the less frequent it will occur.
93
Reliability
• The reliability of a measurement system, or element in such a system, is defined as being
the probability that it will operate to an agreed level of performance, for a specified
period, subject to specified environmental conditions.

• The agreed level of performance might be that the measurement system gives a particular
accuracy.

• A high reliability system will have a low failure rate.

94
Reliability
• A failure rate of 0.4 per year means that in one year, if ten systems are observed, 4 will fail
to meet the required level of performance. If 100 systems are observed, 40 will fail to
meet the required level of performance.

• Failure rate is affected by environmental conditions.

95
Reliability
• With a measurement system consisting of a number of elements, failure occurs when just
one of the elements fails to reach the required performance.

• The reliability of the system might thus be


markedly improved by choosing materials
for the thermocouple which resist attack by
the fluid.

• Thus it might be in a stainless steel sheath to


prevent fluid coming into direct contact with
the thermocouple wires.

96
Requirements
• The main requirement of a measurement system is fitness for purpose.

• This means that if, for example, a length of a product has to be measured to a certain
accuracy that the measurement system is able to be used to carry out such a
measurement to that accuracy.

• If, however, the criterion is for a system with


an accuracy of ±0.5 mm then the system is
not fit for that purpose.

• In order to deliver the required accuracy, the


measurement system must have been
calibrated to give that accuracy.

∓1𝑚𝑚 𝑎𝑐𝑐𝑢𝑟𝑎𝑐𝑦 97
Example
• A special sensor is designed to sense the percent vapor present in a liquid-vapor mixture. If
during a static calibration, the sensor indicates 80 units when in contact with 100% liquid, 0
units with 100% vapor, and 40 units with a 50:50% mixture. Determine the static sensitivity
of the sensor.

98
Example
• A microwave power sensor was calibrated using a faulty calibration source. The calibration
source was enabled as 1mw, but the actual power output of the calibration source was only
0.8 mW. This incorrectly calibrated power sensor was used to measure the output power of
an RF signal generator. The reading shown by the power meter was 10 dBm. What is the
actual output power of the RF signal generator in dBm.

99
Example
• A manufacturer constructed a pressure sensor. Pressure sensor was connected to a known
pressure source and the excitation for the sensors was provided by an ideal power supply.
Five reading at a pressure point was measured. The manufacture averaged the output of
the sensor at each of the measurement pressures. The result of these measurements is
given in the table next slide.

a). Fit the data to several polynomials of different order. What order of polynomial would you
recommend for fitting this data? Explain why you picked this order.
b). Using that order of polynomial what is the equation of the best fit polynomial?
c). What is the standard deviation of the error for your best fit polynomial?
d). The manufacturer would like to use a linear fit for this sensor between 10 KPa and
20Kpa.What is the best fit line for this region?
e). The manufacturer would like to use a linear fit for this sensor between 100KpA and
120Kpa.What would you recommend for the equation of the line in this region?How would
you determine the best fit line in this region given you only have 1 measured point in this
range? 100
Pressure (Kpa) Output Voltage (V)
12.3 0.06642
14.1 0.06861
15.8 0.06874
17.9 0.07303
22.1 0.07638
45.6 0.1517
78.9 0.4756
95.9 0.7588
109.6 1.110
122.4 1.491
139.3 2.166
156.7 2.930
178.9 4.464
Example
• A temperature sensor is calibrated at 5 different temperatures as shown in the table below.
Using this data, derive the best linear calibration curve for this sensor, sketch the calibration
and show the mathematical method for finding the best line. Report the line slope and
intercept. From your result, report the non linearity error from this sensor.

Temperature (C) Output (V)


10 0.21
0 1
2 1.40
25 2.34
80 4.92

102
Example
• A platinum resistance sensor is to be used to measure temperatures between 0 and 200
degree Celsius. During the calibration process, the engineer obtained the following
readings.

Temperature ( ) Resistance (Ω)


0 100.00
100 138.50
200 175.83

The manufacturer gives a calibration equation for this sensor:

a) Try to complete the calibration process by determining the a and b values.


b) Determine the nonlinearity of the sensor at as percentage of Full Scale.

103
Example

104

You might also like