Keywords

1 Introduction

Delrin is a thermoplastic polymer trademarked by DuPont and commonly known as polyoxymethylene (POM). It has properties similar to some metals and therefore is a potential alternative. Regression is applied to the data to determine a continuous output. It is a supervised learning operation in which the algorithm is trained on data, where it figures out the correlation among input and output variables and then makes predictions for new output values given new input values. In this paper, the algorithms are fed the rake angle, speed and feed as input and the corresponding MRR and surface roughness values as output. Higher rake angle usually gives better surface finish [1]. When graphite and polymer composites are cut orthogonally, it is found that surface finish is extremely poor when the rake angle is between 0° and 5°. On increasing the rake angle, the concavities formed on the machine surface decrease resulting in improved surface finish [2]. The rake angle generally used varies from about 6° to 20°, and it can even reach up to 30° under certain conditions [3]. We found the surface roughness to be minimized in this region.

One of the problems with machining is that built-up edge (BUE) is created. If machining parameters are not selected carefully, then there is a build-up of layer at the tool edge called BUE and at the tool-rake interface known as built-up layer (BUL) [4,5,6,7]. Especially, when the aluminium undergoes dry machining, the effect of BUE and BUL is more pronounced. However, the environmental concerns accompanying the utilization of coolants and their disposal make dry machining an attractive alternative. To offset the disadvantage of BUE and BUL, dry machining of aluminium is accompanied by the use of high rake angles (about 30°) and ultra-hard tool materials (like diamond and CBN) [8].

Apart from surface finish, MRR is also of tremendous interest to us. Rake angle does not have as major an effect on MRR as depth of cut (DOC). DOC followed by speed is more influential in determining the MRR in a machining operation [9]. However, on increasing the rake angle and keeping the other parameters constant, there is slight decrease in the MRR [10].

Another important machining parameter is the feed rate. Feed has a greater effect on SR than other machining parameters [11, 12]. Feed is related to surface roughness by the formula Rt = f2/8r [13], where f = feed rate and Rt = peak-to-valley surface roughness. Thus, feed rate and surface finish share an inverse relationship. On the other hand, the MRR is directly proportional to feed rate [14].

Speed plays a major role in determining output parameters like MRR and surface finish. As speed increases, it leads to an increase in MRR as well while reducing the surface finish [15]. Speed and feed dominate the MRR of the workpiece [15].

There are several regression techniques which were used in predicting the SR and MRR like:

1.1 Linear Regression

Linear establishes a relationship between independent variables and dependent variables in an equation [16]. It is one of the most widely used regression analysis techniques because of its simplicity and the fact that a dataset which varies linearly is easier to fit than a nonlinear dataset [17, 18]. For n points present in a dataset, linear regression models assume a linear correlation between x and y. No relation is perfect, and often there is some error/noise which gets incorporated into the equation as shown below:

$$yi = \beta 01 + \beta 1x1 + \cdots + \beta nxn + \varepsilon i = x^{T} \beta + \varepsilon i\,{\text{where}}\,i = 1, \ldots ,n$$

1.2 KNN Regression

It is among the simplest algorithmic techniques in machine learning. In KNN algorithm, the output value is the average of K nearest values. KNN regression technique is a non-parametric type of regression analysis [19].

1.3 Support Vector Regression (SVR)

SVRs come under the category of supervised learning models that predict a continuous output value for a given input. They come under the category of support vector machine (SVM) or support vector network [20]. Our goal in SVR regression is to determine a function that maximizes deviations for all the data points [21]. Errors less than the threshold value of ε are considered negligible, but those greater than that are unacceptable [22]. Linear support vector regression has a general equation:

$$y =\Sigma i = 1\left( {ai - a} \right)\left\langle {xi,x} \right\rangle + b$$

1.4 Bayesian Ridge

Target value is a linear combination of input values. Bayesian regression includes a regularization parameter. Bayesian ridge regression estimates β using L2-constrained least squares [23]. Bayesian ridge regression has a greater than quadratic fit time as the number of samples makes scaling hard. In contrast to the ordinary least squares (OLS) estimator, the weights are shifted toward zeros, which lends stability. By maximizing the marginal log-likelihood over a number of iterations, estimation is achieved. There are several implementation strategies for Bayesian ridge. The implementation mentioned in this paper is taken from [24]. Moreover, better values of the regularization parameters inspired from the recommendation in [25].

1.5 Decision Tree Regression

The core algorithm called ID3 involves breaking the dataset into increasingly smaller subsets represented by a combination of decision as well as leaf nodes [26]. Numerous connections branch forth from a decision node, each of which represents an attribute while leaf nodes represent a decision. Node corresponding to the best predictor is referred to as the root node.

1.6 Gradient Boosting Regression

It is used to make predictions by using an ensemble of ML models. The various ML models are generalized by allowing optimizing on an appropriate cost function [27]. Gradient boosting model helps in the optimization of any arbitrary differentiable loss functions. Training set of the form {(x1, y1), to (xn, yn)} used to determine approximation F(x) to minimize the loss function

$$L\left( {y,F\left( x \right)} \right):F = \arg \min Ex,y\left[ {L\left( {y,F\left( x \right)} \right)} \right].$$

1.7 Neural Networks

