Thickness Measurement of Water Film/Rivulets Based on Grayscale Index

This study proposed a nonintrusive and cost-efficient technique to measure the thickness of a thin water film/rivulet based on the grayscale index. This technique uses millions of probes and only needs a digital camera, fill lights, and pigment. For water colored with diluted pigment, the grayscale index of the water captured by a digital camera depends on the water thickness. This relationship can be utilized to measure the water thickness through digital image processing. In the present study, the relationship between the grayscale index and water thickness was theoretically and experimentally investigated. Theoretical derivation revealed that when the product of water thickness and the color density approaches to 0, the grayscale index is inversely proportional to the thickness. The experimental results show that under the color density of 0.05%, the grayscale index is inversely proportional to the thickness of water film when the thickness is less than 6 mm. This linear relationship was utilized to measure the distribution and profile of a water rivulet flowing on the lower surface of a cable model.

Cobelli et al. [11] and Salvi et al. [13] described the principle of a structured light technique, which is an optical profilometric technique and mainly consists of a projector and a digital camera. In this technique, a fringe pattern of known characteristics is projected onto the test object and then recorded by a digital camera from a different direction. Since the registered fringe pattern is distorted by the object, the object's depth information can be derived from the deformed fringe pattern using information theory. Structured light techniques have been successfully employed for the topography of solid structures in a wide variety of fields, such as three-dimensional (3D) sensing Remote Sens. 2019, 11, 2871 3 of 14 widely used in crack identification [30], characterization of blood samples [31], and three-dimensional reconstruction [32]. In the proposed method, pigment was diluted in a water film, images of the water film were captured by a digital camera, and finally, the thickness distribution was identified based on the grayscale index of the water film. In the present study, the relationship between the grayscale index and water thickness was theoretically derived and experimentally validated. Both the theoretical and experimental results showed that for a thin colored water film, the water thickness is inversely proportional to the grayscale index. This linear relationship was then utilized to measure the distribution and profile of a water rivulet flowing on the lower surface of a cable model. The proposed method has great potential in quality inspection or three-dimensional reconstruction of small-size curved surface structures.

Theoretical Analysis
For a colored water film, the pigment is considered uniformly distribute in the water and the color density (q) is defined as the ratio of the pigment volume to the water volume, which is expressed as: where Q c is the pigment volume and Q w is the volume of water. As water is a transparent liquid, only the pigment elements are visible, and the other areas are blank. In a top view, as shown in Figure 1, the pigments in the top layer might overlap those in a lower layer. It is supposed that a water-soluble pigment will be utilized to color the water and the testing time is short; therefore, the sedimentation of pigment is negligible.
Remote Sens. 2019, 11, x FOR PEER REVIEW 3 of 14 advantages of the nonintrusion, nondestruction, multipoint measurement, high resolution, and cost-effectiveness have also been widely used in crack identification [30], characterization of blood samples [31], and three-dimensional reconstruction [32]. In the proposed method, pigment was diluted in a water film, images of the water film were captured by a digital camera, and finally, the thickness distribution was identified based on the grayscale index of the water film. In the present study, the relationship between the grayscale index and water thickness was theoretically derived and experimentally validated. Both the theoretical and experimental results showed that for a thin colored water film, the water thickness is inversely proportional to the grayscale index. This linear relationship was then utilized to measure the distribution and profile of a water rivulet flowing on the lower surface of a cable model. The proposed method has great potential in quality inspection or three-dimensional reconstruction of small-size curved surface structures.

