Investigation of a corrugated channel flow with an open source PIV software

In this study, the corrugated channel flow was investigated by using an open-source particle image velocimetry (PIV) software. The open-source software called OpenPIV was first verified by using images of an earlier experimental work of a vortex ring formation. The corrugated channel flow images were taken with 200 W power LED light source and a high speed camera and those images were analysed with these spatial and temporal tools of OpenPIV. Laminar, transient and turbulent flow regimes were identified when Reynolds number was below 1100, in between 1100 and 2000 and higher than 2000, respectively. The velocity vectors were found to be about 20% lower than the previous study results. The flow inside the grooves was also investigated with OpenPIV and flow characteristics at the grooves were captured when interrogation window size was lowered. The visualization of the flow was presented for different Reynolds numbers with the relative scale values. As a result of this study, OpenPIV software was determined as promising open source PIV analysis software.


Introduction
Fluid motion analysis is one of the most difficult fields of mechanical engineering.Most of the equations which are being used to understand and to predict fluid motion are complex and difficult to solve.Additionally, sometimes it becomes so hard to find an equation which helps to understand fluid motion just by analytical approach.As a result of these difficulties, experimental studies became crucial and inevitable for this field.One method for understanding fluid motion experimentally is flow visualization technique.A fundamental method to visualize the flow is use of dyes.When a certain colour of dye is used to mark fluid particles, successful qualitative results can be obtained; however, these results would not possess any qualitative findings.Besides, when dye is used for flow visualization, it is known that dye would diffuse after certain time and dye would no longer mark the fluid particles in fluid flow.On the other hand, along with the technological development of optics, advanced visualization techniques have been developed.Planar Laser Induced Fluorescence (PLIF) is an optical diagnostic technique being used widely for flow visualization.In this technique, naturally buoyant particles are mixed with the liquid which is desired to be observed.If the fluid is in gas form, then smoke particles are used.As a different approach, hydrogen bubbles generated from electrolysis can be used for water flow applications [1].The commercial particle image velocimetry (PIV) products use high-tech lasers for illumination and high speed cameras with a data hub to control image capture process.Because of this high-tech setup, these analysis tools require huge investments.Since the PIV technique mainly depends on the images, low quality images taken with a high-speed camera can also be analysed to see if they provide satisfying results.There are promising studies about development of opensource PIV software [2].
The most complicated flow regime to analyse is turbulent flow.Turbulent flow has advantages when mixing of fluid streams or exchange of heat is required.On the other hand, the heat transfer rate mainly depends on temperature difference and heat transfer area so that different geometrical approaches have been studied to increase the heat transfer area.Corrugated wall channels are one of the examples of these studies.These are used widely as heat exchangers in heat transfer systems.The flow around corrugation which is called bulk flow and the flow inside of the corrugations which is called groove flow should be analysed to see the effect of different geometries on the flow.
The objective of this study is the validation of an open-source PIV software and then using it to analyse different flow types in corrugated pipes.

Previous studies
In the present study, the corrugated channel flow is intensely investigated.These investigations were focused on geometry of the corrugation, pressure drop around the corrugation and vortex formation.Since other properties can be derived from velocity, the flowrate estimation due to geometry was important.There are studies about estimation flowrate due to the corrugated pipe geometry [3].The pressure drop needs to be investigated for proper heat transfer rates and proper implementation of corrugated pipes.To understand this, particle image velocimetry is also used [4].The vortices in the grooves enhance the turbulent flow.If the vortex movement is analysed, then the geometry or dimensions of corrugations can be changed to optimize vortex formation and locations of them.There are experimental studies about the location change of vortices inside the groove and the magnitude of it [5].Setting up an experiment is costly and tedious way to analyse flow around corrugation so that different approaches have been used.Computational analysis is a way to analyse the fluid motion around a corrugation and with a successful meshing; it can provide accurate results [6].

Experimental setup
The data used in the present study was taken from an experimental setup as shown in Figure 1.The experimental setup includes a corrugated surface section with Plexiglas walls, a pump for circulation of water, a tank for steady flow and three valves for control of the flow.The section of interest for the images is the corrugated surface section.Its schematic representation which was taken from a previous study can be seen below.In here, H stands for channel height and it is given as 15.86 mm.The corrugation height is defined as h and it is given as 4.15 mm.The wave length of the corrugation is defined with Ȝ and it is given as 6.6 mm.d1 stands for the cavity size and it is given as 3.0 mm.The corrugation size which is defined as d2 is 3.6 mm.The channel width which is defined with b is 20 mm.A high speed camera was placed perpendicular and a light source was used to illuminate the seeding particles.The Reynolds number is defined as Where ȡ stands for density of water, u stands for mean velocity of water, D h stands for hydraulic diameter of channel and ȝ stands for dynamic viscosity of water.A stopwatch and a container were used for measuring mass flow rate and thereby velocity.The hydraulic diameter was calculated as 17.69 mm.

