Corrosion Behavior of LENS Deposited CoCrMo Alloy Using Bayesian Regularization-Based Artificial Neural Network (BRANN)

The well-known fact of metallurgy is that the lifetime of a metal structure depends on the material's corrosion rate. Therefore, applying an appropriate prediction of corrosion process for the manufactured metals or alloys trigger an extended life of the product. At present, the current prediction models for additive manufactured alloys are either complicated or built on a restricted basis towards corrosion depletion. This paper presents a novel approach to estimate the corrosion rate and corrosion potential prediction by considering significant major parameters such as solution time, aging time, aging temperature, and corrosion test time. The Laser Engineered Net Shaping (LENS), which is an additive manufacturing process used in the manufacturing of health care equipment, was investigated in the present research. All the accumulated information used to manufacture the LENS-based Cobalt-Chromium-Molybdenum (CoCrMo) alloy was considered from previous literature. They enabled to create a robust Bayesian Regularization (BR)-based Artificial Neural Network (ANN) in order to predict with accuracy the material best corrosion properties. The achieved data were validated by investigating its experimental behavior. It was found a very good agreement between the predicted values generated with the BRANN model and experimental values. The robustness of the proposed approach allows to implement the manufactured materials successfully in the biomedical implants.


Introduction
Corrosion is a key challenge for improving metallic material's reliability and life cycle. The selection of alloys and metals for structural components depends largely on the physical and mechanical properties, but their corrosion resistance cannot be ignored [1,2]. Cobalt-chromium-Molybdenum (CoCrMo) alloy is known for its remarkable corrosion resistance and hardness that is especially utilized in the fabrication of medical equipment [3]. Nevertheless, under certain circumstances, they corrode, for example, when exposed to some water pollutants or the alloy's standard chemical composition has not been met. The knee implant made up of CoCrMo alloy catches corrosion after several years of use. A little corrosion (body fluid typically containing many cations and anions) leads to metal release, prone to alter the body's metabolism system. Therefore, corrosion control and prediction of CoCrMo alloy is necessary. Over the predicted life span of a metal, its engineering properties can be protected by controlling the corrosion [4]. Prediction and measurement of corrosion is a time-consuming process where traditional mathematical approaches are not enough to forecast such a non-linear process. At present, artificial intelligence is the simple way of analyzing the corrosion behavior in metals or non-metals in which this study intended. Classification and empirical simulation of neural networks (NN) is considered parametric non-linear structures. It may also be viewed as more versatile forms of the standard method of regression. Their versatility allows them to find more general data relationships than conventional mathematical models. Kamrunnahar et al. [5] evaluated the synergetic effects of various parameters that influenced the corrosion rate using supervised neural networks in carbon, Iron, and steel alloy. The authors proved that the developed NN model predicted corrosion rates that were consistent with the experimental sets. In a recent study, Cai et al. [6] applied a hierarchical linear modeling technique to find the effect and growth of corrosion in Zinc, Carbon, and Copper metals under different conditions that resulted in a deviation of ± 30 to 50% over the experimental results for the studied metals. In this research, we focused on the prediction of corrosion and its accuracy against the measured experimental value using Bayesian Regularization-based Artificial Neural Network (BRANN) for CoCrMo alloy.
The standard procedure for estimating the corrosion resistance for non-ferrous metals like CoCrMo alloys is that the material is subjected to electrochemical testing in the presence of 5% NaCl and KCl aqua solutions. From the readings obtained, the testing Tafel plots are drawn; and from the E Corr (Corrosion potential) and I Corr (Corrosion current) values, the corrosion resistance is calculated [7].
Many researchers have tested CoCrMo for the behavior of its corrosion [1][2][3][4][5][6][11][12][13]. In the CoCrMo alloy, when the samples undergo heat treatment which is an integral part of the corrosion behavior of the alloy, the chromium (Cr) carbides are made. The higher Cr available produces a homogenous passive surface and improves corrosion resistance due to thermal treatment as carbon is dissolved [8]. When subjected to heat treatment, cast high-carbon CoCrMo alloys were analysed and a larger grain border size improved the anodic reaction in all solutions [9]. CoCrMo samples were obtained through additive manufacturing (that is, LENS process), indicates the process parameters (such as scan speed, powder feeding speed, and laser resistance) significantly affect the corrosion resistance [10]. The effect of solution treatment followed by aging was studied on the LENS deposited and weld deposited CoCrMo alloy samples. The researchers found that the solutionized samples without aging exhibited high corrosion resistance compared to others [11,12]. When deposited with LENS, studies with CoCrW alloys have shown samples made using high laser strength, medium to high powder feed, and medium to high laser scanning speed, which is better for high corrosion resistance [13]. Aneja et al. [14] studied the strength characteristics of geopolymer concrete with the BRANN model under different backpropagation training algorithms and hidden layers. Their results showed that the BRANN model with ten neurons is the best model to predict the strength of geopolymers with an R 2 value of 0.99. Recently, Li et al. [15] modeled the corrosion rate of carbon steel using ANN with multilayer perceptron and backpropagation. Their proposed ANN model obtained a maximum absolute relative deviation of 8.66%. Kumari et al. [16] attempted to use the Backpropagation Levenberg Marquardt algorithm to evaluate the corrosion behavior of Titanium substrate. The authors found that the developed ANN model achieved excellent accuracy when compared with experimental results in predicting the open circuit potential and Nyquist plots. Zulkifli et al. [17] analysed the corrosion rate of Aluminium Alloy 5083 using Multilayer Perceptron model with Scale conjugate gradient, Bayesian Regularization (BR) and Levenberg-Marquadt (LM) algorithms. LM is the best training algorithm for corrosion rate prediction of the studied Aluminium Alloy, with a high correlation coefficient score (R 2 = 0.992), among the three training algorithms.
All the above experiment results have identified the best among the samples tested but not the best as a whole (i.e., the behavior for the process parameters that were not considered was not identified). The Artificial Neural Network (ANN) approach helps us predict corrosion resistance through interpolation or extrapolation. The tensile strength and strain hardening exponent of Austenitic Stainless Steel Page 3 of 13 116 304 at elevated temperatures were predicted by the researchers using a genetic algorithm and achieved good results [18]. In order to predict the corrosion behavior of samples made with 3D and pressure-less microwave sintered, a mathematical model was developed of porous iron scaffolds. With experimental findings, the built model was validated, where the authors found a maximum prediction value of a 6.97% error [19]. Bayesian Theory of Regularization provides a unifying data processing structure, with some advantages such as overfitting solvation, unique marginalization, and can be used for defining a sophisticated probabilistic model [20,21]. In a different study, a model was built by Krivy et al. using a probabilistic approach to predict the corrosion losses due to environmental conditions such as relevant annual temperature (T) values, sulphur dioxide concentration (SO2), relative air humidity (RH), chloride deposition (Cl). Authors proved that the effect of environmental characteristics on corrosive processes could be analyzed via a probabilistic approach [22]. The residual lifetime of a pipeline has been estimated considering the corrosion's effect using mathematical modelling [23]. Fe/Cu type galvanometer sensor was used to predict the corrosion effect for 34 days, and the researchers could achieve better results through the support vector regression model [24]. Current prediction models for additive processed alloys are either complicated or built on a limited basis. As a result, in this research, BRANN's approach is preferred to create a prediction model that is compatible with the experimental data and makes optimum forecasts with models.
The present work was focused on developing a robust BRANN model to predict the corrosion behavior of CoCrMo subjected to heat treatment. The results show a good match between experimental and numerical results, which enable reducing the number of experimental trials and cost saving considerably. Further, this work can be used successfully for predicting the corrosion features of the most adopted additive manufactured CoCrMo alloys used in various human implants.