Theoretical Analysis
For a colored water film, the pigment is considered uniformly distribute in the water and the color density (q) is defined as the ratio of the pigment volume to the water volume, which is expressed as: where c Q is the pigment volume and w Q is the volume of water.
As water is a transparent liquid, only the pigment elements are visible, and the other areas are blank. In a top view, as shown in Figure 1, the pigments in the top layer might overlap those in a lower layer. It is supposed that a water-soluble pigment will be utilized to color the water and the testing time is short; therefore, the sedimentation of pigment is negligible. To calculate the visible pigment in the top view, the water is uniformly divided into n layers and the thickness of each layer is defined as t Δ . Consequently, the pigment volume in each layer is calculated as q t Δ and the whole thickness of the water T is equal to n t Δ . When the number of layers, n , becomes very large and the thickness of each layer, t Δ , is very thin, the pigment in each layer can be treated as a uniform distribution without overlap. When considering the topmost layer 1 t , there is no overlap and the area without pigment in the top view is calculated as: To calculate the visible pigment in the top view, the water is uniformly divided into n layers and the thickness of each layer is defined as ∆t. Consequently, the pigment volume in each layer is calculated as q∆t and the whole thickness of the water T is equal to n∆t. When the number of layers, n, becomes very large and the thickness of each layer, ∆t, is very thin, the pigment in each layer can be treated as a uniform distribution without overlap.
When considering the topmost layer t 1 , there is no overlap and the area without pigment in the top view is calculated as: where BH is the area of the target water film. However, when considering the top two layers, some pigment in the lower layer becomes visible through the blank area of the topmost layer. Consequently, when only considering the top two layers, the area without pigment in the top view becomes: By this analogy, when considering the total n layers, the area without pigment in the top view is calculated as: Finally, the area of visible pigment in the top view is calculated as: As the thickness of each layer becomes very thin and the number of layers approaches infinity ( n → ∞ ), Equation (5) becomes equivalent to: Then, using the Taylor expansion and dividing by BH on both sides, Equation (6) is rewritten as: where S c (qT)/BH is the nondimensional area of the visible pigment in the top view, which varies with parameters q and T.
In the present study, a thin water film (T close to zero) is considered; therefore, the 2 nd and higher-order terms on the right-hand side of Equation (7) become negligible. It becomes: This equation indicates that under a certain density, q, the nondimensional area of visible pigment per unit area in the top view, S c (qT)/BH, can be simplified as a linear function of the water thickness. Figure 2 shows the relationship between the nondimensional area S c (qT)/BH and the water thickness T for different cases of q, as indicated in Equation (8). For all cases of q, the variation in S c (T)/BH has a similar tendency as that of S c (qT)/BH with increasing T, its rate of increase decreases when T increases, and finally, S c (T)/BH tends to 1.0. For cases with higher value of q, the curves have a higher rate of increase and S c (T)/BH reaches 1.0 at lower water thickness. Figure 2b confirms that the nondimensional area S c (qT)/BH linearly increases with the water thickness when the water film is thin.
As the color intensity is proportional to the visible pigment in per unit area, based on Equation (8), the color intensity should also linearly increase with the water thickness when the water film is thin. Consequently, in a digital image, the grayscale index I G of the water film is a function of the water thickness as follows: where a 0 is constant and a 1 is the slope of the grayscale index relative to the water thickness. Both a 0 and a 1 are sensitive to light condition considering the absorption and scattering of light. However, the influence of light condition on the parameters a 0 and a 1 is not investigated in the present study.
For an 8-bit grayscale image, the grayscale index I G varies in the range of 0 to 255. When the image is dark, I G is equal to 0, which represents the strongest grayscale intensity. When the image is white, I G is equal to 255, which represents the lowest grayscale intensity. As the grayscale index I G decreases with the grayscale intensity, the grayscale index I G decreases with the water thickness T and the slope, a 1 , should be negative. Equation (10) is the inverse of Equation (9): where b 0 = −a 0 a 1 , and b 1 = 1 a 1 . This equation indicates that the water thickness is inversely proportional to its grayscale index in digital images. The linear relationship in Equation (10) will be experimentally validated and the parameters, b 0 and b 1 , will be calibrated through experiments.
with parameters q and T .
In the present study, a thin water film (T close to zero) is considered; therefore, the 2 nd and higher-order terms on the right-hand side of Equation (7) become negligible. It becomes: This equation indicates that under a certain density, q, the nondimensional area of visible pigment per unit area in the top view, ( )/ c S qT BH , can be simplified as a linear function of the water thickness. Figure 2 shows the relationship between the nondimensional area ( )/ c S qT BH and the water thickness T for different cases of q, as indicated in Equation (8). For all cases of q, the variation in  As the color intensity is proportional to the visible pigment in per unit area, based on Equation (8), the color intensity should also linearly increase with the water thickness when the water film is thin. Consequently, in a digital image, the grayscale index G I of the water film is a function of the water thickness as follows: where 0 a is constant and 1 a is the slope of the grayscale index relative to the water thickness. Both When the image is dark, G I is equal to 0, which represents the strongest grayscale intensity. When the image is white, G I is equal to 255, which represents the lowest grayscale intensity. As the grayscale index G I decreases with the grayscale intensity, the grayscale index G I decreases with the water thickness T and the slope, 1 a , should be negative.
Equation (10) is the inverse of Equation (9): where This equation indicates that the water thickness is inversely proportional to its grayscale index in digital images. The linear relationship in Equation (10) will be experimentally validated and the parameters, 0 b and 1 b , will be calibrated through experiments. As the color intensity is proportional to the visible pigment in per unit area, based on Equation (8), the color intensity should also linearly increase with the water thickness when the water film is thin. Consequently, in a digital image, the grayscale index G I of the water film is a function of the water thickness as follows:

