Skip to content

Releases: mohammadrezwankhan/matlab-simulink-energy-lab

v0.7.0 - Two-RC identification and controller metrics

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 23 Jul 22:47
fe21326

Toolbox-free two-RC identification and reusable controller metrics

This release adds a transparent battery equivalent-circuit parameter-identification workflow and promotes controller-comparison results to an export-ready engineering table.

Two-RC identification

  • estimates positive R0, R1, C1, R2, and C2 values from timestamped current, independently estimated OCV, and terminal-voltage data
  • separates the nonlinear time-constant search from the linear resistance solve
  • enforces ordered fast and slow branches and rejects ill-conditioned or nonphysical candidates
  • supports absolute or relative measurement timestamps
  • evaluates fitted parameters on a genuinely separate held-out pulse profile
  • includes deterministic malformed-input, repeatability, and timestamp-offset regression checks

Canonical benchmark:

Calibration RMSE: 0.401 mV
Held-out RMSE: 0.440 mV
Estimated time constants: 2.01 s and 33.88 s

The bundled voltage records are explicitly synthetic and deterministic. They validate the implementation and cross-validation workflow without claiming physical-cell calibration accuracy.

Controller comparison

  • adds a reusable table for open-loop, PI, and filtered-PID performance
  • reports deterministic steady error, overshoot, settling time, duty bounds, and saturation status
  • supports direct CSV export and readback validation

Verification

  • all 16 MATLAB and Simulink checks passed on MATLAB R2026a
  • MATLAB Code Analyzer reported zero findings in the added and changed MATLAB files
  • citation metadata passed the CFF schema validator
  • Markdown links passed the repository link gate
  • generated social preview verified at 1280 x 640 and 86.3 kB

See the two-RC example and closed-loop converter example for equations, assumptions, usage, validation, and limitations.

v0.6.0 - Pouch-cell thermal-gradient model

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 23 Jul 21:09
db2ca45

Pouch-cell through-thickness thermal-gradient model

This release adds a toolbox-free, one-dimensional finite-volume reference for spatial thermal behavior in a lithium-ion pouch cell with asymmetric face cooling.

Engineering capabilities

  • resolves 15 cell-centered through-thickness temperatures by default
  • combines internal volumetric heat generation, through-plane conduction, and independent face convection
  • reports inferred surface, center, volume-average, and hot-spot temperatures
  • exposes every interface and boundary heat flow
  • closes node-level and whole-cell discrete energy balances
  • accepts native irregular timestamps or a requested uniform sample time
  • rejects malformed inputs and unstable explicit time steps

Independent validation

  • all 15 MATLAB and Simulink checks passed on MATLAB R2026a
  • MATLAB Code Analyzer reported zero issues across the five new MATLAB files
  • the symmetric case matches the continuous steady-state slab center temperature within 0.003 degC
  • the medium-to-fine spatial-grid center difference is 0.0024 degC
  • citation metadata and Markdown links passed their GitHub Actions gates

Canonical asymmetric-cooling result:

Peak node temperature: 43.83 degC at 5.60 mm and 1800 s
Peak through-thickness node spread: 3.09 degC

See the pouch-cell thermal-gradient example for equations, assumptions, usage, outputs, validation, and limitations.

v0.5.0 - Battery module liquid-cooling network

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 23 Jul 18:33
9620c38

Six-cell battery module liquid-cooling network

This release adds a toolbox-free thermal-network reference for a six-cell lithium-ion battery module with serial coolant flow.

Engineering capabilities

  • resolves individual cell and coolant-segment temperatures
  • represents nonuniform cell heat generation and nearest-neighbor conduction
  • captures progressive coolant warming along the module
  • compares cooling-flow sensitivity and identifies the hottest cell
  • reports coolant-segment, cell, and module energy-balance residuals
  • supports irregular timestamps and rejects malformed inputs

Validation

  • all 14 MATLAB and Simulink repository checks pass on MATLAB R2026a
  • citation metadata validated by citation-file-format/cffconvert-github-action
  • Markdown link gate passed

See the battery module cooling example for assumptions, equations, usage, expected metrics, and limitations.

v0.4.0 - Real-time battery SOC estimation

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 23 Jul 16:56
453b69a

