OF COMPUTER VISION IN MEASURING TOTAL CUMULATIVE PITCH DEVIATION OF A GEAR

Original scientific paper As the basic part of the mechanical transmission, gears should have high transmission accuracy, so the gear’s precision measurement is a key technology. Based on the existing research, the computer vision technology is introduced in gear test. According to the definitions of technical indexes, such as pitch deviation, tooth thickness deviation, etc., through analysis and research, a new measurement method is proposed, so as to complete the determination of the modulus, tooth number and total accumulated pitch deviation of a gear. In the proposed methods, those indexes such as the pitch and tooth thickness, are measured in arc length, rather than in chordal length, so that they are consistent with their definitions. And the measured points can be positioned on the reference circle of a gear while the pitch and total accumulative pitch deviations are examined. Finally, a gear is measured with the proposed method. The main test is obtained as follows. The single pitch deviation is 10,3 μm, total cumulative pitch deviation is 44,8 μm, and tooth thick deviation is 5,2 μm. The experiment demonstrates that the proposed method is feasible and effective, and can meet the precision need of engineering practice. This study provides a new solution method for the gear’s on-line measurement.


Introduction
Gear is an important rotational part of various machines, and the performance of a machine is affected by gear's precision, so decreasing gears' deviation is an inherent requirement of precision manufacturing [1].In a straight cylindrical involute gear, there are basic parameters such as modulus m, tooth number z, pitch p, outside circle diameter d a , and root circle diameter d f , and so on [2,3].In accordance with the national standard GB/T10095-1988 of China or a similar international standard, gear deviations include pitch accumulated deviation, gear ring radial run-out, basic tangent length change deviation, profile deviation, pitch deviation, lead deviation, tooth thickness deviation and basic tangent average deviation [2,3].When a gear geometry is measured, if the traditional measurement methods and tools are adopted, such as tangent micrometer, universal gear measuring instrument, and so on [4÷6], because of the special structure of the gear, many tested parameters, there are problems such as complex operation, low efficiency, and accuracy easily influenced by human factors.In particular, as for the large size of the gear, there are difficulties in clamping and positioning.With the rapid development of computer vision technology with real time, non-touching and high automation, the computer vision and its applications become a research hotspot [7÷14].According to the requirements of the gear's on-line detection and precision manufacturing, researchers have introduced computer vision into the measurement of gears.As such, the measurement of gears has transformed from contacting to non-contacting.Early, Zhang and Yue used computer vision to test the gear parameters [17,18].Chen et.al.[19] presented a dummy circle scan method to realize the inspection of micro plastic gears with computer vision.Li and Liu [20] obtained the center of the gear, so as to complete the measurement of straight-cut gear with keyways by improving self-adaptation filter, segmentation, edge detection, label and random Hough transform.In addition, Ling and Wang [21] proposed an error compensation model for the pitch cumulative deviation measurement, which was calculated by introducing the error compensation coefficient of the measurement position, which was converted to the reference circle of the gear.The method proposed by Ling and Wang solves the difficulty that the measuring points could not locate in the reference circle.In this study we propose a new method to detect the teeth number by comparison and XOR logic operation, which is simpler and easier to implement than that one proposed by Zhang [17] and Chen [19].At the same time in the detection of pitch deviations, compared with the method proposed by Ling and Wang [21], it is easier to position in the reference circle, so there is no error compensation needed.On the other hand, the measured pitch is consistent with its definition, that is the measuring result is arc length rather than chordal length with conventional detection method.The research in this paper provides technical guarantee for the precision manufacturing of gears.
The paper is organized as follows.First the current situation of gear test is introduced in Section 1. Then test method of gear parameters is proposed, which includes basic parameters and total cumulative pitch deviation and so on in the next section.In Section 3, experiment for gear measurement is carried out, where the tooth number, modulus, diameter of reference circle, total cumulative pitch deviation and tooth thickness and so on are tested.Finally, conclusions and further work on measurement of gear with advance technology are given in Section 4.

