Battery-based energy storage systems (ESS) are playing an increasingly important role in modern electrical grids as they can serve a variety of functions in the generation, transmission, and distribution of electric energy, especially in the case of the high penetration of intermittent renewable energy from wind and solar power generation  . When an ESS relies on an electrochemical storage technology like batteries, an accurate model of its voltage and capacity is essential to evaluating the system’s ability to perform various function required for grid applications. The ESS controller must rely on this model in order to safely and reliably operate the ESS. The existing mathematical battery models vary widely in terms of chemistries, reactions, and geometries modelled. In general, as more detailed physiochemical phenomena are included in a battery model, its simulation results can be expected to be more reliable, but at the cost of increased computational effort. Therefore, an accurate yet relatively simple dynamic mathematical model is required for the battery management systems (BMS) to facilitate efficient ESS control in grid applications so that the charging/discharging processes can be properly managed to optimize battery performance and durability.
According to their modeling methodology, battery models can be classified as Electrochemical Multiphysics, Equivalent Circuit (EC), and Empirical or semi- empirical dynamic models  . Electrochemical Multiphysics battery models  consider the fundamental battery chemistry and multiphase transport theory to study the effects of the reaction kinetics and geometry on battery performance. The Electrochemical Multiphysics models are well developed but are not suitable for grid applications due to their complicated coupling of species reaction and transport equations. The equivalent circuit battery models  employ the passive circuit elements like capacitors, inductors and resistors to model electrolyte, electrode, polarization resistances along with active current and voltage sources. To improve EC model accuracy, additional resistor-capacitor (RC) networks can be integrated but at the cost of computational efficiency. The EC model with more RC networks also requires more detailed experimental data to determine its model parameters. Empirical models employ elementary mathematical functions such as polynomials, exponentials, power law, etc., to predict the battery performance. Some empirical models, also called OCV models  , are just fitted mathematic functions for a specific battery without any physical meaning and therefore have limited popularity. Other empirical models, called generic models, are derived either from the Nernst equation   or from the Butler-Volmer equation  and are now widely employed in various applications due to its simplicity and relatively high accuracy. The model parameter identification of the dynamic model developed in    is based on a batch least square approach that requires tedious testing and these data sets are not typically available or easy to obtain, especially for grid-scale battery systems. The identified model parameters vary with cycle life and no explicit expressions are presented for the parameters as functions of the battery’s cycle life which make the model difficult to use for control purposes in grid applications. The newly released MATLAB software version R2017b   includes a generic lithium-ion battery model that incorporates the temperature and aging functions and these effects on battery performance can be evaluated individually. This generic MATLAB battery model has been modified by many researchers to include some missing features, such as the self-discharge and internal resistance variation  , nonlinear temperature dependence  , and is commonly applied to the dynamic analysis for electric vehicles   . The most advantageous feature of the generic MATLAB battery model is that the model parameters are estimated from a manufacturer’s datasheet and only three points on one discharge curve are needed, namely the initial fully charged point (100% state of charge), the point at the end of exponential zone and the point at the end of nominal zone  . MATLAB’s generic model did not consider the variation of the battery capacity as a function of its self-discharge, discharge current, cycle life and temperature so it is unable to predict the voltage behavior near the end of the discharge process.
As a lithium-ion battery ages, its voltage and capacity decreases or fades and its internal resistance increases due to the loss of active lithium and the thickness of the solid electrolyte interface (SEI)   and these variations should be carefully considered when developing a the dynamic battery model. This paper describes the advancements made to the generic MATLAB battery model by introducing an additional parameter together with a variable capacity which is a function of the self-discharge rate, the discharge current, the cycle life and operating temperature. The effects of temperature and cycle life on battery performance are estimated using first-order approximations. An explicit and systematic approach is presented to determine the model parameters. More importantly, the identification of model parameters is based only on information typically provided in manufacturer’s datasheets and no tedious battery testing is required.
2. The Modified MATLAB Model
In order to improve the accuracy of the generic MATLAB battery model beyond the nominal zone and to consider the capacity degradation, the equation of the generic MATLAB battery model  is modified as,
where is the battery voltage (V), is charging or discharging time (h), is a voltage constant (V), is internal resistance of the battery (Ω), is battery current (A) where positive current represents discharging the battery and negative current indicates charging the battery, is a polarization constant (V/(Ah)), is a capacity adjustment factor that accounts for capacity degradation, is battery capacity (Ah) at the specific discharge current and point in the battery’s life being modeled, is exponential zone voltage constant (V), and is exponential zone inverse time constant (1/(Ah)), and is the nominal or rated battery capacity at the beginning of life (i.e. n = 1) at a reference discharge current of .
The parameter in Equation (2) can be determined by two battery capacities ( ) at two different discharge currents and under normal temperature (typically 25˚C) and near the beginning of life (e.g. n < 5), as shown in Figure 1.
There are a total of 7 unknowns in Equation (1): , , , , , and . The method described in  can be applied here to estimate the first 6 parameters once the needed three points on a discharge curve are accurately identified. The initial 100% state of charge point is at the beginning of the discharge process ( ). The other two points, one at the end of exponential zone and one at the end of nominal zone, are challenging to distinguish and need to be finely adjusted in order to obtain a good fit. The supporting documentation  for MATLAB’s generic battery model describes that the capacity adjustment parameter ( ) is set at a default value of 0.1 and no detailed procedure is given on how to determine its value. In addition, the determination of the internal resistance relies on the cell efficiency which is not typically provided on manufacturer’s datasheets. In this paper, a new procedure is introduced to determine all model parameters based only on the specifications typically provided on manufacturer’s datasheets. As compared to the MATLAB method, the new procedure proposed is more tolerant of the positions of the required points on discharge curves. In general, the nominal capacity ( ) of the battery can be found directly from manufacturer’s datasheets. The following section will focus on how to determine the other6 unknowns. Figure 1 plots two typical discharge curves
Figure 1. Typical discharge curves at two discharge currents, i1 and i2.
at two different discharge currents that are commonly included in manufacturer’s datasheets.
The first step is to determine the parameters and by using five points on the discharge curve at : , the initial fully charged point; and are within the exponential zone and satisfy the condition of ; , one point near the end point of nominal zone; and , the end point of discharge. Five equations are obtained by applying Equation (1) to these five points accordingly.
Equation (4) minus Equation (5) to eliminate the term ( ),
Assuming , and noticing the relation of , Equations (4) and (7) reduce to
Parameters and can be solved from Equations (10) and (11) as
Equations (8) and (9) becomes
So the parameters and can be obtained from Equations (16) and (17) as
The second step is to determine parameters and . In some cases, the battery’s internal resistance and efficiency are not provided in manufacturer’s datasheets so the MATLAB method to determine given in  is not applicable. Here a new procedure is proposed to calculate the internal resistance by using two points on two different discharge curves at two different discharge currents.
Applying the cell voltage Equation (1) to point P6 on the discharge curve of current i2,
Subtracting Equation (5) (for ) from Equation (20), and solving for the internal resistance results in the following equation,
Once the values of parameters, and are available, the constant voltage, can be obtained from Equation (4),
3. Model Equations with Aging and Temperature Effects
To include both aging and temperature effects, the model Equation (1) is rewritten as,
where is n-th discharge-charge cycle starting from discharging a cell to a fully discharged state and then charging the cell to a fully charged state. is the n-th resting time of the cell after the (n − 1)-th cycle. is the cell temperature. Here the capacity adjustment ( ) and exponential zone time constant ( ) are assumed unchanged.
For simplicity, both the cycling- and temperature-dependences of the parameters in Equation (23) are estimated by the first-order approximation,
where refers to the first-order degradation rate constant of parameter related to cycling life; is the degradation rate constant of parameter related to temperature; is a reference temperature.
3.1. Battery Capacity Degradation Considering Self-Discharge, Cycling Life and Temperature
A battery’s capacity degrades not only due to the cycling life and temperature, but also as a function of the resting time between two consecutive discharge-charge cycles  . Furthermore, it is also varies with the corresponding discharge current. These degradations must first be identified before calculating the degradation rate constants appearing in Equations (24) to (27). Assuming the self-discharge rate constant doesn’t depend on cycling life, then , the battery capacity at beginning of the n-th cycle after resting hours, can be estimated as,
where (1/h) is the rate constant of the self-discharge of the battery, is the battery capacity at the beginning of the n-th cycle (before resting).
Once the battery is fully charged, its stored energy slowly diminishes due to internal self-discharge  (i.e. with no load on the battery). Self-discharge varies with battery types. For a lithium-ion battery, the self-discharge rate is around 5% in the first 24 hours and then reduces to 1% - 2% per month, plus 3% for safety circuit consumption  . The typical values of for a lithium-ion battery cell is given in  as,
The degradation of due to cycling is an irreversible and cumulative process and can be approximated by second-order approximation as,
where is the battery’s capacity given by Equation (2), and are the first-order and second-order degradation rates of battery capacity due to cycling, respectively.
The summation of above Equations (29) from 1 to leads to,
Since the capacity degradation of the battery is also dependent on temperature, Equation (30) is modified as
where and are the first and second-order degradation rates of the battery capacity related to temperature change.
Finally, the degradation of a battery’s capacity due to self-discharge, discharge current, life cycle and temperature is expressed by substituting Equations (31) and (2) into Equation (28) as
Two battery capacities ( ) at two different cycle numbers under normal or reference temperature are needed to calculate the cycling related degradation rates ( and ); another two battery capacities ( ) at two different temperatures under in the first life cycle are required to estimate the temperature related degradation rates ( and ).
where the two battery capacities, and , can be found on the two discharge curves provided by manufacturer’s datasheet under two different cycling numbers and at normal temperature, as shown in Figure 2.
where the two battery capacities, and , can be found on the two discharge curves from the manufacturer’s datasheet under two different temperatures and at the first cycle, as shown in Figure 3.
Figure 2. Two typical discharge curves of two cycle numbers and ( ) at normal temperature ( ) and same constant discharge current ( ).
Figure 3. Two typical discharge curves of two temperatures and at the first cycle ( ) and same constant discharge current ( ).
3.2. First-Order Degradation Rate Constants Related to Cycling Life
To determine the first-order degradation rate constants related to cycling life , point P1 in Figure 1, and three other points on the discharge curve of , namely points P7, P8 and P9, are required, as shown in Figure 2.
Applying the modified cell voltage Equation (23) with Equations (24)-(27) to point P1 with n = 2, points P7, P8 and P9 respectively, and rearranging the resulting 4 equations into the following matrix form,
Note that the value of in expressions (36) and (37) should be the value of at .
The first-order degradation rate constants related to cycling life in Equations (24) to (27), , , and can be obtained by solving Equation (35),
The internal resistance variation is usually very small and can be neglected within a certain life span (for example, ) and therefore, the degradation rate constant related to cycling life for internal resistance is modified as
3.3. First-Order Degradation Rate Constants Related to Temperature
Similar to , the degradation rate constants related to temperature can be calculated by applying the procedures given in Section 3.2 to point P1 with , points P10, P11 and P12, as shown in Figure 3. The formulas for the calculation are given as follows.
Note that the value of in expressions (41) and (42) should be the value of at .
The first-order degradation rate constants related to temperature in Equations (24) to (27), , , and can be obtained by solving Equation (40),
The final battery model takes into account the effects of self-discharge, cycling life and temperature on capacity degradation and battery voltage, and these dependencies are described by Equations (23) to (27), and (32). The identification of the model parameters depends only on the information typically provided in a manufacturer’s datasheet and the procedures used to derive them are presented in detail.
4. Model Validation
The modified model is verified by two steps. First, the model is applied to the two batteries used in  and the predicted battery voltages are compared with those generated by the generic MATLAB model. Secondly, the modified model with the inclusion of aging and temperature is applied to a commercially available lithium-ion battery and the model parameters are extracted. The new model’s calculated battery voltage is then compared with the performance figures provided in the manufacturer’s datasheet.
4.1. Comparison with the MATLAB Model
Both the nickel-metal hydride (NiMH) and lithium-ion batteries from  are used here to check the improvement of battery voltage prediction of the modified model Equations (1) and (2). For the NiMH battery, Figure 4 shows the comparison of voltage prediction by the modified model with the prediction by the generic MATLAB model, and with the values on the manufacturer’s datasheet as well. It can be seen that the overall accuracy of the modified model is better than the generic MATLAB model for all three discharge rates, especially beyond the nominal region.
Figure 5 plots the voltages from both MATLAB and the modified model calculation and from manufacturer’s datasheet for the lithium-ion battery. It is clearly seen that the voltage prediction from the modified model at high C-rate is much better than the MATLAB model prediction. Another significant improvement
Figure 4. Comparison of voltage prediction under different discharge currents for the NiMH battery  .
Figure 5. Comparison of voltage prediction under different discharge currents for the lithium-ion battery  .
is the voltage prediction beyond the nominal zone. All of the three discharge curves (red lines) predicted by the generic MATLAB model converge to the rated capacity which is not the case comparing with the reference data. The modified model demonstrates much higher accuracy within this zone and has correctly predicted the separation of the three discharge curves (black lines) at the end of discharge process.
Figure 6 plots the battery capacity as the function of discharge current and in comparison with the data extracted from the manufacturer’s data for both NiMH and lithium-ion batteries from  .
Figure 6. Battery capacity changes with discharge current for both lithium-ion and NiMH batteries from  .
Table 1 lists the model parameters of the generic MATLAB model and the modified model for both the NiMH and lithium-ion batteries.
4.2. Model Validation Using a Commercially Available Large-Format Lithium-Ion Battery
To further validate the modified battery model, a large-format high capacity (1000 Ah) lithium-ion battery from SINOPOLY was used. The specifications and discharge curves of the battery (Model: SP-LFP1000AHA) can be found in  . Based on the procedures given in Sections 2 and 3, the parameter values for the modified model are extracted and listed in Table 2. For comparison, the generic MATLAB model parameter values are also estimated and presented in Table 2.
The capacity of the SP-LFP1000AHA battery varies with the discharge current, temperature and cycling number. Comparing with the experimental data, Equation (32) gives a very good approximation, as shown in Figure 7.
Figure 8 shows the voltage vs capacity curves from the manufacturer’s datasheet, the MATLAB model, and the modified model for three different discharge currents. The modified model has comparable accuracy with the generic MATLAB model in terms of the voltage prediction in the exponential and nominal zones but has much higher accuracy beyond the nominal zone. Near the end of the discharge process, the new model predicts the battery’s output voltage much closer to the results provided in the manufacturer’s datasheet while the generic MATLAB model incorrectly converges the three (red) curves to a single capacity value due to the MATLAB model doesn’t consider the battery capacity variation with discharge currents.
The voltage predictions by the new model are compared with the manufacturer’s datasheet for three different cycling numbers and the results are plotted in Figure 9.
Figure 7. Comparison of capacity prediction with experimental data for the SP-LFP1000AHA battery.
Figure 8. Comparison of voltage prediction under different discharge currents for the SP-LFP1000AHA lithium-ion battery.
Table 1. Model parameters.
Table 2. Model parameters for the SP-LFP1000AHA battery.
Figure 10 depicts the temperature effects on the discharge curves calculated by the new model under three different temperatures and compares them with the manufacturer’s datasheet.
It can be seen from Figure 9 and Figure 10 that the new model has the capability to predict the discharge curves for different cycling numbers and at different temperatures with a reasonable accuracy.
Figure 9. Comparison of voltage prediction over cycle life under different discharge conditions for the SP-LFP1000AHA lithium-ion battery.
Figure 10. Comparison of voltage prediction under different temperatures for the SP-LFP 1000AHA lithium-ion battery.
The well accepted generic MATLAB model is improved by adopting a variable battery capacity which is expressed as a function of self-discharge, discharge current, cycle number and temperature. The dependence of the model parameters on cycle life and temperature are linearly estimated. The detailed procedures are developed to determine the model parameters and the capacity function. The model parameter identification depends only on information typically available from manufacturer’s datasheets. The new model was compared with the generic MATLAB model for a nickel-metal hydride battery and the lithium-ion battery that are used for the generic MATLAB battery model validation. The simulation results demonstrated that the newly developed model has similar accuracy within the exponential and nominal zones compared to the generic MATLAB model but can correctly capture the discharge curve separation behavior beyond the nominal zone where the generic MATLAB model failed. Further validation on a large capacity lithium-ion battery has shown that the modified model can accurately predict the discharge curves at different discharge currents, at different points in cycle life, and at different temperatures. Future work will be devoted to further validate the model with various battery types, integrate it into a grid-scale energy storage control system with the goal of improving its reliable and economic operation.
 Xu, X., Bishop, M., Oikarinen, D.G. and Hao, C. (2016) Application and Modeling of Battery Energy Storage in Power System. CSEE Journal of Power and Energy Systems, 2, 82-90.
 Nejad, S., Gladwin, D.T. and Stone, D.A. (2016) A Systematic Review of Lumped- Parameter Equivalent Circuit Models for Real-Time Estimation of Lithium-Ion Battery States. Journal of Power Sources, 316, 183-196.
 Ramadesigan, V., Northrop, P.W.C., De, S., Santhanagopalan, S., Braatz, R.D. and Subramanian, V.R. (2012) Modeling and Simulation of Lithium-Ion Batteries from a Systems Engineering Perspective. Journal of the Electrochemical Society, 159, R31-R45.
 Fotouhi, A., Auger, D.J., Propp, K., Longo, S. and Wild, M. (2016) A Review on Electric Vehicle Battery Modeling: From Lithium-Ion toward Lithium-Sulphur. Renewable and Sustainable Energy Reviews, 56, 1008-1021.
 Baccouche, I., Jemmali, S., Manai, B., Omar, N. and Amara, N.E.B. (2017) Improved OCV Model of a Li-Ion NMC Battery for Online SOC Estimation Using the Extended Kalman Filter. Energies, 10, 764.
 Tremblay, O., Dessaint, L.-A. and Dekkiche, A.-I. (2007) A Generic Battery Model for the Dynamic Simulation of Hybrid Electric Vehicles. Vehicle Power and Propulsion Conference, Arlington, 9-12 September 2007, 284-289.
 Ahmed, R., Gazzarri, J., Onori, S., Habibi, S., Jackey, R., Rzemien, K., Tjong, J. and LeSage, J. (2015) Model-Based Parameter Identification of Healthy and Aged Li-Ion Batteries for Electric Vehicles. SAE International Journal of Alternative Powertrains, 4, 233-247.
 Sibi Krishnan, K. Prasanth, P. and Sunitha, R. (2016) Generic Battery Model Covering Self-Discharge and Internal Resistance Variation. 2016 IEEE 6th International Conference on Power Systems (ICPS), New Delhi, 4-6 March 2016, 1-5.
 Kroeze, R.C. and Krein, P.T. (2008) Electrical Battery Model for Use in Dynamic Electric Vehicle Simulations. 2008 IEEE Power Electronics Specialists Conference, Rhodes, 15-19 June 2008.
 Barre, A., Deguilhem, B., Grolleau, S., Gerard, M., Suard, F. and Riu, D. (2013) A Review on Lithium-Ion Battery Ageing Mechanisms and Estimations for Automotive Applications. Journal of Power Sources, 241, 680-689.
 Jaguemont, J., Boulon, L., Venet, P., Dube, Y. and Sari, A. (2016) Lithium-Ion Battery Aging Experiments at Subzero Temperatures and Model Development for Capacity Fade Estimation. IEEE Transactions on Vehicular Technology, 65, 4328-4343.