Abstract
Dimensional synthesis of crank-rocker mechanisms applied to provide some desired values of stroke and time ratio, is of utmost importance for designing an efficient mechanism. In the synthesis and manufacturing of crank-rocker mechanisms, the designers are further challenged by other design criteria, such as quality of motion. In this study, a novel approach based on genetic programming (GP) is proposed for dimensional synthesis of planar crank-rocker mechanisms with optimum transmission angle over the desired stroke and time-ratio. An analytical approach is elaborated which leads to an interesting relationship of length of the coupler and rocker links. It is, therefore, advised that by adopting equal lengths for coupler link and rocker link, one can guarantee the optimality of the transmission angle’s deviation (
Introduction
Mechanisms as basic components of machines are widely used in a widening area of engineering and scientific domains. The synthesis of a mechanism is the study of procedures of combining parametric members whose combination provides some desired behaviors. 1 Dimensional synthesis, as a kind of inverse problem, is concerned with evaluation of geometrical sizes of mechanisms. Dimensional syntheses of crank-rocker mechanisms to provide some desired values of stroke and time-ratio, have been sort of challenging problems in the case of planar mechanisms. However, in the synthesis and manufacturing of crank-rocker mechanisms, the designers are challenged by some other design criteria, for example, quality of motion. Addressing this issue is very important to design an efficient mechanism. 2 The quality of motion is measured by transmission angle’s deviation from ideal value of 900. 3
Generally, synthesis of the crank-rocker mechanisms has been addressed during the last decades. In earlier studies, Joe Brodell and Soni 4 introduced a design chart obtained from an analytical approach to synthesize the crank-rocker mechanism with good quality of motion and unit time-ratio. Balaji Rao and Lakshminarayana 5 presented the optimal synthesis of RSSR crank-rocker mechanisms for different combinations of oscillation angle, time-ratio, and axis angle. The authors in 6 suggested a synthesis procedure which satisfies a prescribed stroke and time-ratio wherein the required definite objective function is optimized. Soylu, 7 investigated a synthesis procedure for the planar mechanism in which the maximum deviation of transmission angle is constrained to be less than a certain desired limit. The graphical and analytical approaches associated with design charts considering some performance criteria, such as stroke, transmission angle, and time-ratio was addressed in Lun and Leu. 8 Balli and Chand 3 investigated the transmission angle’s influence on the different parameters of a mechanism, for example, friction, mechanical advantage, pressure angle, transmission force, input crank angle, tolerance, and the performance sensitivity. The authors also studied the various mechanism’s defects, such as branching, order, circuit, and poor transmission angle in Balli and Chand. 9 Eren and Aydemir 10 introduced a kinematic synthesis scheme for the synthesis of four-bar sley drive linkages. The authors considered the transmission angle, the stroke, and the time-ratio as the parameters affecting the sley trajectory. Hassaan et al. 11 used Powell’s optimization method for optimal design of crank-rocker linkages for a given stroke and time-ratio. Khader 12 proposed the design nomograms for directly designing the crank-rocker mechanism links’ ratios with a definite determined transmission angle limit. Rufino and Ferreira 13 described a variable stroke mechanism and presented a kinematic model to determine the requirements for synthesis of the mechanism. El-Shakeryet al. 14 suggested both analytical and graphical methodologies to optimally determine links’ lengths of crank-rocker four-bar linkage to obtain a targeted design with definite transmission angle. Yildiz 15 addressed the structural design optimization of a four-bar linkage for a trunk lid of a sedan type passenger car, incorporating three different population-based optimization techniques. The authors in Refs.2,16,17 used game theory to present a framework for multi-objective optimal synthesis of four-bar mechanisms for path-generating applications. It should be mentioned that the performance criteria stroke and time-ratio were not taken into account by authors. However, many research works have been devoted to the optimal synthesis of path-generating four-bar mechanism using suitable optimization schemes and computational intelligence techniques.2,17–24
Modeling and identification of data driven systems have always been of a great interest for research workers and have become a new topic of research in a broad range area in engineering science.25–31 Generally, an exactly mathematical relationship between input–output data is needed to model as well as to predict the data-driven system, precisely. However, obtaining such mathematical modeling is so cumbersome and even is not possible in poorly identified systems. Recently, some deep learning algorithms as a part of a broader category of machine learning schemes in conjunction with evolutionary algorithms have drawn considerable attention in computation of imprecisely complex environments. In evolutionary algorithms (EAs), genetic programming is defined as an extension to genetic algorithms (GAs) in which the structures undergoing adaptation are not strings but are hierarchical computer programs of dynamically varying shape and size. Recent research works that set the stage for current GP research topics and applications is various, and includes topology optimization of structures,32,33 optimal modeling of complex systems, 34 controller design, 35 image processing, 36 object detection, 37 data mining, 38 control of robots, 39 and so on.
The available kinematic design methods in mechanism literature calculate the link lengths of a crank rocker mechanism according to minimum transmission angle criteria as a design constraint. On the other hand, as the occurrence of failure of Grashof condition is catastrophic in a four-bar mechanism, guaranteeing Grashof constraint feasibility is of the most importance at both the synthesis stage and the manufacturing process. As far as the authors know, there is no design approach in the literature for a crank-rocker mechanism to determine the link lengths of the mechanism analytically, taking into account the deviation of transmission angle from ideal value as an objective function and guaranteeing the Grashof condition, simultaneously. Moreover, there is still a clear gap in development and implementing meta-heuristic approaches to generate the structural descriptions of mechanisms.
This study tries to overcome these shortcomings by incorporating GP meta-modeling and inverse modeling approaches to solve the optimization problems arising in kinematic synthesis of crank-rocker mechanisms. The objective of the optimization problem is defined as to design a mechanism that has a pre-determined value for stroke and time ratio and simultaneously guarantees the optimality of the motion quality and Grashof condition as well . In this regard, the lengths of the mechanism links are considered as design variables. It is, analytically, advised that keeping equal the length of rocker link and connecting rod link would automatically satisfy the optimality of the transmission angle’s deviation. Then, for each mechanism, the stroke and the time ratio are geometrically obtained as a function of the lengths of the mechanism links. In order to apply GP method for the inverse modeling purpose, some input-output data are constructed based on stroke and time ratio as functions of sizes and lengths of the crank-rocker mechanism. Finally, with the use of the GP, the optimal mathematical model for each design variables are obtained as the functions of both stroke and time ratio.
It is shown that the GP model can successfully find almost simple and easy to use mathematical relations of mechanism’s links needed to synthesize the mechanism with the best quality of motion for any desired values of both stroke and time ratio simultaneously. In fact, the proposed mathematical forms presented in this study, provide the capability to synthesize the length of mechanism’s links for any desired value of stroke and time ratio within the estimated ranges. Moreover, such novel application of the proposed approach of the optimum synthesis of crank-rocker mechanisms leads to a very interesting relationship of length of mechanism’s link. It is advised that keeping equal the length of rocker link and connecting rod link would automatically satisfy the optimality of the transmission angle’s deviation. The proposed approach has been applied for kinematic synthesis of a four-bar crank-rocker mechanism. A comparison between the obtained results of this work and the analytical method, clearly illustrates the efficiency of the proposed method.
Methodology
In this section, a general algorithm for the optimally synthesis of mechanisms has been presented by using genetic programming method. The proposed algorithm has been summarized in Figure 1. The objective of the optimization problem is defined as to design a mechanism that has some desired performance criteria. Generally, the lengths of the mechanism links are considered as design variables, that is, output variables. For each mechanism, the performance criteria, that is, input variables are geometrically obtained as a function of the lengths of the mechanism links. Then, in order to apply genetic programming method for the inverse modeling purpose, some input-output data are constructed based on the performance criteria as functions of sizes and lengths of the mechanism. Finally, with the use of the GP the optimal mathematical model for each design variable are obtained as the functions of performance criteria. The following case study illustrate how the proposed approach depicted in Figure 1 can be used to improve the overall design of a four-bar crank-rocker mechanism for any desired stroke and time-ratio while optimizing transmission angle’ deviation.

Schematic algorithm of the proposed approach for synthesis of mechanisms.
Crank-rocker mechanism: A case study
The four-bar mechanism is the simplest and the most popular linkages, which consists of three movable links and a fixed link. A crank-rocker is a type of four-bar mechanism which is widely used for converting continuous rotary motion to oscillatory motion with a quick return feature. A four-bar linkage is called a crank-rocker when the shortest link is connected to the ground link. As illustrated in Figure 2,

Schematic of a four-bar mechanism.
Angles
In this study, the stroke, time-ratio, and transmission angle’s deviation (

Schematic of crank-rocker mechanism at its limiting situation.
According to Figure 3 and by using cosine law, the stroke and time-ratio of the mechanism are kinematically computed as a function of four parameters, that is, the length of the mechanism’s links. The parameters
The stroke and time ratio are then calculated using equations (6) and (7), respectively.
in which
The transmission angle’ deviation is formulated as
According to equation (8),

The minimum and maximum values of transmission angles.
where,
where,
Optimization of transmission angle
In the synthesis and manufacturing of mechanisms, design engineers usually are faced quality of motion. Addressing this important issue is essential to synthesize an accurate, efficient, and reliable mechanism that functions satisfactorily during its period of service. The transmission angle of mechanism employed as a measure of the quality of force transmission of the mechanism. For instance, it helps to decide the “Best” among a family of possible mechanisms for most effective force transmission.
In this section, an analytical approach adopted from Ahmadi et al. 24 is given to obtain an explicitly mathematical equation which guarantees the optimality of the transmission angle’s deviation and also ensures the Grashof condition.
In this way, equation (8) can be rewritten using equation (9) as follows,
In order to obtain a relationship between
By taking substitution variables
The necessary conditions of equation (12) is transferred to equation (14) using some algebraic manipulation as
Evidently, both
In order to obtain real solution, the radicand terms in equation (13) should be positive values. Readily, by considering
in which, |.| denotes the absolute value. The equation (15) simply represent Grashof condition. Moreover, by using
Such analytical approach indicates that keeping equal the length of
Results and discussion
As shown in Table 1, the sample points include two inputs (
Input-output data pairs for the crank-rocker four-bar mechanism.

The input samples.
The main advantage of GP for the modeling process is its ability to produce models that build an understandable structure, that is, a formula or equation relating input and output variables, which might shed engineering insight into the processes involved. 40 Thus, for mechanism synthesis instances, GP may offer advantages over other techniques since GP can self-modify, through the genetic loop, a population of function trees in order to finally generate an optimal and physically interpretable model. Specifically, a comparative analysis of GP and multi-layer perceptron artificial neural network (MLP-ANN) for metamodeling of the sample points is provided in Table 2. The results show that across all three systems GP provided greater training and prediction capability. The close proximity of training and prediction performance of GP implies relatively greater resistance to overfitting. The analysis of computational effort by GP and MLP-ANN reveals that GP requires a greater amount of computing time. However, this increased cost of fitting a GP metamodel may not be significant when the data is computationally expensive. 41 Furthermore, GP produces explicit functions in contrast with the models generated by other nonparametric approaches, such as MLP-ANN.
Comparison of the proposed GP and MLP-ANN method.
In order to succeed the inverse modeling procedure, the GP algorithm is deployed as a surrogate model. The GP algorithm utilizes computer programs as individuals of its population and models them with a tree structure. 33 More complete details on genetic programming and its terminology is presented in Refs.30,33,34
In the optimization process, the inverse modeling error is evolutionarily minimized as the fitness function which is expressed as follows
in which,
The parameters of GP.
According to Table 3, the initial population in GP execution consists of 100 individuals generated by ramped half and half method with the maximum depth of trees as 7. In the last generation, there are 100 mathematical models with different levels of accuracy and complexity for each normalized length. The best model related to the fitness function considered as the final solution to the problem.
The corresponding mathematical expressions of such GP- type models for optimum

Scatter diagram of actually values versus estimated values for design variables

Scatter diagram of actually values versus estimated values for design variables

Scatter diagram of actually values versus estimated values for design variables
The proposed method is now applied effectively to the optimal synthesis of a four-bar mechanism. It is desired to synthesize a crank-rocker four-bar mechanism to provide a stroke of S = 32° (0.558 rad) and TR = 1.06 with the best possible value of quality of motion. Table 4 provides the performance comparison of the synthesized mechanism using the obtained equation (19) of this paper for the given stroke and time ratio with that of analytic method. It should be mentioned that, in analytic method, the optimal values of
Comparative results for crank-rocker four-bar mechanism.

Rocker displacement.
The ideal value of transmission angle is 90° in order to provide the best possible quality of force transmission at the joint. That is why most mechanism designers try to keep the minimum transmission angle’ deviation above a specified value to promote smooth running and good force transmission. Generally, to obtain a good quality of motion, it is recommended in the literature, for example, that the maximum deviation of the transmission angle from
It should be noted that, for a Grashof four-bar mechanism the transmission angle can generally vary from 0° to 90°. In the other hand, for a non-Grashof linkage the transmission angle will be 0° in the toggle positions which occur when the output rocker and the coupler are colinear. 1 However, the equation (15) obtained from the proposed approach would automatically guarantees the optimality of the motion quality and also ensures the Grashof condition, that is, the transmission angle will not be 0° or 180°. The values of TA over the entire range of motion for the mechanism is also shown in Figure 10. It is evident from Figure 10 that the synthesized mechanism keeps the transmission angle within the recommended range while simultaneously improve the overall design of four-bar mechanism to met the desired stroke and time-ratio.

Deviation of transmission angle from 90°.
More importantly, it should be mentioned now that the genetically obtained synthesis equations of this paper can now be readily employed for the design of any crank-rocker mechanism used in real-world practical applications such as the sley drive of weaving machines, 10 the mixer mechanism, 42 the shaper linkage, 43 windshield wiper mechanism, 44 the continuously variable transmission (CVT) system, 45 etc. For instance, the application of the proposed approach for the design of four-bar linkage sley drive mechanisms is elaborated. The minimum transmission angle’ deviation, the stroke, and the time ratio are the parameters affecting the sley motion curve. The optimum values of these parameters should be used by taking into account the desired sley motion on the one hand and dynamics of the mechanism on the other hand. Once the required sley motion curve is determined from the shed geometry of a weaving machine, the kinematic design approach introduced in the proposed methodology can be used to optimize a four-bar sley drive mechanism with the best quality of motion.
Conclusion
In this paper, by using genetic programming, a unified approach for optimal syntheses of four-bar crank-rocker mechanisms was proposed so that any desired values of both stroke and time-ratio are achieved wherein the optimality of the transmission angle deviation as well as Grashof condition is guaranteed analytically. It was proved that keeping equal the length of connecting rod link and rocker link would guarantee the optimality of the transmission angle deviation and also ensures the Grashof condition. In this way, the length of three links, namely, reference bar, crank, and connecting rod was considered as design variables. A complete set of input-output data was obtained by considering the pertinent mechanism’s geometry relations and constraints. It is shown that GP can successfully find almost simple and easy to use mathematical relations of design variables needed to synthesize the mechanism for desired values of both stroke and time-ratio simultaneously. In fact, the proposed mathematical forms presented in this paper, provide the capability to synthesize the length of mechanism’s links for any desired value of stroke and time-ratio with optimum transmission angle. Further considerations are suggested to conduct as future works:
- In the case of this study, the dynamic considerations have not been taken into account. However, the future works may consider several dynamic performance criteria such as maximum values of the ground bearing forces during one input crank revolution, maximum required value of driving torque, maximum shaking force/moment, etc.
- The present study addressed the problem of dimensional synthesis of planar linkages in a deterministic environment, that is, the dimensional tolerance and joint clearance were not considered. However, in real world applications, the dimensional tolerance and joint clearance are investable in the stages of manufacturing and assembling. Certainly, any experimental attempt is required to hire some robust design approaches and uncertainty analysis which can be done as future research.
- Further possible future research avenues are to introduce advances from the GP literature to further improve the generalization ability and also to investigate the capability of the other methods of artificial intelligence in metamodeling of mechanism synthesis applications.
Footnotes
Handling Editor: Chenhui Liang
Declaration of conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
Funding
The author(s) received no financial support for the research, authorship, and/or publication of this article.