Experimental Setup
where 0 a is constant and 1 a is the slope of the grayscale index relative to the water thickness. Both When the image is dark, G I is equal to 0, which represents the strongest grayscale intensity. When the image is white, G I is equal to 255, which represents the lowest grayscale intensity. As the grayscale index G I decreases with the grayscale intensity, the grayscale index G I decreases with the water thickness T and the slope, 1 a , should be negative.
Equation (10) is the inverse of Equation (9): where This equation indicates that the water thickness is inversely proportional to its grayscale index in digital images. The linear relationship in Equation (10) will be experimentally validated and the parameters, 0 b and 1 b , will be calibrated through experiments. As the color intensity is proportional to the visible pigment in per unit area, based on Equation (8), the color intensity should also linearly increase with the water thickness when the water film is thin. Consequently, in a digital image, the grayscale index G I of the water film is a function of the water thickness as follows:

Experimental Setup
where 0 a is constant and 1 a is the slope of the grayscale index relative to the water thickness. Both When the image is dark, G I is equal to 0, which represents the strongest grayscale intensity. When the image is white, G I is equal to 255, which represents the lowest grayscale intensity. As the grayscale index G I decreases with the grayscale intensity, the grayscale index G I decreases with the water thickness T and the slope, 1 a , should be negative.
Equation (10) is the inverse of Equation (9): where This equation indicates that the water thickness is inversely proportional to its grayscale index in digital images. The linear relationship in Equation (10) will be experimentally validated and the parameters, 0 b and 1 b , will be calibrated through experiments. As the color intensity is proportional to the visible pigment in per unit area, based on Equation (8), the color intensity should also linearly increase with the water thickness when the water film is thin. Consequently, in a digital image, the grayscale index G I of the water film is a function of the water thickness as follows:

Experimental Setup
where 0 a is constant and 1 a is the slope of the grayscale index relative to the water thickness. Both When the image is dark, G I is equal to 0, which represents the strongest grayscale intensity. When the image is white, G I is equal to 255, which represents the lowest grayscale intensity. As the grayscale index G I decreases with the grayscale intensity, the grayscale index G I decreases with the water thickness T and the slope, 1 a , should be negative.
Equation (10) is the inverse of Equation (9): This equation indicates that the water thickness is inversely proportional to its grayscale index in digital images. The linear relationship in Equation (10) will be experimentally validated and the parameters, 0 b and 1 b , will be calibrated through experiments.

