An Improvement in Biodiesel Production from Waste Cooking Oil by Applying Thought Multi-Response Surface Methodology Using Desirability Functions

The exhaustion of natural resources has increased petroleum prices and the environmental impact of oil has stimulated the search for an alternative source of energy such as biodiesel. Waste cooking oil is a potential replacement for vegetable oils in the production of biodiesel. Biodiesel is synthesized by direct transesterification of vegetable oils, which is controlled by several inputs or process variables, including the dosage of catalyst, process temperature, mixing speed, mixing time, humidity and impurities of waste cooking oil that was studied in this case. Yield, turbidity, density, viscosity and higher heating value are considered as outputs. This paper used multi-response surface methodology (MRS) with desirability functions to find the best combination of input variables used in the transesterification reactions to improve the production of biodiesel. In this case, several biodiesel optimization scenarios have been proposed. They are based on a desire to improve the biodiesel yield and the higher heating value, while decreasing the viscosity, density and turbidity. The results demonstrated that, although waste cooking oil was collected from various sources, the dosage of catalyst is one of the most important variables in the yield of biodiesel production, whereas the viscosity obtained was similar in all samples of the biodiesel that was studied.


Introduction
In recent scenarios, the consumption of energy has increased greatly due to the change in life styles and the significant growth of population.This increase of energy demand has been supplied by the use of fossil resources, which is having a serious environmental impact on global warming and deforestation.Fossil fuels are limited sources of energy.Thus, this increasing demand for energy has led to a search for an alternative, renewable fuel, such as biodiesel.Biodiesel is renewable, clean and environmentally acceptable as it is derived from vegetable oils and animal fats [1].Waste cooking oil could be a potential replacement for vegetable oils for the production of biodiesel due to its low raw material cost and because it solves the disposal problem [2,3].The quantity of waste cooking oil that is generated annually is immense, and the methods of disposal of waste cooking oil are problematic as the may contaminate water in the environment.The amount of waste cooking oil that each country generates varies with the use of the vegetable oil.The potential amount of waste cooking oil to be collected in Spain is estimated at 150 million liters per year [4].
Production of biodiesel from waste cooking oils involves a fossil energy saving of 21% in comparison to the use of crude oil, and an energy saving of 96% compared to fossil diesel production [5].Each kilogram of collected waste cooking oil can be converted into 0.92-0.97kg of biodiesel.The production of biodiesel from waste cooking oil is one of the best ways to utilize it efficiently and economically.Biodiesel is synthesized by direct transesterification of vegetable oils, in which the corresponding triglycerides react with a short-chain alcohol in the presence of a catalyst.The catalyst improves the solubility and hastens the reaction [6,7].Typically used alkaline catalysts are sodium hydroxide (NaOH) and potassium methoxide (KOCH 3 ) [8].The transesterification process is influenced by several process variables.The type and dosage of catalyst, process temperature, agitation speed, agitation time, water content and impurities, are the main variables that affect biodiesel yield [9,10].Thus, the amount and type of products that are formed during frying affect either the biodiesel properties or the transesterification reaction.For example, the water in waste cooking oil affects the methyl ester yield by favoring a saponification reaction [11][12][13].To remove the undesirable compounds in waste cooking oil, pretreatment is necessary prior to transesterification.The transesterification process involves many variables that affect the reaction.In addition, optimizing so many reaction factors requires a great number of experiments, which are laborious, time-consuming, and not economically viable.Accordingly, a few investigators have used response surface methodology (RSM) to minimize the number of experiments that are necessary to find an optimal combination of process or input variables.Furthermore, due to the simultaneous effects of some process variables on the system, the designed application of modeling tool, such as the RSM response, are essential for maximizing productivity and reducing the costs of the production process.RSM is a statistical method that is used widely to model and optimize processes.It uses the input variables of the process and their responses or outputs to identify the combined effect of the input variables and to obtain the best response [14].RSM attempts to replace the implicit functions of the original design optimization problem with an approximation model that is traditionally a polynomial function (regression model) and, therefore, less expensive to evaluate.When there is more than one output, several response surfaces should be optimized using Multi-Response Surface Methodology (MRS).This paper used MRS with desirability functions [15] to find the best combination of input process variables in biodiesel production from waste cooking oil in several optimization scenarios.The dosage of catalyst, process temperature, mixing speed, mixing time, humidity and impurities of waste cooking oil are the input variables that were considered in this case.The outputs studied are: yield, turbidity, density, viscosity and high heating value (HHV) (Figure 1).Production of biodiesel from waste cooking oils involves a fossil energy saving of 21% in comparison to the use of crude oil, and an energy saving of 96% compared to fossil diesel production [5].Each kilogram of collected waste cooking oil can be converted into 0.92-0.97kg of biodiesel.The production of biodiesel from waste cooking oil is one of the best ways to utilize it efficiently and economically.Biodiesel is synthesized by direct transesterification of vegetable oils, in which the corresponding triglycerides react with a short-chain alcohol in the presence of a catalyst.The catalyst improves the solubility and hastens the reaction [6,7].Typically used alkaline catalysts are sodium hydroxide (NaOH) and potassium methoxide (KOCH3) [8].The transesterification process is influenced by several process variables.The type and dosage of catalyst, process temperature, agitation speed, agitation time, water content and impurities, are the main variables that affect biodiesel yield [9,10].Thus, the amount and type of products that are formed during frying affect either the biodiesel properties or the transesterification reaction.For example, the water in waste cooking oil affects the methyl ester yield by favoring a saponification reaction [11][12][13].To remove the undesirable compounds in waste cooking oil, pretreatment is necessary prior to transesterification.
The transesterification process involves many variables that affect the reaction.In addition, optimizing so many reaction factors requires a great number of experiments, which are laborious, time-consuming, and not economically viable.Accordingly, a few investigators have used response surface methodology (RSM) to minimize the number of experiments that are necessary to find an optimal combination of process or input variables.Furthermore, due to the simultaneous effects of some process variables on the system, the designed application of modeling tool, such as the RSM response, are essential for maximizing productivity and reducing the costs of the production process.RSM is a statistical method that is used widely to model and optimize processes.It uses the input variables of the process and their responses or outputs to identify the combined effect of the input variables and to obtain the best response [14].RSM attempts to replace the implicit functions of the original design optimization problem with an approximation model that is traditionally a polynomial function (regression model) and, therefore, less expensive to evaluate.When there is more than one output, several response surfaces should be optimized using Multi-Response Surface Methodology (MRS).This paper used MRS with desirability functions [15] to find the best combination of input process variables in biodiesel production from waste cooking oil in several optimization scenarios.The dosage of catalyst, process temperature, mixing speed, mixing time, humidity and impurities of waste cooking oil are the input variables that were considered in this case.The outputs studied are: yield, turbidity, density, viscosity and high heating value (HHV) (Figure 1).

