Optimal design of an off-grid hybrid renewable energy system considering generation and load uncertainty: the case of Zanjan city, Iran

In this paper, designing a hybrid stand-alone photovoltaic/wind energy system with battery storage (PV/WT/Batt) is presented to minimize the total cost of the hybrid system and considering reliability constraints for Zanjan city in Iran country considering generation and load uncertainties. The total cost includes the cost of the system components and load losses cost and also deficit power probability-hourly interruption probability index, which is defined as the reliability constraint. The optimal size of the system components is found using an improved crow search algorithm based on mutation and crossover operators of the genetic algorithm to prevent premature convergence. The optimal designing of the hybrid system is implemented considering the uncertainty of photovoltaic and wind resources as well as the load demand of the system based on the probability distribution functions of uncertain parameters using Monte Carlo simulation. The simulations are implemented in two deterministic and probabilistic scenarios. In the deterministic scenario, the optimal design of various combinations of the hybrid system is investigated in view of the system cost and deficit power probability probability-hourly interruption probability index based on the improved crow search algorithm with and without the cost of load loss. The results of the deterministic scenario showed that the system cost is increased considering the cost of load loss, but the system load is supplied with higher reliability. Also, the deterministic results cleared the superiority of the improved crow search algorithm compared with conventional crow search algorithm and particle swarm optimization methods. Moreover, the results of the system designing showed that considering the uncertainty, the system cost increases, and the reliability is significantly improved. The results cleared that the system cost in deterministic and probabilistic designing is obtained 1.0108 M$ and 1.210 M$, respectively for load supply equal to 153.87 MWh. So, due to the inherent nature of the uncertainty in the renewable resources power generation as well as continuous load changes, a probabilistic approach of the hybrid system designing is necessary to know the accurate cost and reliability. Effective performance of the proposed method in system designing with lowest cost and higher reliability. Achieving to a more reliable hybrid energy system with considering cost of load losses in designing. Increasing the system the cost and improving the reliability considering uncertainties of generation and load. Effective performance of the proposed method in system designing with lowest cost and higher reliability. Achieving to a more reliable hybrid energy system with considering cost of load losses in designing. Increasing the system the cost and improving the reliability considering uncertainties of generation and load.

Crow i present position in iter iteration AP j,iter Probability that crow j is aware of iteration N samp Number of random samples in the MCS

