EE3901/EE5901 Sensor Technologies
Week 1 Notes
Introduction to Sensors

Profile picture
College of Science and Engineering, James Cook University
Last updated: 14 January 2022

The goal of this week is to learn the basic concepts of how to characterise sensors. This week is heavy of definitions. As a study tool, you are strongly encouraged to write your own glossary of terms that gives concise definitions of each of the concepts introduced here.

Introduction to sensors

A sensor is a device that measures some property of its environment. Examples of properties that we can measure include:

  • Force
  • Distance
  • Speed
  • Sound pressure level (loudness of audio)
  • Chemical composition
  • … and many more.

Discussion Question: What are other types of sensors can you think of?

All sensors are energy converters. Every measurement involves a transfer of energy. For example, a photodetector absorbs light energy and converts it into electric current. In this example, there is a continual transfer of energy from the light source to the sensor. However, in other cases, there may be an equilibrium condition where the net energy flow is zero. For example, consider a temperature sensor that is initially at room temperature and is then placed into a hot furnace. The temperature sensor must initially absorb heat from the furnace, which is a transfer of energy. Eventually the sensor comes to the same temperature as its new surroundings, at which point an equilibrium has been reached and there is no net flow of energy.

In this subject, we will focus on sensors that respond with an electrical signal as opposed to any other kind of response (e.g. optical, chemical, thermal, etc). For our purposes, an electrical signal is a voltage, current, charge, resistance, capacitance, or inductance. We will learn how to design interface circuits to make these electrical signals accessible to downstream electronics such as an analog-to-digital converter. The goal of these interface circuits is to amplify, convert, transmit, and ultimately make this electrical signal available in a more convenient and robust manner for use by another circuit.

Measurements

When discussing measurement, it is important to distinguish between two related quantities:

  • The measurand is the physical property that we seek to observe, for example, temperature, pressure, flow rate, etc. The measurand is the “true value” that exists in the world. When we perform a measurement, we are trying to learn some information about this true value.

  • The measurement is the result of using a sensor to observe the measurand. The measurement is always subject to some uncertainty. Hence we should always think of the measurement as merely being an estimate of the measurand.

If the measurand is denoted xx then the measurement is written x^\hat{x}, where the ‘hat’ indicates that it is an estimate of the true value.

Self check quiz 1.1

We can mathematically describe the relationship between measurement and measurand as follows:

x^=x+ϵ,\hat{x} = x + \epsilon,

where x^\hat{x} is the measurement, xx is the measurand, and ϵ\epsilon is the error in the measurement.

Based on your general knowledge, which of the following do you think are plausible mechanisms that could contribute to the error ϵ\epsilon? Select all that apply.

Answer: (a), (b), (c), (d), (e), (f), (g), (h)

The transfer function

The transfer function the mathematical relationship between the sensor stimulus xx and the sensor output yy, written as y=f(x)y=f(x). For example, the sensor stimulus xx might be the temperature and the response yy might be a voltage.

The transfer function is used to convert the sensor response into the actual measurement, e.g. x^=f1(y)\hat{x}=f^{-1}(y). Recall that the ‘hat’ on the x^\hat{x} indicates that it is an estimate of the true measurand xx.

Example of a transfer function

A thermocouple is a type of temperature sensor which produces a voltage

V=a0+a1T+a2T2,V=a_{0}+a_{1}T+a_{2}T^{2},

where TT is the temperature, and the coefficients a0a_{0}, a1a_{1} and a2a_{2} are constants that depend upon the types of metals used in the thermocouple.

You could solve this equation (using the quadratic formula) to obtain the measured temperature T^\hat{T}.

Digital vs analog sensors

An analog sensor outputs a continuous electrical quantity such as voltage, current, resistance or capacitance. An digital sensor always chooses one output state at a time from a fixed set of possibilities. Very often this will be a signed or unsigned integer of a given number of bits. Recall that an n-bit integer has 2n2^{n} possible values.

Sensor characteristics

Sensitivity

Figure 1: An example transfer function showing a region of higher sensitivity and a region of lower sensitivity. Zoom:

Sensitivity is how large the response is for a given change in the measurand. It is the slope of the transfer function, as shown in Figure 1. Precisely:

sensitivity(x1)=f(x1)(1)\text{sensitivity}(x_{1})=f'(x_{1}) \tag{1}

where f=dfdxf' = \frac{df}{dx} is the derivative of the transfer function. Notice that the sensitivity is evaluated at a specific value x1x_1. If the transfer function is non-linear then the sensitivity will vary depending upon the value of the measurand.

The units of sensitivity will be (electrical quantity) per (physical quantity). For example:

  • A displacement sensor may have a sensitivity of 10 V/mm.
  • A pressure sensor may have a sensitivity of 80 mV/kPa.

For digital sensors, the sensitivity relates to “counts” per physical quantity or “least significant bits” (LSB) per physical quantity e.g. a light sensor with 50 counts/lux. You will also see this written as 50 digits/lux or 50 LSB/lux. This means the digital sensor’s output integer rises by 50 for every increase of 1 lux.

Resolution

The resolution is the smallest change in measurand stimulus that can be accurately detected.

For analog sensors, this is often limited by noise. A small change may be undetectable if it is indistinguishable from noise.

For digital sensors, assuming no problems of noise, the resolution will be defined by the sensitivity. Specifically,

resolution (digital sensor)=1sensitivity.(2)\text{resolution (digital sensor)} = \frac{1}{\text{sensitivity}}. \tag{2}

The sensitivity is how many LSBs there are per unit of measurand; the resolution is much measurand there is per LSB.

Example 1.1

For example, consider a digital accelerometer. Accelerometer specifications are often referenced to the typical strength of Earth’s gravity, g=9.81 m/s2g = 9.81\ \text{m}/\text{s}^2. For example, in the context of an accelerometer, ‘mg’ means ‘milli-g’ which is 103g10^{-3}g. If an accelerometer had a resolution of 16 mg/digit or equivalently 16 mg/LSB, this means that it advances to the next integer when the acceleration changes by 16 mg. For this device the sensitivity is

sensitivity=1 LSB0.016 g=62.5 LSB/g.\text{sensitivity} = \frac{1\ \text{LSB}}{0.016\ \text{g}} = 62.5\ \text{LSB}/\text{g}.

Self check quiz 1.2

The datasheet of a digital accelerometer states that its resolution is 32 mg/LSB. What is it sensitivity?

LSB/g

Hint: Calculate the answer in the specified units, and enter your answer as a decimal number without rounding.

Answer: 31.25

Span or range

Figure 2: The meaning of full-span (FS) and full-span output (FSO), as shown on a sketch of a transfer function. Zoom:

The full span is the range of measurands that can be accepted by the sensor. The full span is also called the range of a sensor. This property is illustrated in Figure 2.

Often the maximum of the range is caused by physical limits of the underlying sensor, e.g. a pressure sensor will have a maximum rated pressure that it can withstand. The minimum value is often limited by the sensor’s resolution, but could also be affected by physical limits, for example, a temperature sensor may not operate at extremely low temperatures.

Error, bias, precision and accuracy

A measurement error is when the measured value differs from the measurand. In practice there is always some degree of measurement error because no sensor system can ever be perfect.

There are several ways to define error. In simplest terms, the error is the raw difference between the measured and true value:

error=(measured value)(true value).(3)\text{error} = (\text{measured value}) - (\text{true value}). \tag{3}

The error has the same units as the measurement. A positive error means that the measurement is too large, and a negative error means that the measurement is too small.

The absolute error is the absolute value of the error:

absolute error=error.(4)\text{absolute error} = \left|\text{error}\right|. \tag{4}

The relative error is scaled in proportion to the magnitude of the true value:

relative error=errortrue value.(5)\text{relative error} = \frac{\text{error}}{|\text{true value}|}. \tag{5}

The relative error is dimensionless, and is often represented as a percentage. In this case it can be called a percentage error. Some authors will take the absolute value of the relative error so that it is always a positive number.

Self check quiz 1.3

The triple point of water is known to be 273.13 K. When you measure it with a new thermometer, you measure 274.24 K. What is the relative error in your measurement, rounded to the nearest 0.1%?

% (round to one decimal point)
Answer: 0.4