Materials
To prepare biodiesel by NaOH catalyzed transesterification, used cooking sunflower oils of domestic origin were collected from various local restaurants and used as raw materials.Prior to transesterification, these samples of waste cooking oils were filtered by a cellulose filter to remove any insoluble impurities and heated at 100 °C for 10 min to remove most of the moisture.All chemicals, including methanol (98%) and NaOH, were of analytical reagent grade.Experiments were

Materials
To prepare biodiesel by NaOH catalyzed transesterification, used cooking sunflower oils of domestic origin were collected from various local restaurants and used as raw materials.Prior to transesterification, these samples of waste cooking oils were filtered by a cellulose filter to remove any insoluble impurities and heated at 100 • C for 10 min to remove most of the moisture.All chemicals, including methanol (98%) and NaOH, were of analytical reagent grade.Experiments were conducted Energies 2017, 10, 130 3 of 20 in a laboratory scale setup, with 50 mL of the oil heated to the desired temperature using a water bath and a magnetic hot plate stirrer with a temperature controller.The speed of the stirrer was kept constant throughout each experiment.The amounts of NaOH and methanol were then added to the oil.The heating and stirring were stopped after the reaction had reached the preset reaction time.The biodiesel was washed by deionized water several times until the waste water had become clear.This biodiesel then was added to glass containers and were subsequently analyzed to determine the yield (η), turbidity (Turb), density (ρ), viscosity (µ) and higher heating value (HHV).

