Develop the artificial neural network approach to predict thermal transport analysis of nanofluid inside a porous enclosure

This study explores the impacts of heat transportation on hybrid (Ag + MgO) nanofluid flow in a porous cavity using artificial neural networks (Bayesian regularization approach (BRT-ANN) neural networks technique). The cavity considered in this analysis is a semicircular shape with a heated and a cooled wall. The dynamics of flow and energy transmission in the cavity are influenced by various features such as the effect of magnetize field, porosity and volume fraction of nanoparticles. To explore the outcomes of these features on hybrid nanofluid thermal and flow transport, a BRT-ANN model is developed. The ANN model is trained using a dataset generated through numerical scheme. The trained ANN model is then used to predict the heat and flow transport characteristics for various input parameters. The accuracy of the ANN simulation is confirmed through comparison of the predicted results with the results obtained through numerical simulations. By maintaining the corrugated wall uniformly heated, we inspected the levels of isotherms, streamlines and heat transfer distribution. A graphical illustration highlights the characteristics of the Hartmann and Rayleigh numbers, permeability component in porous material, drag force and rate of energy transport. According to the percentage analysis, nanofluids (Ag + MgO/H2O) are prominent to enhance the thermal distribution of traditional fluids. The study demonstrates the potential of ANNs in predicting the impacts of various factors on hybrid nanofluid flow and heat transport, which can be useful in designing and optimizing heat transfer systems.

Develop the artificial neural network approach to predict thermal transport analysis of nanofluid inside a porous enclosure Saleem Nasir 1,2* , Abdallah S. Berrouk 1,2* , Taza Gul 3 & Aatif Ali 4 This study explores the impacts of heat transportation on hybrid (Ag + MgO) nanofluid flow in a porous cavity using artificial neural networks (Bayesian regularization approach (BRT-ANN) neural networks technique).The cavity considered in this analysis is a semicircular shape with a heated and a cooled wall.The dynamics of flow and energy transmission in the cavity are influenced by various features such as the effect of magnetize field, porosity and volume fraction of nanoparticles.To explore the outcomes of these features on hybrid nanofluid thermal and flow transport, a BRT-ANN model is developed.The ANN model is trained using a dataset generated through numerical scheme.The trained ANN model is then used to predict the heat and flow transport characteristics for various input parameters.The accuracy of the ANN simulation is confirmed through comparison of the predicted results with the results obtained through numerical simulations.By maintaining the corrugated wall uniformly heated, we inspected the levels of isotherms, streamlines and heat transfer distribution.A graphical illustration highlights the characteristics of the Hartmann and Rayleigh numbers, permeability component in porous material, drag force and rate of energy transport.According to the percentage analysis, nanofluids (Ag + MgO/H 2 O) are prominent to enhance the thermal distribution of traditional fluids.The study demonstrates the potential of ANNs in predicting the impacts of various factors on hybrid nanofluid flow and heat transport, which can be useful in designing and optimizing heat transfer systems.

