## 1.

## INTRODUCTION

Measurement science is an important part of modern engineering, being essential in almost all spheres of electronic industry. With respect to metrology, the quality of measurement results has been expressed in terms of uncertainty. This uncertainty quantifies the lack of knowledge or doubt about the validity of the result of a measurement, that is usually composed by realization of random variables. In order to provide an international consensus for evaluating and expressing uncertainties, the Guide to the Expression of Uncertainty in Measurement (GUM) 1 was developed. One of the initial requirements for this recommendation is that the approach has to be universal, so the GUM treats all uncertainty contributions identically, more or less as if the distributions were Gaussian and the relations were linear. According to the GUM, uncertainty is the parameter associated with the result of a measurement, that characterizes the dispersion of the values that could reasonably be attributed to the measurand. However, the GUM has some limitations. For instance, it does not contemplate the case of measurements involving complex-valued quantities, which was included in supplement 2 (2). A method for propagating uncertainty in complex parameters has also been addressed in Refs. 3 and 4, where the multivariate form of the error propagation law is explored. This approach deals with the real and imaginary components as distinct measurands and the correlation between them, arising from shared influence input quantities.

In some applications, when the quantity of interest as well as the parameters on which it depends are complex to define the measurement model in term of its real and imaginary functions can be a tough task. Fortunately, tools for uncertainty calculation are available (5). Also “An Uncertainty Toolbox” for Matlab has been developed by our research group. This software toolbox includes the implementation of the GUM tree method with automatic differentiation. Its basic concept and additional aspects such as numeric representation of uncertainty have been discussed in Ref. 6.

Teaching philosophies addressing uncertainty in scalar-valued quantities and robust design principles for reliability and safety measurement system, have been proposed in Ref. 7 and 8 respectively. In electrical measurements, many parameters of interest are complex-valued. That’s why we introduce an example of the Maxwell-Wien Bridge to our students. This simple example is suitable for discussing pros and cons of using such uncertainty toolbox with complex quantities and also for enhancing the awareness with respect to uncertainty and how it can impact the overall outcome in measurement chains.

## 2.

## TEACHING CONCEPT

The course in question, Measurement Science, Sensors and Actuators, target students in the third year of Information Technology. Accordingly, it is expected that they are familiar with concepts of electrical measurements, complex variables calculus, probability theory and stochastic. The course outline is illustrated in Table 1. We decide to start the course introducing the concept of uncertainty, interpreting measurements as realization of random variables provides some information about the parameter in question. We also introduce the original GUM including terms such as combined standard uncertainty and its determination by means of Taylor series expansion. The extension of this term for complex measurements is studied through the “Uncertainty Toolbox” for Matlab developed and maintained in our research group. It implements the GUM tree method, considering an extension of the error propagation law for complex parameters.

## Table 1:

Outline for introducing the concept of uncertainty with complex quantities.

Section | Content |
---|---|

1.Basic Concepts | Introduction to Uncertainty, GUM and its application to measurement equation. Presentation of uncertainty toolbox in Matlab |

2.Defining complex uncertain quantities | Limitation of the original GUM regarding complex measurements. Uncertainty for complex measurements, supplement 2 of GUM. Defining complex quantities with the uncertainty toolbox. |

3.Example Maxwell-Wien Bridge | Pitfalls in the classic balance equation. Finding a suitable measurement model. Implementation using the uncertainty toolbox with Matlab |

4.Discussion | Advantages of using the Toolbox. Generalization of the concept of uncertainty for complex measurements. |

## 3.

## COMPLEX-VALUED QUANTITIES USING THE UNCERTAINTY TOOLBOX

Figure 1 exemplifies how to define a complex quantity as uncertain object. First, the real and imaginary components are declared independently, e.i the real part *x* has value = 3, standard uncertainty = 0.2 and name *’reaL_Z*’. Then, the function *complex* is used to create the uncertain complex quantity *Z*.

Complex numbers can be expressed in Cartesian and/or Polar representation. It is noteworthy to highlight how the standard uncertainty can be interpreted in both cases. Figure 2 shows the uncertain complex quantity Z in the complex plane. In the Cartesian case, we can easily represent the values and uncertainties of the real and imaginary parts *x* and *y*. We can also interpret them as realizations of random variables, with mean and standard deviation directly associated with the properties value and standard uncertainty respectively. In the Polar case, it is not so intuitive to make such analogy, but the uncertainty can be geometrically represented as shows Figure 2.

In the next section we introduce an example of the Maxwell-Wien bridge, as an extension of the Wheatstone Bridge circuit addressed in Ref.7 towards the complex domain.

## 4.

## THE MAXWELL-WIEN BRIDGE WITH UNCERTAINTIES

Bridge circuits are well-known topologies usually introduced in courses of measurement science, due to its wide application for the determination of unknown impedances and as realization of compensation method. AC bridges can be used to measure the value of inductance, capacitance and/or frequency. The Maxwell-Wien bridge is found to be more suitable for measuring unknown inductance (usually with low quality factor) and its circuit is shown in Figure 3. We introduce the Maxwell-Wien Bridge to emphasize how this toolbox for uncertainty calculation may change the way to present this subject to students and also as a suitable example for showing how to use the toolbox involving complex quantities.

If we consider the general AC bridge balance equation, the value of the unknown impedance *Z _{x}* can be determinated as

where *Z*_{2} = *R*_{2}, *Z*_{3} = *R*_{3}, *Z*_{x} and *Z*_{1} are complex quantities given by *Z*_{x} = *R*_{x} + *jwL*_{x} and respectively, with *w* representing the angular frequency of the power supply with effective voltage *U*_{rms}. To determinate the corresponding combined standard uncertainty of *Z*_{x} we could think in directly applying the GUM method for uncorrelated inputs to the measurement model in (1), leading to