Response Surface Method for Optimizing Biodiesel
The RSM method seeks to establish the relationships between input variables (i.e., independent variables) and one or more output variables (i.e., response variables).Box and Wilson introduced it in 1951 [16] for experimental data that were gathered to provide a model or optimal response.RSM was developed originally to model experimental responses, but has been used with other techniques to optimize industrial processes and products [17,18].Essentially, RSM consists of a collection of statistical techniques that use a regression model that relies on a low-degree polynomial function (Equation ( 1)): where Y is an experimental response, f is a function that consists of cross-products of the polynomial's terms, X 1 , X 2 , X 3 . . ., X k are the input vectors and e is an error.The quadratic model (second-order) is a commonly used polynomial function.It is seen in Equation ( 2): where the linear part is the first summation, the quadratic part is the second part and the product of the pairs of all variables is the third part.The values of coefficients b 0 , b i , b ii and b ij are determined by regression analysis, although these functions do not always provide good results for complex problems that involve many nonlinearities and inputs.The reason is that they cannot be adjusted when the data are sparse as they are continuous functions that are defined by polynomials.The p-value (or Prob.> F) is defined as the probability of obtaining a result that is equal to or greater than what was actually observed.This assumes that the model is accurate.The p-value can be computed by analyzing the variance (ANOVA).If it exceeds the model's F and the model has no term that exceeds the significance level (e.g., α = 0.05), the model will suffice within a confidence interval of (1-α).Some researchers have used ANOVA to determine the effect of the process variables or inputs on the process outputs [19,20].If there is more than one output for a problem, the latter is described as MRS.It causes and suggests that outputs are in conflict, because the optimal configuration may differ greatly from one output to output.Harrington [15] suggested a compromise.It provides desirability functions for each output, Equations ( 3) and (4), as well as an overall desirability, namely the geometric mean of the D (desirability) of each output (Equation ( 5)): Energies 2017, 10, 130 where A and B are the limiting values, s is an exponent that indicates the importance of achieving the target value, X is the input vector and f r is the model for prediction.It is desirable to use a second higher degree polynomial to optimize responses [21].In the desirability approach, each estimated response is transformed into a unit-less utility that is bounded by 0 < d r < 1.A higher value of d r indicates a more desirable response value.The optimization aspect of the R package v.1.6[22] looks for a combination of importance factors (or weights from 1 to 3) that satisfies the process criteria of each response and input.

Experiments Design
In order to create accurate models with the minimum amount of data to support the initial hypotheses, RSM must establish a design of experiments (DoE) [23].Several methods have been suggested.However, this requires a design matrix (inputs) to be constructed in order to measure the response or outputs.A Box-Behnken design (BBD) [24] with three factors and three levels was used in this case.The input variables that were used to develop the DoE were methanol/oil molar ratio (M), catalyst (C), temperature (T), speed (S), time (t), humidity (H) and impurities (I).The experimentally selected factors for optimization and their respective ranges were as follows: methanol/oil molar ratio (6:1-9:1), quantity of NaOH catalyst (1-2 wt.%), reaction temperature (20-40 • C), reaction speed (500-1000 rpm), humidity (0-3 wt.%) and impurities (0-3 wt.%).The variable ranges that are provided in Table 1 were adopted to cover the intervals that commonly are utilized in literature [25][26][27][28][29]. Once the inputs and levels have been set as in Table 1, the design matrix and their corresponding combination of operating conditions are generated using the Statistical Software R (R Development Core Team, Auckland, New Zealand) [30].In this case, 56 experiments are needed to cover the entire range of possibilities and to determine the optimal production of biodiesel.The design matrix (see Table 2) shows the number of experiments and the corresponding values for the combination of variables (ratio oil, catalyst, temperature, speed, time, humidity and impurities).The response variable that was used to select the biodiesel yield was established in each experiment after phase separation.The biodiesel yield can be calculated using Equation ( 6) [31]: In addition to yield, the following variables were determined in the final biodiesel product: turbidity measurements were carried out with a 2100Q Turbidimeter (Hach Company, Loveland, CO, USA).Kinematic viscosity values were determined with Cannon-Fenske viscometers (Cannon Instrument Co., State College, PA, USA) at a temperature of 40 • C following the standard ASTM D445 method [32].Density measurements were carried out using a pycnometer according to ASTM D941 [33].The HHV of the biodiesel was obtained in a bomb calorimeter (Parr-1351, Parr Instrument Company, Moline, IL, USA), according to the ASTM D2015 standard method [34].

