Laser Fluorescence and Extinction Methods for Measuring the Flow and Composition of Milk in a Milking Machine

: Automation of milking systems is linked to accurate measurement of ﬂuctuations in milk ﬂow during milking. To assess the ﬂuctuations of the milk ﬂow, the formation and movement of milk portions in the milking machine-milk pipeline system was studied. By considering the movement of a milk plug along the milk pipeline, a hydraulic model of the formation of a critical volume of milk in the milking machine manifold was compiled. In practice, the most expedient way of determining milk ﬂow parameters may be to measure the laser ﬂuorescent and extinction responses of moving air-milk mixture. We have implemented a new laser sensing method for measuring the ﬂow rate and composition of milk on the basis of counting the optical response pulses received from moving dispersed components by a CCD array or a randomized ﬁber optic bundle. Using the developed laser sensors, the theoretical model of milk ﬂow was tested.


Introduction
The study of milk flow fluctuations during milking is of scientific and practical interest in order to accurately measure them for automating the control of milking machines operation modes. In addition, an essential physiological aspect is the control of the end of the milking process in order to exclude overexposure of the teat cups and the harmful effect of vacuum pressure on the animal. At the same time, it is important to minimize the duration of determining the parameters of milk flow, at which the timely switching off and removal of the milking machine should be performed.
Optical methods for monitoring flow inhomogeneities and composition of multiphase liquid media are promising, since they have high sensitivity and speed, and can also carry out non-contact and non-destructive diagnostics [1][2][3][4][5][6][7][8][9][10][11][12][13][14]. Since it is recommended to use devices for measuring milk flow that do not cause a significant pressure drop in the milk hose, optical diagnostic methods can improve the efficiency of the farm equipment. Among them, fluorescence methods should be especially noted as having high selectivity [10][11][12], as well as light scattering methods [4][5][6][7][8] and methods for measuring optical extinction [13,14] as completely relevant for dispersed media, which represent a random collection of small particles. In the case of milk, these are micelles of caseins and fat globules.
Due to the inertia of chamber flow meters, direct flow meters are increasingly used, for example, the FFS30 infrared milk sensor from SCR (Netanya, Israel) [15] or meters with contact electrodes [16,17]. The simultaneous measurements of milk yield and the component composition of milk (fat, protein, lactose, etc.) are necessary for determining the productivity and quality of animal milk [18,19]. At the present time, there is no system that provides simultaneous measurement of both the flow rate and the composition of milk in one device. Most modern farms have only a flow meter installed in the milking machine, while the milk quality analyzer is a separate sample analyzer or samples are sent to specialized laboratories for quality analysis. Methods using NIR analyzers with more advanced data processing algorithms are being developed and improved [20][21][22]. So far, only one system is known that provides a simultaneous analysis of the quality and measurement of milk yield, including a combination of rather complicated devices in operation [23,24]. Thus, the current trend in milking automation is to increase the functionality of milk meters by combining measurements of quantitative (flow rate, milk yield) and qualitative characteristics of milk flow (fat, protein, lactose, etc.), which are recommended to be carried out using the same physical principles, mainly optical spectrometry [25].
It should be borne in mind that since milk contains dissolved air and an ionic component, long-lived ion-stabilized nanobubbles must be present in it [26]. In addition, shear stresses in air-saturated milk lead to the formation of both microbubbles and macrobubbles during transportation in a milk pipeline [27][28][29][30][31]. Thus, it turns out that the milk moving in the pipeline of a milking machine is actually a milk-air mixture. Moreover, the operation of the milking machine in the mode of milk plugs should be particularly considered, when the milk is separated by continuous air gaps in the milk pipeline.
The complexity of the movement of milk-air mixture in the hose of a milking machine and the time limitation cause certain difficulties in measuring a portion of milk when it moves in the flow. Therefore, it is necessary to define a model for estimating milk flow parameters and study the variances of these parameters.
It is important to note that in the process of express assessment of milk quality directly on the farm, specialists are primarily interested in abnormal deviations of the measured milk components in order to take appropriate preventive measures for feeding or treating animals. A more accurate periodic assessment can be carried out already in biochemical laboratories.
In this work, we investigated the processes of transporting milk flows in milking machines in order to find out the possibility of simultaneous measurement of the flow rate, quantity and component composition of milk.