Highlights

  • Adds a reusable, toolbox-free two-state extended Kalman filter for real-time battery state-of-charge and RC-polarization estimation.
  • Uses the same piecewise-linear OCV table for voltage prediction and the local dOCV/dSOC measurement Jacobian.
  • Applies a Joseph-form covariance update and supports strictly increasing uniform or irregular measurement timestamps.
  • Includes a deterministic one-hour benchmark with a deliberate 20-percentage-point initial SOC bias and repeatable noisy terminal-voltage measurements.

Verified benchmark

  • Initial prior SOC error: -0.200
  • First posterior SOC error: -0.142
  • Final SOC error: +0.0001
  • SOC RMSE: 0.0066
  • Sustained two-percent settling time: 18 s
  • Posterior terminal-voltage RMSE: 1.581 mV

The full MATLAB/Simulink workflow reports All 13 MATLAB and Simulink checks passed. Citation metadata and Markdown links also pass their independent workflows.

Start here

run('examples/battery-soc-ekf/check_battery_soc_ekf.m')
run('examples/battery-soc-ekf/run_battery_soc_ekf.m')

The model remains an educational reference. Replace the illustrative OCV, electrical parameters, and covariance tuning before cell-specific use.

v0.3.0 - Validated battery, thermal, and converter lab

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 22 Jul 23:29
de3ac63

Highlights

  • Expands the battery references from one basic RC script to reusable first-order and exact two-RC simulators with nonlinear OCV, irregular time intervals, SOC-boundary current limiting, and duty-cycle accounting.
  • Adds coupled electro-thermal behavior with reversible entropic heat, temperature-dependent resistance, continuous limit-exposure metrics, and a cooling-conductance sensitivity study.
  • Adds native Simulink battery RC, battery 2RC, battery thermal, and averaged buck-converter references checked against their MATLAB counterparts.
  • Adds ideal switching and bounded closed-loop converter studies, including open-loop, PI, and filtered-PID load-step comparison.
  • Runs all twelve no-plot checks through one reliable run_all_checks entry point in MATLAB R2026a CI.
  • Adds validated CFF 1.2.0 citation metadata and a versioned changelog for research and teaching use.

Validation

  • All twelve MATLAB and Simulink checks passed locally and in GitHub Actions on MATLAB R2026a.
  • CITATION.cff passed the official cffconvert 2.0.0 GitHub Action.
  • The repository-wide Markdown link audit passed.

Scope

These models remain inspectable educational references. Their parameters are not calibrated to a particular cell or converter, and they must be revalidated before hardware, safety, or design use.

See CHANGELOG.md for the release history.

v0.2.0 - Temperature-aware battery modeling

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 19 Jul 20:04
d17a795

Highlights

  • Adds a temperature-aware battery equivalent-circuit example in base MATLAB.
  • Couples irreversible electrical losses to a single-node thermal energy balance.
  • Feeds lumped cell temperature back into ohmic resistance.
  • Includes plotting and no-plot entry points, explicit assumptions, physical bounds, and an energy-conservation assertion.
  • Documents the expected 37.32 degC peak temperature, 28.95 degC final temperature, 33.32 W peak irreversible heat, and 0.608 final SOC for the included pulse case.

Validation

  • MATLAB R2026a mlint reports no findings for both new scripts.
  • The pull request link-check workflow passed.
  • An independent execution of the same discrete equations reproduced the documented outputs and a thermal energy-balance residual below 1e-6 J.
  • Full local MATLAB batch execution was unavailable because the installed R2026a instance could not obtain a license; run check_battery_thermal_model in a licensed MATLAB session for native execution.

Scope

This remains an educational reference model. Parameters are not fitted to a specific cell, and the model excludes spatial gradients, reversible entropic heat, aging, hysteresis, thermal runaway, and pack-level interactions.

See the implementation and review history in #70.

v0.1.0 - Verified energy-modeling examples

Choose a tag to compare

@mohammadrezwankhan mohammadrezwankhan released this 13 Jul 15:58
3de253c

First public reference release of the MATLAB Simulink Energy Lab.

Included:

  • runnable first-order battery RC model with pulse-current input, SOC tracking, and terminal-voltage response
  • runnable converter average-model example and parameter check
  • no-plot validation scripts with documented expected outputs
  • engineering guidance for assumptions, units, reproducibility, validation, and review

Verified with MATLAB R2026a. These examples are educational references and are not calibrated design models.