Harmonic problems in wind power plants

Harmonics has always been of special concern in power system studies. In the past the power system comprised mainly of passive components with relatively linear operating range and synchronous generators. Harmonic analysis of such systems is the state-of-the art right now.
The wind turbines are nowadays mainly connected together into a collector system through a widespread network of medium voltage (MV) sub-sea cables. The voltage is then stepped up and the wind power plant (WPP) is connected to the power grid through long high voltage (HV) cables which constitute the HVAC or HVDC transmission system. Such configuration is still being challenging to the industry from harmonic generation, propagation and stability perspective [1].
The presence of harmonics inside the WPP is a nuisance as it leads to higher current and voltage levels in the system. Consequently, the system loss is higher system, and there is higher component stress. Moreover, if there is series or parallel resonance points in the WPP, the resonating harmonics may get amplified and then that can be destructive. The resonance can be series or parallel type as shown in Fig. 1. Besides, there are other issues with harmonic interference and power quality [2].

Harmonic problems in wind farms

Fig. 1 Harmonic problems in wind power plants.

Identification of the presence of harmonics in the system and potential resonance conditions are very critical for the design of a WPP. Measurement of harmonic content is an important element of the WPP and wind turbine evaluation process. Measurement of field data is also required to validate the theoretical analysis and numerical simulations. The measurement equipment should be carefully adjusted in order to record harmonics of interest with acceptable accuracy and precision.
The harmonic measurements should be carried out during continuous wind turbine normal operation, i.e. fault free operation complying with the description in the wind turbine manual excluding wind turbine start-up and shutdown as described in IEC 61400-21. Since different operational modes are characterized by different frequency response of the converter thereby affecting the harmonic emission, the operational modes should be considered, and any change in the mode should be noted during the measurement process [3].
It is also recommended to perform measurements when the wind turbines are not operational such that the harmonic background spectrum can be evaluated. The wind turbine during background measurements should neither inject nor absorb any harmonic current during this process.
Harmonic mitigation by design is affected by several uncertainties in different factors during the design of a WPP. Some of them are listed below:

  • Lack of accurate models provided by the manufacturers.
  • Component tolerances in the WPP model.
  • Wind turbine harmonic emission model uncertainties.
  • Phase angle between harmonics from different wind turbines and possible harmonic cancellation.
  • Different operating modes of the wind turbines (e.g. power production levels, wake effects, voltage control, etc.).
  • Lack of reliable information from TSOs and DSOs for the external network model.
  • Changes in the wind turbine converter controller affecting harmonic emission.
  • Linear model of WPP components (e.g. transformers, converters, cables, etc.).
  • Linear harmonic load flow calculation method excluding possible frequency coupling.

[1] Ł. H. Kocewiak, C. L. Bak, J. Hjerrild, "Wind Turbine Converter Control Interaction with Complex Wind Farm Systems," IET Renewable Power Generation, Vol. 7, No. 4, 2013.
[2] Ł. H. Kocewiak, S. K. Chaudhary, B. Hesselbæk, "Harmonic Mitigation Methods in Large Offshore Wind Power Plants," in Proc. of The 12th International Workshop on Large-Scale Integration of Wind Power into Power Systems as well as Transmission Networks for Offshore Wind Farms, Energynautics GmbH, London, UK, 22-24 October 2013, 443-448.
[3] Ł. H. Kocewiak, "Harmonics in Large Offshore Wind Farms," PhD Thesis, Aalborg University, Aalborg, 2012.

Posted in Harmonics, Wind Farms | Tagged , , , | 1 Comment

How to adjust figures in Matlab?

I was asked few times about possible adjustment of figures in Matlab. Many times there is simply a need to change slightly the default view in order to align with the template in our publication, book, etc. Thus I will try to show few parameters that can easily adjust the view according to our expectations.

Fortunately in Matlab there is an extended flexibility of doing that. I need to admit that it is much more convenient to edit figures in Matlab than in other engineering tools (e.g. LabVIEW, PSCAD, PowerFactory, etc.). Therefore I personally export all of my results into Matlab and later adjust.

Let me explain how to obtain the following figures. As one can see the figures present the same result but slightly in a different way. I do not need to mention that nicely presented research results can easily attract broader audience. Hence even in the conservative scientific world it is of great importance to be able selling our findings.