Using Response Surface Methodology to Optimize Biodiesel Variables
The reaction conditions for pretreatment and biodiesel production have been optimized using RSM by many authors.For example, the RSM technique was applied by Mumtaz et al. [35] for optimization of biodiesel production from rice bran and sunflower oils.Mansourpoor and Shariati [36] used the RSM technique to optimize the biodiesel production from sunflower oil.Yuan et al. [37] studied the use of waste rapeseed oil with high free fatty acids as feedstock for production of biodiesel using RSM to optimize the conditions for maximum conversion to biodiesel and understand the significance and interaction of the factors affecting the biodiesel production.The biodiesel yield was obtained by Dhingra et al. using the RSM technique on Karanja oil using KOH as catalyst [38].
Several researchers have used the RSM to obtain the optimal combination of inputs or process variables in biodiesel yield.However, most of this work is based on the modeling and optimization of relatively few output and input variables.This makes the optimization problem much easier.For example, Aworanti et al. [39] investigated the effects of methanol to oil molar ratio, catalyst amount and reaction time on the transesterification of waste cooking oil to biodiesel using RSM.Omar et al. [40] used RSM to study the relationship of methanol to oil molar ratio, catalyst loading, reaction time and reaction temperature on methyl ester yields and free fatty acid conversion in heterogeneous transesterification of waste palm cooking oil to biodiesel by Sr/ZrO 2 catalyst.
Other authors, such as Noshadi [41], have investigate the process variables that affect acid-catalyzed transesterification of waste cooking oil with methanol in a continuous reactive distillation column, in order to better understand the relationship between operating conditions and the response yield, and to determine the optimal condition of the process using RSM.Rashid et al. [42] applied RSM with central composite rotatable design to explore the optimum conditions for transesterification of Moringa oleifera oil.The four process input variables that were considered were reaction temperature, reaction time, methanol/oil molar ratio and catalyst concentration.
Furthermore, Hameed et al. [43] studied the influence of process variables (methanol/oil molar ratio, reaction time and amount of catalyst) on the production of biodiesel from palm oil using KF/ZnO catalyst.In this case, the effects of three transesterification process variables were studied simultaneously on the response (yield) using RSM based on central composite design (CCD).Ghoreishi and Moein [44] applied RSM to analyze the effect of four independent variables (molar ratio of methanol to oil, reaction temperature, pressure and time) on the yield of the biodiesel production by the supercritical methanol method.Waste vegetable oil was used as raw material and the transesterification reaction took place in a supercritical batch reactor.In a similar fashion, Azócar et al. [45] studied the application of waste frying oil mixed with rapeseed oil as a feedstock for the effective production of fatty acid methyl esters in a lipase-catalyzed process.RSM was used to optimize the interaction of four variables: the percentage of waste frying oils (WFO) in the mixed feedstock, the methanol-to-oil ratio, the dosage of Novozym as a catalyst and the reaction temperature.Pullen and Saeed [46] studied the effects of catalyst type, number of reaction stages, the free fatty acid and moisture content for optimized biodiesel production from rapeseed oil.De Paola et al. [47] used a factor analysis to evaluate the effect of process variables on yields of biodiesel production from husk oil.The two variables considered are mixing rate and enzyme loading, since it has been recognized that they affect process performance singularly and through interaction effects.Furthermore, Ghadge and Raheman [12] used a central composite rotatable design to study the effect of methanol quantity, acid concentration and reaction time on the reduction of free fatty acid content of mahua oil during its pre-treatment for the production of biodiesel.Each of the three variables significantly affected the acid value of the product, with methanol being the most effective followed by reaction time and acid catalyst concentration.Using response surface methodology, a quadratic polynomial equation was obtained for acid value by multiple regression analysis.
Kim et al. [48] studied the optimization of experimental variables, such as catalyst type, catalyst concentration, and molar ratio of methanol to oil and reaction temperature, on the transesterification for the production of rapeseed methyl ester.According to the Taguchi method, the catalyst concentration played the most important role in the yield of rapeseed methyl ester.
More recently, Dwivedi and Sharma [49] implemented the Box-Behnken response surface methodology for maximizing biodiesel yield from Pongamia oil by optimizing four process variables.They were: methanol-to-oil molar ratio, catalyst (KOH) concentration, reaction temperature and reaction time.Hamze et al. [29] applied RSM based on Box-Behnken design to investigate the effects of the main process variables, including the methanol-to-oil molar ratio, catalyst concentration, and reaction temperature, on the biodiesel yield.The results revealed that the catalyst concentration is the most important parameter.
In this study, the biodiesel variables or outputs of yield, density, viscosity and high heating value were optimized when the input or process variables were the methanol-to-oil molar ratio, the dosage of catalyst, process temperature, mixing speed, mixing time, humidity and impurities of waste cooking oil.