Experimental Setup
In this section, as shown in Figure 3, a special experimental setup is designed to verify the theoretical results and to calibrate the unknown parameters b 0 and b 1 . This experimental setup consists of a camera, two fill lights, and a water tank. The camera is fixed three meters above the water tank and takes pictures of the water film. Pigment is dissolved in the water film. The two fill lights are symmetrically located on both sides of the tank and are used to adjust the luminous intensity on the water surface. The camera, as shown in Figure 4, is a Canon 700D with a Tamron SP AF17-50 mm lens. The lens aperture is set constant as f/5.6, the shutter speed is set as 1/30 s, and the picture mode is set as a grayscale picture with 5184 × 3456 pixels. The fill lights are continuously adjustable and the luminous intensity is measured by an illuminometer (TES 1339R). The color density was chosen as 0.05%. As the pigment used in this study is a kind of black water-soluble ink and the testing time is short, the effect of pigment sedimentation is ignored.
The water tank is specially designed, as shown in Figure 5. It is 100 cm in length and 50 cm in width. The physical position in the tank is indicated by the coordinates x and y, with the origin at the top left corner. The bottom of the tank linearly rises from 0 to 1.0 cm from the left side to the right side. When the water tank is installed horizontally, the water thickness is proportional to the horizontal distance and the slope of the water thickness to the horizontal distance is 1/100. This means that the actual water thickness, T a (x), is a function of the coordinate x as follows: where x| T a =0 is the position of zero water thickness. A white paper with black grids, consisting of nine row black gridlines and nineteen column black gridlines, is attached on the lower side of the tank bottom to identify horizontal distance x and, consequently, the actual water thickness T a (x). The interval between the gridlines is 5 cm, as shown in Figure 6.
Before the tests, the luminous intensity on the bottom of the tank is measured, as shown in Figure 5a. The results show that the luminous intensity on the bottom of the tank is relatively uniform. The mean value and standard deviation are calculated as 78.8 Lux and 0.8 Lux, respectively. A white paper with black grids, consisting of nine row black gridlines and nineteen column black gridlines, is attached on the lower side of the tank bottom to identify horizontal distance x and, consequently, the actual water thickness ( ) a T x . The interval between the gridlines is 5 cm, as shown in Figure 6.
Before the tests, the luminous intensity on the bottom of the tank is measured, as shown in Figure 5a. The results show that the luminous intensity on the bottom of the tank is relatively uniform. The mean value and standard deviation are calculated as 78.8 Lux and 0.8 Lux, respectively.   A white paper with black grids, consisting of nine row black gridlines and nineteen column black gridlines, is attached on the lower side of the tank bottom to identify horizontal distance x and, consequently, the actual water thickness ( ) a T x . The interval between the gridlines is 5 cm, as shown in Figure 6.
Before the tests, the luminous intensity on the bottom of the tank is measured, as shown in Figure 5a. The results show that the luminous intensity on the bottom of the tank is relatively uniform. The mean value and standard deviation are calculated as 78.8 Lux and 0.8 Lux, respectively.     Figure 6 shows a raw image taken by the camera. The surroundings of the water tank have been cropped. In the water tank, it is obvious that the thicker water at the left side appears darker than the thinner water at the right side, which qualitatively coincides with the theoretical analyses. In the y direction, the grayscale intensity is uniform because the water has the same thickness. In addition, the water edge on the right side is clear and distinct.

Image Processing
To make the physical coordinate x only dependent on the column number and the physical coordinate y only dependent on the row number, the raw image is adjusted through perspective transformation [33], as shown in Figure 7. The horizontal and vertical gridlines are perpendicular to each other.   Figure 6 shows a raw image taken by the camera. The surroundings of the water tank have been cropped. In the water tank, it is obvious that the thicker water at the left side appears darker than the thinner water at the right side, which qualitatively coincides with the theoretical analyses. In the y direction, the grayscale intensity is uniform because the water has the same thickness. In addition, the water edge on the right side is clear and distinct.

Image Processing
To make the physical coordinate x only dependent on the column number and the physical coordinate y only dependent on the row number, the raw image is adjusted through perspective transformation [33], as shown in Figure 7. The horizontal and vertical gridlines are perpendicular to each other.  Figure 6 shows a raw image taken by the camera. The surroundings of the water tank have been cropped. In the water tank, it is obvious that the thicker water at the left side appears darker than the thinner water at the right side, which qualitatively coincides with the theoretical analyses. In the y direction, the grayscale intensity is uniform because the water has the same thickness. In addition, the water edge on the right side is clear and distinct.