Digital Particle Image Velocimetry Technique 4.1 Typical setup
The typical PIV setup includes a double-pulsed laser for illumination, laser sheet optics to transform laser beam into a light sheet, a transparent walled flow setup, buoyant seeding particles and a high-speed camera to capture images.The laser should be synchronised with the camera so precisely because the time interval between two consecutive images is crucial for good PIV data.The seeding also plays a very important role since the seeding marking the fluid particles must follow the flow.Their diameter should be in between 10-100 μm.They should be naturally buoyant so that they decrease the time lag between accelerations of fluid and the particles.The material of the particles could be reflective or fluorescent.

Image processing
The method to analyse PIV images is mainly based on cross-correlation technique.The cross-correlation technique is used to determine the similarity between two series as a function of time difference between them.PIV software subdivides each image pair into interrogation windows then looks for the intensity correlation between each interrogation window by using cross-correlation.The location of the peak in this correlation function indicates the average displacement of particles in the two related interrogation windows in image A and image B.
Error reduction is done by windows shifting and postprocessing of the results.In windows shifting, the software uses the displacement field found from crosscorrelation of images A and B. The image A is subdivided into interrogation windows like the first crosscorrelation process then the known displacement vector is used to determine the corresponding interrogation window in image B. A new cross-correlation is done between these two interrogation windows to get a correction to the previously found displacement vector.In post processing, outlier removal is crucial and easy to perform.To find the outlier, a threshold deviation is defined.The software checks magnitudes of vectors, and if a vector exceeds the threshold value times standard deviation of the whole vector field then it is identified as outlier.The outlier vectors are replaced with interpolated EFM 2015 vectors from neighbours.The rest is the conversion process of the pixel displacement field to velocity field.

Validation of OpenPIV software 5.1 Introduction
In order to use OpenPIV as an analysis tool, its output needs to be verified by using a known previous work or by comparison with a professional commercial product output.The validation of the results for this study was done by using a previously captured and published vortex ring formation experiment images [7].These high quality professional PIV images were analysed with OpenPIV and the resultant vectors were post-processed via Spatial and Temporal Analysis Toolbox which is complementary software for OpenPIV.The validation was conducted for three different time instants.These points were selected according to the previous work.An example set of analysed consecutive images can be seen below.(See Figure 2) This analysis was conducted with 32x32 interrogation window size and 32x32 overlap.The result of this analysis can be seen in Figure 3.It can be clearly seen that there are some extraordinary long and misdirected vectors in front of the vortex ring generator.These vectors are called outliers.These outliers are reduced with outlier filtering.Experimental apparatus also has remarkable effect on outliers.After getting the vector files, filtered and interpolated results were imported to Spatial and Temporal Analysis Toolbox.An example view of the vectors before the analysis process can be seen below (See Figure 4).

Results and discussion
For three different time instants three image pairs were analysed.OpenPIV analysis mode was selected as instantaneous and the contour quantity selected as vorticity.The results of OpenPIV can be seen in below figures.(See Figures 5-7)

02107-p.3
To be sure about the position of the vortices, a pixel conversion was also performed.Since the earlier work has used x/D as a coordinate axis, the pixel numbers corresponding to these values had to be calculated.The D value which represents the inner diameter of the cylinder was given as 3.73 cm.The images have 1024 x 1024 pixel spatial resolution and the field of view is 4.65D x 4.65D.So there are 59.0389 pixels for 1 cm.The bottom vortex location is around 0.65.The pixel number corresponds to this position was calculated as 143.14 px.The starting position is 1024 px, the cylinder head black section should be taken into account, then the starting pixel coordinate becomes 1000 px, the end position can be found easily by subtraction of the x distance.So that the vortex position was calculated as 856.86 px.
The above plot which was generated according to the OpenPIV result shows that the vortices are around 860 pixels.So it can be certified that OpenPIV results are quite accurate when compared to results of a commercial product.Since the validation only at one point is not statistically satisfying, the other points were also analysed by following the same procedure.The results were presented below.(See Figures 6 and 7) The most important visual property of this analysis was the stopping vortices.These vortices can be seen next to the main vortices.Small and reverse directional vortices shown in Figure 7 are called stopping vortices.The magnitudes of the vorticity were quite accurate but the problem about these results is that when the position verification applied to these images, vortex position for t = 2s was roughly 60 pixels ahead of the paper result and position for t = 3s was roughly 40 pixels ahead of the paper result.The vortex at t = 5s also had a positioning problem; it was roughly 100 pixels ahead of the paper result.
The accuracy of the software was checked by using a known experimental data and the results were satisfying.The position problem of the vortices was tried to be solved by changing the scale or the analysis type but the result was failure.Analysis of the corrugated pipe flow was decided to be done to see the error of the software when analysing velocity values.

Velocity analysis of bulk flow 6.1. Introduction
The visualization of the flow around corrugated pipes with a high speed camera gives rough information about the flow characteristic but it needs to be supported qualitatively.This section is about velocity analysis of corrugated channel flow by using OpenPIV software.In order to do that, images of a previous graduation thesis which were taken with a high speed camera and a 200 W LED source were used.These image pairs were selected for five different Reynolds numbers and three different flow regimes.

