ELEKTRYKA 216 Zeszyt 3-4 (239-24) Rok LXII Adam CICHY, Sebastian BARWINEK Silesian University of Technology, Gliwice PHASE SHIFTER IN QUASI-BALANCED CIRCUITS WITH DETUNING Summary: A virtual measurement system, designed to measure loss factor tan δ, has been analysed in this paper. The system uses a structure of non-bridge, quasi-balanced circuit for capacitance measuring. After detuning the system from the quasi-balanced state, it is possible to measure tan δ. Some implementations of the phase shifters in the LabVIEW environment are presented. The influence of the signal parameters on the phase shift error is presented. The short-term Fourier transform algorithm has been used as the phase angle measurement algorithm. Results of simulation studies and results of the real measuring system using data acquisition board USB-6251 from National Instruments are compared. Keywords: virtual instruments, phase shifter, measurement of phase shift, LabVIEW PRZESUWNIK FAZOWY W UKŁADACH QUASI-ZRÓWNOWAŻONYCH Z ODSTROJENIEM Streszczenie: W artykule analizowano właściwości przesuwnika fazowego stanowiącego istotny element wirtualnego układu pomiarowego, przeznaczonego do pomiaru współczynnika strat elektrycznych tg δ. Układ wykorzystuje rozwiązanie niemostkowego układu quasi-zrównoważonego do pomiaru pojemności. Po odstrojeniu układu od stanu quasi-równowagi jest możliwy pomiar współczynnika tg δ. Przedstawiono różne możliwości realizacji przesuwnika fazowego π/2 w środowisku LabVIEW. Zaprezentowano wpływ parametrów sygnału na błąd przesunięcia fazowego. Jako algorytm pomiaru kąta fazowego wykorzystano algorytm krótkookresowej transformaty Fouriera. Porównano wyniki badań symulacyjnych oraz wyniki badań rzeczywistego układu pomiarowego wykorzystującego kartę pomiarową NI USB-6251 firmy National Instruments. Słowa kluczowe: przyrządy wirtualne, przesuwnik fazowy, pomiar kąta przesunięcia fazowego, LabVIEW
94 A. Cichy, S. Barwinek 1. INTRODUCTION Quasi-balanced methods with phase detection are used for measurements of immittance components as well as dielectric loss factor and coil quality factor. In these circuits we recognise a certain state, where phase shift of selected circuit signals is very precisely defined. This is the so-called quasi-balanced state [1]. In the measurement process we try to reduce the circuit to this particular state by using a single adjustable element. Fig. 1. Block diagram of active quasi-balanced circuit for measuring the reactive component of the impedance Rys. 1. Schemat blokowy aktywnego quasi-zrównoważonego układu do pomiaru składowej biernej impedancji Example of such quasi-balanced system is shown in Fig.1 [2], [3]. In the discussed system quasi-balanced state relates to orthogonality of signals marked as w 1 and w 2. This is an active circuit used for measuring impedance s reactive component. Signals subjected to detection may be expressed as: where: w w A U X jb I U X voltage across measured impedance Z X, I X current flowing through impedance Z X, A voltage amplifier gain, B conversion gain of current/voltage converter. 1 2 X jbi X, (1.1) In the discussed system, we may use amplifier with controlled gain A or current/voltage converter with controlled conversion gain B as the adjustable element. It is necessary to use a phase shifter; its precision has a direct impact on measurement results. Phase shift between signals w 1 and w 2 is measured with phase-sensitive detector; in quasi-balanced state shift is equal to π/2. In this state it is possible to determine reactive component of investigated impedance using the following formula:
Phase shifter in... 95 Im A B Z X, (1.2) where: A voltage amplifier gain in quasi-balanced state, B conversion gain of current/voltage converter in quasi-balanced state. In order to determine dielectric loss factor, we first establish quasi-balanced state and then detune the entire system by changing the setting of e.g. gain A. At this point, dielectric loss factor may be calculated using equation [4]: tan X tan WA 1 A (1.3) A 2. MEASUREMENT SYSTEM Measurement system shown in Fig.1 has been designed as a virtual instrument (Fig.2). Instrument consists of hardware and software parts. Hardware is made up of data acquisition board NI-USB6251 made by National Instruments and PC. Fig. 2. Block diagram of the measuring system Rys. 2. Schemat blokowy układu pomiarowego Software has been based upon graphical development environment LabVIEW. Program code may be divided into following parts (in accordance with Fig.3): data acquisition block, data processing block, algorithm for measuring phase shift angle, visualisation and result archive block. Short-term Fourier transform algorithm found in MATLAB script [5] has been used a detector of quasi-balanced state. This algorithm is characterised by high precision and noise immunity [6].
96 A. Cichy, S. Barwinek Two different designs of phase shifter have been tested: the first one performs derivation of measured signal (function Time Domain Math), the second one is a delay-type design (delay is achieved by shifting a set number of samples /changing index/ in the table). In case of phase shifter operating on the principle of changing data indices in table, it is necessary to ensure that: f s 4 f where: f s signal sampling frequency, f c tested signal frequency, N any natural number greater than zero. c N, (2.1) Fig. 3. Fragment of program code Rys. 3. Fragment kodu programu This instrument may be configured for operation in two different modes: - simulation (tested signal is simulated with the help of Sine Waveform function), - measurement (signal is input from external generator). It is also possible to change signal parameters and algorithm for measuring phase shift angle. Measurement results are presented in instrument panel as text data and curves (Fig.4).
Phase shifter in... 97 Fig. 4. VI front panel Rys. 4. Panel przyrządu wirtualnego 3. MEASUREMENT RESULTS The objective of our investigations was to check quality of different designs of phase shifters used in virtual quasi-balanced systems, in particular of those dedicated to detuned systems employed in measurements of dielectric loss factor tan. Sine signals with amplitude equal to 1 V and frequencies equalling 5 Hz, 1 Hz, 2 Hz, 5 Hz, 1 Hz have been used in the tests. 1 samples of measurement signals have been acquired; algorithm employed for measurement of phase angle has utilized a rectangular window with full width at half maximum (FWHM) equal to 2 samples. Phase angle measurement result is equal to value averaged from 96 samples, while the final result is obtained from 12 trial runs. Phase shifting of sine signals may be carried out by determining derivative of the signal with respect to time. This is a relatively simple method of algorithming /2 phase shifter, but is usually less immune to noise. Different methods of numerical differentiation may be used, e.g. finite differencing or more advanced Richardson s extrapolation. LabView package is equipped with function for determining signal derivative, but manufacturer does not provide any information on algorithm used. This function has been subjected to simulation tests. Simulation results are shown in Fig.5. Next, data acquisition board has been used to investigate phase shifter performance. Real measurement signals from Rigol DG111 generator have been input into the shifter. Measurement results are shown in Fig.6.
98 A. Cichy, S. Barwinek 1 Symulacja pochodna 8 błąd bezwzględny, 6 4 2 1 3 1 4 1 5 1 6 1 7 częstotliwość próbkowania, Hz Częstotliwość sygnału: 5 Hz 1 Hz 2 Hz 5 Hz 1 Hz Fig. 5. Results of simulation using a phase shifter based on the signal derivative Rys. 5. Wyniki symulacji z zastosowaniem przesuwnika fazowego opartego na pochodnej sygnału pomiar pochodna 8 błąd bezwzględny, 6 4 2 1 3 1 4 1 5 1 6 Częstotliwość próbkowania, Hz Częstotliwość sygnału: 5 Hz 1 Hz 2 Hz 5 Hz 1 Hz Fig. 6. Results of measurement using a phase shifter based on the signal derivative Rys. 6. Wyniki pomiaru z zastosowaniem przesuwnika fazowego opartego na pochodnej sygnału Another method of phase shifting the signal utilizes appropriate shift in time (time delay). In case of phase angle equal to /2 signal should be delayed by ¼ of waveform period. In digital measurement systems the delay is carried out by changing indices of tabularised samples of measurement signal. This type of phase shifter has been subjected to simulations and tests using real input measurement signals in the same way as before. The obtained results are shown in Figs.7 and 8.
Phase shifter in... 99,2 symulacja tablica, błąd bezwzględny, -,2 -,4 -,6 -,8 1 3 1 4 1 5 1 6 częstotliwość próbkowania, Hz Częstotliwość sygnału: 5 Hz 1 Hz 2 Hz 5 Hz 1 Hz Fig. 7. Simulation results - a set number of samples has been shifted Rys. 7. Wyniki symulacji z zastosowaniem przesunięcia o zadaną ilość próbek 4 pomiar tablica 3 błąd bezwzględny, 2 1-1 1 3 1 4 1 5 Częstotliwość próbkowania, Hz Częstotliwość sygnału: 5 Hz 1 Hz 2 Hz 5 Hz 1 Hz Fig. 8. Measurement results - a set number of samples has been shifted Rys. 8. Wyniki pomiaru z zastosowaniem przesunięcia o zadaną ilość próbek The obtained results may be assessed by comparing phase shift errors. Minimum absolute error determined for system with derivative was equal to.3 in simulations (for signal with 5Hz frequency and sampling frequency of 5 khz), while measurements for real signals yielded error equal to.1 (for signal with 5Hz frequency and sampling frequency of 8 khz). On the other hand, minimum absolute error determined for delay-type system dropped beneath 1-13 in a couple of cases, while for real input system we achieved.1 (for
1 A. Cichy, S. Barwinek numerous combinations of parameters such as signal with 5 Hz frequency and sampling frequency equal to 1 khz). Maximum absolute error determined for derivative-type system for both simulation tests and tests using real input signal is equal to 9 (for sampling frequency equal to twice signal frequency) and 45 (for sampling frequency equal to four times signal frequency). Maximum absolute error determined for delay-type system is equal to.8 for simulations (this error has been obtained for several tests, including signal with 5 Hz frequency and sampling frequency of 4 khz), while in case of real input signal it is 3.6 (for signal with 5 Hz frequency and sampling frequency of 2 khz). 4. CONCLUSION Application of appropriate phase shifter has a direct impact on accuracy of achieving quasi-balanced state and measurement of impedance components, dielectric loss factor and coil quality factor. Two significantly different possibilities of phase shifter design have been presented. Phase shifter π/2 using signal derivative is characterised by higher errors than phase shifter using shift by a set number of samples. The shift error decreases when sampling frequency goes up: if sampling frequency is doubled, then error is approximately halved. In case of high sampling frequencies the measurement signal is distorted by the shifter. Method utilizing sample tabularisation makes it possible to obtain errors as small as.1 (in case of simulation errors are due to rounding and at best they are close to 1-13 ) even at sampling frequency equal to 1 khz. In case of measurements using signal derivative minimum errors have been greater by two orders. Lower sampling frequency results in lower hardware and computation requirements. The drawback of this method is the necessity of ensuring appropriate proportion between sampling frequency and signal frequency. REFERENCES [1]. Cichy A.: Analiza właściwości układów quasi-zrównoważonych z detekcją fazową przeznaczonych do pomiaru składowych immitancji. Monografia 479. Wydawnictwo Politechniki Śląskiej, Gliwice 213. [2]. Cichy A., Skórkowski A., Barwinek S.: Automated quasi-balancing in virtual quasibalanced circuit designed to capacitance measurements. 19th Symposium IMEKO TC-4 Symposium and 17th TC-4 IWADC. Workshop Advances in Instrumentation and
Phase shifter in... 11 Sensors Interoperability, Barcelona. Universidad Politecnica de Catalunya, Barcelona, Spain 213. [3]. Cichy A., Skórkowski A., Barwinek S.: Double quasi-balanced meter for measurement of inductor quality factor. 19th Symposium IMEKO TC-4 Symposium and 17th TC-4 IWADC. Workshop Advances in Instrumentation and Sensors Interoperability, Barcelona. Universidad Politecnica de Catalunya, Barcelona, Spain 213. [4]. Cichy A., Roj J.: Method of Measurement of Capacity and Dielectric Loss Factor Using Artificial Neutral Networks. (W recenzji). [5]. Barwinek S.: Implementacja i właściwości wybranego algorytmu pomiaru kąta przesunięcia fazowego w środowiskach MATLAB i LabVIEW, Dokonania Młodych Naukowców 1/214 Nr 2 ISSN 23-4436 Creativetime, Kraków 214. [6]. Gajda J., Sroka R.: Pomiary kąta fazowego: metody, układy, algorytmy. Wydawnictwo Akademii Górniczo-Hutniczej im. Stanisława Staszica, Kraków 2. [7]. National Instruments USB-6251 NI 625xSpecifications. Dostępny w WWW: www.ni.com/pdf/manuals/371291h.pdf [Dostęp: 12. styczeń 214]. [8]. National Instruments DAQ M Series User Manual NI 622x, NI 625x, and NI 628x Devices. Dostępny w WWW: www.ni.com/pdf/manuals/37122k.pdf [Dostęp: 12. styczeń 214]. Dr inż. Adam CICHY Silesian University of Technology Faculty of Electrical Engineering Institute of Measurement Science, Electronics and Control Akademicka, 1 44-1, Gliwice Tel. 32 2371241; adam.cichy@polsl.pl Mgr inż. Sebastian BARWINEK Silesian University of Technology Faculty of Electrical Engineering Institute of Measurement Science, Electronics and Control Akademicka, 1 44-1, Gliwice Tel. 32 2371241; sebastian.barwinek@polsl.pl Post-graduate student holds a scholarship under project DoktoRIS Scholarship for Innovative Silesia co-financed by European Union within the framework of European Social Fund.