Experimental Results
Table 3 shows the experimental results obtained for the output variables (η, Turb, ρ, µ, and HHV) according to the Box-Behnken DoE design matrix (Table 2).

Analysis of Variance
Equation (2) was fitted using the data shown in Table 2 to obtain regression equations for all responses with the use of the R Base package [30,50].For each response, second-order polynomial models were constructed.Then, the most accurate model was selected with the use of several criteria (R2, p-value, mean absolute error (MAE) and root mean square error (RMSE)).
Equations ( 7)- (11) show the second-order polynomial functions that were obtained to model yield (η), turbidity (Turb), density (ρ), viscosity (µ) and high heating value (HHV).These equations show Tables 4-8 show the results of ANOVA for each of the final quadratic models.The p-value of most process variables is less than 0.01.Thus, the variables used for quadratic models are statistically significant.The multiple correlation coefficient (R 2 ) is a measure of the variation about the mean of the values provided by the regression model.All values of R 2 in the following results are close to 1.This indicates that these models have good predictive capability.MAE and RMSE are calculated to determine the generalization capacity of the quadratic models using the samples shown in Table 4 according to Equations ( 12) and ( 13): In this case, Y kExperiment are the experimentally-obtained responses, and Y kModel are responses from the quadratic models that RSM and m experiments produced.Prediction errors are shown in Table 9.The maximum error corresponds to η (MAE equal to 10.445 and RMSE equal to 12.803), and the minimum error corresponds to ρ (MAE equal to 0.009 and RMSE equal to 0.012).
Figure 2 shows the relationship between the actual values that were obtained experimentally (Table 1) and the predicted (quadratic models) values of η (Figure 2a), Turb (Figure 2b), ρ (Figure 2c), µ (Figure 2d), and HHV (Figure 2e).The figures show that these models suffice for the prediction of these values, as the residuals that were obtained are small and the correlations between actual and predicted values are high.Figure 2 shows the relationship between the actual values that were obtained experimentally (Table 1) and the predicted (quadratic models) values of η (Figure 2a), Turb (Figure 2b), ρ (Figure 2c), µ (Figure 2d), and HHV (Figure 2e).The figures show that these models suffice for the prediction of these values, as the residuals that were obtained are small and the correlations between actual and predicted values are high.In order to test the proposed models, 15 new experiments that had not been used during the training process were conducted (See Table 10).Table 11 shows the errors obtained from the 15 new experiments.The maximum error corresponds to η (MAE equal to 15.081 and RMSE equal to 22.853), and the minimum error corresponds to ρ (MAE equal to 0.063 and RMSE equal to 0.066).