Methods and Materials
The experimentation is carried out in two stages. One is to conduct the samples' physical testing fabrication using specific parameters. The second stage is to run the BRANN model to predict the same for the change in parameters.

Physical Method
The CoCrMo alloy samples are processed using an Additive Manufacturing process, i.e., LENS, using gas atomized spherical powder (size 40-150 μm) to provide a supply of CoCrMo alloy content. The sample input parameters are powder rate (5 g/min), laser power (350 W), and laser scanning rate (20 mm/s), as shown in Table 1. Generally, the heat treatment on metals is carried out to enhance the hardness and other mechanical properties by heating the samples to above the recrystallization temperature, holding at the same for specified time and then cooling within air/furnace/by means of water/oil. Sudden cooling with water or oil (Solution treatment) improves hardness but to ensure the uniformity in the grains the solution treatment is followed by ageing which comprises of heating holding and cooling in furnace (slow cooling).The ageing temperature, solution and ageing times and are used as process parameters following L9 Orthogonal arrays, ensuring constancy of solving temperature (1200 °C).  Figure 1 depicts the as-prepared sample via the LENS deposition method. All the samples are tested for their corrosion resistance using electrochemical analysis, and at least 3000 readings were collected for each sample. The data of electrochemical measurements have been used to build the proposed NN model.