List of symbols u , v
Velocities components ms − www.nature.com/scientificreports/transportation in the exchangers used active and passive strategies.Passive processes demand surface models like a rough top and elongated interface of liquids, whereas active procedures need exterior forces like a spongy surface and permanent magnets [30][31][32] .The nanoparticles were subjected to an electrical force, which may have an impact on the nanofluid's morphology and mobility, energy transmission is improved by an applied electric field 33,34 .The perks of such a modification involve modest design and control, and low energy consumption 35,36 .Yang et al. 37 employed an experimental method to determine presence of thermal waves in lagging proportion observations.They tackled a planner motion scenario by utilizing the Laplace transformation method, taking into account a tubular transmitter capable of heating an extensive volume with no apparent limit.They were used in trials to test the procedure, and it was discovered that the ratio in sand is lower than that in thin pork.Under appropriate scale uncertainty, the time delay rates for both intervals were just under 1, indicating that no thermal waves were generated.In a perforated aperture, the Sheikholeslami research 38 modelled electrodynamic nanocomposites.In the presence of thermal radiations and an electric field, CVFEM was used to assist the modeling.Additionally, as the buoyancy forces and radiation factors climbed, the Nusselt number grows as well.Hamida et al. 39 used the Galerkin Finite Element Method (GFEM) to show heat transfer in a duct filled with hybrid nanofluids (HNFs) operating in an electromagnetic field.
This study, which was motivated by the aforementioned studies, clarifies the hydrothermal consequences of naturally occurring, laminar, magnetically driven Ag + MgO/H 2 O hybrid nanofluid flows inside of an enclosure.The inner circular boundary remains hot while the outside round boundary is turned frigid.The complete numerical simulation is carried out using the finite element method based on the control volume (CVFEM) which provide set of information for BRT-ANN.Analyze and evaluate the expected outcomes of BRT-ANNs that were developed using the training, testing and verification datasets with the recommended solutions provider.Both nanoparticles are used in various discipline like Nanocomposites are used in anti-cancer treatments, biosensors, heat exchangers, and other applications 40,41 , whereas MgO is used in a variety of other industries, including ceramics, electronics, petroleum products, catalysts, surface coating, and many more 42 .In this work Ag + MgO/H 2 O hybrid nanofluid has been permitted to grow the thermal performance.However, Ag + MgO resulted from the highest Nusselt number (φ = 0.05) among all experienced cases.The results also indicated that raising the concentration of nanoparticles by 0.01, together with increasing the voltage supplied for the electric field, could improve the Nusselt number by up to 5.19% and accelerate heat transfer in the channel, respectively.For the numerical solution in this study, MATLAB (version R2019b) is utilized.Major research challenges that should be investigated during the modelling are: • How do the velocity distributions and rate of heat transfer are affected by the Hartmann number, porosity factor, Rayleigh number and nanoparticle concentrations?• What elements substantially change the temperature of the hybrid nanofluid?
• How can we minimize/improve the other engineering quantities of interest with the suggested hybrid nano- fluid flow while proactively estimating the wall concentration?• How are the simulation model and ANN model successfully connected?

Description of the problem
To accomplish hybrid nanofluids, Ag and MgO are dissolved in water.In the presence of a magnetic field, the flow of a hybrid nanofluid is taken into consideration in an amorphous enclosure.In a perpendicular orientation, magnetization has been introduced.The interpretation of the sinusoidal wall pattern is The boundary condition of flow and geometry is shown in Fig. 1a.The governing mathematical models for the temperature simulation using the Boussinesq-Darcy force and non-equilibrium thermal theory are as tries to follow: where the relationship of hybrid nanofluids are defined as 12 : The k ef , and µ ef is

Here
The Koo-Kleinstreuer-Li model for k ef defines as follows [43][44][45] : whereas the function g ′ T, d p , φ for hybrid nanofluid is identified as, ( 6) The dimensionless form of partial differential system is where the non-dimensional factors are: Given that the inner side is presumed to be heated, the boundary requirements are as follows: Here the local and average Nusselt number, when the wall is cold:

CVFEM modelling and grid test
The suggested modeling approach shown in Eqs.(11-14) has been numerically solved using an advanced CVFEM procedure.The discrete form of partial differential equation is typically displayed in space using a globally determined coordinate system in the finite element approach.The proposed method uses hexahedral elements to discretize the physical domain.Elements are separated into smaller control volumes in the new destination.For excellent outcomes, it is important to consider the ideal grid design.The quantity of grids has a significant impact on the overall computational complexity and the reliability of model analyzed data.Adopting narrow grids, which result in significant discretization mistakes, causes inaccurate research outcomes.The round-off error, however, could grow to be much bigger than the truncation error if the grid is too narrow, which would produce less reliable results 6 .Therefore, choosing the appropriate quantity of grids is important 7 .In several CFD studies, the ideal grid size was determined through grid independence analysis.(Fig. 2) demonstrates the comparison between the current study and earlier available research showing a strong level of agreement which present the originality of the present research work.The grid independence test can identify which grid configuration yields the best overall numerical results with the least quantity of grids by analyzing the mathematical data achieved with various grid dimensions and intensities.The proper mesh has been utilized in each scenario and the solution range is not just evaluated on the grid size in CVFEM code.For perfect precision in the case of high grids, a more sophisticated computer has been employed to locate the solution.Figure 3a, illustrates the grid presentation of the suggested model.In order to meet the requirements of the grid sensitivity test, 15920 components are chosen for this mathematical calculation, as shown in Fig. 3b. (11) On all walls = � = 0, On the outer wall = θ s = 0, θ nf = 0, On the inner wallθ s = 1,

Nu loc dr
For the outcomes of the model expression, the MATLAB software's "CVFEM" function implements a numerical technique.The neural network is developed employing data source that considers variants connected to the proposed nanofluid movement mechanism in the regions 0 and 4. The CVFEM strategy, which utilizes configuration settings for iterations, consistency objective, and acceptance rate for solving prevalent mathematical equations, is adapted in MATLAB software to support the proposed neural network approach.