Image Processing
To make the physical coordinate x only dependent on the column number and the physical coordinate y only dependent on the row number, the raw image is adjusted through perspective transformation [33], as shown in Figure 7. The horizontal and vertical gridlines are perpendicular to each other. Six bunches of data (see r1 to r6 in Figure 7) are extracted from the adjusted digital image to verify the linear relationship in Equation (10) and to calibrate the unknown parameters, b0 and b1. Each bunch has approximately 310×3100 pixels. They are separated into three segments as follows: S1 is the water film segment, which is entirely covered by the water film; S2 is the edge segment, which is partially covered; and S3 is the background segment which is totally blank. In each bunch, the grayscale index of the pixels in the same column is averaged because their water thickness is the same.
The relationship between the grayscale index and the horizontal coordinate x of r3 is shown by the blue line in Figure 8. The minimums in the blue line represent the black gridlines, which have a much lower grayscale index (stronger grayscale intensity) and can simply be removed. In S1, the grayscale index clearly increases with the horizontal distance. In particular, when the horizontal distance x is in the range of 40 to 80 cm, the grayscale index linearly increases with the horizontal distance x and consequently linearly decreases as the water thickness increases. The data in S2 has been deleted because it contains both, as shown in Figure 7. In S3, the grayscale index is nearly constant at an average value of 175, which is the grayscale index of the background. At the edge of the water film, in S2, the water film has a cambered surface due to surface tension. This means that the water thickness at the water edge and the corresponding horizontal coordinate x do not comply with the same linear relationship as that in S1. The parameter in Equation (11) Six bunches of data (see r1 to r6 in Figure 7) are extracted from the adjusted digital image to verify the linear relationship in Equation (10) and to calibrate the unknown parameters, b0 and b1. Each bunch has approximately 310 × 3100 pixels. They are separated into three segments as follows: S1 is the water film segment, which is entirely covered by the water film; S2 is the edge segment, which is partially covered; and S3 is the background segment which is totally blank. In each bunch, the grayscale index of the pixels in the same column is averaged because their water thickness is the same.
The relationship between the grayscale index and the horizontal coordinate x of r3 is shown by the blue line in Figure 8. The minimums in the blue line represent the black gridlines, which have a much lower grayscale index (stronger grayscale intensity) and can simply be removed. In S1, the grayscale index clearly increases with the horizontal distance. In particular, when the horizontal distance x is in the range of 40 to 80 cm, the grayscale index linearly increases with the horizontal distance x and consequently linearly decreases as the water thickness increases. The data in S2 has been deleted because it contains both, as shown in Figure 7. In S3, the grayscale index is nearly constant at an average value of 175, which is the grayscale index of the background. Six bunches of data (see r1 to r6 in Figure 7) are extracted from the adjusted digital image to verify the linear relationship in Equation (10) and to calibrate the unknown parameters, b0 and b1. Each bunch has approximately 310×3100 pixels. They are separated into three segments as follows: S1 is the water film segment, which is entirely covered by the water film; S2 is the edge segment, which is partially covered; and S3 is the background segment which is totally blank. In each bunch, the grayscale index of the pixels in the same column is averaged because their water thickness is the same.
The relationship between the grayscale index and the horizontal coordinate x of r3 is shown by the blue line in Figure 8. The minimums in the blue line represent the black gridlines, which have a much lower grayscale index (stronger grayscale intensity) and can simply be removed. In S1, the grayscale index clearly increases with the horizontal distance. In particular, when the horizontal distance x is in the range of 40 to 80 cm, the grayscale index linearly increases with the horizontal distance x and consequently linearly decreases as the water thickness increases. The data in S2 has been deleted because it contains both, as shown in Figure 7. In S3, the grayscale index is nearly constant at an average value of 175, which is the grayscale index of the background. At the edge of the water film, in S2, the water film has a cambered surface due to surface tension. This means that the water thickness at the water edge and the corresponding horizontal coordinate x do not comply with the same linear relationship as that in S1. The parameter in Equation (11) At the edge of the water film, in S2, the water film has a cambered surface due to surface tension. This means that the water thickness at the water edge and the corresponding horizontal coordinate x do not comply with the same linear relationship as that in S1. The parameter in Equation (11), x| T a =0 , needs to be identified.