Methods
For measuring milk flow, international standard ISO 5707 Milking machine installations -Construction and performance recommends using certified devices that cause a pressure drop of no more than +3 kPa and have an error of no more than +5% [32,33]. In milking robots, it is required to control the rate of milk flow by a quarter, which actualizes the creation of small-sized high-precision sensors. The main criteria for assessing the studied parameters of the milk flow can be attributed to: the speed of movement of the milk portion V m (m/s) and its length l (m), the filling factor of the free section of the hose with milk k f (%), the volumetric concentration of air bubbles in 1 cm 3 of the milk portion n ab , the size of the air bubbles d ab (µm), the particle size of the milk constituents (fat, protein, lactose) d p (µm), the discreteness of scanning the sections of the milk plug along the length ∆l (m) and in time ∆t (s). It is obvious that the full functional of the requirements for hybrid milk flow sensors and milk composition can be written as follows: To estimate the parameters of milk flow theoretically, we propose a model of the formation and movement of milk portions in the system: milking machine-milk pipeline, considering it as a capacitive flow-through hydraulic system with preliminary accumulation of a certain critical volume of milk W m cr (Figure 1), which consists of two components: the volume of milk in the collector W m c and the volume of milk in the milk hose W m h , corresponding to the arc length ∆l h (Equation (2)). Due to the difference in the flow rates of milk (I m ) and air (q a ), a milk plug is formed. To estimate the parameters of milk flow theoretically, we propose a model of the formation and movement of milk portions in the system: milking machine-milk pipeline, considering it as a capacitive flow-through hydraulic system with preliminary accumulation of a certain critical volume of milk ( Figure 1), which consists of two components: the volume of milk in the collector and the volume of milk in the milk hose , corresponding to the arc length Δ (Equation (2)). Due to the difference in the flow rates of milk ( ) and air ( ), a milk plug is formed. Under the influence of the resulting pressure drop, the milk plug begins to move along the milk hose into the milk line ( Figure 2). Expression for the volume of milk in the manifold is: where is the diameter of the milk chamber of the collector (m), ℎ is the critical milk level in the collector (m). Taking into account the parameters of the hose, we have: Under the influence of the resulting pressure drop, the milk plug begins to move along the milk hose into the milk line ( Figure 2). where … are the corresponding functionals: milk flow rates, error relativity, vacuum pressure stability, sampler, milk component composition (fat, protein, lactose, etc.); ∧, ⊻ are logical operators.
To estimate the parameters of milk flow theoretically, we propose a model of the formation and movement of milk portions in the system: milking machine-milk pipeline, considering it as a capacitive flow-through hydraulic system with preliminary accumulation of a certain critical volume of milk ( Figure 1), which consists of two components: the volume of milk in the collector and the volume of milk in the milk hose , corresponding to the arc length Δ (Equation (2)). Due to the difference in the flow rates of milk ( ) and air ( ), a milk plug is formed. Under the influence of the resulting pressure drop, the milk plug begins to move along the milk hose into the milk line ( Figure 2). Expression for the volume of milk in the manifold is: where is the diameter of the milk chamber of the collector (m), ℎ is the critical milk level in the collector (m). Taking into account the parameters of the hose, we have: Expression for the volume of milk in the manifold is: where d c is the diameter of the milk chamber of the collector (m), h cr c is the critical milk level in the collector (m). Taking into account the parameters of the hose, we have: where h cr h is the critical milk level in the hose (m), z is the difference in height between the lowest point of the collector and the hose (m). The critical volume of milk in the hose can be written by analogy as: is the hose bend radius, α is the center angle corresponding to the hose arc ∆l h . Thus, expression (5) will be written as follows: Finally, expression (2) takes the form: Next, consider the scheme of the steady-state movement of the milk flow in the hose of the milking machine ( Figure 2). For the plug mode, we will use the well-known equation of motion of the milk plug [34], which in the transformed form is written as: where V is the speed of the milk plug (m/s); p 1 , p 2 is the pressure difference on the plug from below and from above, Pa; l is the plug length (m); α is correction for the amount of motion; β is the angle of inclination of the hose (degrees); ρ is the density of the milk-air mixture (kg/m 3 ); d is the diameter of the milk hose (m); λ is coefficient of hydraulic resistance of the milk hose, g is the acceleration of gravity. The steady-state mode of movement is characterized by the constancy of the milk flow rate in a certain area, where it is advisable to place the milk flow sensor, while the first term on the right side of Equation (8) vanishes and the expression will be rewritten as follows: Solving (9) with respect to V leads to the formula: where ∆p = p 1 − p 2 is the pressure difference at the ends of the plug.
Considering that the plug has the shape of a cylinder, its length can be determined through the value of the critical volume of milk W m cr : Taking into account Equation (11), expression (10) for the theoretical speed of the milk plug can be rewritten as: Knowing the parameters of the pumping system used in the milking machine, the derived formula allows us to calculate the theoretical speed of the milk plug. The calculated value of the milk plug velocity can be extrapolated to the velocity of the entire pulsating milk-air flow and then the theoretical calculation can be compared with the value of the flow velocity measured in the experimental setup by an optical method.
Obviously, the W m cr value will vary for different types of milking machines, having a significant effect on the speed and length of milk plugs. At the same time, fluctuations of the density of the milk-air mixture ρ depending on the milk flow rate, contamination of milk-air flows can be, according to various estimates, from 0.5 to . . . 0.94 kg/L, having a significant effect on the accuracy of measuring the mass flow of milk [35]. It is quite difficult to theoretically estimate the air saturation indicators of the milk plug due to the strong variation in the indicators of milk flow rate, pressure drop and air flow rate. Therefore, the most appropriate way to solve this problem can be the use of optical spectroscopy methods with measuring the scattering angles of a moving liquid saturated with air bubbles.
Let us consider a schematic diagram of measuring the speed of the movement of a milk plug with steady motion on a segment of hose with a length of ∆l ( Figure 3). Knowing the parameters of the pumping system used in the milking machine, the derived formula allows us to calculate the theoretical speed of the milk plug. The calculated value of the milk plug velocity can be extrapolated to the velocity of the entire pulsating milk-air flow and then the theoretical calculation can be compared with the value of the flow velocity measured in the experimental setup by an optical method.
Obviously, the value will vary for different types of milking machines, having a significant effect on the speed and length of milk plugs. At the same time, fluctuations of the density of the milk-air mixture depending on the milk flow rate, contamination of milk-air flows can be, according to various estimates, from 0.5 to ... 0.94 kg/L, having a significant effect on the accuracy of measuring the mass flow of milk [35]. It is quite difficult to theoretically estimate the air saturation indicators of the milk plug due to the strong variation in the indicators of milk flow rate, pressure drop and air flow rate. Therefore, the most appropriate way to solve this problem can be the use of optical spectroscopy methods with measuring the scattering angles of a moving liquid saturated with air bubbles.
Let us consider a schematic diagram of measuring the speed of the movement of a milk plug with steady motion on a segment of hose with a length of ∆ ( Figure 3). We denote the moments when the bow part of the milk plug passes the initial and final sections, respectively: and . With a small assumption, taking into account the low compressibility (extensibility) of the milk plug, we can accept the equality of the velocities of the bow part and the stern part of the milk plug: Formula (13) can be used to experimentally determine the flow rate by detecting the moments of entry and exit of a milk plug from the pipe segment at the ends of which optical detectors are placed. Then the actual parameters of the milk plug (length, volume, mass) and flow rate can be determined by the known expressions: where , are, respectively, the moments of the beginning and the end of the passage of the milk plug of the initial point of the controlled section of the hose.
It should be noted that the method for measuring milk flow using the transit time of the milk plug is known and previously implemented, for example, in [36], while we propose new laser sensing methods based on the discreteness of the milk components. We denote the moments when the bow part of the milk plug passes the initial and final sections, respectively: t 1 and t 2 . With a small assumption, taking into account the low compressibility (extensibility) of the milk plug, we can accept the equality of the velocities of the bow part V b pl and the stern part V s pl of the milk plug: Formula (13) can be used to experimentally determine the flow rate by detecting the moments of entry and exit of a milk plug from the pipe segment at the ends of which optical detectors are placed. Then the actual parameters of the milk plug (length, volume, mass) and flow rate q m can be determined by the known expressions: where t s 1 , t e 1 are, respectively, the moments of the beginning and the end of the passage of the milk plug of the initial point of the controlled section of the hose.
It should be noted that the method for measuring milk flow using the transit time of the milk plug is known and previously implemented, for example, in [36], while we propose new laser sensing methods based on the discreteness of the milk components.
To measure milk flow parameters, we applied laser fluorescence and extinction methods, which have been implemented in experimental setups with the use of diode lasers, laser beam rasterization, array photodetectors, and multichannel fiber-optic bundles. Information signals were recorded by a digital oscilloscope. Fiber optic probe structures have been optimized for biological fluids, including dairy products, in terms of radiation intensity and signal-to-noise ratio.