Multi-Response Optimization
Tables 12-20 show the combination of process variables that were studied in examining the biodiesel production process by means of desirability functions using the Desirability package [51] according to nine different criteria.The first and second columns show, respectively, the inputs and outputs that were studied, and the goal that was established in the optimization process.The third column shows the degrees of importance considered in the optimization process.Finally, the fourth column shows the optimized values obtained and the fifth column shows the desirability values.
Table 12 shows the results when the design requirements that are based on yield production, turbidity, density, viscosity and HHV of biodiesel were considered with the same level of importance (equal to one).In this case, the value of the overall desirability was 0.710.
Table 13 shows the results when the design required were based on maximizing yield were considered with a higher level of importance than other process criteria.The goal that was established was a value of three (maximum), and the overall desirability obtained was 0.709.Table 14 shows the results when the design requirements that were based on minimize turbidity.The overall desirability obtained was 0.710.Table 15 shows the results when the design requirements were based on minimizing the density and viscosity.The overall desirability obtained in this case was 0.467.Table 16 shows the results when the design requirements were based on maximizing the H.The overall desirability obtained was 0.626.Table 17 shows the results when the design requirements were based on minimizing the density and viscosity.The overall desirability obtained in this case was 0.710.Table 18 shows the results when the design requirements that were based on minimizing the speed of agitation.The overall desirability obtained was 0.710.Table 19 shows the results when the design requirements were based on minimizing the time.The overall desirability obtained in this case was 0.710.Finally, Table 20 shows the results when the design requirements were based on minimizing the molar ratio oil.The overall desirability obtained in this case was 0.710.From the results that appear in Tables 12-20, it can be seen that the process variables are very similar for all different design requirements that were studied.Thus, for example, the ranges of values for the molar ratio oil for the different design requirements that were studied extend from 6.06-7.35,whereas the ranges for the catalyst was 0.73 wt.%-0.78 wt.%.The time and speed of agitation were, respectively, 19.98-20 s and 499.96 rpm-500.01rpm, and the temperature varied from 20-33.70 • C. In addition, the humidity and impurities in the waste cooking oil were, respectively, 0 wt.%-1.82 wt.% and 0.77 wt.%-2.70 wt.%.  show that the values of humidity and impurity are practically zero.This indicates that, as the humidity and impurity values increase, the rest of the variables (η, Turb, ρ, µ, and HHV) decrease.From these results, it follows that the optimal process variables for different design requirements were found in a relatively narrow range.
Once the different biodiesel optimization scenarios were obtained, nine new experiments according to the combination of process variables that appear in Tables 12-20 were prepared in order to determine the accuracy of the proposed methodology.Table 21 shows the values of different biodiesel outputs according to the nine biodiesel optimization scenarios that were studied.This table shows that the experimentally-obtained values for the nine biodiesel optimization scenarios did not differ significantly from those that application of the MRS methodology produced (see the results of Tables 12-20).In this case, in order to compare the different errors in predicting the outputs according to the nine design requirements under study, MAE and RMSE were obtained from the normalized data.It is common practice to normalize the data in statistical processes so that all variables use the same scale (i.e., 0-1).In this case, the data were normalized by subtracting the minimum value from each original value and dividing by the range of each variable as shown in Equation ( 14): where Y k,norm are the normalized outputs of the models that were developed with RSM and of those that were obtained experimentally.The error that appears in the last two columns represents the MAE and RMSE that were normalized for each variable in each of the nine biodiesel optimization scenarios that were studied.However, the normalized MAE and RMSE in the last two rows correspond to the errors in each of the outputs that were studied.For example, when minimize the turbidity is considered to be an optimization variable for biodiesel production, the errors obtained are the smallest (MAE = 0.04 and RMSE = 0.02), but when minimize the viscosity and density are considered, the error is the largest (MAE = 0.12 and RMSE = 0.08).In contrast, the maximum errors obtained for each of the outputs are lower when predicting viscosity (MAE = 0 and RMSE = 0.01) and greater when predicting turbidity (MAE = 0.03 and RMSE = 0.09).In addition, the values of MAE and RMSE that were obtained for each of the different outputs are all in acceptable agreement according to the texting error.