Introduction
Using of renewable energy has grown exponentially. Different countries, considering their industrial capabilities and geographical potentials, are trying to benefit from these resources. The share of new energy in the budgets of developed countries is increasing [1,2]. One of the most important goals of using renewable energy sources is to reduce costs. The use of renewable energy sources is a good way to supply electricity consumption of remote areas to reduce the economic costs of expanding and transferring network lines, reduce environmental pollution and increase energy effectiveness [1,2]. The most important sources of distributed generation (DG) based on renewable energy are photovoltaic (PV) arrays and wind turbines (WTs). Power generation systems that include different energy resources are named "hybrid" systems because they have more than one energy source to supply AC or DC loads [3]. Evaluating the economic income due to the use of the renewable energy sources in hybrid systems requires examining the level of system reliability, which due to the uncertainty of the renewable resources generation, the need for reliability studies in the hybrid system is more felt [4,5]. So, in the system design, the optimal size of the renewable resources with storage system should be determined with minimizing the system cost and also satisfying the load reliability level [6]. Some researches are conducted on stand-alone system design. The PV/WT/fuel cell system design is presented to reduce the annual costs considering load interruption probability via improved sine-cosine algorithm (ISCA) and particle swarm optimization (PSO) method in [7] and using an imperialist competitive algorithm (ICA) in [8]. In [9], economical and reliable designing of the PV/WT/Hydrogen system is developed with the aim of reducing the net present cost and providing a combined constraint of reliability for the Ardabil region of Iran. In [10], designing the hybrid system is evaluated based on PV and battery storage as grid-connected with the capability of grid import and export using linear programming (LP). The hybrid PV/WT/Tidal/Hydrogen system design is studied with the aim of evaluating cost/ reliability based on whale optimization algorithm (WOA) based on reliability constraint in [11], using discrete harmony search algorithm (DHSA) in [12]. In [13], designing of different hybrid system based PV, WT, Batt and grid are presented economically and technically and the optimization problem is solved using non-dominated GA for household application. In [14], PV/WT/Batt system design is developed and aimed at minimizing the net present cost considering the reliability constraint using the improved crow search algorithm. The hybrid PV/WT/Batt system design is implemented with annual cost minimization and reliability enhancement by Grey Wolf optimizer (GWO) in [15]. These studies show that using a powerful optimization method, sizing of the components can be found in such a way that the lowest cost is achieved with the best reliability. Moreover, with the increasing demand for wind and PV energy, the fluctuations of their output power have created a great challenge for reliable and economical operation of energy systems and load supply based on these types of systems. Therefore, uncertainty assessment due to the fluctuation and unpredictability of PV and wind energy sources in hybrid energy systems is necessary for accurate cost and reliability calculations and is also inevitable for decision-makers of power systems [16,17]. Various methods for estimating the uncertainty have been reported in previous studies, including robust optimization (RO), distance-based analysis, probabilistic method (PM), feasibility method, hybrid possibilityprobability method (HPP), and information gap decision theory (IGDT) [16,17]. One of the common methods of modeling uncertainty is the Monte Carlo simulation (MCS). The MCS is one of the most accurate and common random methods [16]. Limited studies have been addressed on the use of PV and wind energy sources due to uncertainty. The annual PV energy estimate is presented in [18], considering the uncertainty of energy generation. In [19], changes and predictions of PV power system uncertainty in Arizona, USA have been investigated as the main challenge for operators to maintain power balance and costs minimization. In [20], the effect of uncertainty in load demand and energy resources on the economic and technical performance of hybrid PV and combined cooling, heating (CCHP + PV) systems are evaluated. In [21], a method for estimating the PV power uncertainty and identifying methods is presented to reduce uncertainty. In [22], the analysis of energy uncertainty for WTs has been done based on the MCS and the effect of practical parameters with uncertainty has been evaluated on wind farm power generation. In [23], a comparison of uncertainty's importance degree in calculating wind power is presented considering the technical parameters of wind speed and wind tower height based on time series. In [24], a probabilistic power model of WTs is proposed to determine the uncertainty of wind energy conversion system based on wind speed changes using MCS.
As can be seen from previous research, most studies of stand-alone hybrid systems designing are presented as deterministic and without considering the uncertainty of renewable energy resources generation and also load demand. So, due to continuous changes in the load demand and also changes in the renewable power generation, the designing of the hybrid systems should be performed considering the uncertainties of the generation and load to achieve accurate values of the cost and reliability.
In this paper, grid-off hybrid PV/WT/Batt system designing is presented with the uncertainty of photovoltaic and wind power generation and load demand using radiation and wind speed real data in Zanjan region, Iran country. The objective function is defined as minimizing the total cost of the hybrid system (TCHS) includes the net present cost as well as the cost of load losses. Also, the reliability constraint is presented as deficit power probability probability-hourly interruption probability (DPPHIP) index. Improved crow search algorithm (ICSA) inspired based on crows' food search behavior and enhanced using genetic algorithm operators that this algorithm is applied for the optimal design of the hybrid system [25,26]. First, the designing problem is solved as deterministic and then the probabilistic approach based MCS is implemented using renewable generation power and system load demand. The designing results including the optimal size of the components and the optimal cost and reliability values are evaluated in comparison with conventional CSA and PSO methods [27]. In deterministic designing, the effect of considering the cost of load loss is investigated on system designing. Moreover, the results of deterministic and probabilistic hybrid system designing are compared.
In Sect. 2, the modeling of the hybrid system is presented. In Sect. 3, the problem formulation is described. The proposed meta-heuristic approach and implementation process are described in Sect. 4. In Sect. 5, the results are presented and also discussed. Section 6 given the conclusion.