Identification of x| T a =0
The data in S1 validated the linear relationship derived from the theoretical analyses. The water thickness and the grayscale index comply with the same linear function when the coordinate x is larger than 40 cm and less than x| T a =0 . Consequently, the parameter x| T a =0 can be obtained by linearly extending the linear fitting curve (see the purple dashed line in Figure 8) until the grayscale index reaches the mean value of S3. Figure 8 shows an example of x| T a =0 identification using the r3 data. x| T a =0 is identified as 107.1 cm at the intersection of the purple dashed and the red dash-dotted lines.
Finally, by substituting x| T a =0 into Equation (11), the actual water thickness T a along the coordinate x is calculated as: T a (x) = −(x − 107.1)/100 (12)

Calibration Results
According to Equation (11), the water thickness of each pixel is calculated based on its horizontal coordinate, x. The relationship between the water thickness and the grayscale index is investigated in this subsection.
The six bunches of data from Figure 7 are very close, as shown in Figure 9. When the water film is less than 6 mm, the grayscale intensity obviously and linearly increases as the water thickness increases. The rate of increase begins to decrease when the water thickness is deeper than 6 mm. This tendency agrees well with the theoretical analyses. These findings verified that the grayscale intensity is linearly related to the water thickness when the water film is thin.
Finally, by substituting 0 | a T x = into Equation (11), the actual water thickness a T along the coordinate x is calculated as:

Calibration Results
According to Equation (11), the water thickness of each pixel is calculated based on its horizontal coordinate, x. The relationship between the water thickness and the grayscale index is investigated in this subsection.
The six bunches of data from Figure 7 are very close, as shown in Figure 9. When the water film is less than 6 mm, the grayscale intensity obviously and linearly increases as the water thickness increases. The rate of increase begins to decrease when the water thickness is deeper than 6 mm. This tendency agrees well with the theoretical analyses. These findings verified that the grayscale intensity is linearly related to the water thickness when the water film is thin.
The data in the range of 1.7 mm to 6 mm are then linearly fitted, as shown by the purple dashed line in Figure 9. The formula is: The goodness of fit, When Equation (14) is adopted to measure the water thickness, the resolution is 0.091 mm and the measurement range is 6 mm. The resolution and range can be improved by using a higher grayscale or higher color density.  The data in the range of 1.7 mm to 6 mm are then linearly fitted, as shown by the purple dashed line in Figure 9. The formula is:

Measurement of the Profile of a Water Rivulet Flowing on a Cable Surface
The goodness of fit, R 2 , is calculated as 0.99, indicating a good linear relation between I G and T. The linear range should be approximately 0 to 6 mm. These experimental tests verified that the grayscale intensity linearly decreases with the water thickness when the water film is thin and calibrated a0 and a1 as 175 and −11, respectively. Equation (13) is rewritten as: When Equation (14) is adopted to measure the water thickness, the resolution is 0.091 mm and the measurement range is 6 mm. The resolution and range can be improved by using a higher grayscale or higher color density.