Test method of gear parameters 2.1 Basic Parameters and test method of involute gears
The diagram of a cylindrical involute gear is shown in Figure 1.The swelling part of the gear is called a tooth, which is arranged in a circle, and the teeth of gear pair engage with each other, which can make the gears to run continuously.The basic parameters are listed as follows.The diameter of the outside circle: according to the coordinates of the outside circle the equation of the ellipse is fitted as following, Its center coordinates are ((BE -2CD)/(4AC -B 2 ), (BE -2AE)/(4AC -B 2 )), and the distance between the outside circle sampled points and the center is taken as radius.The outside circle's diameter is obtained from the mean of the radiuses, denoted with d a .
(2) Root circle diameter: similarly, firstly elliptical equation of root circle is fitted, so the root circle diameter is gotten according to its radius' average value, denoted with d f .
(3) Reference circle: the reference circle is a circle with standard pressure angle and the standard modulus, which is shown in Fig. 1.The diameter of the reference circle is obtained by the gear's modulus and teeth number, denoted with d r .
(4) Tooth thickness: the arc length of arc between the two sides of a gear tooth in reference circle, as is shown in Fig. 1, where the length of the arc CB is tooth thickness, denoted with s.
(5) Space width: The width or spacing between two adjacent teeth in reference circle.As shown in Fig. 1, the length of the arc AC is taken as space width, and in the reference circle of involute cylindrical gear, tooth thickness is equal to space width, that is s=e.
(6) Pitch: in the reference circle, minor arc length of adjacent two teeth in the same side of the tooth profile is pitch.As is shown in Fig. 1, length of the arc AB is circular pitch, denoted with p, and p=s+e.(7) Modulus: the parameter of the gear size, m, which is the ratio of the pitch to circumference ratio, i. e. π / p m = . If moduli of a pair of meshing gears are equal, the gears would run smoothly.
For the involute gear, the gear modulus should adhere to the standard, which can reduce the number of cutting tools and the cost of the gear processing, and at the same time improve the manufacture precision.
While the modulus of gear is determined, firstly reference circle's diameter approximate value is obtained according to the diameter of gear's outside circle and root circle.Then modulus' approximation value is gotten according to the teeth number, i. e. m' = (2r a + 2r f )/z, where the r a and r f are the radius of outside circle and root circle.By comparing with standard module, the closest value to standard modulus is taken to be gear's actual modulus m.And with modulus m and tooth number z, the radius of the reference circle r is gotten as follows, Then the base circle's radius is obtained as the following, where α is press angle in reference circle, and in general, α =20°. .If point A in the base circle is the starting point of the involute, and the rolling angle ω is taken as a variable, then the mathematical expression of involute is written as following, ω ω θ where b r is the radius of basic circle.As for standard gears, the two theoretical curves of a tooth are in coincidence with its actual profile.As shown in Fig. 2, the curves EF, GH and other theoretical involutes constitute the profile of the gear.
(1) Pitch deviation pt Δf The pitch deviation pt Δf is the difference of the actual pitch and the theoretical pitch of a gear.If pitch deviation is in accordance with the requirements of pitch deviation, gears can move smoothly.
In engineering, it is difficult to make the measurement points be located at the reference circle accurately while the pitches are tested with traditional touching methods.Generally it is permitted that measurement points are located at the tip and middle part of the gear's profile.It is similar for the measuring of tooth thickness.If the computer vision measurement technology is adopted, through image processing and data processing for the sampled gear image, the mathematical expression of the reference circle is obtained while the outside circle, root circle and inner circle of gear are fitted.Then the intersection points of the gear profile and the reference circle are gotten, i.e. 1 c ) , ( , as shown in Fig. 2. Assume the radius of reference circle to be r, the centre of circle to be o, and the angle between 1 oc and 3 oc to be 1 β , so the length of minor arc between 1 c and 2 c is the reference circle pitch of the gear, that is 1 p = 1 β r .While the acute angle 1 β is tested, with the normalized vector of 1 oc and 3 oc , we have their corresponding unit vectors ' 1 oc and ' 3 oc , so their angle can be obtained in the light of the following formula, ( ) At the same time, the lengths of arcs between Then the difference ptn Δf between the actual pitch p n and theoretical pitch p is obtained.Let the maximum of the differences as pitch deviation pt Δf (If the measured values of all pitch deviations ptn Δf are truth value, the sum of all ptn Δf of a standard gear is 0).
(2).Total cumulative pitch deviation The total cumulative pitch deviation of gear the maximum difference between the actual arc length and the corresponding theoretical value between two adjacent teeth on the reference circle.If the cumulative deviation value is consistent with the standard requirements, the accuracy of the transmission movement can be guaranteed.According to the deviation of the pitch, each pitch deviation is accumulated successively, i. e.
(3).Tooth thickness deviation Tooth thickness deviation is the difference of the actual thickness of tooth and its theoretical one.Its measurement is similar to that of a pitch.Firstly the crossover points of the reference circle and profile are solved, i. e.The actual tooth thickness is subtracted by its theoretical value respectively, and the maximum of those differences is taken as the tooth thickness deviation s E ∆ .

