The MATLAB/Simulink model is based on the paper "A Dynamic Lithium-ion battery model considering the effects of the termperature and capacity fading"
The Blocks folder contains the Simulink blocks.
The Scripts folder contains the MATLAB scripts used to launch the MATLAB simulation and the text files containing the input data for the simulation.
Matlab
├── Blocks
│ ├── complete_model.slx
│ ├── simulation.slx
│ ├── *.slx
├── Scripts
│ ├── simulink_simulation.m
│ ├── plot_simulation_csv.m
│ ├── data
│ │ ├── input_data.txt
│ │ ├── input_control.txt
│ │ └── results.csv
Each block is named after the number of the equation found on the paper (A Dynamic Lithium-ion battery model...) on which the model is based.
| File name | Description |
|---|---|
complete_model.slx |
Contains the complete model made up of all the other Simulink blocks |
simulation.slx |
Contains the complete_model block and connects it to the input and output MATLAB variables |
| File name | Description |
|---|---|
delta_E_regression.m |
Script that finds the potential correction term that is dependant on the temperature. Refer to this paper at Fig. 6 |
plot_simulation_csv.m |
Script that plots the output data of the C Model contained in the /data/result.csv |
simulink_simulation.m |
Script that launches the simulation of the Simulink model /Blocks/simulation.slx |
Complete Simulink model
The above picture shows the complete Simulink model. Four main blocks contain the additional sub-blocks, each is named after the equation it implements.
Detail of Simulink model
The following expressions are implemented in the detailed view of the Simulink model
The idea behind the cycle number counter was con consider each full charge/discharge cycle as one cycle. The counting is made easy by using the c-rate computed above.
- The model inputs are passed via the file
/data/input_data.txt - Some battery voltage constraints (V_max and V_min) can be set in
/data/input_control.txt: the simulation is stopped when the output voltage of the battery leaves the interval between V_max and V_min. - Executing
simulink_simulation.mlaunches the simulation. - The output data are shown on plots.