Hybrid system modeling
The PV/WT/Batt renewable system is considered as a hybrid energy system that includes WT, PV panel, battery, DC/DC converter, AC/DC converter, and also inverter. Schematic of hybrid PV/WT/Batt renewable system is showed in Fig. 1. The battery is used to enhance the system's reliability.
In the hybrid PV/ WT/Batt system, the battery is charging when the power of the renewable resource is higher than the load level. When the generated power of the renewable units is less than the load demand, the battery is in discharge mode. Of course, under equal conditions of generation and consumption, battery energy is unchanged.

Hybrid system contribution
The global energy charter is a guide to sustainable energy implementation that includes better legislation, increased efficiency of energy systems, renewable energy solutions, financing, and community educational and behavioral goals. The main goals of the global energy charter for sustainable development are reducing atmospheric emissions and establishing international, regional, and national programs to improve energy efficiency, controlling energy safety, and managing waste. It is predicted that with the creation of energy crisis in the world and depletion of nonrenewable energy sources, as well as increasing the level of environmental pollution, it is necessary to use renewable energy to generate electricity. With the growth of technologies in sustainable energy resources, continuous reduction of non-renewable energy reserves, and also free availability of the renewable energy resources (solar, hydro, wind …) in Iran country, architects and designers can apply a desirable design according to climate and environment conditions.

PV model
The generated power of PV panels due to the horizontal component of PV radiation (S) and the PV angle relative to the horizon ( PV ) is defined by [27].
(1) P PV = P PV ,Rated PV ,mppt sin h + PV 1000 ⋅ S sinh where, P PV ,Rated refers to the rated power of each panel, PV ,mppt refers to MPPT efficiency, the value of 1000 indicates the amount of standard radiation at 25° C, h indicates angle between the radiation path and the horizon and S is the horizontal component (W/m 2 ).
In this study, the uncertainty of PV irradiance is considered in the design of hybrid systems. To model the uncertainty, the beta probability distribution function is used as follows [21,28]: where, S is the irradiance, f b (s) is the beta probability distribution function for the variable s, α and β are the beta distribution parameters and are calculated as follows.
where, μ and σ are the mean and deviation from the criterion of this distribution, respectively.

WT model
Wind turbine output power in terms of wind speed ( v W ), low cut-off speed ( v cutin ), high cut-off speed (v cut out ), rated speed ( v rated ), is defined as follows [29]: where, P WG indicates the WT output power, P WG,max refers to the maximum power in kilowatts and P furl is output power at high cut-off speed.
Wind speed changes due to the height of the wind tower should be considered in the design of WTs. In this study, the power law is used to transfer anemometer data at a certain height and the relationship of this model is as follows [9].
where, v h W is wind speed at the height of h wg is wind tower, v h W is measured wind speed at the reference height (h r ), n is the coefficient of the law of wind speed power, which is usually equal to 1 7 for relatively smooth surfaces [29]. (2) In this study, wind speed uncertainty and wind power are considered in the design of the hybrid system. To model wind power uncertainty, the most suitable PDF is the Weibull distribution function, so for wind speed, the Weibull PDF is used as follows [30][31][32][33][34][35]: where, v W is the wind speed, and η and b are the scale parameter and the shape parameter, respectively.

Battery banks
The PV/WT/Batt system design, the battery based on charge and discharge management has been applied to compensate the power fluctuations of the renewable resources and to improve the load reliability.
Under charging conditions, the output power of renewable resources is higher than the load level that excess power is injected into the storage system. Battery energy at time t in charge mode is defined as follows [36,37].
where, E Batt (t) and E Batt (t − 1) refer to the stored energy in time steps t and t-1 and inv is inverter efficiency. ch is battery charging efficiency.
In discharge conditions, the output power of the renewable resources is lower than the load, which deficit power is compensated by the battery discharge. The battery capacity at time t in discharge mode is defined as follows [36,37].
where, disch is battery discharging efficiency.