Measurement of the Profile of a Water Rivulet Flowing on a Cable Surface
The theoretical analyses and experimental results validated that for a thin colored water film, the grayscale index linearly decreases as the water thickness increases. The water thickness can be detected by the grayscale index based on their linear relationship. In this section, the profile of a water rivulet flowing on a cable surface is measured, which is a factor of interest in the field of rain-wind induced cable vibration. Figure 10 shows the experimental setup. A segment of polyvinyl chloride pipe is fixed on an inclined aluminum rod to simulate an inclined stay cable. A plastic pipe is installed to guide the colored water to the upper end of the cable model. Due to the influence of gravity, the water could flow along the cable surface to the lower end [34], as shown in Figure 10. The flowing water simulates the lower water rivulet. A fill light is equipped to adjust the luminous intensity. The measurement area is highlighted on the cable surface as shown in Figure 10. The longitudinal distance, y c , and the circumferential distance, x c , are indicated by black marks.
Remote Sens. 2019, 11, x FOR PEER REVIEW 11 of 14 Figure 10. Setup for water rivulet measurement. Figure 10. Setup for water rivulet measurement. Figure 11 shows a raw image of the water rivulet recorded by a digital camera. It shows that the water rivulet is relatively uniform in the longitudinal direction. In the circumferential direction, it is thicker in the centerline and thinner on both sides. Consequently, the present study mainly focuses on the section profile of the water rivulet. Figure 12a shows the measured grayscale index varying with the circumferential coordinate. It is worth noting that the lens aperture, luminous intensity, and incident angle are not the same as those adopted in Section 3. Consequently, the parameters b0 and b1 identified in Section 3 are inapplicable here. In this section, the parameter b0 is eliminated by subtracting the grayscale index of the background. The grayscale index of the background increases with the circumferential coordinate and it can be well fitted using a quadratic polynomial formula. The dashed purple line in Figure 12a represents the grayscale index of the background. Figure 12b shows the grayscale index without the effect of the background.    The parameter b1 is calibrated by setting the shadow area, S m , which is referred to as the measured sectional area, equal to the actual sectional area of the water rivulet, S a . This kind of calibration method was used by Jing et al. [6].
The measured sectional area is calculated as 121.3 mm, through numerical integration as follows [6]: where W is the width of the water rivulet and x c is the circumferential coordinate. The actual sectional area of the water rivulet S a is calculated as 1.44 mm 2 through the following equation [6]: where V a is the flow rate, which is calculated as 0.072 ml/s by testing the water volume flowing out of the plastic pipe in unit time, and v is the flow speed calculated as 0.05 m/s by a high-speed video. Finally, the parameter b 1 is calculated as −0.012 mm. When multiplied by b 1 , the data in Figure 12b become the cross profile of the water rivulet, as shown in Figure 13. The form line of the cross-section of the water rivulet is close to a parabola. The water thickness is approximately 0.25 mm at the center and the width of the water rivulet is approximately 9 mm.

Conclusions
This study proposed a digital image processing method to measure the thickness of a water film based on the grayscale index. Theoretical and experimental investigations were conducted to reveal the relationship between the thickness of a colored water film and its grayscale index captured by a digital camera. Finally, the profile of a water rivulet flowing on a cable surface was measured using this method. The main conclusions are drawn as follows: (1) theoretical derivation show that the grayscale index is inversely proportional to the water thickness when the product of water film thickness and color density is close to 0; (2) experimental results show that under the color density of 0.05%, the grayscale index is inversely proportional to the thickness of water film when the thickness is less than 6 mm; (3) the profile of a water rivulet on a cable surface was measured by assuming that its thickness was thin and the color density was low. It shows that the thickness of the water rivulet was approximately 0.25 mm, and the width was approximately 9 mm. The measured form line of the water rivulet was close to a parabola. However, it is worth noting that the proposed method is more effective in the lab compared with that in the field conditions because the light in field conditions is hard to control. As it is very difficult to simultaneously measure a thin water film under such complicated conditions using other methods, the measurement accuracy of the proposed method will be further investigated through comparison with other methods in a simpler condition in the future.

Conclusions
This study proposed a digital image processing method to measure the thickness of a water film based on the grayscale index. Theoretical and experimental investigations were conducted to reveal the relationship between the thickness of a colored water film and its grayscale index captured by a digital camera. Finally, the profile of a water rivulet flowing on a cable surface was measured using this method. The main conclusions are drawn as follows: (1) theoretical derivation show that the grayscale index is inversely proportional to the water thickness when the product of water film thickness and color density is close to 0; (2) experimental results show that under the color density of 0.05%, the grayscale index is inversely proportional to the thickness of water film when the thickness is less than 6 mm; (3) the profile of a water rivulet on a cable surface was measured by assuming that its thickness was thin and the color density was low. It shows that the thickness of the water rivulet was approximately 0.25 mm, and the width was approximately 9 mm. The measured form line of the water rivulet was close to a parabola. However, it is worth noting that the proposed method is more effective in the lab compared with that in the field conditions because the light in field conditions is hard to control.