Notch Filter - Bode Plot
Notch Filter - 3D Phase

The figures above show the variation of notch filter depending on the quality factor. The filter is tuned for 100Hz and included in synchronous reference frame and afterwards represented in natural/stationary reference frame. Thus the resonant peaks are shifted ±50Hz. The notch filter transfer function is expressed in the following way.


Such figures can be obtained by using the following code. Please note that also Control System Toolbox is needed to obtain the frequency response of the notch filter.

% Prepare workspace
clc, clear('all'), close('all'),
% Define font parameters
fontname= 'Cambria';
fontsize= 10;
% Get screen resolution
scrsz= get(0,'ScreenSize');

%% Notch filter
% Define frequency parameters
f= 50;                    % Grid frequency [Hz]
omegaO= 2*pi*f;           % Angular frequency [rad/s]
omegaN= 2*omegaO;         % Resonant frequency [rad/s]
step= 0.1;                % Frequency step [Hz]
frequencySeries= 1:step:200;
omegaSeries= 2*pi*frequencySeries;
% Construct transfer function
s= tf('s');
sN= s-1i*omegaO;
sP= s+1i*omegaO;
% Allocate memory
firstIndex= 1; lastIndex= 30; k= 1;
surfTf= zeros(length(frequencySeries),lastIndex);
map= zeros(lastIndex,3);

%% Display results
% Initiate figure
f1= figure('Name','Transfer Function Plot',...
'Position',[scrsz(3)*0.2 scrsz(4)*0.2 scrsz(3)*0.35 scrsz(4)*0.45]);
for index=firstIndex:k:lastIndex,
     Qn= 100/sqrt(2); Qd= index+5;           % Quality factor
     GnN= (sN^2+omegaN*sN/Qn+omegaN^2)/(sN^2+omegaN*sN/Qd+omegaN^2);
     GnP= (sP^2+omegaN*sP/Qn+omegaN^2)/(sP^2+omegaN*sP/Qd+omegaN^2);
     Gn= 1/2*(GnP+GnN);                      % From SRF to NRF
     [magGn,phaseGn]= bode(Gn,omegaSeries);  % Frequency response
     GnCplx= magGn.*exp(1i*phaseGn);
     surfTf(:,index)= GnCplx(:);
     sub1= subplot(2,1,1,'Parent',f1);box(sub1,'on'),hold(sub1,'all'),
          'Color',[0 1-index/lastIndex index/lastIndex]),
          ylabel('|{\itG_{notch}}| [abs]'),
          xlim([min(frequencySeries) max(frequencySeries)]),
          ylim([0.5 1.02]),hold('on'),grid('off'),
     sub2= subplot(2,1,2,'Parent',f1);box(sub2,'on'),hold(sub2,'all'),
          'Color',[0 1-index/lastIndex index/lastIndex]),
          xlim([min(frequencySeries) max(frequencySeries)]),
          ylim([-1100 1300]),hold('on'),grid('off'),
          ylabel('\angle{\it{G_{notch}}} [\circ]'),xlabel('{\itf} [Hz]'),
     map(index,:)= [0 1-index/lastIndex index/lastIndex];
c1= colorbar('peer',sub1,'East');colormap(map),
 'YTick',[firstIndex; floor((lastIndex-firstIndex)/2); lastIndex],...
 'YTickLabel',[firstIndex+5; floor((lastIndex-firstIndex)/2)+5; lastIndex+5]),

f2= figure('Name','Impedance Angle',...
     'Position',[scrsz(3)*0.2 scrsz(4)*0.2 scrsz(3)*0.35 scrsz(4)*0.45]);
ax2= axes('Parent',f2);grid(ax2,'on'),hold(ax2,'all'),
mesh(180*unwrap(angle(surfTf))/pi),zlabel('\angle{\it{G_{notch}}} [\circ]'),
     ylabel('{\itf} [Hz]'),xlabel('{\itQ_n} ','Rotation',322),view([60 40]),