Load demand models
The load demand has uncertainty and its uncertainty should be considered in the hybrid system design. The suggested PDF for the load demand is a normal PDF [38], which is defined as follows.
where, x refers to the load, f(x) is the normal load distribution function and μ and σ are the mean and deviation of the load criterion.

Problem formulation
The goal of the system design is minimizing the objective function (OF) as the total cost of the hybrid system (TCHS), including the cost of system components as well as the cost of load loss considering satisfying the reliability constraint as deficit power probability probability-hourly interruption probability index (DPPHIP) incorporating generation and load uncertainty. In other words, such a goal requires identifying the best size of the system components, including the number of PVs, WTs, batteries, inverter injected power to the load, PV panel angle, and wind tower height via the ICSA method.

Objective function
The OF of the hybrid system design is minimizing the TCHS as follows [9,11], and [30][31][32][33]. The TCHS includes capital cost (C cap ), maintenance cost (C main ), replacement cost (C rep ) of the system components as well as the cost of load loss ( C loss−load ). In the OF, the cost of load loss is added to the cost of energy generation in the hybrid system design. The energy generation cost is related to PVs, WTs, batteries, and also inverter capacity.
The capital cost of system components related to photovoltaics, wind turbines, batteries, and also inverters is defined by The maintenance cost of the system components for photovoltaic, wind turbines, batteries, and also inverters are presented as follow: The present annual value and also interest rate is presented by The replacement cost of the hybrid system components are related to photovoltaic, wind turbines, batteries, and inverters that are defined as follows: where, C cap , C main , and C rep are the investment, maintenance and operating cost and replacement costs of components, respectively and C loss−load indicates the cost of load loss. N PV , N WT , N Bat and N Inv are the number of PV panels, WTs, batteries and inverters. C PVc , C WTc , C Batc and C Invc represent components investment costs, C PVm , C WTm , C Batm and C Invm are components maintenance and operating costs, and C PVr , C WTr , C Batr and C Invr components replacement costs. R refers to the project life (20 yrs). Parameter of ir refers to actual interest rate (6%) which is achieved in terms of ir nominal as rated interest rate and annual inflation rate (f). Parameters PWA and K indicate the present annual value and fixed payments, respectively. DP and C loss−kWh are the load unmet power and the penalty cost per kW of DP , respectively. Also, T is the duration of the study period (8760 h).

Constraints
Probability of deficit power (PDP) as well as hourly interruption probability (HIP) as reliability constraints are formulated as follows [14]: is the deficit of load demand at time t, P Load (t) is load demand at time t, P available (t) is transferred power to the load by renewable resources and storage. T is the project study time (8760 h). The DOD refers to the depth of battery discharge (0.8) [14]. Therefore, the reliability constraint is defined as follows: where, PDP max and HIP max are max value of PDP and HIP , respectively.

Proposed method
In this study, the modified crow search algorithm (ICSA) is used to determine the optimal size of PV/WT/Batt system components considering the uncertainty which is described below.

Overview of Improved Crow Search Algorithm (ICSA)
The crow search algorithm is implemented based on the hiding behavior of crows' food. Crows hide their surplus food in special places and find it when they need it. Pursuit of a crow to access the hidden food of another crow may be such that the crow is not aware of its pursuit by another crow, in which case its hiding place will be revealed, or the crow may be aware of the pursuit of another crow. Random position and movement are done to hide the food hiding place [25,26]. The position of crow i in iteration, considering the number of crow N, are as follows [25,26]: where, iter max refers to the iteration's maximum number. The CSA algorithm, after starting with a random solution set, updates the search memory to determine the optimal solution in the search space and creates a new position based on awareness probability (AP) and flight length (FL).
The CSA algorithm is presented in the following two phases: Phase 1 Crow j does not recognize that he is being chased by crow i. In this phase, crow i approach the hidden place of crow j food as follows [25,26]: where, r i refers to a random number ([0, 1]) and FL i, iter represents the crow i flight length in iter iteration.
Phase 2 Crow j knows that he is being chased by crow i. So crow j changes its position in the search space based on the following relation to preventing the food hiding place from being revealed: where, x i,iter refers to the crow i present position in iter iteration and AP j,iter indicates the probability that crow j is aware of iteration.