The error is a property of a single specific measurement. However, it is often useful to “zoom out” and discuss the statistical properties of measurement errors that occur over multiple uses of the sensor. Let us define measurement as a probabilistic process. For instance, let

p=p(x^x)p = p(\hat{x} | x)

represent the probability of measuring x^\hat{x} given a particular true measurand xx. In practical systems, we will often assume that pp follows a Gaussian distribution, which allows for convenient mathematical analysis of measurement uncertainty (as we will see in subsequent weeks). A sketch of this measurement probability is given in Figure 3.

Figure 3: The probability distribution of obtaining a certain measurement given a particular true measurand. For the purposes of explaining the different definitions of accuracy, a single measurement is also indicated with a green circle. Labelled here are the key definitions related to measurement error and uncertainty. Zoom:

We define the key properties as follows.

Bias, also called trueness, is a constant offset in the sensor response. In the probabilistic interpretation of measurement,

bias=E[x^]x,(6)\text{bias} = E[\hat{x}] - x, \tag{6}

where E[x^]E[\hat{x}] is the expected value of x^\hat{x}. Notice that bias can be corrected for because it is a simple constant offset. The bias can be estimated (e.g. through a calibration procedure where the same measurand is measured repeatedly), and the correction can be included in the transfer function.

Suppose you have a sensor with a simple linear transfer function of the form y=Axy = Ax where AA is the sensitivity. For example, a differential pressure sensor may have a sensitivity of 1 mV/kPa, giving a transfer function in SI units of y=0.001xy = 0.001x where yy is voltage and xx is pressure. Any detected bias could be incorporated by modifying the transfer function to read y=A(x+b)y = A(x+b) where bb is the bias.

Precision is how much information is gained from a single measurement. If there is a lot of measurement noise then a single measurement would have a wide range of uncertainty, and would be less precise. A formal definition is

precision=standard deviation of measurements=E[(x^E[x^])2](7)\begin{align*} \text{precision} & =\text{standard deviation of measurements}\\ & =\sqrt{E\left[\left(\hat{x}-E[\hat{x}]\right)^{2}\right]}\tag{7} \end{align*}

The key point is that a precise sensor always gives the same result, regardless of whether that result is true.

However, the word ‘precision’ is also used to refer to the resolution of a measurement, especially when specifying the number of significant figures. It is important to be aware of the difference between limited resolution and random measurement noise.

The term accuracy is often used when discussing measurement. Unfortunately, there are several different definitions of accuracy, and its meaning is not always clear. Probably the most common definition of accuracy is that it means the same thing as ‘bias’. In this definition, an accurate sensor is one where the expected value of the measurement is close to the measurand. Notably, the sensor can be accurate (have low bias) even if it is not precise (i.e. not repeatable).

Another common meaning of ‘accuracy’ is as a qualitative label of how ‘good’ a sensor is. In this case, both bias and precision are important.

Finally, ‘accuracy’ is also sometimes used discuss a specific measurement (as opposed the entire sensor). In this case accuracy can be synonymous with ‘error’.

Noise

Noise is an unwanted signal that interferes with a measurement. The most common mathematical model of noise that we will consider is additive white Gaussian noise (AWGN).

Define x^i\hat{x}_i to be the ithi^\text{th} measurement obtained from a sensor system. In the presence of AWGN, this measurement is given by

x^i=xi+zi,(8)\hat{x}_i = x_i + z_i, \tag{8}

where xix_i is a hypothetical noiseless measurement, and ziz_i is a random variable drawn from a Gaussian distribution. We can consider xix_i as the “true value” that would have been measured at that instant if there were no noise. In practical scenarios, xix_i and ziz_i cannot be determined independently; all we can do is calculate statistical properties of the measurement and its noise.

Importantly, the distribution of the noise has zero mean. If you find this objectional, consider the following. Suppose that there were a physical process that resulted in the additive noise term having a non-zero mean. Such a process could be treated as a bias and simply subtracted away. Once the bias is subtracted off, the remaining component necessarily has zero mean. Hence we can always apply a calibration process such that the only remaining noise is that with zero mean. Overall, the purpose of the noise model is to account for physical processes that cannot be removed by calibration.