Computational Method
The experimental data gathered from previous literature work was analyzed. The inputs and outputs needed for the overall process of the ANN approach were selected accordingly. The cumulative experimental data to train, test, and validate processes were split into 60%, 20%, and 20% data sets, respectively. The proposed model was developed using MATLAB 2020 b, which is the leading mathematical software. MAT-LAB is a programming environment for algorithm creation, interpretation of data, modelling, and numerical computing and is widely used by engineers and researchers. The ANN was trained based on Bayesian Regularization (BR) algorithm. The purpose for selecting BR-based ANNs is-they can handle many complex datasets and can differentiate between dependent and independent variables in complex, non-linear connections. Once input and relations are known, invisible data often assess the unseen relationships in order to generalize and predict the model with unseen data. This type of technique's benefit is the capability of robustness than usual back-propagation networks and can decrease or remove the necessity for long cross-validation. Here, a neuron has a role in adding each source neuron's value in the previous column with which it is connected. Until applying this factor, the relation between the two neurons is recorded by an additional element called "weight" (w1, w2, w3). The only value that can be modified during the learning cycle was the neurons' weight at each connection. The weight values strongly play an important role in determining the output for the given input values [25]. The weights values are multiplied with input values and added with a bias to obtain the least possible error as per Eq. 1 [26]. Furthermore, the calculated total value will be added with a bias value. Finally, the neuron applies a function named "activation function" to the obtained values after all these summations. The process of these calculations with a computational rule can be seen in Fig. 2. where,x new is new value, w is weight, and b is bias.
The coefficient of determination (R 2 ) and mean square error (MSE) values were calculated as per Eq. 1 and 2 during the training process of Bayesian Regularization-based Artificial Neural Network (BRANN). (1) where n is the no. of sample values, y p , y a and y avg are predicted, actual and average of actual values.
The models were eventually tested and validated with separated data sets. In order to further assess the new analysis, the conclusions presented for BRANN are then applied to previously conducted work. The entire workflow suggested for this analysis is presented in Fig. 3.
During the development of BRANN, the parameters such as solution time, aging time, aging temperature, and corrosion test time are considered as inputs, whereas the Ln (corrosion rate) and Ewe (stationary potential measurement for corrosion) are considered as outputs. Figure 4 represents the traditional BRANN architecture. The first layer is made of input parameters, the hidden layer is made of hidden neurons and the outgoing layers are made up of Ln and Ewe.

Results and Discussion
The findings of the LENS deposited, as well as the heattreated CoCrMo samples, have been explained in the following section. Tafel plots have been taken as the basis to analyse both cases.

Potentiodynamic Curves
The potentiodynamic curves or Tafel plots of the samples S1 to S9, subjected to corrosion test, are shown in Fig. 5. On analysing the plots and the corresponding Corrosion current and potential, it was observed that all the samples had exhibited good corrosion resistance and all the samples have undergone pitting type of corrosion. Still, the sample S7, which was solutionized for 3600 s and atmospherically aged for 21,600 s, has shown the maximum corrosion resistance among the samples verified. Figure 5 shows the comparison of sample 7, before and after corrosion. However, the reasons for the same were already discussed elsewhere [27] by one of the authors. Now, the main focus of this study is on predicting corrosion behavior with other temperatures and times.
(2)  Table 2. The representation of activation functions used in the training of BRANN is shown in Fig. 6.

Training of BRANN
During the training process, the divided training dataset from the experimental data were used. The R 2 values during the training process for all the nine samples, S1, S2, S3, S4, S5, S6, S7, S7, S8, and S9, are found to be satisfactory, with the values of 0.999 each. The R 2 values obtained in the training stage are illustrated in Table 2. The summary of all the training R squared plots of all nine samples is shown in Fig. 7.
The number of data sets values for each sample is equal during the training phase of a model. However, data are divided into identical proportions for the development of the (4) tansig(n) = 2 1 + e − 2n − 1 (5) Purlin (n) = f(n) = n model, with a ratio of 60%, 20% and 20% for training, testing, and validation stages, respectively. In the training process, the BRANN was developed for all samples using 1800 values. Figure 8S1-S9 demonstrates the training results for the BRANN proposed for each sample. Figure 8 shows that the qualified BR-based ANN is best conducted to predict real data sample values. Thus, the findings obtained indicate that the suggested approach created the least output error.

Testing of BRANN
Upon completing the training process, the performance of the proposed BRANN is tested using the divided testing dataset. The R 2 values during testing were satisfactory with the values of 0.999 for all nine samples S1-S9, respectively. The R 2 values obtained in the training stage are presented in Table 2. The summary of all the testing R squared plots of all nine samples is shown in Fig. 9.
In a model's testing process, the number of data sets values for each sample is equivalent. For all samples, the BRANN was established using 600 values during the testing process. The testing stage's performance for the suggested BRANN for each sample is shown in Fig. 10S1-S9. The simplest way to estimate actual data sample values is to use the professional BR-based ANN. The testing results thus demonstrate that the proposed solution produced the least performance error.

Validation of BRANN
For certain random unseen values, the BRANN approach has predicted the new values truthfully. The forecasts made for all 9 samples are shown in Fig. 11S1-S9. The shifts from sample to sample can be seen. But for this experimental unsightly data collection, the proposed BRANN model  Fig. 11. The plot indicates the model made accurate predictions for both Ln and Ewe for given sample values. The summary of prediction accuracies for all the 9 samples is given in Table 3.

Comparison Study
A comparison study is made after conducting experiments with BRANN to predict the corrosion behavior of CoCrMo alloy. As stated earlier in this article, few researchers have used different tools to predict different metals' prediction behavior. A few previous articles were selected for the comparison, and the findings are shown in Table 4. The findings revealed that the existing model succeeded previous works during the comparative study, supporting robustness.

Summary and Future Prospective
Bayesian Regularization-based Artificial Neural Network approach was proved as a corrosion prediction tool for additive manufacturing of CoCrMo Alloy. The results

Conflicts of interest
On behalf of all authors, the corresponding author states that there is no conflict of interest.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing,

Fig. 11
Actual and predicted values for corrosion behavior of LENS deposited samples (S1 to S9) adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons. org/licenses/by/4.0/.