Designation of artificial neural networks modeling
The NF-tool (neural network fitting tool) is then used on a sequence similar to that described in 46,47 .A single neural network model is presented in Fig. 4a.The suggested network's structure is presented in Fig. 4b and the BRT-ANN is constructed employing MATLAB's NF tool with the appropriate settings of unseen neurons, testing datasets, training datasets, and validation datasets.Software is used to train a neural network's weight function via Bayesian Regularization backpropagation.To achieve optimization, the suggested BRT-ANN incorporates a multi-layer neural network structure with Bayesian Regularization backpropagation.The BRT-ANN procedure was implemented to obtain the results of a hybrid nanofluid flow in a porous cavity system using the NF-tool with 5 neurons in the hidden layer by varying Da, Ra, Ha and δs for various values.The datasets for learning, verification and evaluation were allocated 70%, 15%, and 15%, respectively.Tan-Sig formulation was utilized for transmission in ANN models with hidden nodes along with Purelin function was used for output nodes 48 .The transfer function can be changed in the manner described below:  Evaluating the predictive capability of ANN models is significant after the construction of ANN models and the obtaining of predicted results.The predictive performance of ANN models has been evaluated using the MSE (mean squared error), R (coefficient of determination) and error rate metrics.Below is a representation of the algorithms used to estimate the system performance 49,50 .

Results and discussion
A non-equilibrium simulation has been used to demonstrate how a magnetic field affects the mobility of hybrid nanofluids inside a perforated enclosure.For the high grid formulation, the computational technique (CVFEM) was employed.The results examine the impact of modifying the physical parameters like Rayleigh number,   www.nature.com/scientificreports/porosity factor and the Hartmann number.The thermophysical data of nanocomposites are presented in Table 1.
The profiles of velocity as well as their AE (absolute error) analysis graphs for two cases are shown in Figs. 5 and 6 for the BRT-ANN findings of the present model for two cases.The geometrical configuration and suppose boundary assumption and a sampler triangular element and its associated volume control are presented in Fig. 1a,b.Figure 2 and Table 2 illustrate how the results of the current study and previous research 35 and 36 have Table 1.Ag and MgO nanoparticles thermophysical characteristics 21,22 .been validated.Table 3 displays the collected data, which illustrate that the Nu variations dropped as the mesh quality grew, leading us to the conclusion that the highest grade, extra fine mesh guaranteed correct results.The numerical changes in Nu ave against Ha for the various values of φ Ag and φ MgO are shown in Table 4.The results of BRT-ANN for the flow model to solving various cases are presented in Table 5.This outcome presents that the attained finding is comparable to the available work considering common parameters.Figure 3a is the representation of the suggested model for the number of grids in smaller and higher while Fig. 3b  www.nature.com/scientificreports/varies with an increasing number of epochs, and demonstrate that the regression results for the final gradient are almost zero.Additionally, the graphs display fluctuations in the values of mu, that imitate changes in the BRT-ANN weights.The results represent that as the quantity of epochs rises, then the numbers of smallest gradient coefficient keep falling, eventually resulting in the adoption of the excellent and suitable levelsof errors from BRT-ANN models after several testing process.These outcomes show that the ANNs' training operations were successfully finished.The training stages of BRT-ANN models are depicted in Fig. 7a,b, where the x-axis represents the target values and the y-axis displays the BRT-ANN predictions (output) for two cases.The solid compatibility (fit) line exhibits the graphical representation of the data points collected during the training process.The R value denotes the magnitude of the relationship between the target and output values, and the solid line shows the linear regression line that fits the target and output values.The computation of the regression analysis resulted in an R = 1, a precise linear correlation between the output and the targeted values.These findings demonstrate that the BRT-ANN models have effectively completed the trainings mood with minimal levels of error.Figure 8a illustrates how the velocity of the nanofluid decreases with an increase in φ 1 , φ 2 due to an improvement in the nanoparticle volume fractionSuch findings suggest that the BRT-ANN simulation magnificently ended the training stage with very little error.The impact of the magnetic component on the resulting nanofluid flow is depicted in Fig. 8b. Figure 8c the error analysis for distincet epochs.Actually, the graphs show that M has a diminishing impact on the dynamical profiles connected to nanofluid velocity.It is significant to analyze the error histogram to measure the efficiency of BRT-ANN models.Figure 9a,b provides a graphical representation of the predicted errors from multilayer perceptron network models by subtracting the outputs from the targets for two selected cases.The visualizations of the error histograms show that the errors from each stage of the BRT-ANN model are relatively small.It is clear that errors build up as they approach the zero-error line.As compared to the baseline error with surrounding errors, the average error bin for the developed BRT-ANN models is 6.8 × 10 −7 , 2.64 × 10 −6 respectively.