Simulate the neurons in the human brain. Artificial neural networks consist of a minimum of three layers, viz. the input, output and hidden layer. The connection between is assigned weights which can be positive, negative or zero [28]. The NN learns the correlation present in the data through repetition. More the number of repetitions, better the NN learns. Once it has learned the relationship, it can generalize to previously unseen data and can thus predict output values for new input data.

1.8 Genetic Algorithm (GA)

GA is an evolutionary algorithm which we have utilized for optimization. In GA, we start off with an initial population which may be randomly generated. We then select the fittest members from this initial population based on various criteria and make them pass their “genes” to the next generation. This step is known selection. “Offspring” are created by mating the parent population selected in the previous step. This process keeps on repeating until the point where the offspring produced are not much different from the parents. This point is known as convergence [29,30,31].

2 Experimental Investigations

In this paper, three different cutting parameters, namely feed (mm/rev), depth of cut (mm) as well as speed (RPM), vary, and the corresponding MRR (mm3/min) and surface roughness (micrometres) are represented by a Taguchi L27 orthogonal array. The train_test_split function of sklearn splits the dataset further into two categories: training and testing. Testing data represents one-third of the entire dataset, with the rest being training data.

A homopolymer Delrin rod of diameter 34 mm was selected, and CNC turning operation was performed on it. Before performing final CNC turning operation, a roughing operation was performed on it. At the end of the turning operation, the diameter was reduced from 34 to 33 mm. In the CNC turning operation, three different depths of cuts were provided: 0.5, 1.0 and 1.5 mm. The entire rod was broken into three pieces of equal length, and all the operations for a particular depth of cut were performed on each rod in succession. Various regression techniques were then applied on the dataset, and the mean square error was calculated to determine the accuracy of the ML regression models. The scikit-learn library of python was used for implementing the various regression techniques [32]. In addition to regression techniques, a neural network has also been implemented to predict the MRR and surface roughness using the Keras library [33]. Matplotlib library has been utilized to plot the experimental MRR and SR values along with the predicted MRR and SR values [33]. MATLAB optimization toolbox is used to implement multi-objective genetic algorithm to find the optimized values of the input variables [34]. CNC turning experimental data obtained was arranged in a L27 orthogonal array (Table 1).

Table 1 L27 orthogonal array

3 Results and Discussion

It was found that the least mean square error while predicting both MRR and SR was obtained by NN. The mean square error obtained, for each regression technique, is represented in Table 2. As can be seen from the table, neural net gives the best overall results, as it has an extremely small MSE.

Table 2 Mean square error obtained for MRR and SR, which is calculated using various regressors

The above results can be confirmed by visualizing the values obtained using regression techniques with the true values of both MRR and SR on two different graphs (the graph for neural network has not been included as the values for NN have been reshaped and will have to be represented by another scale than shown in Figs. 1 and 2).

Fig. 1
figure 1

Obtained and true values of surface roughness (plotted using matplotlib library in python)

Fig. 2
figure 2

Obtained and true values of material removal rate (MRR) (plotted using matplotlib library in python)

Out of the three regressions, viz. linear, SVR and Bayesian ridge regression, linear regression has the least error for both MRR and SR. For linear regression, the equation found is:

$$\begin{aligned} y & = [[0.0092381\;\; - 1.31666667\;\; - 1.15333333] \\ & \quad \,[ - 6.41442733\;\; - 886.39633333\;\; - 65.8162]]*x \\ & \quad + \left[ {1.4800000000000002\;\;3380.573266666667} \right]. \\ \end{aligned}$$

The equation obtained on application of linear regression was taken, and genetic algorithm (GA) was applied to it for optimizing the input variables. In order to implement GA, the optimization toolbox in MATLAB was used. In this experiment, the MATLAB genetic algorithm was selected in the optimization toolbox. The following parameters are used during the optimization: An initial population of 50 with feasible population as the function and tournament type with a crossover of 0.8. We also selected a single-point crossover and mutation which is adaptive feasible.

3.1 Optimization Using Genetic Algorithm (GA)

As can be seen from Fig. 3, the multi-objective GA iterates for obtaining the best solution and finds it on the 139th generation. The graph in Fig. 5 plots Objective 2 on the y-axis against Objective 1 on the x-axis giving the Pareto front. Average speed for each generation is determined in Fig. 7. The score diversity is represented in a histogram in Fig. 4 while Fig. 6 plots each individual’s rank. These graphs help us determine the optimized solutions.

Fig. 3
figure 3

Average distance

Fig. 4
figure 4

Score diversity

Fig. 5
figure 5

Pareto front graph

Fig. 6
figure 6

Rank histogram

Fig. 7
figure 7

Average Pareto spread

4 Conclusion

Prediction of SR and the material removal rate through regression allows us to conclude the following:

  1. 1.

    Neural networks give the least mean square error of 0.108 and are thus an improvement over regression.

  2. 2.

    In the graph showing comparison of regression techniques, it shows that KNN regression has the best fit.

  3. 3.

    On applying genetic algorithm, we find that optimization takes 139 generations which is quite fast.

  4. 4.

    The optimum cutting parameters are 150 rpm 0.6 mm/rev feed and 1.49 mm depth of cut. At this combination, SR is 0.351 μm and MRR is 1788.91 mm3/min.

  5. 5.

    Increasing feed while keeping other factors constant resulted in a decrease in the surface finish of the workpiece.