and let the students do an interpretation of the results. The aim is to highlight two important issues. The first one is related to the fact of propagating uncertainty of complex-valued quantities, where the bivariate form of the Gaussian error propagation law 3, should be considered. Then *Z*_{x} is expressed in terms of its real and imaginary components as

and its covariance matrix is given by

obtained by applying the error propagation law in the general matrix form, addressed in 9. The uncertainties of the real and imaginary parts of *Z*_{x}, *u*^{2}(*R*_{x}) and *u*^{2}(*wL*_{x}) respectively, could be found by applying the GUM method for scalar quantities. It is valid to clarify that the standard uncertainty of *Z*_{x} it is not a complex quantity and can be expressed as

It proceeds from the fact that in multivariate statistics the total variance is described as the trace of the covariance matrix, i.e. it ignores correlations.

The second issue to point out is that apparently some important influences are missing. From the measurement model in (1), it could be induced that the choice of the AC voltage source and the accuracy of the instrument that measures *U*_{g} will have no impact on the resulting uncertainty. This is obviously not correct, which leads to do a more detailed analysis in order to find a suitable measurement model that considers the influences of *U*_{rms} and *U*_{g}. In general, to fully determine the standard uncertainty it may not be sufficient to only consider a measurement equation.

Consequently, the students are instructed to derive a more complete measurement model such as

Here we emphasize that despite the value of *U*_{g} is measured to be zero, it may still be significantly different from zero and must not be omitted for uncertainty considerations. In order to find an expression for the combined standard uncertainty of *Z*_{x}, we first should express (6) in terms of the known parameters, i.e.

Then, the expressions for *R*_{x} = *real*(*Z*_{x}) and *ωL*_{x} = *imag*(*Z*_{x}) are derived with respect to *U*_{rms}, *U*_{g}, *C*_{1}, *R*_{1}, *R*_{2}, *R*_{3}, leading to the corresponding sensitivity coefficients , , and so on. Therefore, the resulting standard uncertainty of *R*_{x} and *ωL*_{x} are given by

where the uncertainty *u*(*X*) of the respective input quantities were previously calculated. Considering the result in (5), we can get the uncertainty associated to the complex quantity *Z*_{x}. However, the procedure for splitting equation (7) in its real and imaginary components can be difficult to perform manually and it is very likely that calculation errors are made, as well as in the derivation of the sensitivity coefficients.

Hence the next step is to introduce the uncertainty toolbox for Matlab to obtain the value and uncertainty of the unknown parameter *Z*_{x}. Figure 4 shows how to implement the procedure explained above step by step. Note that the equivalent impedance *Z*_{1} is declared in terms of its real an imaginary parts, as was explained previously. Nevertheless, to obtain the combined standard uncertainty of the unknown impedance it does not require any additional effort, but providing the standard uncertainty for the input quantities. The last command line returns the numeric value of *u*_{c}(*Z*_{x}).

In Figure 5 is presented the contributions of the input variables to the standard uncertainties of *R*_{x} and *L*_{x}, showing that the main contributions come from the uncertainties of the measured voltage (*U*_{g}) and the capacitor (*C*_{1}) respectively. The reported values represent the square root of the contribution of each input quantity to the squared standard uncertainty of the output.

Figure 6 depicts how to obtain the covariance and correlation matrix associated with *R*_{x} and *L*_{x}. The correlation coefficient between the real and imaginary components of the impedance *Z*_{x} is not 0 due to the shared input parameters. With this example can be highlighted that the benefit of using the toolbox is not merely the automatic calculation of the unknown values and its associated uncertainties, it also provides means to analysis how the different sources of uncertainty contribute to the final result.

For comparative purposes, we also use the toolbox applying the model in (1). (See Figure 7). We obtain the same result for the unknown impedance, with a change in the standard uncertainty. This is because the main contribution to the uncertainty becomes from *U*_{g}, despite the fact that the contribution of *U*_{rms} can be neglected, as was shown in Figure 5.

With the help of the toolbox we can easily study the dependencies between variables and how a change in one of the input parameters can influence the contribution of other inputs, as well as the combined standard uncertainty of the result.

## 5.

## DISCUSSION OF ADVANTAGES AND DISADVANTAGES

Measurement results can be shown as realizations of random variables and the GUM tries to describe the probability density function using the standard uncertainty. Therefore, our aim is to put the focus on the fact that uncertainty in the measurement of complex-valued quantities can be analyzed in terms of its real and imaginary components, as a realization of a 2-dimensional random vector. We consider a software toolbox for the automatic calculation of the combined standard uncertainty involving complex measurements. One of the main advantages of using the toolbox is that the students’ attention can be guided towards the measurement model construction and the study of the sources of uncertainty rather than in the calculations itself. Another important point is that students can easily improve their abilities using the toolbox, since Matlab environment is acquainted for them.

An observed disadvantage is that sometimes students can experience a lack in the notion whether a result is in the correct order of magnitude, since the toolbox doesn’t take into account the SI, as with electronic calculators in general. On the other hand, the toolbox uses the GUM approach 2, based on a first-order Taylor series approximation (only the complex derivatives of first order are needed) i.e. all uncertainty contributions are treated as if their relations were linear. Therefore for measurement models with significant non-linearity, the results given by the toolbox may be inaccurate. Such limitations are no intuitive for students and must be emphasized.

## 6.

## CONCLUSION

A teaching concept for considering uncertainty in complex-valued quantities have been proposed. The approach is based on the utilization of an “Uncertainty Toolbox” in Matlab which implements the GUM method, involving either scalar or complex-valued quantities and supporting different measurement models. Using this approach in measurement science education may help to increase the awareness with respect to uncertainty, leading to its consideration in early design phases which can contribute to the robustness and reliability of systems.