Properties
The influence of various model flow parameters such as Ra and Ha on the velocity filed in the axially and rotational magnitudes were shown in Figs. 10 and 11.The fluid flow pattern is defined by the Rayleigh number in regard to buoyancy-driven flow, commonly known as free convection.Since the conduction stage is steady and the convectional motion of fluid is minimal for low Rayleigh numbers, the energy trajectories have the same pattern.The thermal boundary layer on the surface of the inner wall thins as the Ra rises gradually ( Ra = 50, 100, 150, and 200), as revealed in Fig. 10 a, b, c and d, suggesting that convectional is more important for heat transfer at these maximum amounts.Also, the topmost portion of the internal spherical wall is starting to develop a cloud.A strong cloud is pushing the flow forcefully up against the top of the box at this point.The center of the primary vortices also keeps rising as the convection velocity rises.Thus, the Lorentz force, together with a rise in Rayleigh number and a drop in Hartmann number, confines the nanofluid movement as shown in Fig. 11a,  b, c and d.In addition to the fact that conduction in the porous medium is significantly stronger than natural convection, the isotherms on permeable surfaces become more contorted as the flow quality improves.This is because there is more naturally occurring convection in the free flow.As a result, conductions and natural convection have replaced heat transfer as the primary means of controlling energy transmission in porous surfaces.As shown in Fig. 11a, b, c and d    • The cavity's design has a small impact on the flow and heat transport mechanisms.The rate of energy trans- mission is amplified in a cavity with sharper edges.• The magnetic field's influence gradually slows down the rate of energy transmission.The performance of hybrid nanocomposites as an energy transmission medium in the cavity is not significantly impacted through the inclination angle of the magnetic field.• Thermal efficiency of hybrid nanofluids massively increase with a little increment in volume fraction.
• The MSE value, R value and average error rate for the ANN design model to predict the Nusselt number have been calculated as 1.13 × 10 −5 , 1 and 0.02%, respectively.• In the upcoming analysis, research in the presented BRT-ANNs based single network might be performed to model the estimates of all benchmark results determined by the CVFEM procedure base numerical outcomes of various fluid models. https://doi.org/10.1038/s41598-023-48412-xwww.nature.com/scientificreports/

Figure 1 .
Figure 1.(a) Geometrical configuration and suppose boundary assumption using (b) A sampler triangular element and its associated volume control.

Figure 2 .
Figure 2. Validation of current outcomes with previous work 38 .

Figure 3 .
Figure 3. (a) The grid presentation of the proposed model, (b) The grid test profile.

Figure 4 .
Figure 4. (a) A model configuration for singular neural networking, (b) Design of a planned neural network.

Figure 6 .
Figure 6.The designed transition state for BRT-ANN model.

Figure 11 .
Figure 11.Variation in different Hartmann numbers for velocity profile.

Figure 12 .
Figure 12.Variation in different porous parameters for velocity profile.

Table 2 .
signifies the grid test profile.The graphical representation in Fig.5a,b depicts the training performance of BRT-ANN models of two slected cases.Initially, MSE (mean squared error) magnitude are greater, but as the quantity of train epochs improves, they decrease gradually.That is possible to see the convergence of the shapes generated via statistics from the BRT-ANN testing, verification and trained processes and the best line is indicated by dotted lines at epochs (164 and 702).Once theBRT-ANN achieves the value of lowermost mean square error at these epochs, signifying the conclusion of the training mood later several repetitions of epochs, the model's training is deemed to be complete.Such strategy denotes that the superior concert training stage of ANN simulation has been successfully finalized.Figure6a,b graphically illustrates the training states of BRT-ANN models, including the gradient coefficient, mu and validation checks for two cases.The graphs depict how the gradient coefficient Evaluation of present and reported outcomes.

Table 3 .
Computational analysis of grid independence test.

Table 4 .
Effect of Ha on Nu ave for various values of φ Ag and φ MgO .

Table 5 .
The outcomes of BRT-ANN for the flow model.