How do you simply test and verify a battery's charge and discharge capability when connected to a network in Simulink?
7 views (last 30 days)
Show older comments
I would like to simply test and verify the charge and discharge capability of a battery when connected with an average-value VSC and a three-phase network. Whenever I did it, I always experience no behavior changes from the battery/network or I encounter convergence errors. The image below shows what connections I've done so far with a battery pack, an average-value VSC and IEEE-9 bus network. However, I am unsure what to connect to the modwave input of the VSC. A simpler network could help me better understand how each component interacts with one another.

I have seen the peak shaving example (https://www.mathworks.com/help/simscape-battery/ug/peak-shaving-bess.html), but I find it too complex to replicate, since it already integrates control systems.
Any form of help is appreciated. If you are an expert in this field, I would like to keep in contact with you. Thank you!
0 Comments
Answers (1)
Tridib
on 5 Nov 2025
You may start with a basic setup: Connect the battery to the VSC, and then connect that to a three-phase load or network. This makes it easier to see how the battery and VSC work together before adding them to a bigger system like the IEEE-9 bus.
The VSC’s “modwave” input needs a modulation signal. For simple tests, you can just use a constant value or a step change. For more realistic results, use a control system to create this signal based on what is happening in the grid or battery.
To test battery discharging, set up the VSC to send power from the battery to the load or network. Watch the battery current and state of charge. To test charging, reverse the power flow. Use scopes or the Data Inspector to monitor battery’s voltage, current, and SoC.
Also, make sure all your components have the right settings and pick suitable solver options. If you run into numerical issues, add small snubber resistors or capacitors for stability.
Hope this helps!
0 Comments
See Also
Categories
Find more on Simscape Battery 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!