Results
We developed two experimental setups that exhibit the principles of laser fluorescence and extinction for measuring the flow rate and composition of the milk in a milking machine. The measurements of the milk flow velocity were compared with theoretical estimates using the Formula (12).
The influence of air bubbles on the characteristics of milk flow in milking machines was studied experimentally using laser-induced fluorescence method (Figure 4). The setup (Figure 4) employs semiconductor lasers operating at a wavelength of 405 nm and a TCD1304DG CCD linear image sensor (Toshiba, Tokyo, Japan). lasers, laser beam rasterization, array photodetectors, and multichannel fiber-optic bundles. Information signals were recorded by a digital oscilloscope. Fiber optic probe structures have been optimized for biological fluids, including dairy products, in terms of radiation intensity and signal-to-noise ratio.

Results
We developed two experimental setups that exhibit the principles of laser fluorescence and extinction for measuring the flow rate and composition of the milk in a milking machine. The measurements of the milk flow velocity were compared with theoretical estimates using the Formula (12).
The influence of air bubbles on the characteristics of milk flow in milking machines was studied experimentally using laser-induced fluorescence method (Figure 4). The setup (Figure 4) employs semiconductor lasers operating at a wavelength of 405 nm and a TCD1304DG CCD linear image sensor (Toshiba, Tokyo, Japan). To obtain a narrow spatial distribution of the laser beam, we use a raster consisting of a sequence of metal strips deposited on optically transparent glass with equal intervals between them. The raster design is shown in Figure 5. To obtain a narrow spatial distribution of the laser beam, we use a raster consisting of a sequence of metal strips deposited on optically transparent glass with equal intervals between them. The raster design is shown in Figure 5. To obtain a narrow spatial distribution of the laser beam, we us of a sequence of metal strips deposited on optically transparent glass between them. The raster design is shown in Figure 5. We employed two replaceable rasters with a stripe width of 1 These rasters were attached to an opaque base with a 1 mm hole in t We employed two replaceable rasters with a stripe width of 100 and 200 micron. These rasters were attached to an opaque base with a 1 mm hole in the center to narrow the laser beam aperture. The laser beam passed first the hole and then the raster, so that the transverse distribution of the laser beam intensity got rectangular shape, and thus the laser-irradiated area had a narrow width of~100 microns and sharp boundaries. The raster is left-aligned with a bandpass filter as milk flows from left to right in the diagram shown. This alignment is necessary to record the spatial profile of the fluorescence signal from the portions of milk moving from left to right. The fact is that the fluorescence does not decay immediately and the milk particles excited by the UV laser at the beginning of the CCD array still continue to emit light after passing a distance of~1000 CCD pixels.
The CCD has 3648 pixels. Actually, not all of the CCD pixels are used. The CCD length is 29 mm and the filter length is 19 mm. Thus, only about 2400 are in use. We deliberately do not use the entire length of the CCD, because on the one hand, the initial pixels may not work distinctly, and on the other hand, the distribution of the fluorescence signal along the CCD has a width of no more than about 2000, so the remaining pixels are not required. Below we show a photograph of the setup (Figure 6), the scheme of which is shown above in Figure 4.
Initial experimental results showed that the fluorescent response propagates and is fixed at distances of up to 20 mm along the length of the milk tube in the sensor (Figure 7). With the passage of air bubbles, a clearly visible change in the slope of the fluorescence intensity distribution along the pipe is observed. The X-axis is the pixel numbers of the CCD array. Pixel pitch is 0.008 mm. Pixel range 500 to 3000 corresponds to 20 mm distance along the milk pipeline.
It can be assumed that the small peaks on the fluorescent signal distribution curves (Figure 7) exhibit dispersed milk components, presumably fat globules.
The study of milk-air mixture movement along the milk pipeline by the optical extinction method in the spectral range of 800-850 nm showed that the use of randomized multichannel fiber optic bundles enables the determination of fluctuations in the milk flow. A schematic of the experimental setup is shown in Figure 8. An important feature of the multichannel fiber optic bundles is mixing optical modes, which eliminates the appearance of speckles and heat transfer from the laser heated during operation to the milk pipe.
The CCD has 3648 pixels. Actually, not all of the CCD pixels are used. The CCD length is 29 mm and the filter length is 19 mm. Thus, only about 2400 are in use. We deliberately do not use the entire length of the CCD, because on the one hand, the initial pixels may not work distinctly, and on the other hand, the distribution of the fluorescence signal along the CCD has a width of no more than about 2000, so the remaining pixels are not required. Below we show a photograph of the setup (Figure 6), the scheme of which is shown above in Figure 4. Initial experimental results showed that the fluorescent response propagates and is fixed at distances of up to 20 mm along the length of the milk tube in the sensor ( Figure  7). With the passage of air bubbles, a clearly visible change in the slope of the fluorescence intensity distribution along the pipe is observed. The X-axis is the pixel numbers of the CCD array. Pixel pitch is 0.008 mm. Pixel range 500 to 3000 corresponds to 20 mm distance along the milk pipeline. It can be assumed that the small peaks on the fluorescent signal distribution curves (Figure 7) exhibit dispersed milk components, presumably fat globules.
The study of milk-air mixture movement along the milk pipeline by the optical extinction method in the spectral range of 800-850 nm showed that the use of randomized multichannel fiber optic bundles enables the determination of fluctuations in the milk flow. A schematic of the experimental setup is shown in Figure 8. An important feature of the multichannel fiber optic bundles is mixing optical modes, which eliminates the appearance of speckles and heat transfer from the laser heated during operation to the milk pipe. The experimental setup (Figures 8 and 9) provides an imitation of the milking machine operation due to the bubble generator. The milk flow in the milk pipe is not constant, but a succession of air and milk parts of unequal size. The elements 6 and 8 constitute together a fiber optic based optocoupler. Accordingly, the receiver 8 measures the extinction of the intensity of the laser source 6 after passing across the tube in which the milk flows. The optical extinction during the passage of dispersed milk components through the laser beam has the form of short pulses in time. The highest pulses on the oscillograms are obviously given by fat globules as they are the largest among other milk components and most attenuate the light beam. Since we are dealing with a moving milk-air mixture, the flow of milk is not continuous but fragmented by air gaps (large bubbles). During the passage of a large bubble that approached 8, the receiver 8 stops measuring extinction pulses from small particles of milk (specifically, fat globules) and serves in conjunction with the receiver 7 to detect the number of bubbles passing per unit time. The reference signal coming from the receiver 8 has a double function. First, it is necessary for analyzing the composition of milk by detecting pulses of extinction from dispersed components in the milk plug, primarily fat globules, in order to thus determine the fat content in milk. In addition, assuming that the speed of the milk plug is proportional to the number of pulses per second, the milk flow velocity can be evaluated. Second, it can detect the moment of arrival of large bubbles, which are essentially air gaps in the milk flow. At the same time, the receiver 7 can be used to detect the moment when the bubble passed the distance between 7 and 8; and, in turn, from the bubble transit time, the speed of the entire air-milk flow can be also determined. It can be assumed that the small peaks on the fluorescent signal distribution curves (Figure 7) exhibit dispersed milk components, presumably fat globules.
The study of milk-air mixture movement along the milk pipeline by the optical extinction method in the spectral range of 800-850 nm showed that the use of randomized multichannel fiber optic bundles enables the determination of fluctuations in the milk flow. A schematic of the experimental setup is shown in Figure 8. An important feature of the multichannel fiber optic bundles is mixing optical modes, which eliminates the appearance of speckles and heat transfer from the laser heated during operation to the milk pipe. The experimental setup (Figures 8 and 9) provides an imitation of the milking machine operation due to the bubble generator. The milk flow in the milk pipe is not constant, but a succession of air and milk parts of unequal size. The elements 6 and 8 constitute together a fiber optic based optocoupler. Accordingly, the receiver 8 measures the extinction of the intensity of the laser source 6 after passing across the tube in which the milk flows. The optical extinction during the passage of dispersed milk components through the laser beam has the form of short pulses in time. The highest pulses on the oscillograms are obviously given by fat globules as they are the largest among other milk components and most attenuate the light beam. Since we are dealing with a moving milk-air mixture, the flow of milk is not continuous but fragmented by air gaps (large bubbles). During the passage of a large bubble that approached 8, the receiver 8 stops measuring extinction pulses from small particles of milk (specifically, fat globules) and serves in conjunction with the receiver 7 to detect the number of bubbles passing per unit time. The reference signal coming from the receiver 8 has a double function. First, it is necessary for analyzing the composition of milk by detecting pulses of extinction from dispersed components in the milk plug, primarily fat globules, in order to thus determine the fat content in milk. In addition, assuming that the speed of the milk plug is proportional to the number of pulses per second, the milk flow velocity can be evaluated. Second, it can detect the moment of arrival of large bubbles, which are essentially air gaps in the milk flow. At the same time, the receiver 7 can be used to detect the moment when the bubble passed the distance between 7 and 8; and, in turn, from the bubble transit time, the speed of the entire air-milk flow can be also determined. Experiments with raw milk using the setup (Figures 8 and 9) showed that the passage of large fat globules can be recorded by reading the optical signal from the fiber optic bundle of the receiver 8 ( Figure 10). Experiments with raw milk using the setup (Figures 8 and 9) showed that the passage of large fat globules can be recorded by reading the optical signal from the fiber optic bundle of the receiver 8 ( Figure 10). Figure 9. Photograph of the laser extinction sensor based on multichannel fiber-optic bundles shown schematically in Figure 8.
Experiments with raw milk using the setup (Figures 8 and 9) showed that the passage of large fat globules can be recorded by reading the optical signal from the fiber optic bundle of the receiver 8 ( Figure 10). The response pulses should be counted at a threshold discrimination of non-informative noise. As can be seen from the oscillograms of recorded signals (Figure 10), smallsized impulse emissions most likely correspond to optical extinction on small fat globules, and sharp peaks in the minus region are mainly associated with the presence of large fat globules. When milk moves along the milk pipe, these minus peaks change the frequency of their appearance.
Based on the recorded waveforms (similar to those in Figure 10), we have plotted a graph (Figure 11) that illustrates a direct correlation between the flow velocity and the frequency of negative pulses in discrete extinction pattern of the flowing milk. Experimental values of were obtained by counting the number of pulses exceeding the threshold noise value, estimated from the oscillograms as the average height of uniform noise (−100 mV). Statistical averaging over a set of sequentially recorded signals was performed; mean values of with standard deviations and a linear approximation are displayed in Figure 11. The response pulses should be counted at a threshold discrimination of non-informative noise. As can be seen from the oscillograms of recorded signals (Figure 10), small-sized impulse emissions most likely correspond to optical extinction on small fat globules, and sharp peaks in the minus region are mainly associated with the presence of large fat globules. When milk moves along the milk pipe, these minus peaks change the frequency of their appearance.
Based on the recorded waveforms (similar to those in Figure 10), we have plotted a graph (Figure 11) that illustrates a direct correlation between the flow velocity and the frequency of negative pulses N p in discrete extinction pattern of the flowing milk. Experimental values of N p were obtained by counting the number of pulses exceeding the threshold noise value, estimated from the oscillograms as the average height of uniform noise (−100 mV). Statistical averaging over a set of sequentially recorded signals was performed; mean values of N p with standard deviations and a linear approximation are displayed in Figure 11. graph ( Figure 11) that illustrates a direct correlation between the flow velocity and the frequency of negative pulses in discrete extinction pattern of the flowing milk. Experimental values of were obtained by counting the number of pulses exceeding the threshold noise value, estimated from the oscillograms as the average height of uniform noise (−100 mV). Statistical averaging over a set of sequentially recorded signals was performed; mean values of with standard deviations and a linear approximation are displayed in Figure 11. The dependence ( Figure 11) can be considered as an experimental test of the outlined milk flow model, since (ordinate axis) was calculated as the average number of pulses per second over several waveform oscillograms measured for each of the given values of flow velocity (abscissa axis), which were set in the pumping system of the experimental setup using the relationship of speed and pressure according to Formula (12). The adjusted values of flow rate were checked by measuring the volume of the milk passed through the sensor during the test using a graduated cylinder. Figure 11. Influence of the milk velocity on the counting rate of response pulses N p , measured as the number of counts per second (cps) in the reference signal.
The dependence ( Figure 11) can be considered as an experimental test of the outlined milk flow model, since N p (ordinate axis) was calculated as the average number of pulses per second over several waveform oscillograms measured for each of the given values of flow velocity (abscissa axis), which were set in the pumping system of the experimental setup using the relationship of speed and pressure according to Formula (12). The adjusted values of flow rate were checked by measuring the volume of the milk passed through the sensor during the test using a graduated cylinder.
The approximate linearity of the obtained dependence ( Figure 11) indicates the adequacy of the applied model of laminar flow for air-milk mixture. Thus, the measurements of response counting rate can in principle be used to determine both milk flow rate and fat content.