Test experiment and data processing 3.1 Image Sampling and Processing
In experiment, the measurement aparatus consists of monocular vision system, and the optical axis of camera is vertical to platform.While the gear is tested, firstly the computer vision system is calibrated, and the scale of camera is obtained, i. e. .In order to demonstrate the availability and feasibility of the proposed method, some known parameters of the examined gear are as follows: its tooth number is 15, and the diameter of its inner hole is 34 mm.
According to the proposed method, first the gear's image is sampled, as shown in Fig. 3. Then the image is processed to extract the edge feature of gear as shown in Fig. 4 [26÷29].Technical Gazette 24, 1(2017), 71-78

Basic parameters of gear measured
According to the requirements of measuring items, the basic parameters of a gear are tested as follows.
(1) The inner hole of a gear is one of important parameters to be tested.The ellipse of the inner hole is obtained as follows, The central coordinates ( ) of the inner hole obtained from Eq. ( 8) are (334,6804; 239,5906).Then the distance between the central coordinates and sampled points is regarded as the radius of inner hole.Thus its diameter is obtained from the average value of radiuses, that is 133,0782 (pixel).According to the scale of CCD, the diameter is 34,0195 mm measured physically.
(2) Similarly the fitting equation of the outside circle is gotten as follows, The central coordinates obtained from Eq. ( 9) are ( a a y x , ) i.e. (333,7309; 240,3721).Then the distances between the central coordinates and sampled points of outside circle are obtained.So its diameter can be obtained from the average value, that is the diameter of outside circle is 333,0409 (pixel).According to the scale of camera, the diameter is 85,1371 mm measured physically.
(3) The fitting equation of root circle is obtained as follows, Because the involute equation of a gear is transcendental, it is very difficult to solve the crossover points of the involutes and the reference circle according to the method proposed by Zhang and Chen [17,19].In our method, when the tooth number of gear is determined, first the distances between the sampled points of the profile and the center of the reference circle are calculated.If one front point's distance is equal to or smaller than the radius of the reference circle, and the next points' distance is equal to or larger than the radius of the reference circle, one of the sampled points, or their average value is the crossover point.Similarly, if one front point's distance is equal to or larger than the radius of the reference circle, and the next point's distance is equal to or smaller than the radius of reference circle, one of the sampled points, or their average value is the crossover point.In the algorithm, if the distance between the central coordinates of the reference circle and one sampled point is smaller than the radius of the reference circle, the counter variable is set to 0, i. e. ) (n i =0.If the distance between the central coordinates and the next sampled point is larger than the radius of the reference circle, and Then XOR operator is carried out for the two adjacent variables.At the same time, the counter variable is accumulated, that is . (If the distance between the sampled point and central point is equal to the radius, the sampled point is the crossover point, and the accumulation operator is carried out for counter variable, that is 1

+ = k k
).In experiment, when the number of tooth are tested, all the crossover points of the reference circle and the profile are solved, and the tooth number can be obtained by checking the counter variable k, which is 30, so the tooth number of the gear is 15.The approximate radius of the gear's reference circle r' = 37,1221 mm, so the approximate modulus of the gear m = 4,9496 mm.Then through computer programming or checking table of gear standard manuals [2,3], the module of the gear can be obtained, i. e. m = 5 mm.At the same time, the actual diameters of gear's reference circle can be obtained, that is d = mz = 75 mm .According to the camera calibration parameters, the diameter is 293,3865 (pixel) in image plane.
The inner hole, outside circle, root circle and reference circle of the gear are drawn in Fig. 5 according to the Eqs.( 8) ÷ (11), where the yellow curve denotes the reference circle.(Note that the reference circle radius in the right item of Eq. ( 11) should be changed as 146,6933 (pixel)).At the same time, the basic parameters of the gear are listed in Tab. 1, where DIH denotes the diameter of the inner hole, DOC the diameter of outside circle, DRC the diameter of the root circle, TN the tooth number, M the modulus, and DRC the diameter of the reference circle.

Tooth profile computed and plotted
While the experiments were carried out for the gear detection, the center of reference circle is taken as that of the base circle, that is (334,2261; 240,2577).According to the Eq. ( 3), the basic circle's radius is 137,8466 (pixel), so one side of profile's involute expressions is rewritten as follows, ω ω θ θ sin 2577 240 As is shown in Fig. 2, the rolling angle of the involute is ω, which is the sum of the pressure angle α and expansion angle θ.Since the starting position of the involute does not begin from the X axis, the corresponding rotation angle is calculated as follows.
From Fig. 5, one of the crossover points of the base circle and the profile is r 1 (441,2036; 113,0105).According to computer graphics, the positive direction of the Y axis in image coordinate system is top-down, so we can calculate the inclination angle of the line or 1, i. e.As for the other side of involute profile, according to the symmetry properties, we get it by multiplying Eq. ( 12) with -1, and rotating a certain angle anticlockwise as above.In this case, it is needed to rotate an angle of 15,1517° anticlockwise.
The other cogwheels can be obtained from Eqs. ( 12), ( 13), ( 14) and ( 15) by rotating angle β around the center (334,2261; 240,2577) of the basic circle, that is, , and The tooth profiles of the gear are drawn in Fig. 5 according to Eqs. ( 12), ( 13), ( 14), ( 15), ( 16) and (17).All the tooth profiles are plotted from the inside to the outside, they do not need being plotted precisely as those parts of the profiles near the root circle.Technical Gazette 24, 1(2017), 71-78 First, according to the comparison and XOR logic operation, the crossover points' coordinates of gear's reference circle and profile are gotten.As can be seen from Fig. 5, with normalized processing, the unit vector 1 oc and 3 oc are [0,9049; 0,4256] and [0,6535; 0,7569] respectively.In the light of Eq. ( 6) we get β 1 = 0,4190 rad, and the minor arc of is 61,4621 pixel, so the gear's pitch pt1 f =15,7119 mm.Because the theoretical pitch is 15,7080 mm, the difference between them is taken as pitch deviation (PD), i. e. pt1 Δf = 3,9 μm.In the experiment, according to Tab. 2, the pitch deviation, tool cumulative pitch deviation and tooth thickness deviation are obtained and shown in Tab. 3, where TCPD denotes the total cumulative pitch deviation.In order to compare the proposed measurement method with conventional methods, the gear is tested in universal tool microscope, and the corresponding deviations are obtained as in the 3 rd column in Tab. 3.

Conclusions
This study has investigated a new method for measuring the basic parameters of involute spur gears and several individual deviations based on computer vision.Experiments demonstrate that the proposed method has the advantages of convenient operation, high efficiency and high measurement accuracy, and the measurement accuracy can meet the needs of engineering practice.If the traditional contacting method is used to measure the pitch of gear, it is very difficult to have the measurement points located at the reference circle accurately, and the resulted chordal pitch and chordal tooth thickness are not consistent with their definitions.In general, the proposed scheme is of good reference value and application value.As for the other parts of the single deviations detection, because of the limitation of computer vision and the complex structure of gear itself, it also needs to be studied further.In order to achieve the measurement of the whole single parameters and comprehensive parameters of the gear with computer vision, we need to study the characteristics of the computer vision and the technical indexes of gears in future [30,31], so as to have new discovery and insights.

Figure 1 1 )
Figure 1 Frontal projection of flank profile of involute gear (1) Number of teeth: the teeth number on the entire gear circumference, which is denoted with z.The diameter of the outside circle: according to the coordinates of the outside circle the equation of the ellipse is fitted as following,