Implementation of ICSA for optimal system design
In this study, the genetic operators as crossover and mutation [39] are applied for enhancing the CSA capability and the resulting algorithm is named improved CSA (ICSA). The flowchart of a battery storage operation and hybrid PV/ WT/Batt design is showed in Fig. 2. The ICSA implementation steps for solving the designing of the hybrid system considering uncertainty are as follows: Step 1 Apply the design data and algorithm parameters. In this step, data of components cost and capacity and also the algorithm parameters including crow population number, the maximum number of iteration, FL and AP.
Step 2 Stochastic parameters of the hybrid system, including load, wind speed, and consequently, the capacity of WTs and PVs are found randomly and according to the probability distribution functions of each of them. The (29) X i,iter = i = 1, 2, … , N; iter = 1, 2, … , iter max iter − x i,iter r j ≥ AP j,iter a random position otherwise number of random samples (generated by the MCS) must be the same for all parameters.
Step 3 For i = 1:N samp (Nsamp: is the number of random samples in the simulation), a random sample of each random parameter is selected. In order to create different scenarios for the existing uncertainty, which includes PV and wind power as well as load demand, the Monte Carlo sampling method [16, 22 and 24] has been used. Based on this, 1000 random samples of 8760 h information are generated for each of the uncertain parameters presented by the MCS. Also, low probability samples are discarded and finally, 100 samples (matrix 1 in 8760) are applied to the program for each uncertain parameter.
Step 4 The population of the optimization algorithm is determined in the form of decision variables. The decision vector is defined based on the number of PV panels, the number of WTs and the number of batteries, transfer the power of the inverter to the load, the angle of the PV panels, and the height of the wind tower as follows: Step 5) The TCHS is computed for each CSA population member by satisfying the constraints of the problem. The constraints of the problem are the constraints of the PVs, WTs, batteries, the angle of the panels with sunlight, and as well as the height of the wind tower.
Step 6 In this step, the crow with the lowest TCHS is determined as the best.
Step 7 The algorithm population is updated and the TCHS value is calculated for each updated population. In the case of achieving a better objective function than in step 6, the best OF is considered the best solution.
Step 8 At this step, the mutation and crossover operators of the genetic algorithm are used for the population of the CSA algorithm with the aim of preventing trapping in the local optimal and power increasing the algorithm in achieving the global optimal.
Step 9 In this step, the TCHS is calculated for the updated population in step 8. If the TCHS value is less than the value obtained in step 7, it is replaced with it.
Step 10 Repeat steps 3 to 9 to achieve the convergence criteria (achieving the lowest TCHS and implementation of (32) X = N PV N WG N Batt P inv PV h wg (33)  Step 11 The probability distribution function (PDF) of the optimal variables and as a result, the TCHS objective function and the reliability constraints are plotted and the results are obtained numerically.

Simulation results
The results of hybrid PV/WT/Batt system designing are given as deterministic (without uncertainty) and as probabilistic (with uncertainty) for Zanjan city in Iran country. The parameters of the hybrid system components are presented in   In the study [14], PV/WT/Batt system designing is done as deterministic with the objective of cost of components using ICSA. The uncertainty and also cost of load loss are not considered in the system design in [14]. In this section, the impact of considering the cost of load loss ( C loss−load ) is investigated in deterministic problem and the results are evaluated with the method in [14]. In this paper, the hybrid PV/WT/Batt system is designed considering C loss−load using ICSA, CSA and PSO algorithms, and the results are compared with [14]. The best results for each method are extracted after 20 runs and 50 populations and a maximum of 100 replications. The min and max values of the optimization variables are also given in Table 2.

Results of deterministic design of hybrid system (without uncertainty)
The PV/WT/Batt system designing is simulated to minimize the TCHS as well as load loss cost considering DPHI-Pmax = 5% and the obtained results are given. The capability of the ICSA is evaluated in comparison with the CSA and PSO methods. The results of the deterministic design of different system combinations are given in Table 3 and the obtained results are compared with the Ref. [14]. The results cleared that the PV/Batt without the participation of wind energy is the best combination in terms of cost and reliability for Zanjan city and this result is adapted to Ref. [14]. The convergence process of the PV/Batt system design is also shown in Fig. 4, using different algorithms. The Fig. 4, shows that the ICSA method has a lower cost than the CSA and PSO and also has converged in a lower number of iterations and found the optimal solution.
Based on the obtained results in Table 3, the PV/Batt system is the optimal selection for the Zanjan city in deterministic design. The results cleared that the PV/  Batt system with a cost of $ 1.1979 M$, HIP and DPP are equal to 187 h and 0.0192 MW is the optimal combination in view of economic and technical aspects. The results also cleared that the TCHS of the WT/Batt system design for load supply is higher and the reliability is lower than the optimal combination. Comparing the results with Ref. [14], it is observed that considering C loss-load has increased the cost but significantly improved the reliability of the load. The HIP value compared to Ref. [14], is decreased from 438 to 187 h, the amount of DPP is decreased from 0.0328 MW to 0.0192 MW and the cost increased by 18.63%. In the other hybrid system combination considering C loss-load , the system cost has increased and the reliability indices have improved. Therefore, considering C loss-load , as part of the objective function provides a more reliable and popular system in the energy market to provide remote applications, especially sensitive loads that require high reliability. In Fig. 5, the changes in battery storage energy with DPPHIP max = 5% for the hybrid PV/Batt system are plotted based on the ICSA with and without C loss-load . According to the obtained results and the improvement of reliability considering C loss-load , the level of the storage system has increased.

Results of probabilistic design of hybrid system (with uncertainty)
The probabilistic results of hybrid PV/WT/Batt system designing are given using the ICSA algorithm considering generation and load uncertainty based on probability distribution functions (PDFs) of real data for Zanjan city. It must be said that the optimal combination of the hybrid system in the design without uncertainty for the city of Zanjan, is obtained hybrid PV/Batt system, although the results are almost similar to the PV/WT/Batt combination but without the contribution of WTs. For this reason and for considering the uncertainty of both PV and wind sources, the probabilistic approach is implemented on the hybrid PV/WT/Batt system. Figures 6, 7, 8 showed the irradiance, wind speed, and load PDFs. After initiating the PDFs of irradiance, wind speed, and load demand and implementing the proposed method based on the ICSA, the PDFs of decision variables are shown in Fig. 9. It should be noted that the number or value of each decision variable is obtained from the sum of multiply each sample by its probability (density axis). The numerical results of the probabilistic design and its comparison with the deterministic design are also presented in Table 4.
The probabilistic design results of the hybrid PV/ WT/Batt system are presented for DPPHIP max = 5% with C loss-load in Table 4. Based on the deterministic design results, the optimization program has used the contribution of PV resources and batteries (PV/Batt system) to meet the load. While considering the uncertainty, the program has used the contribution of both PV and wind sources to supply the load. In the deterministic case, one-year of information of irradiance and wind speed is used to design the hybrid system, which can not be enough information to measure the potential of energy resources in Zanjan, while in the probabilistic design approach, different scenarios of radiation and wind speed are considered as PDFs. According to the probabilistic design results, 125 WTs, 204 PVs, and 819 batteries are used to supply the load. Based on the load changes in the uncertainty designing, the transferred power of the inverter to the load is obtained 35.56 kW, the height of the wind tower is 31.2 and the angle of the PV panels is 47.62 degrees. The TCHS has increased from $ 1.1979 to $ 1.210 M$ in the probabilistic approach compared to the deterministic designing. Also, the DPP has been reduced from 0.0192 to 0.0167 MW and the HIP is reduced from 187 to 72 h due to considering uncertainty in the probabilistic approach. Therefore, considering generation and load uncertainty, the cost of hybrid system design is increased but the system reliability is improved. The PDFs of TCHS, DPP, and HIP are depicted in Figs. 10, 11, 12, respectively. According to these figures, the value of changes in each index and the probability of its occurrence are given.

Discussion
In [14], the deterministic the hybrid PV/WT/Batt system designing is studied to meet the load demand considering real data of Zanjan region, Iran country. The objective of this study is to identify the best size of hybrid system  components with minimizing the TCHS and DPPHIP enhancement using ICSA meta-heuristic algorithm. It should be noted that the deterministic design of hybrid PV/WT/Batt system is studied without considering the uncertainty of generation and load in [14]. Comparison of the results between the deterministic design in Ref. [14] and the probabilistic designing of PV/WT/Batt for DPHIP max = 5% are presented in Table 5. It is clear that the ICSA method in [14] obtained the optimal combination as PV/Batt system with 333 PVs, 389 batteries, and an inverter transfer power equal to 29.52 kW. Also, according to the results of Table 5, considering the uncertainty, the ICSA has obtained 125 WTs, 204 PVs, 819 batteries, and an inverter transfer power equal to 35.58 kW. On  the other hand, it can be seen that the amount of TCHS in the deterministic and probabilistic design is equal to 1.0108 and 1.210 M$, respectively, which indicates that the cost has increased due to considering uncertainty. The load of the system and also renewable resources generation have uncertainty that must be considered in actual designing of the hybrid system, determination of the accurate contribution of the renewable energy resources and storage units, designing cost and reliability of the hybrid system. In addition, considering the uncertainty in the hybrid system designing allows energy system engineers to make the right decisions based on possible probabilities and investment budgets. Also, considering the uncertainty prevents large costs due to incorrect sizing of system components due to deterministic designing and thus the system load is supplied with more reliability considering uncertainty.

Conclusion
In this paper designing framework for a hybrid PV/WT/Batt system is presented with the objective of minimizing the TCHS and satisfying the DPPHIP as reliability constraint considering the uncertainty of PV and wind generation and load demand for the Zanjan city in Iran country. The optimal size of the components, including the number of PVs, WTs, and batteries, as well as inverter power capacity, the height of the wind tower, and the angle of the PV panels are determined optimally using the ICSA. The simulation results are presented for different approaches such as deterministic and probabilistic methods with and without the uncertainty, respectively. The results of the deterministic design are given for various combinations of the hybrid system and the optimal configuration of the system is found with the lowest cost and more reliability value. Also, the probabilistic design of the system considering the uncertainty of generation and load demand is performed using Monte Carlo simulation based on the probability distribution functions of irradiance, wind speed, and load power. The performance of the ICSA is evaluated in comparison with the CSA and PSO in a deterministic approach and the achieved results of deterministic and probabilistic approaches are compared. The results of deterministic design showed that the renewable resources with energy management of the battery storage are capable to supply the load in all system configurations. The obtained results demonstrated that the hybrid PV/Batt system is determined as the optimal configuration of the hybrid system with minimum TCHS and higher reliability than the other configurations. Also, the results cleared that considering the cost of load loss in objective function provides a more reliable system for supplying the sensitive loads, which further improves the reliability index. In deterministic design, the superiority of the ICSA is proved with lower cost and better reliability than the CSA and PSO. Moreover, the results of the probabilistic approach showed that the TCHS of the hybrid system is increased more but the reliability is more enhanced significantly compared to the deterministic approach. So, the results of the probabilistic design showed that the uncertainties of the generation and load demand should be considered to achieve a cost-effective and reliable system in the hybrid system designing.

Conflict of interest
The authors declare that they have no conflict of interest.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, 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:// creat iveco mmons. org/ licen ses/ by/4. 0/.