INSTITUTE OF PHYSICS PUBLISHING MEASUREMENT SCIENCE AND TECHNOLOGY Meas. Sci. Technol. 13 (2002) 963–974 PII: S0957-0233(02)33465-9 Analysis and alternatives in two-dimensional multigrid particle image velocimetry methods: application of a dedicated weighting function and symmetric direct correlation J Nogueira, A Lecuona, U Ruiz-Rivas and P A Rodrı́guez Departamento de Ingenierı́a Térmica y de Fluidos, Universidad Carlos III de Madrid, c/ Butarque 15, 28911-Leganés, Madrid, Spain Received 5 February 2002, in final form 22 April 2002, accepted for publication 10 May 2002 Published 20 June 2002 Online at stacks.iop.org/MST/13/963 Abstract Multigrid particle image velocimetry (PIV) is an open path in the search for high-resolution PIV methods. It is based on an iterative scheme that uses the information of initial processing to adapt the method parameters in order to improve the measurements. This is mainly performed by reducing the size of the interrogation windows and shifting them. In multigrid PIV, two sources of error can significantly affect the final measurement quality: (1) the error coming from the amplitude response of the initial large interrogation windows to spatial frequencies; (2) the error originating from the truncation of particles at the borders of the final small interrogation windows. By applying weighting functions and using symmetric direct correlation both errors can be reduced, respectively. These techniques have been separately tested in the past, but a joint implementation has not yet been analysed. This task is fulfilled and both sources of error are further clarified. For this purpose, a one-dimensional single wavelength displacement field is used. This gives us the opportunity to analyse the non-linear behaviour of PIV, together with the influence of basic parameters on it. In addition to this, the multigrid method, so far described, is enhanced by compensation of the particle pattern deformation. The metrological performance of this advanced method is tested using synthetic images and the results are compared with those delivered by established PIV methods. Coherence between these results and those obtained in a real image is also detailed. Keywords: fluid flow velocity, spectral characterization, multigrid PIV, local field correction PIV, perturbed and forced jets 1. Introduction The scientific community and industrial developers recognize particle image velocimetry (PIV) as an important tool for measuring velocity in fluid flows. Nevertheless, even the basic configuration designed to extract only two components 0957-0233/02/070963+12$30.00 © 2002 IOP Publishing Ltd of the velocity along a two-dimensional domain (2D 2C PIV) is still under active evolution, mainly by attempts to expand its capabilities and to reduce the measurement uncertainty. In the domain of correlation PIV an important aim in this research activity is the development of higher spatial resolution techniques. The use of PIV for measuring in Printed in the UK 963 J Nogueira et al turbulence is recent, but on this topic small-scale description requires such high resolution, together with a careful spectral characterization and the removal of bias errors when possible. The advanced PIV methods that focus on high resolution are iterative. Relying on initial measurements, they tune or adapt the method to obtain better ones. In correlation PIV, two main branches of advanced 2D methods deserve a mention: local field correction PIV (LFC-PIV) and multigrid PIV. Information about the former can be found in Nogueira et al (1999, 2001b). It consists of an iterative PIV method with subpixel image distortion and shift. Its originality consists of achieving spatial resolutions far smaller than the size of the smallest interrogation window. This is possible thanks to the iterative procedure and by using an appropriated weighting window that avoids improper response for wavelengths smaller than the interrogation window. Information about multigrid PIV can be found in Soria (1996), Hart (1999), Scarano and Riethmuller (2000) and Lecordier et al (2001), among others. It is also an iterative PIV method. In this case, the use of image distortion is optional. The method achieves high resolution by reducing the size of the interrogation window with an appropriate shift based on the previous iteration. A comparison of the metrological qualities of these methods can be obtained by comparing figures 1 and 18 in the review by Scarano (2002). Care should be taken in this comparison as both horizontal and vertical axes respectively display inverse concepts. In the paper by Nogueira et al (2001b) and in this present paper, further evolutions of LFCPIV and multigrid PIV are offered, together with a common base comparison. A third way of obtaining high resolution is the use of hybrid methods. These start by using large interrogation windows, switching at a certain point to particle tracking velocimetry (PTV); see Keane et al (1995) and Cowen and Monismith (1997), among others. The considerations of the advantages and disadvantages of using PTV are out of the scope of this paper. In this paper we mainly focus on launching some proposals that can increase the accuracy of contemporary multigrid PIV. In order to evaluate the gains obtained, a comparison with LFC-PIV seems customary. In order to establish a common base for comparison, in this paper peak fitting is always performed using two orthogonal three-point Gaussian fits. Although the basic procedure of multigrid PIV has been documented elsewhere, some notes about it are given below to establish a framework for further discussion. In this technique, the iterative cycle of PIV processing is used for two purposes: (1) To obtain higher spatial resolution. This is achieved by reducing the size of the interrogation windows. The price to pay is accepting the possibility of a lower signal-to-noise ratio (s/n) and the corresponding higher measurement uncertainty. The reason for this is a reduction of the number of correlating particles. This drawback is especially relevant for those windows small enough to approach the working limits of PIV. At intermediate steps in the progression towards smaller interrogation window sizes, the methodology tries not 964 only to increase the spatial resolution, but also to increase the s/n by reducing the dispersion of particle displacements within the interrogation window. These opposing considerations eventually bring an optimum window size. (2) To diminish the loss-of-pairs due to the in-plane displacement of particles between correlating windows. This is achieved by redefining the location of the interrogation windows in the PIV images, using the previously measured displacements. The concept has been called ‘window shifting’ (see Westerweel et al (1997), among others). The consequence is an increase in the s/n and, theoretically, a null average displacement in the interrogation window at the end of a repetitive processing. This requires subpixel window shifting and thus image interpolation. In addition to this, some advanced methods use ‘image distortion’ techniques for the same purpose, i.e. s/n ratio enhancement (Fincham and Delerce (2000), Scarano and Reithmuller (2000), among others). Image distortion has already been introduced by Huang et al (1993) at each window and by Jambunathan et al (1995) over the whole image. Details on how to perform this distortion can be found in both works and in Nogueira (1997) and Nogueira et al (1999), among others. Using this technique, an attempt is made to reduce the remaining particle displacements in the interrogation window after image shift, assuming a continuous local displacement field between the centres of the interrogation windows, i.e. ‘grid nodes’. Thus, non-uniform displacements within the interrogation window are compensated for by the information obtained in previous interrogations. Ideally, after a sufficient number of repetitive image distortion processings, a negligible displacement between correlating windows remains, thus yielding the maximum possible s/n. This technique also requires image interpolation. The iterative attribute of multigrid methods is fully confirmed when there is a point where a decision is taken on whether to repeat previous interrogations with a different set-up and the same window size or to progress reducing the window size. This is the same when the original images are also deformed. Otherwise, the method is just progressive, in a hierarchy towards high resolution. In the study reported here, we do not address the optimum strategy in the iterative multigrid process, but underpin some consideration towards optimization, including the number of iterations and the way to preclude error growth. The proposals offered in this paper cover large as well as small window interrogation steps. This is especially relevant as one of the advantages of multigrid PIV is the low number of iterations, making all the steps relevant. 2. Synthetic images In order to compare metrological figures of the proposals, synthetic images have been used. In these images, the displacement field, sy (x, y), corresponds to a one-dimensional (1D) single wavelength λx along the x-direction: sy = 2 sin(2π x/λx )(pixels). (1) Analysis and alternatives in 2D multigrid PIV methods (a) (b) (a) (b) Measured Displacement Displacement Real Position x Position x Figure 2. A scheme of PIV displacement distributions in the measurement of a sinusoidal 1D field: (a) displacement to be measured; (b) output. Figure 1. Close-ups of synthetic images (40 × 40 pixels each): (a) image of type 1; (b) image of type 2. Amplitudes larger than two pixels have not been considered in this study, owing to the now current procedure of shifting the interrogation windows. The out-of-plane loss of particles, related to large displacements, is considered by directly eliminating some of them. Varying the spatial wavelength λx allows us to evaluate the amplitude and phase response to a monochromatic and simple signal. Owing to the non-linear characteristics of the PIV processing, additional considerations are introduced in the paper, when necessary. The synthetic images formed by randomly located particles are discretized assuming an 8 bit square pixel sensor. The shape of the imaged particles is Gaussian, and it is integrated with unity fill factor over each pixel surface (Westerweel 1998). Where particles overlap, the corresponding intensities are added, thus neglecting laser interference effects. The remaining parameters that define the images divide them into two categories: • Type 1 images. These are purposely designed to test the performance of the techniques in respect to the spatial wavelength amplitude response. For this purpose, they contain no additional noise. The mean distance between particle images is small, δ = 2 pixels, i.e. 4/(π δ 2 ) ∼ 0.3 particles per pixel area (ppp). For small enough particles, the imaged diameter is determined by the diffraction limit of the lens, rather than the geometrical particle diameter. This implies a shift towards monodispersivity of the particle image size distribution. According to this, the e−2 diameter of the Gaussian particle images was simplified to have a uniform value of d = 2 pixels. Although the luminosity of each particle was considered uniform, overlapping gives a reasonable inhomogeneity, see figure 1(a). This type of image is comparable with those obtained seeding air with micrometre-size oil droplets in large wind tunnel facilities. • Type 2 images. It is also important to consider the effect of noise sources and other difficulties. To fulfil this, at least partially, and to allow direct comparison with previous works (Nogueira et al 1999, 2001b) a second type of image has been designed. The mean distance between the particle images is larger, δ = 4.5 pixels, i.e. 4/(πδ 2 ) ∼ 0.06 ppp in order to create low s/n areas. The diameter of the particle images is random, ranging from d = 2 to 4 pixels. Their random peak intensity ranges from 0 to 92% of the maximum grey level. Both intensity and diameter are allowed to randomly and independently differ up to 10% within each particle pair, which takes into account effects coming from particle laser scattering and laser pulse inhomogeneities. Five per cent of particles have no second image to correlate, simulating out-ofplane displacement. A continuous background grey level reaches up to 20% of the maximum intensity range and it is smoothly distributed over large zones (∼60 pixels). This tries to simulate stray light and room illumination. This type of image is similar to those obtained in small laboratory facilities. In these facilities, it is usual to seed water with pollen, spores or plastic particles. This, together with smaller magnifications, leads to large particle image diameters. Figure 1 depicts a close-up of both types of images. 3. Errors related to iterative PIV with large windows In a single-step straight PIV processing, correlation and peak detection processes average the particle displacements contained in the interrogation window in a complex non-linear way. Actually, the way in which they are averaged can generate a substantial difference in the output. In a generic way it is said that correlation PIV represents the most frequent displacement. In this section we study the different situations concerning the mentioned averaging, in order to clarify these concepts. To evaluate the nature of the averaging process, it is useful to analyse the response of the PIV to 1D single wavelength sinusoidal displacement fields, such as those proposed in expression (1). The window side length F will normalize the wavelength. Monte Carlo simulations have been performed to reveal the details of the averaging process, the results of which will be presented later. The output of the simulations has shown a non-linear functional dependence with the input. The degree of this non-linearity depends on the length scales F , d, δ, λx , sy and pixel size. To point out the mechanics of this phenomenon, figure 2 depicts a scheme for a certain, but representative, condition. It corresponds to an idealization of the measurement obtained when F /λx < 1. For F /λx > 1 this effect also appears, but in a more complex way, as it is combined with other effects that will be later analysed in due detail. The output shows a deviation over the sinusoidal input waveform, making it look more squared. This deviation grows with F /λx when F /λx < 1. From the point of view of Fourier decomposition, this implies the appearance of negative 965 amplitude third harmonic, besides smaller higher-order terms. The rationale behind this is as follows. The flatness of the measured waveform at its top and bottom is because the PIV may not average all the displacements within the interrogation window. Actually, it does not take into account the contribution of particle pairs whose correlation peak does not overlap with the main one, and take partially into account those which partially overlap. The result is that, when the main correlation peak comes from the maximum sinusoidal displacement, other different displacements within the interrogation window affect the result less than they would in the case of a moving average. Small particles deliver narrow correlation peaks, thus reducing overlapping and as a result increasing the abrupt slope change between positive and negative maximum displacements, see figure 2(b). Increasing the deviation from the sinusoidal input is the effect obtained and consequently exacerbating the non-linear effect of PIV. In the limit of very small pixel-resolved particle diameters, a cluster of correlation peaks would appear, hence precluding the much-invoked averaging effect of correlation PIV. The output for a sinusoidal input would be something similar to a square waveform with notches. On the other hand, when the particles are larger than the displacements within the interrogation window, one can imagine the situation where all the individual peaks fully overlap. In this situation, the ensemble correlation peak represents a particle-weighted average of the displacements within the window. For this reason, the PIV response to a spatial waveform is frequently referred to as being similar to that of the moving average. Further analysing this averaging of displacements within the interrogation window, an additional source of error appears for F /λx > 1, which is specifically important for iterative processing. Nogueira et al (1999 and 2001b) have documented that PIV interrogation windows, without any grey level weighting, introduce a negative amplitude response for several frequency intervals. Processing the synthetic images proposed in section 2 allows a Monte Carlo analysis of this issue. The response of a single-step straight PIV (not using window weighting) has been evaluated as the ratio of the amplitude at wavelength λx , in a Fourier decomposition of the output waveform, over the sinusoidal input amplitude. Figure 3 shows the results obtained. This figure also shows the amplitude response of the moving average with filter width F , as a reference. In this figure, the behaviour of the PIV is as described above, in the interval 0 F /λx < 1, which is marked with black lines. Out of this interval, one can observe the negative amplitude response, also mentioned above. This response is analogous to that of the moving average. This means a phase inversion response (shift of π radians). For larger values of F /λx (not depicted in figure 3) successive cycles of positive and negative amplitude response appear, matching those of the moving average. In terms of error, these negative response intervals mean that the root mean square of the error, rms(e), is larger than that of the signal amplitude, rms (sy ). rms (e)/rms (sy ) > 100% means the possibility of obtaining errors larger than 100% in the final output. 966 F und am en ta l wa vele ngth re lative a m plitude J Nogueira et al 1 .0 0 .8 0 .6 0 .4 0 .2 0 .0 A -0 .2 C B -0 .4 -0 .6 -0 .8 -1 .0 0 .0 0.2 0 .4 0 .6 0 .8 1.0 1 .2 1 .4 1 .6 1.8 2 .0 N ormalised window size F / λ x Figure 3. The 1D amplitude responses of single-step PIV without any weighting function: circles, F = 64; squares, F = 32; open symbols, type 1 images; filled symbols, type 2 images; full curve, moving average amplitude response. The squares with a dashed outline indicate the displacement distribution within the interrogation window, not to scale. It is obvious that this phenomenon also occurs for particle displacement distributions having a shape similar to the sinusoid (square, triangle, etc). The mechanisms of correlation peak formation, introduced above, explain the layout of the data. A particle pair with displacement sp contributes to the main correlation peak, with displacement sm , only if their difference is less than the radius considered in the peak fitting algorithm, R, plus the pair peak waist wp : |sm − sp | < R + wp . (2) This condition does not consider spurious contribution to the peaks. Alternatively, it is said that correlation PIV represents the most frequent particle displacement. This is a more vague condition than that indicated in expression (2), coinciding with it somewhere. However, both arguments justify the higher than moving average amplitude response found in figure 3. This mechanism also justifies what happens in the region between points of null response, A and C in figure 3. There is more aggregation of pair peaks with the opposite sign to the one corresponding to the centre of the window, thus giving a false displacement with a maximum value near point B. Figure 3 shows that the response obtained in type 2 images is smaller than that obtained in type 1 images. This is caused by the larger particle diameters used in these images, allowing the averaging effect to increase in the peak aggregation process, as indicated previously. Furthermore, the noise content smears the peaks extending the averaging effect, thus improving measurement from the linear theory point of view. This means introducing fewer harmonics and thus less spectral distortion. On the other hand, its linear low-pass effect is higher. The smaller response of the 32 pixel windows in respect to the 64 pixel windows is because, for the same F /λx , λx is smaller, which leads to larger peak overlapping. This results from the closer spurious peaks correlating false particle pairs. Analysis and alternatives in 2D multigrid PIV methods 3.1. Effects of the phase inversion on the amplitude response of multigrid PIV Figure 3 shows that the negative amplitude response introduces errors larger than 100% at certain wavelengths (vertical distance to 1). As a result, a multigrid PIV method using windows with F = 64 pixels will introduce this error between λx = 64 and 32 pixels, besides other smaller wavelength intervals. Analogously, windows with F = 32 will give the same effect for wavelengths between λx = 32 and 16 pixels. These scales are common in flows diagnosed by PIV. This error gives an initial window shift opposite to the real one, which can fool the adaptation of the method in search of a Displacement field: s y = 2sin(2πx /λ x ) (pixels) 1.2 F =32 followed by F =16 1 rms(e )/rms(s ) Here, the fundamental wavelength λx has been used to measure the amplitude response. Other choices, such as the use of the overall amplitude, would give different figures, but obviously the behaviour is the same. Actually, this option would yield a smaller amplitude response, not revealing the non-linear effect. This is of relevance for turbulence spectral assessment. Another relevant effect is that the amplitude response of PIV does not decrease with F /λx as fast as a low-pass filter, such as the moving average. This means that noise, or small wavelength content, in the displacement field could introduce in the output an appreciable erroneous influence, of special concern in the intervals of negative amplitude response. A main consequence is that spatial derivatives can contain large errors for F /λx > 0.5 in single-step unweighted PIV processing, even with no extra consideration to peak locking (Westerweel 1998, Nogueira et al 2001a). The effects of particle diameter and of peak fitting radius found so far make the amplitude response curves such as figure 3 not unique; on the contrary, they are dependent on basic parameters of images and processing. If there are gradients in the vertical displacement, ∂sy /∂y = 0, the effects presented here are modified, as when ∂sx /∂y = 0 or/and ∂sx /∂x = 0. The extension of the modification is complex to describe, but responds to the same background described here. In summary, the simple approach to single-step unweighted correlation PIV processing just described highlights its non-linear behaviour. A boost effect of the large spatial gradients and a damp effect of the small gradients has been described, analysed, and the originating mechanism explained. Structures in a flow field are undoubtedly more complicated than 1D sinusoids. A study of these remains to be performed. Nevertheless, if the local shape is similar to a sinusoid, this makes what has been described here directly applicable. Expression (2) can be considered as a design rule for PIV implementation. In what follows, image distortion techniques are considered. In addition to the advantages offered by this technique, its effect on the non-linearity described up to now is relevant. Image distortion iteratively reduces the displacement to be measured, eventually converging to a null displacement to be measured. In this way the response of the method after a sufficient number of iterations progressively approaches a linear response. Window shifting alone does not offer this possibility. F =64 followed by F =16 0.8 1 step, F =16 0.6 0.4 0.2 2 steps, F =16 0 20 25 30 35 40 45 50 λ x (pixels); (δ =2 pixels). 55 60 65 Figure 4. The relative error shown as a function of wavelength for different two-step PIV methods, with image distortion and without any weighting function. A single-step method has been added for comparison; type 1 images. better measurement; as a result reducing the s/n and eventually leading to a spurious vector or outlier. Even without the arousal of outliers a deleterious effect appears. Figure 4 shows that, for the mentioned intervals, the use of large windows worsens the measurement, even when small windows are used afterwards. To perform this test, the grid distance has been set to 8 pixels for all the iterations. The results vary with different grid distances, but the qualitative behaviour is the same. This figure shows that, in both intervals of negative amplitude response, a single iteration with a small window performs better than processing first with a large window and afterwards with a small window. However, sometimes the use of large windows is necessary to obtain robustness of the method against difficulties with seeding, illumination or noise, i.e. the resistance to produce outliers. In other words, robustness is the resistance to lock in a false peak. Besides this, a large window can cope with large displacements but not small displacements. Window shifting and window deformation using the previous measured displacement, in principle, can make feasible the following measurement step with a smaller window. This way of processing means extending the measuring range and increasing the s/n, thus enhancing robustness. The multigrid methods tested in figure 4 include image distortion. The behaviour of the methods would be qualitatively similar with window shifting only, nevertheless the image distortion amplifies the effect of a good or a bad measurement. This means that avoiding image distortion would reduce the effect of the error in cases with large windows, but would also reduce the good performance in the case of two steps with F = 16 pixels. Another consideration to be taken into account is that the presence of outliers could also amplify the error in the case of image distortion. In the test presented here (d = 2 pixels, displacement <2 pixels), the s/n was large enough to avoid outliers in the first iteration. It can be concluded that, in a conventional multigrid method, large windows may introduce robustness, but often at the expense of accuracy, due to the negative amplitude response. 3.2. Error amplification and instabilities Multigrid methods, processing through several steps with image distortion, present an additional effect which comes 967 (a) (b) ∆ F F Figure 5. Two extreme ways of implementing the compensation of the particle pattern deformation: (a) distortion using only the grid nodes of the window corners; (b) using all the grid nodes. For clarity (b) displays only some displacement vectors. from the negative amplitude response. It produces a distortion of the PIV images in the opposite direction to the correct one. This increases the deformation between the correlating images instead of decreasing it. Hence, this can lead to a divergent instability, unless countermeasures are taken, such as those documented in Nogueira et al (1999, 2001b). These works conclude that a proper selection of the ratio between the window size F and the grid-node spacing avoids the instability. The criterion there presented, Fn 2n , is here proposed again, but now expanded in its application, allowing it to operate on two consecutive steps, n and n + 1, thus being less restrictive and yielding the same effect: Fn+1 2n (3) where n is the step number. In successive steps, if the criterion of expression (3) is held, the error due to the negative response appears, but no instability is triggered. This is because for F 2 the compensation of the particle pattern deformation introduces the aliased wavelengths as error, instead of the unstable wavelengths. These aliased wavelengths fall outside the unstable range. If the hierarchy of successive steps does not follow the criterion in expression (3), there is another way of avoiding the instability, by relying on the same theoretical background. This consists of implementing the deformation of the image for each interrogation window just by a reduced number of grid nodes, instead of the more detailed piecewise deformation using all the grid nodes. Figure 5 depicts two extreme ways of doing this. Obviously, the first way implies a low-pass effect when compared to the second option. The application of lowpass finite impulse response averaging filters on every step to the displacement field is another alternative, but also brings a loss in high-resolution capability. In this study we also indicate that the joint use of some of these resources, such as image distortion and low-pass averaging filters, has to be implemented with care, as their combination can introduce in the final output stable artefacts, instabilities apart. 3.3. Avoidance of negative amplitude response There is an unproblematic way of avoiding the negative amplitude response, contrasting with the cloudy horizon drawn for the compensation of the particle pattern deformation in the previous subsection. As stated at the beginning of section 3, the averaging of small features in the displacement field brings 968 Fundamental wavelength rel. amp. J Nogueira et al 1.0 0.8 0.6 0.4 0.2 0.0 -0.2 -0.4 0.0 0.2 0.4 0.6 0.8 1.0 1.2 1.4 1.6 1.8 2.0 Normalised window size F /λx Figure 6. The amplitude response of single-step PIV with the weighting of expression (4). The dashed curve represents the moving average and the full curve represents the moving average weighted with expression (4). The symbols are the same as those in figure 3. some problems. However, modulating the way this averaging occurs is possible, thus alleviating the negative aspects. One approach to doing this is to apply a weighting function on the grey level distributions, f and g, of both interrogation window. A weighting function υ, designed to avoid negative amplitude response, has already been developed by the authors (Nogueira 1997, Nogueira et al 1999). This function is 2 2 ξ η η ξ υ 2 (ξ, η) = 9 4 − 4 + 1 4 − 4 + 1 F F F F (4) where ξ F /2 and η F /2 are orthogonal coordinates with origins at the centre of the interrogation window. Using this weighting function, the computation of the correlation coefficient, Clm , has to follow expression (5): Clm = F /2 F /2 ξ,η=−F /2 ξ,η=−F /2 υ(ξ,η)f (ξ,η)·υ(ξ,η)g(ξ +l,η+m) . F /2 2 2 ξ,η=−F /2 υ (ξ,η)g (ξ +l,η+m) υ 2 (ξ,η)f 2 (ξ,η) (5) Here, l and m are the image displacements. Figure 6 shows the equivalent results to those depicted in figure 3, but using this weighting function. Although this figure plots only for F /λx 2.0, no negative amplitude response has been detected when using the weighting function of expression (4). In addition to this, there are no null amplitude response wavelengths. Actually, the amplitude response, r, of the moving average weighted with this function is always positive: sin(π F /λx ) 36 1 − r= π F /λx (π F /λx )2 (π F /λy )2 sin(π F /λy ) × 1− . (6) π F /λy This window shows both a higher cut-off frequency and a smaller low-pass order than the unweighted window, which is favourable in terms of amplitude response. The absence of negative amplitude response allows for correct shifting and/or deformation of interrogation windows in advancing steps, therefore avoiding the instability described Analysis and alternatives in 2D multigrid PIV methods Displacement field: s y = 2sin(2πx /λ x ) (pixels) 0.6 0.6 0.5 Unweighted multigrid Unweighted multigrid rms(e )/rms(s ) rms(e )/rms(s ) Displacement field: s y = 2sin(2πx / λ x ) (pixels) 0.7 0.5 0.4 0.4 0.3 0.3 0.2 0.2 0.1 0.1 Weighted multigrid Weighted multigrid 0 0 20 25 30 35 40 45 50 λ x (pixels); ( δ=2 pixels). 55 60 65 Figure 7. The relative error of weighted and unweighted multigrid PIV methods applied on type 1 images, seven steps. The main text gives the details. in the previous subsection. This point has been thoroughly checked in synthetic as well as in real images. Unfortunately, the application of a weighting function induces a small but accumulative erroneous slip in the measurement (Nogueira et al 1999), which shows up after a large number of steps. This slip is larger with smaller windows, making inadvisable its use for windows with F < 32 pixels. 4. Comparison between weighted and unweighted multigrid PIV down to F = 16 In this section we report on the results of testing the proposal of weighting the interrogation windows. A conventional multigrid method has been implemented for comparison and is labelled ‘unweighted’ in figures 7 and 8. It includes the compensation of the particle pattern deformation using bilinear velocity interpolation between consecutive grid nodes, as in Nogueira et al (1999), and using biparabolic grey level interpolation. We have selected F = 16 pixels in all the iterations. The use of larger windows introduces errors within the tested range of frequencies, as figure 4 depicts, and it is advisable only when a high robustness is required. The iteration is formed by six steps of = 8 pixels, followed by one of = 4. In this way there is no error amplification for any wavelength, even smaller than 16 pixels, because of expression (3). It must be accepted that the parameters defined here for the multigrid PIV are somewhat arbitrary. Nevertheless, the setup has been chosen with care, so that the performance yield is representative of the different possibilities. For a certain single wavelength, error minimization would lead to a different setup, but better overall performance is difficult for a conventional multigrid method. This method has been compared with a weighted method that uses the same grid distances as the conventional multigrid example and the same number of steps. F = 64 is used in the first iteration, followed by F = 32 (dashed curves in figures 7 and 8). The large size weighted window warrants that, in addition to the increase in accuracy, which is observable in the figures, there is a high robustness. Another weighted scheme was tested in this campaign. It corresponds to the same window sizes, but the first step of = 8 pixels is followed by six steps of = 4. Owing to the 20 25 30 35 40 45 50 55 60 65 λ x (pixels) ; ( δ=4.5 pixels). Figure 8. The relative error of weighted and unweighted multigrid PIV methods applied on type 2 images, seven steps. The main text gives the details. CORRELATION OF INTERROGATION WINDOWS FROM IMAGES a AND b: FFT SPURIOUS CONTRIBUTION TO CORRELATION Displacement > – 1 pixel Figure 9. Error mechanism introduced by the periodicity of the FFT. weighting, there is no amplification of the error and the grid distance can be freely chosen. Again, an additional increase in accuracy, due to a closer sampling, is evident (lower full curve in figures 7 and 8). It is obvious that these later advantageous techniques need a larger computing time, because of the introduction of the weighting function. Note that part of the denominator in expression (4) changes when l and m change and thus has to be calculated the same number of times than the numerator. In addition, the larger number of vectors in the second weighted case increases the computing time as well. 5. Errors related to iterative PIV with small windows The application of windows smaller than 16 pixels on real images still seems to be a subject under development. Several recent applications of advanced multigrid methods do not use small windows, an example is Scarano and Riethmuller (2000). In that paper, devoted to multigrid PIV, the authors process real images with windows of 32 and 16 pixels. Nevertheless, there is ongoing research on methods especially designed to deal with smaller windows. Fincham and Spedding (1997) show good measurements with small windows, but the requirement for a large particle diameter arises, giving an optimum diameter of around 6 pixels. Nogueira et al (2001a) have introduced a way to successfully deal with small windows and small particles. The algorithm presented there is the symmetric direct correlation (SDC). It has been proven that this procedure gives good results in tests over synthetic as well as over real images, using subpixel offset of the interrogation windows. Here, it 969 J Nogueira et al Image a Image b 0.5 Correlation coef. Gray level Gray level 1 1 0.5 0 0 -3 -2 -1 0 1 2 DC-PIV 1 Interrogation window 3 0.6 0.4 0.2 0 -3 -2 -1 Spatial pos. (pix.) 0.8 0 1 2 3 -1 Spatial pos. (pix.) -0.5 0 0.5 1 Displacement (pix.) Figure 10. A 1D example showing that, even at zero displacement, DC-PIV loses the correlation peak symmetry if there is a truncation of particles at the window borders. Single particle truncated at the border of a 5-pixel window. Image a Image b SDC-PIV 1 1 0.5 1 Interrogation window Correlation coef. Gray level Gray level Interrogation window 0.5 0 0 -3 -2 -1 0 1 2 3 Spatial pos. (pix.) 0.8 0.6 0.4 0.2 0 -3 -2 -1 0 1 2 3 Spatial pos. (pix.) -1 -0.5 0 0.5 1 Displacement (pix.) Figure 11. An example of the symmetry recovery of SDC-PIV with a single particle truncated at the window border and null displacement. Filled and open symbols depict the correlation function of the two DC methods. The full curve depicts the average. will be evaluated with the compensation of the particle pattern deformation instead of the simpler subpixel offset. In section 5.1 we give a brief description of the underlying principles, as an introduction to discussing the results of the tests on its performances. In this section we also evaluate the increase in accuracy with respect to state-of-the-art algorithms. 5.1. Selection of the correlation algorithm for small windows The correlation function with a pair (a and b) of large interrogation windows is time consuming. In order to save time, most PIV methods turn to the fast Fourier transform (FFT), instead of the direct correlation (DC) calculation. The use of FFT completely ignores the image out of the interrogation windows, substituting it by a periodic patch of windows. The effect is the introduction of a spurious contribution in the calculation of the correlation coefficient for any non-null displacement. This reduces the s/n. Figure 9 depicts the mechanism of this source of error, which is more relevant the smaller the window is. With small interrogation windows, it is possible to afford the increase in computing time of the DC. Using it avoids the reduction of the s/n associated to the periodicity of the FFT. Nevertheless, getting rid of this source of error does not necessarily mean having a better performing algorithm; other sources of error have to be checked. Detailed studies such as Huang et al (1997) show that DC produces errors, even when evaluating null displacements between two identical images. One of the main reasons for this is the truncation of particles at the window borders (Nogueira et al 2001a). The way to avoid this error in FFT, using a discrete shift of the interrogation window, is useless for DC with a symmetrical 970 peak-fitting function or with small particles (Nogueira et al 2001a). The reason for the error lies with the lack of symmetry of the DC algorithm itself, which leads to an asymmetric peak. Figure 10 shows that the correlation peak of a single 2 pixel wide particle, truncated at the border, although peaking in the right position, is not shape symmetric. As the correlation coefficient is calculated at discrete increments, this introduces a bias error in the output of the subpixel peak-fitting algorithm. With DC, this source of error is present even if there is no displacement of the particles, misleading iterative window shifting algorithms. We have proposed a new algorithm to avoid the error: SDC (Nogueira et al 2001a). This algorithm consists of a slight modification of DC, as follows. To force symmetry everything done in the first image, a, in respect to the second image, b, must be done in image b in respect to image a, and both outputs have to be averaged. Once recovering symmetry, no error appears for cero displacements as sketched in figure 11. Furthermore, the symmetry of the algorithm allows for iterative subpixel offset dealing with the error coming from particle truncation (Nogueira et al 2001a), as in the FFT case. It should be pointed out that the convergence of iterative methods with image deformation under ideal conditions is cero displacement for the cases of FFT and SDC, presenting no truncation error. Other ways to deal with the truncation error include weighting windows, such as the one already introduced for large windows, or masks that erase particles at the borders (Lourenco and Krothapalli 2000). This last option needs identification of particles, as in PTV, which is not always Analysis and alternatives in 2D multigrid PIV methods Displacement field: s y = 2sin(2π x / λ x ) (pixels) 0.2 Weighted + 3 DC steps rms(e )/rms(s ) rms(e )/rms(s ) Weighted + FFT steps 0.6 Weighted multigrid Weighted + 3 FFT steps 0.1 LFC-PIV 0.5 Weighted + SDC steps 0.4 Weighted multigrid (only large windows) 0.3 0.2 0.1 Weighted + 3 SDC steps LFC-PIV 0 0 20 25 30 35 40 45 50 55 60 65 λ x (pixels); ( δ=2 pixels). Displacement field: s y = 2sin(2πx /λ x ) (pixels) 0.15 Weighted + FFT steps 0.1 Weighted + SDC steps Weighted multigrid (only large windows) Optimum measurement 0.05 0 5 10 LFC-PIV 15 20 25 30 35 0 5 10 15 20 25 30 35 40 45 50 Number of steps Figure 12. The relative error of small windows processing type 1 images with multigrid schemes, weighting at large windows steps and with several options at small ones. Ten steps. The large window method, LFC-PIV, is included for comparison. rms(e )/rms(s ) Displacement field: s y = 2sin(2πx /λ x ) (pixels) 0.7 40 45 50 Number of steps Figure 13. The evolution of the relative error shown as a function of the number of iteration steps. The multigrid schemes of figure 12 have been allowed to progress for 50 steps. Type 1 images, λx = 31 pixels. feasible for small δ. The advantages and disadvantages of PTV are studied elsewhere. 5.2. SDC implemented with compensation of the particle pattern deformation The SDC is proposed here for small interrogation windows. As commented in section 3 it is not advisable to weight such windows and thus they will be used unweighted. Therefore, to test SDC together with the compensation of the particle pattern deformation, the extra care to include is the restriction from expression (3). Figure 12 presents the results of a test performed on type 1 images. This test takes as landmark the ‘weighted multigrid’ method from figure 7 (lower full curve, corresponding to one step of F = 64, = 8 followed by six steps of F = 32, = 4). After these steps, the multigrid process is completed in three different ways: (i) with three further steps of SDC using F = 8 and = 4, giving the performance line marked with hollow diamonds; (ii) the same three steps but with FFT giving slightly worse results; (iii) with three steps of DC, clearly inappropriate, as predicted. Figure 14. The evolution of the relative error as a function of the number of iteration steps. The multigrid schemes of figure 12 have been allowed to progress for 50 steps. Type 2 images, λx = 31 pixels. In addition, figure 12 shows the performance of the LFCPIV method, with F = 64 and = 4, for comparison. Besides the information contained in figure 12, it is of interest to observe the behaviour of the different schemes with the number of processing steps. For this purpose, in the following tests the number of iterative steps is large. In all the methods considered, a control algorithm avoids excessive growth of errors and allows for a fair comparison with other techniques, such as LFC-PIV. This is the same algorithm that LFC-PIV uses; this means refusing correction of the measurement in a processing step if the peak of the local correlation coefficient and those of at least five neighbours are all reduced (Nogueira et al 2001b). This has almost no effect for a small number of steps, but improves the measurement when the number is large. In LFC-PIV, this algorithm tries to approach the minimum error. When it is reached, the number of iterations defines the optimum measurement. Figure 13 indicates this point. There, one can observe the evolution of the error with the number of iterations for the case of λx = 31 pixels. The scale of the error has been zoomed in order to appreciate the differences among the methods. It seems clear that the reduction of window size allows us to reach less error faster, but the weighted multigrid that only uses large windows (F = 64 for the first step and 32 afterward) achieves a similar performance after several further iterations. For type 2 images, the results, shown in figure 14, are somehow different. The performance of those methods that reduce the window size down to F = 8 yield an error increase as soon as this size is applied in step eight. On the other hand, the results shown here are in some way coherent with those in figure 13. Both figures show that the larger the interrogation window is, the lower the error can be. This occurs after a larger number of steps and with appropriate weighting for large windows. We can attribute the difference between figures 13 and 14 either to the larger distance between particles or to the noise in type 2 images. To distinguish both sources, we measured images similar to those of type 1, but with δ = 4.5 pixels. The results were qualitatively equal to figure 13, reproducing almost the same graph, but with 30% higher error. Consequently, the difference in the error growth rate, depicted in figure 14, is attributed to the noise sources detailed in section 2. 971 J Nogueira et al 2 pixels Figure 15. Close-ups of the two real images to correlate (40 × 40 pixels). = 5 pixels Figure 17. Flow field measured with LFC-PIV within the square zone in figure 16. It acts as reference for the performances of other methods. The grid distance corresponds to 4 pixels. The local correlation coefficient indicates the presence of twelve false vectors (1.2% of the total number of vectors). A 11.3 pixel mean displacement has been subtracted. Figure 16. General structure of the real flow. Only the zone within the square is used in the test. A 4.7 pixel mean displacement has been subtracted. In summary, the use of weighted windows in a multigrid method offers a decrease in measurement uncertainty. Care should be taken when using image deformation with grid distances smaller than F . In these cases, the error of all the options here proposed decreased up to a certain number of steps, reaching a minimum, to grow afterwards. This error grows more rapidly with noisy images and small windows. A method based on large weighted windows (without the reduction of size associated to multigrid) reaches the same level of uncertainty, but giving even better results for large numbers of steps. However, none of methods can match the approximately half uncertainty figure of LFC-PIV on both types of synthetic images. Although generalization of these conclusions for < F is not possible with the available data, they seem to be consistent with the mechanics explained here and we have not found cases where different conclusions arise. The main advantage of small window sizes over other advanced techniques based on large windows is the reduction of computing time. On the other hand, higher noise content in the images seems to compromise its application. This may indicate a loss in robustness for difficult images. 6. Coherence when processing real images As the displacement field is unknown in real images, no direct evaluation of the errors is possible. Nevertheless, the coherence or likelihood of the results in real images with those obtained in synthetic ones can be evaluated. 972 The real PIV image chosen for this test corresponds to a study on the near field of co-flowing round water jets subjected to simultaneous axial forcing and azimuthal perturbation. This locks jet instabilities and reduces out-of-plane particle losses in meridian symmetry planes. The diameter of the inner nozzle, D, is 15 mm, the mean flow velocity, umean , is 0.69 m s−1 and the velocity of the outer flow, u0 , is 0.12 m s−1 . Consequently, the Reynolds number, ReD = D(umean −u0 )/ν, is 7000. The frequency of the axial forcing is 10 Hz. The seeding used for the PIV measurements is inertized licopodium spores, which have a diameter around 20 µm and are neutrally buoyant. A DANTEC DoubleImage 700 camera was used. Its field of view was set around 45 × 35 mm, corresponding to the 768 × 484 pixels CCD sensor. The time between pulses was set to 700 µs. More details about the experiment and the PIV method can be read in Ruiz-Rivas et al (2002) and Rodrı́guez et al (2001). Close-ups of the experimental PIV images are depicted in figure 15, showing a similar layout as the type 2 synthetic image in figure 1(b). The particular case examined here corresponds to the small flow inhomogeneities in the potential zone of the jet core, shown in the square in figure 16. The coherence test is based on the results presented in section 5, supported by the similarity of the images in figures 1 (type 2) and 15. There, LFC-PIV has given accurate and robust results. Its output after 80 iterations, depicted in figure 17, will be used as reference. The deviation between this vector field and those calculated with other methods will suit as an approximation of the error. It is marked with an asterisk, rms (e)∗ . In this case the reference displacement field shows rms (s) = 0.9 pixels, slightly smaller than the amplitude chosen for the synthetic cases. Figure 18 depicts the results of this evaluation. After 80 steps, this plot would show null error, due to the arbitrary reference chosen. This figure shows a similar behaviour to that depicted in figure 14, thus implying coherence with the results using synthetic images, although it seems to correspond to images with a higher noise content. Analysis and alternatives in 2D multigrid PIV methods Weighted + FFT steps & Weighted + SDC steps 0.8 rms(e )*/rms(s ) In order to ascertain the validity of the conclusions drawn from synthetic 1D displacement images, a real image with similar particle layout, but with turbulent displacement distribution, was prepared. The results obtained in the real image are coherent with those in the synthetic images. Displacement field: real 0.9 0.7 0.6 0.5 0.4 Weighted multigrid (only large windows) 0.3 Acknowledgments 0.2 0.1 LFC-PIV 0 0 5 10 15 20 25 30 35 40 45 50 Number of steps Figure 18. The evolution of the relative error as a function of the number of iteration steps for the methods studied in this paper. They correspond to the analysis of the real image indicated in figures 15–17. 7. Summary and conclusions The methodology of using 1D sinusoidal waves offers the possibility of studying the linear and non-linear responses of PIV, giving hints to further progress in the understanding of its behaviour. It has been shown that a negative amplitude response increases the measurement uncertainty for some wavelength intervals in single-step unweighted PIV implementation. In standard multigrid PIV methods, the effect reduces the signalto-noise ratio, thus increasing the possibility of outliers. Even more, it can induce instability in methods incorporating image distortion and image shifting techniques, thus leading to outliers. Specific ways of implementing the hierarchy of the progression towards smaller window size and smaller grid node distance are proposed to avoid this instability. The use of a proper weighting function offers a more robust and uncomplicated alternative, although valid only for large windows. This technique eliminates negative amplitude response and avoids other errors. No restrictions remain in the full use of image distortion technique to increase the spatial resolution. Under favourable conditions for successfully applying unweighted windows of 16 × 16 pixels (i.e. evaluating the response for wavelengths larger than 20 pixels in flow fields that do not produce outliers for such windows) the results with weighted windows of 32 × 32 pixels with the same number of processing steps are clearly better. Figures 7 and 8 illustrate this point. The use of this weighting function with large windows gives a further advantage; i.e. a better positioning of subsequent windows, hence contributing to the robustness of the method. Smaller windows of 8 × 8 pixels offer a substantial reduction of computing time. When almost no noise is present, they approach the better accuracy of large weighted windows in fewer steps, see figure 12. In these tests, the systems using SDC algorithms performed better than those based in FFT or DC. A reasonable noise content severely reduces the performance of such small windows. Besides this, a reduction in robustness is anticipated. Another main conclusion is that larger weighted windows offer the potential of a lower error figure, but this shows up after a substantial number of iterating steps. This work has been partially funded by the Spanish Research Agency grant AMB1999-0211, DPI2000-1839-CE, Feder 1FD97-1256 in collaboration with the Universidad de Las Palmas de Gran Canaria and under the EUROPIV 2 project (a Joint Programme to Improve PIV Performance for Industry and Research) is a collaboration between LML URA CNRS 1441, DASSAULT AVIATION, DASA, ITAP, CIRA, DLR, ISL, NLR, ONERA, DNW and the universities of Delft, Madrid (Carlos III), Oldenburg, Rome, Rouen (CORIA URA CNRS 230), St Etienne (TSI URA CNRS 842), Zaragoza. The project is managed by LML URA CNRS 1441 and is funded by the CEC under the IMT initiative (Contract no GRD1-199910835). References Cowen E A and Monismith S G 1997 A hybrid digital particle tracking velocimetry technique Exp. Fluids 22 199–211 Fincham A M and Delerce G 2000 Advanced optimisation of correlation imaging velocimetry algorithms Exp. Fluids 29/7 S13–22 Fincham A M and Spedding G R 1997 Low cost, high resolution DPIV for measurements of turbulent fluid flow Exp. Fluids 23 449–62 Hart D P 2000 Super-resolution PIV by recursive local-correlation J. Visual. 3 (2) 187–94 Huang H, Dabiri D and Gharib M 1997 On errors of digital particle image velocimetry Meas. Sci. Technol. 8 1427–40 Huang H T, Fiedler H E and Wang J J 1993 Limitation and improvement of PIV: part II. Particle image distortion, a novel technique Exp. Fluids 15 263–73 Jambunathan K, Ju X Y, Dobbins B N and Ashforth-Frost S 1995 An improved cross correlation technique for particle image velocimetry Meas. Sci. Technol. 6 507–14 Keane R D, Adrian R J and Zhang Y 1995 Super-resolution particle-imaging velocimetry Meas. Sci. Technol. 6 754–68 Lecordier B, Demare D, Vervisch L M J, Réveillon J and Trinité M 2001 Estimation of the accuracy of PIV treatments for turbulent flow studies by direct numerical simulation of multi-phase flow Meas. Sci. Technol. 12 1382–91 Lourenco L M and Krothapalli A 2000 True resolution PIV: a mesh-free second-order accurate algorithm 10th Int. Symp. on Applications of Laser Techniques to Fluid Mechanics (Lisbon, 2002) Nogueira J 1997 Contribuciones a la técnica de velocimetrı́a por imagen de partı́culas (PIV) PhD Thesis ETSIAeronáuticos, Universidad Politécnica de Madrid, Spain Nogueira J, Lecuona A and Rodrı́guez P A 1999 Local field correction PIV: on the increase of accuracy of digital PIV systems Exp. Fluids 27/2 107–16 Nogueira J, Lecuona A and Rodrı́guez P A 2001a Identification of a new source of peak-locking, analysis and its removal in conventional and super-resolution PIV techniques Exp. Fluids 30/3 309–16 Nogueira J, Lecuona A and Rodrı́guez P A 2001b Local field correction PIV, implemented by means of simple algorithms, and multigrid versions Meas. Sci. Technol. 12 1911–21 973 J Nogueira et al Rodrı́guez P, Ruiz-Rivas U and Lecuona A 2001 Near field vortex dynamics in axially forced, laminar, co-flowing jets: descriptive study of the flow Eur. J. Fluid Mech. B/Fluids 20 673–98 Ruiz-Rivas U, Lecuona A, Rodriguez P A and Nogueira J 2002 PIV measurements in co-flowing jets subjected to axial forcing: vorticity and strain field structure Selected Papers of the 10th Int. Symp. on Applications of Laser Techniques to Fluid Mechanics (Lisbon, 2002) (Berlin: Springer) at press Scarano F 2002 Iterative image deformation methods in PIV Meas. Sci. Technol. 13 R1–19 974 Scarano F and Riethmuller M L 2000 Advances in iterative multigrid PIV image processing Exp. Fluids 29/7 S51–60 Soria J 1996 An Investigation of the near wake of a circular cylinder using a video-based digital cross-correlation particle image velocimetry technique Exp. Thermal Fluid Sci. 12 221–33 Westerweel J 1998 Effect of sensor geometry on the performance of PIV 9th Int. Symp. on Applications of Laser Techniques to Fluid Mechanics (Lisbon: Instituto Superior Técnico) Westerweel J, Dabiri D and Gharib M 1997 The effect of a discrete window offset on the accuracy of cross-correlation analysis of digital PIV recordings Exp. Fluids 23 20–8