set(gca,'XTick',[firstIndex; floor((lastIndex-firstIndex)/2); lastIndex],...
 'XTickLabel',[firstIndex+5; floor((lastIndex-firstIndex)/2)+5; lastIndex+5],...

Feel free to use and modify included Matlab code. I am also looking forward to hear from you in case of any suggestions and comments.

Posted in Software | Tagged , | Comments Off on How to adjust figures in Matlab?

Wind turbine harmonic models

Harmonic emission is recognized as a power quality concern for modern variable-speed wind turbines. For this reason, relevant standards (e.g. IEC 61400-21) require the measurement of harmonics and their inclusion in the power quality certificates of wind turbines. Understanding the harmonic behavior of wind turbines is essential in order to analyze their effect on a grid to which they are connected. Wind turbines with power electronic converters are potential sources of harmonic distortion, and therefore knowledge of their harmonic current emissions is needed to predict wind farm behavior and to design reliable wind farms [1]. The emission of harmonic currents during the continuous operation in steady state of a wind turbine with a power electronic converter must be stated according to the standards.

Nowadays there is a lack of appropriate wind turbine model descriptions for harmonic analysis purposes in standards. It is shown in this paper how the harmonic model should be developed based on measurements. It is recommended to develop wind turbine harmonic models based on the Thevenin (equivalently Norton) approach. The best way is also to compare results with simulations however various aggregation techniques can change measurement results and this should be taken into consideration.

In model development the most crucial measurements are done at the grid-side converter AC terminals and after the main reactor. Based on these measurements the wind turbine harmonic model can be developed based on the Thevenin approach. Please note that the Thevenin approach is equal to the Norton approach in harmonic assessment in wind power plants. The model developed based on the measurements describes the wind turbine harmonic behavior.

In model development it is important to use measurements that can describe the grid-side converter harmonic behavior. The reactor current is the most reasonable choice as well as the voltage at the converter AC terminals or the voltage after the series reactor. Unfortunately both measurement places can introduce some uncertainties.

If one would like to develop the model based on measurements after the series reactor the reactor impedance should be included in the Thevenin impedance. Unfortunately it is not so easy (especially for lower frequencies) to measure the frequency dependent impedance of the reactor. Small errors/uncertainties in the reactor measurements can introduce significant errors in model development, especially for harmonics with low magnitude. Therefore measurements at the grid-side converter AC terminals seem to be more reasonable because the reactor impedance is not needed in the Thevenin impedance. In case of measurements directly at the converter terminals only the internal converter impedance specified by the control structure is required. However such measurements also introduce some uncertainties. Please note that in high power density wind turbines with LV converters there is a need to use several parallel connected converters with sharing reactors. Such converters introduce a certain degree of unbalance which can affect internal harmonic current flow between converter modules. Even if coupled sharing reactors are designed to limit the current imbalance some asymmetry in harmonic generation between converter modules can be seen. The current flowing from the converter to the grid can be assessed based on measurements of all converter modules.

As it was mentioned earlier the converter internal impedance is strongly dependent on control structures applied by different manufacturers. Most of nowadays wind turbines are based on fast current control loop which has the most significant impact on the converter frequency response. Even if in theory the fundamental frequency controller is represented in the same way in natural/stationary reference frame still the controller transfer function may significantly vary if the current control is implemented in stationary or synchronous reference frame [4]. Please note that also harmonic compensation and switching frequency can affect the internal converter impedance. Therefore the internal impedance is kept as a trading secret by the wind turbine and converter units manufacturers.

The problems mentioned above cannot be avoided. Therefore it is recommended to perform simultaneous measurements in both locations (i.e. converter AC terminals and between the series reactor and the wind turbine transformer) and develop two independent models based on two datasets. Later the models can be compared.

In order to avoid any aggregation errors during the calculation of the Thevenin equivalent harmonic voltage sources it is recommended to apply harmonics directly from the Fourier decomposition (i.e. from the 10-cycle window). Later the obtained results (i.e. Thevenin equivalent harmonic sources) could be aggregated according to the methods recommended above. According to IEC 61400-21 there is a need to have at least nine 10min time-series of instantaneous measurements for each power bin. Based on experience it can be said that one month of measurements should be absolutely enough.

At the end it is worth to emphasize the the harmonic assessment approach presented in the IEC 61400-21 standard concerning measurements and power quality assessment in wind turbines assumes measurements of 10-minute harmonic current generated by a wind turbine for frequencies up to 50 times the fundamental frequency of the grid [2], [3]. It has to be emphasized that the most popular standard concerning measurements and power quality assessment of grid-connected wind turbines refers only to current harmonic components without any phase information. Therefore it impossible to evaluate if the harmonic current is flowing into the wind turbine and is mainly caused by background distortions or is caused by the grid-side converter and is flowing from the wind turbine to the grid.

Sometimes based on the power quality report from IEC 61400-21 the wind turbine is modeled as an ideal current source which can cause significant errors in harmonic analysis of wind farms. The harmonic source can be modeled only as an ideal current source for component where the internal converter impedance is equal to infinity. This can happen only for controlled frequencies (e.g. harmonic compensation) and the current value is equal to the reference signal in the control loop [4], [5].

[1] "Wind Turbine Generator Systems – Measurement and Assessment of Power Quality Characteristics of Grid Connected Wind Turbines," IEC 61400-21, 2008.
[2] H. Emanuel, M. Schellschmidt, S. Wachtel, and S. Adloff, "Power quality measurements of wind energy converters with full-scale converter according to IEC 61400-21," in International Conference on Electrical Power Quality and Utilisation, Lodz, 2009, pp. 1-7.
[3] A. Morales, X. Robe, and M. J. C, "Assessment of Wind Power Quality: Implementation of IEC61400-21 Procedures," in International Conference on Renewable Energy and Power Quality, Zaragoza, 2005, pp. 1-7.
[4] Ł. H. Kocewiak, J. Hjerrild, and C. Leth Bak, "Wind Turbine Control Impact on Stability of Wind Farms Based on Real-Life Systems Analysis," in Proc. EWEA 2012 - Europe's Primier Wind Energy Event, Copenhagen, 16-19 April 2012, pp. 1-8.
[5] Ł. H. Kocewiak, "Harmonics in large offshore wind farms," PhD Thesis, 2012, pp. 332, 978-87-92846-04-4.

Posted in Harmonics | Tagged , , | Leave a comment

Oversampling (resampling) data in harmonic data processing

When using a rectangular window, it is important to synchronize the measurement window accurately with the power system frequency to achieve integer multiple of periods in analysed time series (i.e. window period is and integer multiple of analysed frequency component natural period). For example, if the power system frequency is 50.2 Hz whereas the window size is 200 ms, the fundamental frequency spectral line of the discrete Fourier transform is no longer projected (represented) by one complex vector in the orthogonal basis but spanned over the whole basis. One can even say that the power system frequency in the estimated spectrum becomes an interharmonic with spectral leakage as a consequence. Therefore appropriate data should be prepared before the projection into frequency domain.

In order to limit possible data processing errors the signal should be adjusted before spectral analysis. Power system frequency variation can be limited by application of various interpolation methods. It is strongly recommended to always oversample the analysed signal. In this particular case acquired waveforms with sample rate of 44.1 kS/s/ch are oversampled up to 51.2 kS/s/ch. According to this procedure 1024 samples per cycle is obtained, which is an integer power of 2 and can be used to apply fast Fourier transform. Please note that for 10-cycle data blocks discrete Fourier transform should be applied.

Frequency estimation

Figure 1 Single tone frequency. (a) Measured power system frequency variation. (b) Frequency variation after resampling (spline interpolation).

Oversampling of each 10-cycle data blocks before spectrum estimation significantly limits fundamental frequency variation over analysed window and therefore the stationarity assumption is strengthened for frequency component of interest (i.e. linked with the fundamental frequency). As it can be seen in Figure 1 resampling with high precision definitely improves signal quality. The figure presents analysed one minute of acquired voltage waveform and each point is an estimated fundamental frequency over 10-cycle rectangular window. The discrepancy as a difference between two measured values, given in Figure 1(b), is acceptably small and the sample standard deviation is 4.3548•10-6. Please note that scale 0.2s used on abscissa (i.e. horizontal axis) in Figure 1 denotes the step size between neighbouring samples. If there are 300 samples in presented results (as in Figure 1) the total duration is 1 minute (i.e. 0.2s∗300=60s).

It can be seen that both factors such as main tone detection algorithm as well as interpolation algorithm are crucial in appropriate harmonic magnitude and phase estimation. Various interpolation techniques can give different results. The most sophisticated unfortunately are usually the most time consuming. Therefore taking into consideration enormous amount of data to process from few months of multipoint measurements also the interpolation should be optimized and agreement between acceptable accuracy and calculation speed should be found.

Roughly speaking, during interpolation process new samples between existing samples are computed. Different methods were used in data processing such as nearest (coerce) method, linear method, spline method, cubic method, and finite impulse response filter method [1]. The nearest method finds the point nearest to xi  in an X array and then assigns the corresponding y value in an interpolated Y to yi. The linear method interpolates yi on the line which connects the two points (xj,xj+1) when the corresponding location xi of interpolated value yi which is located between the two points in an X array. The spline method known also as cubic spline method is almost always the most suitable solution. Within the method the third-order polynomial for each interval between two adjacent points in X (xj,xj+1) is derived. The polynomials have to meet the following conditions: the first and second derivatives at xj and xj+1 are continuous, the polynomials pass all the specified data points, the second derivatives at the beginning and end are zero. The cubic Hermitian spline method is the piecewise cubic Hermitian interpolation. This method is similar to cubic spline interpolation and derives a third-order polynomial but in Hermitian form for each interval (xj,xj+1) and ensures only the first derivatives of the interpolation polynomials are continuous. Compared to the cubic spline method, the cubic Hermitian method is characterized by better local property. The cubic Hermite interpolation method guarantees that the first derivative of the interpolant is continuous and sets the derivative at the endpoints in order to preserve the original shape and monotonicity of the data [2]. Also interpolation based on finite impulse response filter is popular [3], [4]. This method provides excellent results also for frequency analysis, although it is more intensive computationally [2].

Order Interpolation method Computation time [ms] Marker
1 Linear 110 x
2 Coerce 70 *
3 Cubic spline 130
4 Hermitian spline 430 +
5 FIR filter 290

Table above shows the computation time of data interpolation with different algorithms. In each of the cases the presented time is measured for resampling of 10 cycles of measured data. It can be seen that the simplest algorithms exhibit less computation burden. On the other hand in many cases simple algorithms cannot give satisfactory interpolation results and thus affect the harmonic calculation results. Figure 2 shows how different interpolation techniques affect harmonic magnitude estimation from measurements carried out at the LV side of the wind turbine transformer. It can be seen that the coerce method is affected the worst while other algorithms give comparable results.

Oversampled measurements

Figure 2 Different interpolation techniques used in oversampling of waveforms measured at LV side of the wind turbine transformer.

It was observed that in case of more distorted waveforms (e.g. gird-side converter output voltage) interpolation method choice plays a crucial role. In Figure 3 one can see that also linear interpolation and cubic Hermitian spline interpolation do not give satisfactory results. Therefore the most suitable for harmonic components estimation appear to be cubic spline interpolation as well as finite impulse response filter interpolation. Since the spline method (as presented in table above) is less time consuming, this method was used in further data processing. The selected measurement period was selected when the power system frequency were varying below 50 Hz or above 50 Hz.

Oversampled measurements

Figure 3 Different interpolation techniques used in oversampling of waveforms measured at the grid-side converter AC terminals.

[1] S. C. Chapra and R. Canale, Numerical Methods for Engineers: With Software and Programming Applications, 6th ed. McGraw-Hill Science, 2009.
[2] National Instruments, "LabVIEW 2011 Help," National Instruments Manual, 2011.
[3] R. A. Losada, "Digital Filters with MATLAB," The Mathworks, 2008.
[4] R. W. Schafer and L. R. Rabiner, "A digital signal processing approach to interpolation," Proceedings of the IEEE, vol. 61, no. 6, pp. 692-702, Jun. 1973.

Posted in Harmonics | Tagged , , , | Leave a comment

Commercial power quality meters

The use of a rectangular window requires that the measurement window is synchronized with the actual power system frequency, hence the use of a 10-cycle window instead of a window of exactly  200 ms. The IEC standard [1] requires that 10 cycles correspond with an integer number of samples within 0.03%. To ensure synchronism between the measurement window and the power system frequency, most power quality meters use a phase-locked loop generating a sampling frequency that is an integer multiple of the actual power system frequency. One of the commonly used in the company power quality meters is Elspec G4500 which provides full functionality regarding measurements of power quality. An exemplary connection of such measurement equipment in there phase system is presented in Figure 1 [2].

Elspec G4500 connection

Figure 1 Exemplary connection of Elspec equipment in wind turbines.

Before power quality indices are calculated by the Elspec equipment, acquired data is processed. Processing stage comprises of fundamental frequency detection, sample rate adjustment according to the detected frequency, and Fourier decomposition applied. The approach of sample rate adjustment is to adjust the finite orthogonal Hilbert basis in order to express each of frequency components in the Fourier space only by one vector from the Hilbert basis. The whole data acquisition, processing and logging process is briefly presented in Figure 2.

A synchronization (i.e. sample rate adjustment according to the fundamental frequency) error leads to cross-talk between different harmonic frequencies. The 50 hz component is by far the dominating component in most cases so that the main concern is the cross-talk from the 50 hz component to higher order components. From the other side, resampling process can affect frequency components which are not integer multiple of the fundamental frequency.

This phenomenon can be easily seen in the spectrum of pulse width modulated voltage source converters with fixed frequency ratio. Since generated output voltage of the wind turbine is a function of the fundamental frequency (fo) and the carrier frequency (fc), results obtained by the Elspec system are incorrect to some extent. The magnitudes of Fourier transform harmonic components are the more inaccurate the higher significant is the fundamental variation. Even if the result of applying the discrete Fourier transform to the basic window is a spectrum with 5-hz spacing between frequency components and the spectrum thus contains both harmonics and interharmonics, the results can be sometimes significantly inaccurate.

Power quality meter data processing

Figure 2 Data processing algorithm used by Elspec equipment.

As a good example of this is one of the most significant sideband harmonic components from the first carrier group. Exemplary results of measurements form the LV side of the wind turbine transformer can be seen in Figure 3. As it was mentioned previously the wind turbine frequency ratio is mf=49 and the analyzed sideband harmonic component is of frequency fc+2fo. Three scatter plots present the same harmonic component measured during the same period using different data acquisition devices and processing techniques.

Sideband harmonic - not resampled signal Sideband harmonic - resampled signal
(a) (b)
Sideband harmonic - Elspec G4500

Figure 3 Sideband harmonic component affected by different processing techniques: (a) sideband harmonic calculated in post-processing from resampled signal, (b) sideband harmonic calculated in post-processing from original signal, (c) sideband harmonic calculated on-line by power quality meter.

Data processing results presented in Figure 3 show how easily inappropriately applied processing techniques can provide wrong results. Results from Figure 3(a) show sideband harmonic component measured using results obtained from the measurement campaign with direct Fourier decomposition (i.e. without sample rate adjustment). From Figure 3(b) presents the same data but resampled and later discrete Fourier transform is applied, Figure 3(c) describe sideband harmonic component magnitude obtained by the Elspec measurement system.

It can be observed that results using various processing approach provide different results. Due to the fact that the frequency of sideband harmonic components generated by modulation with constant carrier frequency does not vary significantly and Fourier decomposition without earlier sample rate adjustment gives the most appropriate results. This is presented in Figure 3(a) and only small magnitude variation affected by nonlinear relation between the modulation index () and the sideband harmonic components as well as measurement and data processing (i.e. small spectral leakage) errors. Completely different and unacceptable results are seen in Figure 3(b) where analysed waveform is resampled. One can observe that due to significant spectral leakage the estimated magnitude sometimes can be even equal to zero. Therefore sometimes power quality meters can provide values significantly affected by processing errors. This behaviour is present in the scatter plot from Elspec measurements (Figure 3(c)). It is important to emphasize that the algorithm in the power quality meter applies lossy compression which also determines estimated magnitudes. Estimated harmonic components are assumed to be insignificant and not saved (i.e. set to zero) if the magnitude is lower than a certain threshold which is defined based on measured waveform distortion and maximum allowed database storage capacity per month. Such limitations provides scatter plots as in Figure 3(c) which is similar to Figure 3(b) but modified due to averaging and magnitudes below the threshold artificially set to zero.

[1] "Electromagnetic compatibility (EMC) - Part 4-30: Testing and measurement techniques - Power quality measurement methods," International Electrotechnical Commission Standard IEC 61000-4-30, 2008.
[2] P. Nisenblat, A. M. Broshi, and O. Efrati, "Methods of compressing values of a monitored electrical power signal," U.S. Patent 7,415,370 B2, Aug. 19, 2008.

Posted in Harmonics | Tagged , | Leave a comment