Memuat
Memuat
A 1RC-cell observer recovers the SOC even when the initial guess is wrong and the current sensor is biased.
0 views
A digital twin of a 96-series 60 Ah EV battery pack: a one-RC equivalent cell with an OCV-versus-SOC curve, driven by a driving current profile, with a 0.5 V noisy voltage sensor and a 3 A current-sensor bias. The observer uses the same model and corrects itself with the difference between measured and predicted voltage. Coulomb counting, which only integrates the current, is shown as the comparison and keeps drifting.

Three sine waves (base load, acceleration, road vibration) are summed and clipped by a Saturation block, giving a current from about -39 A (regeneration) to 79 A.
The SOC is an Integrator output, the RC voltage is set by a second Integrator, and the terminal voltage comes from the OCV(SOC) table minus V1 and R0 times current.
The pack voltage gets 0.5 V of noise and the current gets a constant 3 A bias, so the measurements no longer match the true state.
The same model runs from an initial SOC guess of 50 percent; the difference between measured and predicted voltage, times gains L1 and L2, is fed back to both integrators.
An integrator of the biased current, starting from 50 percent SOC, serves as the baseline; all three signals are plotted together in a Scope and logged to the Workspace.
System
A 96S 60 Ah EV pack: a 1RC equivalent cell (R0 0.9 mOhm, R1 0.7 mOhm, C1 24,000 F) with a 12-point OCV curve.
Scenario
A 3,600 s simulation with a 0.1 s step; the true SOC starts at 90 percent, the estimators start from a 50 percent guess.
Note: The data comes from a simulation with cell parameters chosen for the example, not from measurements of a real battery.
Simulink model soc_baterai_observer.slx (standard block diagram); Builder script buat_model.m and runner jalankan.m; Result plots grafik_soc (PNG) and metrik.json; Step-by-step PDF guide (sent with the package; also part of the video class); Video tutorial in the MATLAB Simulink 2026 Trends class (this project's episode; episode 1 is free); Requires MATLAB and Simulink (built in R2025b); the slh.m builder helper is included.
Yes. The .slx model opens in MATLAB with Simulink (built in R2025b; use the same or a newer release). Project 09 also needs the Communications Toolbox. The package includes the builder script and the runner, so you can also rebuild the model and rerun the plots yourself.
Yes. Parameters are kept in the Model Workspace, so you can change values such as gains, capacities and profiles and rerun the simulation. If you would like us to adapt or extend the model for you, message us on WhatsApp.
The project costs US$17. Use the "Buy via WhatsApp" button on this page; the project files are delivered after payment is confirmed.
Found a problem or have a suggestion for this project? Tell us on WhatsApp
Back to MATLAB Simulink portfolio