Discussion
The applicability of laser sensing methods for assessing the flow rate and composition of dairy products in pipelines of milking complexes has been studied experimentally. Our experiments have shown that using the methods of laser-induced fluorescence response and laser extinction together with digital signal processing algorithms, it is possible to control the flow rate and amount of dispersed components of milk, in particular fat globules, in the milk pipeline. The tested technique for the monitoring of milk flow and composition in a pipe with laser/LED illumination in the 800-850 nm spectral region is based on the optical extinction properties of fat globules of about 0.01 . . . 10 µm in size, contained in milk in large quantities. When measuring the fat content in raw milk using the proposed technique, the presence of fat globule agglomerates up to 100 µm in size must be taken into account. It should be noted that exact measurement of milk fat percentage requires a calibration of the sensor.

Conclusions
The use of the proposed analytical model of milk flow through the pipeline of a milking machine in conjunction with laser sensing methods provides a physical basis for simultaneous measurements of the flow characteristics and composition of milk. The detection of optical response pulses from moving fat globules can serve as a principle for measuring the flow rate and fat content of milk, when milking cows or processing dairy products in technological lines. Such a new type of laser milk sensors can be developed using laser diodes or LED with different wavelengths from UV to near-IR range together with CCD array photodetectors and multichannel fiber bundles.