Estimation Techniques for State of Charge in Battery Management Systems on Board of Hybrid Electric Vehicles Implemented in a Real-Time MATLAB/ SIMULINK Environment Estimation Techniques for State of Charge in Battery Management Systems on Board of Hybrid Electric Vehicles Implemented in a Real-Time MATLAB/ SIMULINK Environment

The battery state-of-charge estimation is essential in automotive industry for a successful marketing of both electric and hybrid electric vehicles. Furthermore, the state-of-charge of a battery is a critical condition parameter for battery management system. In this research work we share from the experience accumulated in control systems applications field some preliminary results, especially in modeling and state estimation techniques, very useful for state-of-charge estimation of the rechargeable batteries with different chemis-tries. We investigate the design and the effectiveness of three nonlinear state-of-charge estimators implemented in a real-time MATLAB environment for a particular Li-Ion battery, such as an Unscented Kalman Filter, Particle filter, and a nonlinear observer. Finally, the target to be accomplished is to find the most suitable estimator in terms of performance accuracy and robustness.


Introduction
We are currently seeing a significant increase in global environmental pollution, with immediate repercussions on air, water and soil quality. More precisely, especially in the developed countries around the world the environmental pollution has reached scary limits. Related to this it is worth to mention the presence of a significant amount of hydrocarbons pollutants (benzene, toluene and xylene) in the emissions of the vehicles equipped with gasoline or diesel engines that are characterized by a variable toxicity depending on the chemical composition of the exhaust gases. Furthermore, these toxic substances are propagated through the air from one region of the world to another one and surrounds countries and continents becoming a global phenomenon, consisting of irreversible pollution of water, air and soil at the planetary scale. Therefore, the need to conceive and implement new environmental conservation strategies at the global scale is required. Also, a changing in the thinking of the people about a significant reduction in energy consumption without sacrificing the comfort is crucial. In these circumstances there is a real hope that with the current technology available could stop the global destruction of the environment. Moreover, the new strategies based on electrical energy consumption assure a sustainable development of each community are critical to achieve a clean and efficient urban or rural transportation. As a viable solution to the global energy shortage and growing environmental pollution is the use of the electric vehicles (EVs) [1]. Nowadays, the electric vehicles (EVs) including hybrid electric vehicles (HEVs), plug-in hybrid electric vehicles (PHEVs), and pure battery electric vehicles (BEVs) are gaining popularity in automotive industry and will dominate soon the clean vehicle market [2]. Related, in [2] is mentioned also that by 2020, it is expected that "more than half of new vehicle sales will likely be EV models", with the batteries playing "the key and the enabling technology to this revolutionary change". They are conceived "to handle high power (up to a hundred kW) and high energy capacity (up to tens of kWh) within a limited space and weight and at an affordable price" [2]. The most advanced and promising battery technologies existing in EVs manufacturing automotive industry are the nickel-metal hydride (NiMH), lithium-ion (Li-Ion) and nickel-cadmium (NiCad) batteries considered as the most suitable for HEVs/PHEVs/EVs all over the world.
They have a great potential to reduce greenhouse and other exhaust gas emissions, and require extensive research efforts and huge investments [2].
Nevertheless, amongst them the most promising power source with a great potential to be developed and to get a wide application in the future on the EVs market is the Li-Ion battery recommended by its light weight, high energy density, tiny memory effect, and relatively low self-discharge compared to its strong competitors, namely Ni-Cad and Ni-MH batteries, as is mentioned in [1,2].
Additionally, the newest Li-Ion batteries are safer and less toxic than the same batteries in competition. Due to the diversity and the complexity of EVs field we limit our case study only to HEVs applications since we have got some research experience in modeling, control and the estimation strategies related to this field. Therefore, one of the main objectives of this research work is to disseminate the most relevant results obtained until now in this area and to share some interesting ideas with our readers. The Li-Ion battery is a main component integrated in the battery management system (BMS) of a HEV that is responsible for "improving the battery performance, prolonging battery life, and ensuring its safety", as is mentioned in [1,2]. This desideratum is achieved by the BMS through recording continuously the main parameters of the Li-Ion battery and performing an accurate estimation of its state-of-charge (SOC). An accurate SOC estimation is a vital operation to be performed by the BMS of the HEV in order to prevent the dangerous situations when the battery is over-charged or over-discharged, and to improve considerably the battery performance [1]. More precisely, the battery SOC is an inner state of a battery that can be defined as the available capacity of a battery, as a percentage of its rated capacity [1][2][3]. Its estimation is an essential operational condition parameter for battery management system (BMS) but it cannot be measured directly [1]. The estimation of Li-Ion battery SOC value is based on the measurable data set of the battery parameters, mainly the current, voltage, and temperature by using several estimation strategies, implemented in real-time MATLAB/SIMULINK platform that includes many real-time features [3][4][5][6][7][8][9][10][11]. All SOC estimation strategies are model-based, and can be grouped in Kalman Filter (standard, extended, unscented, particles filter), as those developed and implemented in real-time in [3][4][5][6][7][8][9][10][11], linear, nonlinear and sliding mode observers estimators, including also fuzzy improved versions, well documented in [1,[8][9][10]. The environmental impact is a key issue on the enhancing the battery technologies, as is mentioned in [12].
Definitely, the selection criteria of the specific chemistry battery to be integrated in BMS structure of a HEV are the cost, the specific power and energy, cycle life, and the presence of poisonous heavy metals [2,12]. A complete literature review on life cycle assessment (LCA) of HEVs since 1998 until 2013 has been conducted in [12]. In our research we are only focused on the technical aspects, such as battery modeling and developing the most suitable estimation techniques of battery SOC.
The remainder of this chapter is organized as follows. In Section 2, the widely-used 2RC-series cells Li-Ion battery equivalent model circuit (EMC) is introduced and the state space equations are derived. In Section 3, is proposed for design and implementation in real-time three nonlinear estimators, namely an Unscented Kalman Filter (UKF), Particle Filter (PF), and a nonlinear observer estimator (NOE).
The simulation results and the performance analysis of the proposed estimators are presented in Section 4. Section 5 concludes the book chapter.

The continuous and the discrete time state-space Li-Ion battery model representation
In this section we introduce a generic model capable to describe accurately the dynamics of Li-Ion battery, based on the same set of first-order differential equations in a state-space representation. For simulation purpose, a specific Li-Ion battery model is considered to prove the effectiveness of the proposed SOC estimation strategies. This model can be obtained from the generic model by changing only the values of the model parameters in state-space equations. For our case study we choose the widely-used 2RC -series cells Li-Ion battery equivalent model circuit (EMC) as model-based support, well documented in [1,8,11].

Li-Ion battery terminology
In this subsection we introduce briefly the same terminology as in [2] to introduce the most used terms in this chapter that characterize the Li-Ion battery architecture and its performance.

Li-Ion battery characterization architecture terminology
A single battery cell is a complete battery with two current leads and separate compartment holding electrodes (positive (+) and negative (À)), separator, and electrolyte. A few cells are connected in series, parallel or in series -parallel combinations, either by physical attachment or by welding in between cells to form a battery module. Similar, several modules are connected to form a battery pack placed in a single compartment for thermal management. A HEV may have more than one batteries packs placed in a different location of the car.

Li-Ion battery performance terminology
A battery cell is fully charged when its terminal voltage reaches the maximum voltage limit value after being charged at infinitesimal current levels, for example a maximum limit voltage value of 4.2 V at room temperature (25 C). A battery terminal voltage value greater than this limit corresponds to a dangerous over-charging operating condition. Similar, a battery cell is fully discharged when its terminal voltage reaches the minimum voltage limit value after being drained at infinitesimal current levels, for example a minimum limit voltage value of 3.0 V at room temperature. A battery terminal voltage value smaller than this limit corresponds to a dangerous over-discharging operating condition. The capacity of a battery is measured in Ampere-hours (Ah) defined as the total charge that can be discharged from a fully charged battery under specified conditions. The rated Ah capacity is the nominal capacity of a fully charged new battery under the conditions predefined by the catalog specifications of the battery, e.g. the nominal condition could be defined as room temperature 25 C and battery discharging is at 1/25 C-rate. The C-rate is used to represent a charge or discharge rate equal to the capacity of a battery in 1 hour, e.g. for a 6 Ah battery, 1C-rate is equal to charge or discharge the battery at a constant current value of 6 A; in the same way, 0.1C-rate is equivalent to 0.6 A, and 2C-rate for charging or discharging the battery at a constant current value of 12 A. The power density of the battery is an important criterion of battery selection that is defined as the peak power per unit volume of a battery (W/l). In the battery model dynamics, the effect of its internal resistance is significant. It is defined as the overall equivalent resistance within the battery. Also, it is worth to mention that its value varies during the charging and discharging battery cycles, and moreover may vary as the operating condition changes. The peak power according to the U.S. Advanced Battery Consortium (USABC)'s definition is given by: where V OC is the open-circuit voltage (OCV) and R is the battery internal resistance.
The peak power is defined at the condition when the terminal voltage is 2/3 of its OCV. The SOC of the battery provides an important feedback about the state of health (SOH) of the battery and its safe operation. SOC is defined as battery available capacity expressed as a percentage of its rated capacity. More precisely, the SOC can be defined as the remaining capacity of a battery and it is affected by its operating conditions such as load current and temperature: The SOC for a fully charged battery is 100% and for an empty battery is 0%, defined for a discharging cycle, when discharging battery current is positive, as: where η is the coulombic efficiency of the charging or discharging battery cycle, Ahnom represents the nominal battery capacity, i τ ð Þ is the instantaneous value of charging (i t ð Þ ≤ 0) or discharging (i t ð Þ ≥ 0) battery current.
The relation (3) can be also written as a first order differential equation that further it will be used for SOC state estimation: The SOC is a critical condition parameter for battery management system (BMS), often affected by its operating conditions such as load current and temperature; consequently, an accurate estimation of SOC is very important, since it is the key issue for the healthy and safe operation of batteries. The depth of discharge (DOD) is used to indicate the percentage of the total battery capacity that has been discharged at time t, defined as: The SOH of the battery is defined as the ratio of the maximum charge capacity of an aged battery to the maximum charge capacity when this battery was new. Its life cycle (number of cycles) is given by the number of discharging-charging cycles that the battery can withstand at a specific DOD (normally 80%) before it fails to meet the desired performance criteria. The actual operating life of the battery is affected by the charging and discharging rates, DOD, and by the temperature. The higher the DOD is the shorter will be the cycle life. To attain a higher life cycle, a larger battery is required to be used for a lower DOD during normal operating conditions.
The Battery Management System is an integrated battery structure consisting of measurement sensors, controllers, serial communication, and computation hardware with software algorithms such as Proportion Integral Derivative (PID) and adaptive control laws, Kalman filters estimators, adaptive or sliding mode observers designed to decide the maximum charging/ discharging cycles current and the duration from the estimation of SOC and SOH of the battery pack, as is shown in [11,[13][14][15].
2.1.3. Battery management systems: architecture, trends, functions, monitoring, faults detection, hardware and software components A BMS as an important connector between the battery and the HEV plays a vital role in improving battery performance and optimizing vehicle operation in a safe and reliable manner, as is mentioned in [13]. Nowadays, the trend of the BMSs is a rapid growth of the EV and HEV market, thus it is essential for the automotive industry to develop a comprehensive and mature BMSs. As is stated in [13]"the U.S. Council for Automotive Research (USCAR) and the U.S. Advanced Battery Consortium (USABC) have set minimum goals for battery characteristics for the long-term commercialization of advanced batteries in EVs and hybrid electric vehicles (HEVs)". Furthermore, to increase the market segment of EVs and HEVs automotive industry, the main concerns such as reliability and safety remain constantly for both of them, battery technology (BT) and BMS.
The BMS hardware and software components, the safety circuitry incorporated within the battery packs play an important role to monitor, control, compute and to show continually the safety state, the SOC, SOH, as well as the longevity of the battery.
Moreover, in [13] is emphasized one of the most dangerous situations such as the ignition of a Li-Ion battery during overcharging operating conditions, due to the volatility, flammability and entropy changes. Also, after repeated over-discharging cycles, the battery cell capacity is reduced significantly, due to irreversible chemical reactions, and thus the BMS needs to monitor and control constantly the Li-Ion battery state. Whenever any abnormal conditions happen, such as self-discharge leakage current through the insulation resistance of the battery, well-known as ground insulation resistances of the negative and positive bus of BMS R p , and Rn respectively, over-voltage or overheating operating conditions are identified, and in a very short time the BMS should notify the user and to execute the preset correction procedures [13,16]. In addition to these foremost functions, the BMS also monitors the system temperature to provide a better power consumption scheme, and communicates with individual components and operators [13]. Technically, a comprehensive BMS is equipped with the most suitable hardware and software components of the newest generation [14,15], integrated in the HEVs and EVs structure to accomplish the main following functions: (1) real-time monitoring of battery states by a performing data acquisition system of external signals (i.e. voltage, current, cell temperature etc.); (2) ensure user safety protection, and extend the battery life; (3) using performing and intelligent algorithms (as for example, genetic, fuzzy logic, neural networks and expert systems based on artificial intelligence) has the ability to estimate and monitor the battery internal parameters and states (i.e. the DC resistance, insulation resistances R p , and Rn, polarization voltage, maximum available capacity, SOC, SOH, etc.); (4) the ability to prevent over-charge or over-discharge of the battery; (5)efficient battery energy utilization, thermal management and SOC cell balancing; (6) delivery of battery status and authentication to a user interface; (7) the ability to communicate with vehicle controller and all other components [13,16]. In order to achieve these objectives, researchers focus on battery modeling, SOC estimation, consistency evaluation and equalization, such as stated in [16].
Furthermore, to increase the effectiveness of BMS in [13] is proposed a new BMS with the following categories of components: A. Hardware with the following components: Safety circuitry; Sensor system; Data acquisition; Charge and discharge control; Communication; Thermal management.
The sensor system block integrates different sensors capable to monitor and measure battery parameters including cell voltage, battery temperature, and battery current. The new proposed BMS in [13] it seems to have a lot of improvements in terms of current safety circuitry designs that can be easily implemented, amongst them is worth to mention the addition of accurate alarms and controls to prevent overcharge, over-discharge, and overheating. Therefore, the external signals such as the current, voltage, and temperature must be measured to improve the capability of state tracking in real life applications [13]. Data acquisition (DAQ) block in conjunction with the data storage block are critical parts for the software in the BMS to analyze and build a database for system modeling and estimation algorithms development.
The charge and discharge control block is integrated in hardware architecture of the BMS to implement the charge-discharge protocol. A variable resistor may be necessary to help balance cells or perform internal resistance measurements. In [13] is mentioned also that the "cell balancing control is still a critical design feature with room for improvement in order to equalize the battery pack and estimate the battery status in an efficient way". Most subsystems in a BMS are stand-alone modules, and hence, data transfer throughout the BMS is required. Communication through a CAN Bus is a major way to transfer data between the stand-alone subsystems within the BMS [13].
Furthermore, the recent development of smart batteries within the context of innovative electronics and artificial intelligence, more data can be collected to communicate with the user and the charger through the microchips incorporated within the battery [13]. In addition, "wireless and telecommunication techniques are gradually being incorporated into charging systems that facilitate communication between the battery and the charger". Finally, the last thermal management hardware module proved during the time that its integration in a BMS is critical to be integrated since the temperature variations between the cells have a great impact on cell imbalance, reliability and performance [13].
B. Software with the following components: SOC estimation and monitoring; SOH estimation and monitoring; Cell balancing; Fault Detection and Isolation; User interface.
The software compartment integrated in BMS structure is in reality such as an artificial "brain" that controls all hardware operations and examines all sensors data for making decisions and to implement in real-time linear, nonlinear and intelligent SOC, SOH estimators, and also FDI techniques. As is mention in [13], "the switch control, sample rate monitoring in the sensor system block, cell balancing control, and even dynamic safety circuit design should be handled by the software of a BMS". In addition, the software components assure online data processing, and also reliable and robust automated data analysis by controlling battery functions, representing an essential factor to perform successfully the SOC, SOH estimation and fault detection and isolation algorithms. The robust SOC and SOH estimators are design to integrate also a capability assessment of the life status of the battery and to "sets the operating limits according to state-of-the-art algorithms, such as fuzzy logic, neural networks, state-space-based models, and so on " [13]. Most of the soft battery faults are detected through online data processing by means of an intelligent data analysis that provides information about the occurrence of the faults and their persistence by fault warnings, and also indicates abnormal limits of operating conditions. The history of the past measurements data set is recorded and provides the pre-alarm condition before the possible battery faults. In [17,18] is proposing a real-time diagnosis approach that detects, isolates, and estimate specific sensor faults, such as battery voltage, current temperature, and fan motor. The sensor fault estimation can provide great benefits for enhancing the reliability of BMSs. Also, the sensor fault estimation can provide fault-tolerance capability to the BMS by allowing it to continue in degraded and in safe mode even after the sensor faults occur, as is mentioned in [17]. Failure in Li-Ion batteries can be also attributed to a combination of manufacturing defects, safety component failure, or human operating errors, as is specified in [18]. Furthermore, in [18] are developed some methods for realistic fault injection. Two types of sensor faults are considered in [18], namely an intermittent signal loss due to faulty wiring connections and sensor bias resulting from time or temperature drift. For the fan motor, the only fault considered is a total motor failure, and thus no longer provide cooling to the battery. The occurrence of the realistic battery faults are established based on the preset thresholds. These thresholds are computed as a minimum values that assure the prevention of the false alarms, based on the minimization of the residual error probability when occurs a fault, by studying the probability density functions (PDF)) of the healthy and faulty signals, such is shown in [18]. The PDfs are obtained through extensive experimental data collection or simulations on the system.
Roughly, for many faults scenarios to compute the magnitude of the thresholds we can use also the statistics of the residual errors for healthy system between the measured values data set and its estimated values, such as the mean μ X À Á and the standard deviation (σ) calculated in steady state. The threshold can be calculated by addition to the mean μ X À Á of residual error approximatively two times the standard deviation 2σ ð Þ. The decision for occurrence of the fault is given by comparison of the residual error and the computed threshold. The tuning of the threshold to avoid the false alarms can be done by well-known trials and error method. The user interface block must display the essential information of the BMS to the users.

Li-Ion battery EMC description
The equivalent model circuits (EMCs) are simple electric circuits consisting of voltage sources, resistors and capacitors networks, commonly-used to simulate the dynamic behavior of the Li-Ion batteries [1,8,11]. The role of the resistor-capacitor (RC) series networks integrated in EMCs is to improve models' accuracy, and also to increase the structural complexity of the models [1,8]. In this research paper we chose for Li-Ion battery model design and implementation stages an equivalent second order model RC circuit. It consists of a resistor R, two series RC cells (R 1 C 1 , R 2 C 2 ), and an open-circuit voltage (OCV) source dependent of SOC, i.e. OCV (SOC), as is shown in Figure 1(a), in NI Multisim 14.1 editor. In EMC architecture, R denotes the internal ohmic resistance of the Li-Ion battery, the parallel cells (R 1 , C 1 ), (R 2 , C 2 ) connected in series denote the electrochemical polarization resistances and capacitances, for which T 1 = R 1 C 1 , T 2 = R 2 C 2 can imitate the fast polarization time constant, and the slow polarization time constant for the voltage recovery of the Li-Ion battery respectively {14]. Also, i t ð Þ is the battery instantaneous value of the direct current (DC) flowing through the OCV source, and v t ð Þ represents the measured battery instantaneous value DC voltage. The main benefit of the RC second order EMC architecture selection is its simplicity and the ability to be implemented in real-time applications with acceptable range of performance [1,8].
Also "this choice is due to the early popularity of BMS for portable electronics, where the approximation of the battery model with the proposed EMC is appropriate", as is mentioned in [1,8]. Related, this approach has been extended easily to Li-Ion batteries for automotive industry and for many other similar energy storage applications [11]. Since the EMC is used in following sections to design and implement in real-time all three proposed nonlinear state estimators, now it is essential to precise the main factors that affects the battery parameters, especially the internal and insulation resistances and their impact on the battery dynamics in a realistic operating conditions environment. The internal resistance of the battery is affected by the following factors: conductor resistance, electrolyte resistance, ionic mobility, separator efficiency, reactive rates at the electrodes, and concentration polarization, temperature effects and changes in SOC. When a battery fails, it is typically since it has built up enough internal resistance that it can no longer supply a useful amount of power to an external load, according to the maximum power transfer between the source and the load. The insulation positive and negative resistances of the battery are denoted by R n , and R p respectively, and are shown in the diagram from Figure 1(b). The main objective is to get a good insight on the impact of the insulation resistances on the battery dynamics, as is described in detail in [16]. Also, in [16] the HEV is considered as a "complex production of mechanical-electrical integration", for which the power supply typically being in the range 100-500 V is obtained by means of several series battery packs. Amongst the BMS hardware devices consisting of high voltage components, the traction battery, electrical motor, energy recycle device, the battery charger and its auxiliary device deal with a large current and insulation [16], thus insulation issue must be under consideration since the design stage. As is stated in [16], the poor working conditions, such as shaking, corrosion, changes in temperature and humidity, "could cause fast aging of the power cable and insulation materials, or even brake the insulation, which would decrease the insulation strength and endanger personnel". Thus, needs to ensure safety operating conditions for personnel are required to evaluate the insulation conditions for entire HEV's BMS.
The National Standard (NS) 18384.3-2001, stipulates several safety requirements for HEVs, especially for insulation resistance state, measurement method [16]. According to NS, the insulation state of an EV is evaluated according to the ground insulation resistance of the DC positive and negative bus, V p , and V n respectively, as is shown in Figure 1(b) [16]. The definition of traction battery insulation resistance in NS "is the relative resistance to maximum leakage current (in the worst condition) where there is a short between the traction battery and ground (electric chassis)" [16]. Also, "under the conditions that the maximum AC voltage is less than 660 V, the maximum DC voltage is less than 1000 V and the car weight is less than 3500 Kg, the requirements of the high voltage security are as follows: (1) personnel's security voltage is less than 35 V, or the product of the contact current with a person and the duration of time is less than 30 mA s; insulation resistance divided by the battery rated voltage should be more than 100 ΩV À1 , and preferably more 500 ΩV À1 ", as is formulated in [16]. Thus, to ensure the insulation security of on-board BMS, it is necessary to detect the insulation resistance and raise an alarm in time. Currently, the insulation measurement methods, such as passive ground detection and active ground detection, include the AC voltage insulation measurement method, and the DC voltage insulation measurement method [16]. The passive ground detection insulation measurement method principle is presented in Figure 1(b) where the presence of leakage current is detected by discovering the resultant magnetic field generated by AC voltage around the mutual inductor.

Li-Ion battery continuous time state-space representation
By simple manipulations of Ohm's, current and voltage Kirchhoff's laws applied to the proposed Li-Ion battery's EMC can be written the following first order differential equations that are most suitable to capture the entire dynamics of EMC in time domain: By defining the following state variables representing the polarization voltages of the two RC cells, and considering as battery input u the DC instantaneous current that flows through battery, u ¼ i t ð Þ, and as a battery output y, designating the terminal battery DC instantaneous voltage, i.e. y ¼ v t ð Þ, the Eq. (6) can be written in a state-space representation, as follows. where ½ represent the time constants of the both polarization RC cells, and the OCV combines three additional well-known models, as defined and used in [4,8], given by:

Li-Ion battery characteristics:
• The value of the battery capacity, Q = 6 Ah (Amperes hours), the voltage nominal value of the battery, V nom = 3.6 V (Volts), and the coulombic efficiency, η = 1, for charging cycle, and η = 0.85, for discharging cycle 3. The OCV coefficients: • K 0 = 4.23, K 1 = 3.86E-05, K 2 = 0.24, K 3 = 0.22, K 4 = À0.04 The OCV x 3 t ð Þ ð Þis a nonlinear function of SOC, i.e.x 3 , similar as in [1,3,4,[8][9][10][11], increasing the accuracy of the Li-Ion battery EMC model, known as the EMC combined model, one of the most accurate formulation by combining Shepherd, Unnewehr universal, and Nernst models introduced in [4,8]. The tuning values of model parameters K 0 ; K 1 ; K 2 ; K 3 ; K 4 ð Þ are chosen to fit the model to the manufacture's data by using a least squares curve fitting identification method OCV = h (SOC), as is shown in [3,4,8], where the OCV curve is assumed to be the average of the charge and discharge curves taken at low currents rates from fully charged to fully discharged battery [3,4,6,8]. Also, by using low charging and discharging DC currents can be minimized the battery cell dynamics. A simple offline (batch) processing method for parameters calculation is carried out in [3,4,6,8].

Li-Ion battery discrete time state-space representation
We introduce now the following new notations: With these notations, a discrete time state space representation of the combined EMC Li-Ion battery model is obtained:: Further, a compact discrete time of combined ECM Li-Ion battery state space representation (9) can be written in the following matrix form: where the nonlinear function Ψ x 3 k ð Þ ð Þcan be further linearized around an operating point to get a linear Li-Ion battery combined EMC, easily to be implemented in real-time. To analyze the behavior of the proposed Li-Ion battery EMC for different driving conditions such as urban, suburban and highway, some different current profiles tests will be introduced in the next subsection.

Li-Ion battery equivalent model in ADVISORY MATLAB platform-case study
For EMC validation purpose we compare the results of the tests using a NREL with two capacitors already integrated in an Advanced Vehicle Simulator (ADVISOR) MATLAB platform, developed by US National Renewable Energy Laboratory (NREL), as is shown in [9,10]. The NREL Li-Ion battery model approximates with high accuracy the Li-Ion battery model 6 Ah and nominal voltage of 3.6 V, manufactured by the company SAFT America, as is mentioned in [9,10]. Also, for simulation purpose and comparison of the tests results, the EMC battery model is incorporated in a BMS' HEV, and its performance is compared to those obtained by a particular Japanese Toyota Prius, selected as an input vehicle in ADVISOR MATLAB platform, under standard initial conditions and the setup shown in Figure 2.
Among different driving speed cycles for a large collection of cars provided by the ADVISOR US Environmental Protection Agency (EPA), in our case study for Toyota Prius HEV car, the speed profile is selected as an Urban Dynamometer Driving Schedule (UDDS), as is shown in Figures 3 and 4, respectively.  Both, the driving UDDS cycle for car speed (mph) profile and its corresponding Li-Ion battery UDDS current profile are represented separately in the same ADVISOR MATLAB platform, as is shown in the first two corresponding top graphs from Figure 4.
Also, the exhaust gases emission and SOC curves, as a result to the same UDDS cycle test on the ADVISOR MATLAB platform, are shown in the last two bottom graphs of Figure 4, accompanied by details in the next section.
The Li-Ion battery EMC and the ADVISOR SOCs, for the same initial condition, SOC = 70% and the same UDDS cycle profile input current test, are implemented in a real-time MATLAB environment, as is shown on the same graph at the top of Figure 5. The SOC simulations reveal a great accuracy between Li-Ion battery EMC and its corresponding ADVISOR NREL model represented on ADVISOR MATLAB platform, as is shown in Figure 4, thus an expected confirmation of the EMC validation results.
The second graph from the bottom in the same Figure 5 depicts the EMC battery output terminal DC instantaneous voltage y ¼ v t ð Þ, as a response to the UDDS cycle current input profile test.
The simulation results of Li-Ion battery EMC output voltage show a stabilization of the battery output voltage value at the end of UDDS cycle, i.e. after 1370 seconds.    Likewise, the Li-Ion battery OCV for a discharging cycle at 1C-rate (i.e. 6 Ah Â 1/h = 6A constant input discharging current) is shown in the top of Figure 6, and its corresponding SOC during the same discharging cycle is revealed on the bottom graph of the same Figure 6 respectively.

Development and implementation in real-time of SOC Li-Ion battery estimators on MATLAB/SIMULINK platform
In this section we propose for Li-Ion battery EMC SOC estimation three nonlinear on-board real-time estimators integrated in BMS of HEV, based on Kalman Filter (KF) technique, specifically a nonlinear Gaussian Unscented Kalman Filter (UKF), a non-Gaussian nonlinear Particle Filter (PF), and a nonlinear observer estimator (NOE). The simulations results and a comprehensive performance analysis for each proposed SOC estimator are presented in the following subsections of this section.

Unscented Kalman filter real-time estimator design and robustness analysis
The main aim of this subsection is to build a nonlinear UKF SOC estimator, following the same design procedure described rigorously in [5]. We are motivated by some preliminary results obtained in our research, as you can see in [6,7]. Technically, UKF estimator is based on the principle that one set of discrete sampled points parameterizes easily the mean and the covariance of a Gaussian random variable, as is stated in [5]. Moreover, the nonlinear estimator UKF yields an equivalent performance compared to a linear extended Kalman filter (EKF), well documented in [3,4,8], excluding the linearization steps required by EKF. In addition, the results of UKF real-time implementation for the majority of similar applications are encouraging, and it seems that the anticipated performance of this approach is slightly superior compared to EKF [3,4,8]. Furthermore, the nonlinear UKF SOC estimator can be extended to the applications where the distributions of the process and measurements noises are not Gaussian [19]. Concluding, the implementation simplicity and a great estimation accuracy of the proposed UKF SOC estimator recommend it as the most suitable estimator to be used in almost all similar applications. Explicitly, the nonlinear UKF estimator is an algorithm of "predictorcorrector" type applied to a nonlinear discrete -time systems, such as those described in [3][4][5][6][7]: where f : ð Þ, g : ð Þ are two nonlinear functions of system states and inputs; w k ð Þ, v k ð Þ are zeromean, uncorrelated process, and measurement Gaussian noise respectively. Since the noise injected in the state and output equations are randomly, also the system state vector and the output become random variables, having the mean and covariance matrices as a statistics. The nonlinear UKF SOC estimator has a "predictor-corrector" structure that propagates the mean and the covariance matrix of a Gaussian distribution for the random state variable x k ð Þ in a recursively way, in both prediction and correction phases, as is stated in [3][4][5][6][7]. The propagation of these first two moments is performed by using an unscented transformation (UT) to calculate the statistics of any random variable that undergoes a nonlinear transformation [5][6][7]. As is stated in the original and fundamental work [5], by means of this UT transformation "a set of points, the so-called sigma points, are chosen such that their sample mean, and sample covariance matrix are x and P xx , respectively". Also, "the nonlinear function g : ð Þ is applied to each sigma points generating a "cloud" of transformed points with the mean y and the covariance matrix P yy ". Furthermore, since statistical convergence is not an issue, only a very small number of sample points is enough to capture high order information about the random state variable distribution. The different selection strategies of the sigma points and the UKF algorithm steps in a "predictorcorrector" structure, as well as its tuning parameters are well documented in the literature, and for details we recommend the fundamental work [5]. Since we follow the same design procedure steps for building a nonlinear UKF SOC estimator as in [5][6][7], we are focused only to the implementation aspects.
The simulation results of the real-time implementation of proposed UKF SOC nonlinear estimator in MATLAB R17a environment are shown in Figures 7 and 8. In Figure 7 are presented the simulation results for EMC SOC true value versus EMC SOC-UKF and ADVI-SOR MATLAB platform estimated values.
Also, at the bottom of Figure 7 is shown the EMC battery output terminal true value DC voltage versus EMC-UKF battery output terminal estimated DC voltage. The simulation results reveal an accurate SOC estimation values, and also a very good robustness of UKF estimator to the changes in initial SOC value (guess value, SOCinit = 20%). In Figure 8 are shown the Li-Ion EMC polarization voltages versus Li-Ion EMC -UKF estimates, and in Figure 9 is represented the robustness of EMC-UKF SOC nonlinear estimator to a gradual increase in the internal resistance by 1.5 until 2 times of its initial value. The simulation results reveal a significant decrease in Li-Ion EMC UKF SOC estimator performance to an increase in internal resistance, but still remains convergent to EMC measurements after a long transient.

Particle filter real-time estimator design and robustness analysis
In this subsection we propose a real-time PF SOC nonlinear estimator with a similar" prediction-corrector" structure found to the nonlinear UKF SOC estimator described in the previous subsection 3.1. Consequently, is expected that the proposed nonlinear PF SOC estimator to update recursively an estimate of the state and to find the innovations driving a stochastic process given a sequence of observations, as is shown in detail in the original work [19]. In [19] is stated that the PF SOC estimator accomplishes this objective by a sequential Monte Carlo method (bootstrap filtering), a technique for implementing a recursive Bayesian filter by Monte Carlo simulations.  The process state estimates are used to predict and smooth the stochastic process, and with the innovations can be estimated the parameters of the linear or nonlinear dynamic model [19]. The basic idea of PF SOC estimator is that any probability distribution function (pdf) of a random variable can be represented as a set of samples (particles) as is described in [19], similar thru sigma points UKF SOC estimator technique developed in subsection 3.1 [5]. Each particle has one set of values for each process state variable. The novelty of this method is its ability to represent any arbitrary distribution, even if for non-Gaussian or multi-modal pdfs [5].
Compared to nonlinear UKF SOC estimator design, the nonlinear PF SOC estimator has almost a similar approach that does not require any local linearization technique, i.e. Jacobean matrices, or any rough functional approximation. Also, the PF can adjust the number of particles to match available computational resources, so a tradeoff between accuracy of estimate and required computation. Furthermore, it is computationally compliant even with complex, non-linear, non-Gaussian models, as a tradeoff between approximate solutions to complex nonlinear dynamic model versus exact solution to approximate dynamic model [6,19]. In the Bayesian approach to dynamic state estimation the PF estimator attempts to construct the posterior probability function (pdf) of a random state variable based on available information, including the set of received measurements. Since the pdf represents all available statistical information, it can be considered as the complete solution to the optimal estimation problem. More information useful for design and implementation in real-time of a nonlinear PF estimator can be found in the fundamental work [19]. Since we follow the same design procedure steps to build and implement in real-time a nonlinear PF estimator, as is developed in [19], we are focused only on the implementation aspects. The simulation results in real-time MATLAB R17a environment are shown in Figures 10 and 11.
In Figure 10   nonlinear PF estimator. In Figure 11 are shown the Li-Ion EMC polarization DC voltages versus EMC PF estimates. In Figure 12 is shown the robustness test of Li-Ion EMC-PF SOC nonlinear estimator to a gradual increase in the internal battery resistance by same values considered for Li-Ion EMC-UKF SOC estimator.
The simulation results reveal a good robustness and convergence of Li-Ion EMC-PF estimator, but with a lot variance in the estimated values. Overall, the simulation results reveal a fast PF estimator convergence, a good SOC filtering, an accurate SOC estimation value, and also a very good robustness of PF estimator to big changes in the initial SOC value (guess value, SOCinit = 20%), and slightly slow behavior to an increase in internal resistance of the Li-Ion battery.

Nonlinear observer real-time estimator
In this subsection, a nonlinear observer SOC estimator (NOE) is under consideration. It is proposed to have more flexibility for a suitable choice of the best Li-Ion battery SOC estimator  amongst UKF, PF, and NOE SOC estimators. We follow the same design procedure steps for its design and implementation in a real-time MATLAB R2017a simulation environment as in [1]. The estimator design is based on an important information provided by the linear structure of the matrix Eq. (9).
According to this structure all three state variables Precisely, the nonlinear, linear and sliding mode observers are most applied in state estimation problems to eliminate state estimation error using deviation feedback, as is mentioned in [1]. Furthermore, for Li-Ion battery SOC estimation, most of existing observers are model based using for structure design the difference between the estimated value of battery output terminal DC instantaneous voltage and its corresponding measured DC voltage value multiplied by the observer gains to correct the dynamics of all estimated states, as follows: where the matrices A and B are the same as in Eq. (9), b x k ð Þ is the estimate of the EMC states vector, and L k is the observer gains vector (similar to the extended Luenberger observer for nonlinear systems). The particular structure of Li-Ion battery EMC reveals that the output estimation error e y is mainly caused by an inaccurate SOC estimated value, as is stated also in [1]. Consequently, only the SOC state estimate from third discrete state Eq. (15) will be affected, i.e. the observer gains vector becomes: l 1k ¼ 0, l 2k ¼ 0, l 3k 6 ¼ 0 (16) This outcome improves significant the NOE SOC estimation accuracy and simplifies the structural complexity of the proposed nonlinear observer estimator. The dynamics of the nonlinear observer estimation errors can be described by the following differential equations [1]: In [1] is proved that all three states estimation errors described by the system of Eq. (17) converge asymptotically to zero in steady-state, and the observer gain for the new simplified structure is approximated by an adaptive law: that allows the value of l 3k to change dynamically according to the deviation between the measured battery output DC voltage and battery EMC output DC voltage. In Eq. (18), l 30 , α and β are tuning parameters designed to adjust the adaptive property of l 3k . Amongst them, l 30 determines the convergence rate of the proposed NOE at first "inaccurate" stage, the coefficients α and β are used to adjust observer gain l 3k when the SOC state estimation also reaches "accurate" stage, as is stated in [1].
Furthermore, three main assumptions are formulated in [1] to tune the values of EMC-NOE parameters l 30 , α and β: (a) l 3k ≥ 0 to ensure the stability of the proposed NOE; (b) if SOC state estimation error is large, the value of l 3k should be big enough to ensure a fast convergence rate; (c) if the voltage estimation error is small, the value of l 3k should be small enough to avoid SOC estimation "jitter" effect. By extensive simulations performed in a real-time MATLAB R2017a simulation environment the requirements (a), (b), (c) are met if the NOE parameters l 30 , α and β are tuned for the following values: l 30 = 0.3, α = À0.01, and β = À 1. The simulation results on the estimation performance of Li-Ion EMC-NOE are shown in Figures 13 and 14.
In Figure 13 are shown the simulation results for Li-Ion EMC SOC true value versus Li-Ion EMC SOC-NOE and ADVISOR MATLAB platform estimated values. At the bottom of Figure 13 are presented the Li-Ion EMC battery output terminal true values DC voltage versus Li-Ion EMC battery output terminal DC voltage estimated by the proposed Li-Ion EMC NOE SOC estimator. In Figure 14 are displayed the Li-Ion EMC polarization DC voltages versus Li-Ion battery EMC-NOE estimates.
In Figure 15 is depicted the robustness of Li-Ion EMC-NOE SOC estimator to an increase in internal battery Li-Ion resistance with the same values as used for the previous nonlinear estimators, EMC UKF and EMC PF respectively.
The simulation results in Figure 15 reveal slightly slow robustness to an increase in internal resistance of Li-Ion battery compared to simulation results from Figure 13, but still the convergence is reached in a long transient with much variation in the SOC estimates. Overall, the simulation results from this section reveal a fast NOE estimator convergence, a good SOC filtering, an accurate SOC estimation value, and also a very good robustness of PF estimator to big changes in the initial SOC value (the same guess value as for UKF and PF, SOCinit = 20%), compared to a gradual degrade in SOC estimation performance to an increase in internal battery resistance.    Figure 16 disclose a precious information about the convergence of all three proposed estimators to Li-Ion EMC SOC true values for the proposed Li-Ion battery EMC. Furthermore, a useful benchmark is built in terms of the statistics errors between the states estimates and the corresponding model states values, such as root mean square error (RMSE), mean square error (MSE) and mean absolute error (MAE), defined in [6]. They are very easy to be computed in MATLAB R2017a, and the results are shown in Table 1. The MSE is a measure of how close the estimates values fit to model "true" values. The squaring is done so negative values do not cancel positive values. The smaller the MSE, the closer the fit of the estimates values is to the model "true" values. The RMSE is just the square root of the MSE [6].
The RMSE is probably the most easily interpreted statistic, since it has the same units as the model states. Similar as MSE, lower RMSE the state estimates fit better the model states, i.e. battery SOC and the battery polarization voltages. The MAE statistic is helpful to determine the accuracy of the Li-Ion battery EMC-UKF, EMC-PF and EMC-NOE SOC estimates with respect to the "true" model values. It is usually similar in magnitude to RMSE, but slightly smaller, and has the same units as the model states data set.  UKF and PF estimators. Consequently, for this kind of applications the EMC-NOE SOC estimator is the most suitable estimator compare to UKF and PF estimators.

Conclusions
The main contribution of this research paper is the design and implementation in real time of a three robust nonlinear estimators, namely UKF, PF and NOE, capable to estimate with high accuracy and robustness the Li-Ion battery SOC based on a simple battery 2R EMC without disturbance uncertainties. The simulation results obtained in a real-time MATLAB simulation environment reveal that amongst all three proposed nonlinear SOC estimators the EMC NOE is a most suitable alternative to SOC UKF and PF estimators for this kind of application. The number of tuning parameters for SOC EMC NOE is much smaller than for UKF and PF estimators. The proposed SOC EMC NOE proves its effectiveness in terms of implementation