Figure 2 gear diagram 2 . 2
Figure 2 Standard gear diagram 2.2 The measurement principle of the total pitch deviation In Fig. 2, assume the length of line oP between point P and the base circle center o be r k , pressure angle α , the angle of involute exhibition θ , involute rolling angle θ α ω + =

1 ,
until the final cumulative pitch deviation pz F ∆ is obtained (z is the number of teeth).According to the above data, if the maximum value is total cumulative pitch deviation p F ∆ can be obtained, i. e. p

2 φ 1 φ r , 2 φr
so on are obtained in turn, i. e. 1 φ , , … …., and n φ .Finally corresponding arc lengths i.e. ,… …, and n rφ are gotten respectively, which are the tooth thickness 1 s , 2 s , … …, and n s .At the same time the theoretical tooth thickness is obtained, which is the half of the pitch, i. e. 2 p s = .

Fig. 3 Figure 4
Fig.3The sampled gear image central coordinates (x f , y f ) of the root circle are (334,2670; 240,8104), obtained from Eq.(10).Similarly, the diameter of the root circle is 247,8191 (pixel) or 63,3513 mm physically.In the light of the diameters of the outside and root circles, approximate value of the reference circle's radius is 145,2150 (pixel), that is r' = 37,1221 mm.Then the central coordinates (x r , y r ) of reference circle are obtained as (334,2261; 240,2577), from the central coordinates of inner hole, outside circle and root circle of the gear.So the approximate equation of gear's reference circle can be written as the following,

Figure 5
Figure 5 Drawing of fitting curves

Table 1
The measured results for the gear geometry parameters Similarly, the other pitch deviations ptn Δf can be obtained, as shown in the second row of Tab. 2. Let the maximum of the PDs as the pitch deviation of the gear, i. e. pt Δf =10,3 μm.

Table 2
Deviations measured

Table 3
Deviations comparison