Results and discussion
In order to get a statistically satisfying result three different time instants were analysed for each Reynolds number.For Re < 1200, the flow was named as laminar, for 1200 < Re < 2000 the flow was named as transient and for Re >2000 the flow was named as turbulent.The image pairs were selected as one from the start of the experiment, one from the middle and the last one from nearly the end of recording.Those images were imported to OpenPIV and the scaling was set to 1.The analysis was conducted with 32x32 interrogation window size and with 32x32 overlap.One representative result for each flow was presented below (See Figures 8-12).02107-p.4For laminar flow regime and for turbulent flow with Re = 3243.87,the software gave reasonable result.For transient and turbulent flow with Re = 7340.02analysis, the accuracy was lower.As it can be clearly seen from results, the upper part of the corresponding images could not be analysed accurately.These areas are lack of velocity vectors because of the quality of the images.To visualize it better, original frames were presented.(See Figure 13) points.The lesser the significant intensity points, the lower the accuracy of the analysis.The analysis was conducted with scale value 1.Hence, velocity vectors have the unit of pixels/dt.Where dt represents the time interval between images.To get a physical result, a basic conversion was done.In order to do this, two main parameters were needed to be known, these parameters were dt in seconds and the meter-topixel ratio of the images.The information of the pixels in the image was taken from the camera itself.The images have 640 x 511 pixels and 1006 Hz.Some of the images were taken for different fps rates so that these changes were taken into account while converting the px/dt values to physical units.As it can be seen from the schematic representation of flow domain (See Figure 1) the diameter of the crest (d2) is 3.6 mm.This physical length was taken as reference and the meter-to-pixel ratio was approximated by using an image manipulation program called GIMP.The original image was analysed with GIMP and the pixel ratio of original image and analysis PC's display was found as 1.2.It means 640 pixels are represented with 535 pixels in the GIMP GUI.The diameter of the crest was measured with "Measure" tool and it was found as 129 pixels.The proportion between 129 pixels and 535 pixels was calculated as 4.1473.So the physical length of the image was calculated as 14.93 mm by multiplying crest's physical length with the proportion.This means 640 pixels in the image corresponds to 14.93 mm.So, for 1 m there are 42867 pixels.
The formula used for conversion is the following The vector components in the x-direction were selected with the MIN function which returns the minimum value of a column of data in MS Excel.Since the flow direction is -x, the vectors are negative.The values were then entered to a MATLAB script to calculate the velocity values.The returned value was double-checked if it is an outlier or not.This was done by inspecting its position and the neighbour vector lengths.The theoretical velocity versus calculated velocity results for different Reynolds numbers were tabulated and presented (See Table 1).Re is the Reynolds number, FPS is the frame-per-second rate, u x stands for the velocity vector length in the x-direction.V c is the calculated velocity of the flow and V t stands for the theoretical velocity of the flow due to mass flow rate.

Conclusion
The results show that using OpenPIV to analyze experimental findings highly depends on the image quality, especially when analysing turbulent and transitional flow.When the all velocity values are compared with the theoretical ones, one can say that the error increases as the flow becomes turbulent.The main reason for the error increment is the lack of vector fields around the top of the image due to the blurriness.To be able to analyse corrugated pipe flow with OpenPIV software, the illumination and seeding methods need to be changed.The accuracy of this software is mainly based on the illumination and seeding processes rather than the camera quality.

Visualization of flow inside the grooves
The flow was analysed by using region of interest (ROI) option and the visualization of the flow inside the groove for different Reynolds numbers were presented below.

Conclusions
In conclusion, OpenPIV was verified as promising open source PIV analysis software.The vorticity results came out to be slightly different for location but the magnitude of the vortices were agreed with the earlier study results when validation test was performed.The velocity analysis result does not follow a pattern.For laminar flow, the error is in between 5% and 22%.For transient case the error is in between, 4% and 22%.For turbulent flow, it is in between 3% and 38%.The reasons for that are probably related to the image quality and selection of seeding.The visualization experiment needs to be reconducted by using different seeding methods and illumination methods to obtain more accurate velocity vector fields.Also, the velocity was calculated by using a stopwatch so that the human reaction time delay should be taken into account while considering the error of the results.
The visualization of the images with OpenPIV provided a rough idea about the flow behaviour.When bulk flow results are considered, flow regimes could be identified based on the fluctuating velocity components with OpenPIV.When flow in the grooves are analysed, OpenPIV results provided sense of flow rotation in the grooves.

Figure 1 .
Figure 1.Schematic representation of flow domain

Figure 4 .
Figure 4. Vector field in spatial analysis toolbox

Figure 13 .
Figure 13.a) Non-processed image for turbulent flow with Re = 7340.02b) Non-processed image for transient flow with Re = 1483.92Thered circles show the hardest locations to analyse since there are no significant intensity points.As stated before, PIV technique works with the light intensity of

Table 1 .
Velocity analysis results for all Reynolds numbers