Predicting State of Health and Lifecycle of Li-ion Batteries (pt.2)

Adam Davis
7 min readJun 15, 2022

“I put my heart and my soul into my work, and have lost my mind in the process”

-Vincent Van Gogh

In part one of an analysis of li-ion batteries, I discussed a possible strategy. Here I break it down into facts and possible actionable insight and results. Li-ion batteries to re-iterate are not just for electric cars. They are also in your cell-phones, laptops and many different electronics that are able to be charged. These batteries have normal wear and tear that they go under and one main aspect of this is called plating. Plating is the process of lithium ions getting stuck in the layer between the cathode and anode. Lithium ions are needed to carry the charge from one part of the other. If too many ions get stuck, no more energy to discharge and use.

The data used here is broken down by charge, discharge and rest cycles. There are also full charge and full discharge cycles as well with the test ending when the batteries are close to 30% state of health. One good measure of the state of health of a battery is the speed at which it discharges a given range of volts. This is measured in kilowatt hours or kwh. This is then used to perform a linear regression to allow for a slope and intercept to be found to obtain an estimate of the life cycle of the battery. However, this does not explain the whole story. As will be demonstrated, other factors can affect the lifecycle as well.

kwh before regression

As we can see here the downward trend for the discharge in kwh is mostly linear in nature. Over time the battery cells are not as able to hold the same energy level. The specified range is passing faster and faster over time. Another way to break this down is to visualize the total amount of kilowatt hours discharged throughout each separate trial:

Some of the rates of kilowatts accrued are linear but some are also similar to a logarithmic function. We can be assured that eventually the cell will not use any kwh and the line will go almost flat but never absolutely flat. There will still be a rise in total kwh but not as much or as fast as the more linear curves. It is evident that using less energy could allow the battery to last for longer. We can also see that there is a bottom group of curves that do not have a long range so far. One possible reason is the temperature. With the range of discharge needing to be near constant, approximately 4.2 to 3.2 volts, this seems to be a given.

An indicator of the true state of health is the kwh that the cell expends its energy in a specified constant range (in this case 4.2v-3.2V). The temperature and the total kwh used of the cell will be used to analyze the levels and to create and optimize a model for the lifecycle length of a battery cell.

As the cells aren’t tested to their maximum capacity and full lifecycle, the end lifecycles will need to be estimated from available data. We see from the temperature plots for each full discharge state that the rates of change in temperature can sort of fluctuate. They can decrease, increase or stay the same. For the purposes of our model we will take the full projected temperature increase into effect. The total kwh accrued is also seen as being linear and also decreasing. The slope of this line will be assumed as being fairly constant and will thus lend itself well to prediction from linear regression. The three variables that will be used to predict the end life cycle as accurately as possible will be the slope of the total temperature rise (assuming it remains constant), the total kwh accrued (also assuming it remains constant) as well as the regressed lifecycle. The plot of the regressed lifecycles is as follows:

Kwh per cycle against the total amount of time for the kwh per cycle to reach zero

The lifecycles are now stored as an array able to be used. Instead of attempting to predict (though we also can) the end temperature of the battery cell, we can instead use the rate of increase or decrease to evaluate the performance of the battery. In the running analyzation we will not always have the full test allowed and the objective of this project is to analyze the effect that the output and temperature have on the total amount of time that the battery can be used: i.e. how long and hard can the battery be used for and what slows it down and how fast or slow?

For analyzation purposes the following variables have been calculated:

1. Kilowatt hours for each full discharge during the trial

2. Rate of temperature change (Celsius) for each during trial discharges

3. Beginning temperature pre-trial for each trial

4. Projected final temperature (assuming rise is constant)

5. Kilowatt hours accrued for each trial

6. Projected total kilowatt hours

Target variable is the natural log of the projected time length for each separate trial. The goal is again to accurately predict the lifecycle of the lithium ion battery cell with the limited data that is available.

First for a linear model:

We can see that the performance is not really where we would want to go. We could attempt to tune the parameters but before we test this further the dataset will also be put through a neural network to test the prediction ability:

The neural network keeps track of the best performance of the model on the training and test data. The resulting plot of both the training and test data are as follows:

The performance seems okay. With limited data and testing on projected we have achieved strong accuracy. The model is accurate to within approximately 6 hours on average of runtime with the test data. The model was accurate to within 169 hours on average during training but looks like a strong fit from the graph of the true data against the predicted. With more data available and with more testing the performance should become even better. Using other datasets could also boost performance and have a stronger accuracy. Also a model with perfect training predictions doesn’t always result in a good test score.

What does it all mean?

What it means is that assuming that the information is correct we can be reasonably assured that the variables are able to hold importance to the lifecycle of the battery cells that were tested. We can tell what can prolong the state of health of the battery from the data used:

The longest lasting trials accrued less kilowatt hours overall, have a smaller amount of projected kilowatt hours as well as a more constant rate of change in temperature. The shortest are seen to have a much higher kilowatt hour projected, accrue more kilowatt hours during their respective trials and normally a more steep rate of change in temperature. This is again assuming that the rates remain somewhat constant with minimal actual volatility.

We can see that the lifecycle is longer when the battery is not used to its capacity frequently and the temperature is kept constant or decreasing. Other factors are the temperature of the battery and if it is kept cool or constant or allowed to gain heat unhindered. The time to achieve the desired end voltage of the cell each test was also taken into account. Sometimes this was faster and others slower. Together these were used to bolster the lifecycle projections and to also be able to somewhat accurately tell what the lifecycle of a lithium ion cell could be.

--

--