Conclusions
This work was carried out to investigate yield, turbidity, density, viscosity, and HHV of biodiesel from waste cooking oil.Response surface methodology based on the Box-Behnken design was used to study the effects of the process variables on the biodiesel production from waste cooking oil.According to the ANOVA, the results obtained demonstrated that, although waste cooking oil was collected from different sources, the molar ratio and dosage of catalyst are one of the most important factors in the yield of biodiesel production (see Table 4), whereas the humidity is one of the lowest factor.In addition, humidity and impurities are one of the most important factor for increasing the turbidity (see Table 5), whereas for the HHV the dosage of catalyst is the most important factor (see Table 8).Finally, the dosage of catalyst is one of the most important factors in the biodiesel production.The optimal conditions for maximum yield were found to be: molar ratio of 6.52, catalyst loading of 0.78 wt.%, reaction time of 19.99 min, reaction speed of 499.67 rpm, temperature of 24.44 • C, humidity of 0.21 wt.%, and impurities of 0.17 wt.%.The maximum biodiesel yield under these conditions was 100%.In addition, the optimal conditions for maximum heating value were found to be: molar ratio of 6.4, catalyst loading of 1 wt.%, reaction time of 20 min, reaction speed of 499.6 rpm, temperature of 33.7 • C, humidity of 0.21 wt.%, and impurities of 0.16 wt.%.The maximum biodiesel yield under these conditions was 100%.In conclusion, the optimal conditions for humidity and impurities in all biodiesel optimization scenarios were closest to the minimum values of the range (0 wt. %, and 0 wt.%).The fuel properties of the biodiesel complied with international standards.Thus, the present study confirmed the high quality of the biodiesel that was produced from waste cooking oil.

Figure 1 .
Figure 1.Inputs and outputs variables in transesterification process of Biodiesel production.

Figure 1 .
Figure 1.Inputs and outputs variables in transesterification process of Biodiesel production.

Table 1 .
Independent variables and experimental design levels used with the Box-Behnken design (BBD) method.

Table 2 .
Design matrix for transesterification of waste cooking oil.

Table 3 .
Design experimental matrix for transesterification of waste cooking oil.

Table 4 .
Analysis of Variance (ANOVA) table for the "η" quadratic model.

Table 5 .
Analysis of Variance (ANOVA) table for the "Turb" quadratic model.

Table 6 .
Analysis of Variance (ANOVA) table for the "ρ" quadratic model.

Table 7 .
Analysis of Variance (ANOVA) table for the "µ" quadratic model.

Table 8 .
Analysis of Variance (ANOVA) table for the "HHV" quadratic model.

Table 10 .
Test matrix for transesterification of waste cooking oil.

Table 10 .
Test matrix for transesterification of waste cooking oil.

Table 11
shows the errors obtained from the 15 new experiments.The maximum error corresponds to η (MAE equal to 15.081 and RMSE equal to 22.853), and the minimum error corresponds to ρ (MAE equal to 0.063 and RMSE equal to 0.066).

Table 12 .
The first biodiesel optimization scenario: all variables considered to equally important.

Table 13 .
The second biodiesel optimization scenario: maximizing yield.

Table 15 .
The fourth biodiesel optimization scenario: minimizing the density and viscosity.

Table 16 .
The fifth biodiesel optimization scenario: maximizing the HHV.

Table 17 .
The sixth biodiesel optimization scenario: minimizing the dose of catalyst.

Table 18 .
The seventh biodiesel optimization scenario: minimizing the speed of agitation.

Table 19 .
The eighth biodiesel optimization scenario: minimizing the time.

Table 20 .
The ninth biodiesel optimization scenario: minimizing the molar ratio oil.

Table 21 .
Experimental outputs that were obtained according to the nine biodiesel optimization scenarios.