The terminology “additive white Gaussian noise” indicates several essential properties of this type of noise:

  1. It is “additive”, meaning that the noise is mathematically added to the underlying signal, and hence linear relationships are preserved.
  2. It is “white”, meaning that it has no frequency dependence. In other words, it has a flat power spectrum across the entire measurement bandwidth. This implies that the noise cannot be easily filtered out with a suitable high-pass or low-pass filter.
  3. It is “Gaussian”, meaning that in the time domain, its values are sampled from a Gaussian (aka normal) distribution.

Example 1.2

Use the definition of root-mean-square (RMS) to prove that the RMS intensity of Gaussian noise is equal to its standard deviation.

Hint: RMS intensity, in the limit of large numbers of samples, is defined to be

zRMS=limN1Ni=1Nzi2,(9)z_{RMS}=\sqrt{\lim_{N\to\infty}\frac{1}{N}\sum_{i=1}^{N}z_{i}^{2}}, \tag{9}

and the standard deviation is defined to be

σ=limN1Ni=1N(ziE[z])2(10)\sigma = \sqrt{\lim_{N\to\infty}\frac{1}{N}\sum_{i=1}^{N}\left(z_{i}-E[z]\right)^{2}} \tag{10}
Solution

Let ziz_i be the ithi^{th} sample of noise. Use Eq. (9)(9) to calculate the RMS intensity of the noise.

zRMS=limN1Ni=1Nzi2z_{RMS}=\sqrt{\lim_{N\to\infty}\frac{1}{N}\sum_{i=1}^{N}z_{i}^{2}}

Since the noise has zero mean, we have E[z]=0E[z] = 0 and hence it is a valid transformation to write

zRMS=limN1Ni=1N(ziE[z])2.z_{RMS}=\sqrt{\lim_{N\to\infty}\frac{1}{N}\sum_{i=1}^{N}\left(z_{i}-E[z]\right)^{2}}.

We recognise this as the standard deviation, and therefore

zRMS=σ.z_{RMS}=\sigma.

Signal to noise ratio (SNR) and dynamic range (DR)

The signal to noise ratio (SNR) is a measurement of the power in the signal to the power in the noise. Generally if there is a large SNR then obtaining high precision measurements is straightforward, whereas if there is a low SNR then the measurement becomes more challenging and more subject to uncertainty.

The SNR is often expressed in decibels:

SNR=10log10(PsignalPnoise)=20log10(MsignalMnoise),(11)\text{SNR}=10\log_{10}\left(\frac{P_{signal}}{P_{noise}}\right)=20\log_{10}\left(\frac{M_{signal}}{M_{noise}}\right), \tag{11}

where PP refers to average power and MM refers to RMS magnitude (e.g. voltage or current). The factor of 20 arises because P=VI=V2/R=I2RP=VI=V^{2}/R=I^{2}R so PM2P\propto M^{2} regardless of whether MM is voltage or current.

It is common to plot the transfer function on log-log axes when analysing signal to noise ratios. This is because of the algebraic identity log(Psignal/Pnoise)=log(Psignal)log(Pnoise)\log(P_{signal}/P_{noise}) = \log(P_{signal}) - \log(P_{noise}), which means that on logarithmic axes the SNR is proportional to the distance between a measurement point and the noise floor, as illustrated below in Figure 4.

Figure 4: When the transfer function is plotted on log-log axes, the SNR and dynamic range have a simple geometric interpretation. Both are proportional to the distances indicated on this plot. Zoom:

The dynamic range (DR) is the ratio between the largest and smallest values of the measurement:

DR=10log10(PmaxPmin)=20log10(MmaxMmin),(12)\text{DR}=10\log_{10}\left(\frac{P_{max}}{P_{min}}\right)=20\log_{10}\left(\frac{M_{max}}{M_{min}}\right), \tag{12}

again where P is power and M is RMS magnitude.

In cases where the minimum is 0 (e.g. absolute scales like light intensity, sound pressure, etc), the lower value is the noise floor. In this case the DR is simply the SNR for the largest possible measurand:

DR=10log10(PmaxPnoise)=20log10(MmaxMnoise).(13)\text{DR}=10\log_{10}\left(\frac{P_{max}}{P_{noise}}\right)=20\log_{10}\left(\frac{M_{max}}{M_{noise}}\right). \tag{13}

For reference, human hearing has a DR of roughly 140 dB, and human eyesight has a DR of roughly 90 dB.

Example 1.3

For a given operating condition, a sensor outputs a constant voltage of 100 mV. However the measurement is corrupted by a additive Gaussian noise with a standard deviation of 18 μV. Find the SNR.

Solution

Recall from Example 1.1 that the standard deviation of AWGN is equal to its RMS magnitude. Hence the magnitude of the noise floor is 18 μV.

SNR=20log10(100×10318×106)=74.9 dB.\text{SNR}=20\log_{10}\left(\frac{100\times10^{-3}}{18\times10^{-6}}\right)=74.9\ \text{dB}.

Hysteresis

Figure 5: The impact of hysteresis is that the transfer function is different when sweeping up vs sweeping down the range of measurands. The effect here is exaggerated for educational purposes. A common test for hysteresis is to vary the measurand at a fixed sweep rate in both positive and negative directions and plot the two measured transfer functions on the same axes for comparison. Zoom:

Hysteresis is a history dependence, meaning that different measurement results can be obtained despite the measurand being the same. Specifically the measurement depends upon the recent history of the sensor (as shown in Figure 5).

There are several reasons for hysteresis, for instance:

  • Slow response time, so that the output is a weighted average over its recent history.
  • Temperature changes in a sensing element.
  • Backlash in gears, for instance in a rotation sensor that uses gears to couple to the axle being monitored. When the direction of rotation changes, there will be a small amount of movement in the new direction before the gear teeth ‘bite.’ This is called backlash, and will cause the rotation sensor to display hysteresis because the position of the sensor will be slightly offset depending upon the direction of rotation.
  • Other chemical or physical properties changing in the sensing element in response to the environment being measured.

Hysteresis is sometimes deliberately introduced to avoid rapid switching near a threshold. A circuit called a Schmidt trigger is sometimes used for this purpose.

Response time

Sensors do not respond immediately to an input stimulus.

The response time or rise time is the time required to reach a given threshold, typically 90% of the final value. If the sensor’s underlying physics results in an exponential response (y1et/τy \propto 1 - e^{-t/\tau}) then the rise time is often defined to be the time constant τ\tau, which is the time required for the response to rise by 1e163%1-e^{-1} \approx 63\%. These types of exponential responses are common because they arise from first order differential equations, including for example RC and RL type circuits.

Bandwidth

Figure 6: The bandwidth of a sensor is the frequency at which the output power has dropped by half from its DC (low frequency) value. Zoom:

If the measurand is time-varying, then it is important to consider whether the sensor can respond quickly enough to keep up with the system being measured. The ability of a sensor to track a changing measurand is determined by its bandwidth.

To formally define bandwidth, we consider the frequency response of the sensor system. Much like you can analyse the frequency response of a circuit such as a low-pass filter, so too can you define the frequency response of a sensor. The frequency response of a sensor gives the measurement response when the measurand input is a sinusoid of a given frequency. The frequency response of a typical sensor system is sketched in Figure 6.

Sensors typically have low-pass characteristics, i.e. there is some maximum frequency at which the output voltage or output current starts to drop. This defines the bandwidth of the sensor. Precisely, we define the bandwidth to be point at which the output power has dropped by half. Recall that half power corresponds to a drop of 3 dB.

Conclusion

In this chapter, we have introduced the key specifications and performance characteristics of sensor systems. It is important that you familiarise yourself with this terminology because it will be used in future weeks, especially when we compare and contranst different sensor types in the latter part of the course. We also pointed out the essential fact that every measurement is an estimation of the true state of the world. Next week we will formalise our discussion of measurement uncertainty, and learn how to mathematically analyse the impact of measurement error on the calculations that we perform.

References

Clarence W. de Silva, Sensor Systems: Fundamental and Applications, CRC Press, 2017, Chapter 5.

Jacob Fraden, Handbook of Modern Sensors: Physics, Designs, and Applications, 5th edition, Springer, 2016, Chapter 3.