Clear Filters
Clear Filters

Assertion error in battery pack cooling system implementation

8 views (last 30 days)
I'm encountering an assertion error in my Simscape model related to the state of charge exceeding the maximum value of 1. The error occurs at time 1.200000 during simulation. I have a Pack1 subsystem with a ModuleAssembly1 block, and within it, there's a Module1 block where the assertion is triggered.
I've reviewed the code and calculations in the relevant Simscape source files (ParallelAssemblyType1.ssc and ModuleType1.ssc) around the mentioned line numbers (80-92 and 73-82, respectively). However, I haven't been able to identify the specific cause of the state of charge exceeding 1.
Could someone please provide guidance on how to troubleshoot and resolve this issue? I want to ensure that the state of charge remains within the valid range of 0 to 1 throughout the simulation.
Any suggestions or insights would be greatly appreciated. Thank you!
error message : At time 1.200000, one or more assertions are triggered. State of charge must be less than or equal to 1. The assertion comes from: Block path: PB_cell_balancing/Pack1/ModuleAssembly1/Module1 Assert location: o (location information is protected) o In between line: 80, column: 26 and line: 92, column: 52 in file: C:\Users\EL Fahem\MATLAB\Projects\+packBalancingExample\+ParallelAssemblies\ParallelAssemblyType1.ssc o In between line: 73, column: 39 and line: 82, column: 61 in file: C:\Users\EL Fahem\MATLAB\Projects\+packBalancingExample\+Modules\ModuleType1.ssc

Accepted Answer

Javier Gazzarri
Javier Gazzarri on 16 Jul 2023
Hello Ali,
Can you please check if you are using the same current sign convention we do in the block? In many cases I see this error when starting the simulation at full charge and loading the pack with a charging (positive) current. If so, please use a gain to switch the sign of your current so that positive is for charge and negative is for discharge.
Please let me know how this goes.
Javier

More Answers (0)

Categories

Find more on Foundation and Custom Domains in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!