Videos > Battery Equivalent Circuit Model Simulation in Twin Builder
Apr 18, 2025

Battery Equivalent Circuit Model Simulation in Twin Builder

Introduction

Hello and welcome to this video on Ansys Twin Builder for battery cell equivalent circuit modeling using the Battery Wizard.

Launching Twin Builder and Accessing the Battery Wizard

I've launched Twin Builder and accessed the Battery Wizard by navigating to the menu: Twin Builder > Qkit Battery Wizard.

Setting Up the Working Directory

I set the working directory to the location where my HPPC data is stored. Then, I clicked on the Cell Configuration Tool. Since there was no folder, I created a new one.

Configuring ECM Parameters

  • Used 6 parameters for the ECM parameters.
  • Independent variables: SOC and temperature.
  • HPPC data has 13 levels of SOC values and 2 levels of temperature.
  • Updated cell capacity to 56, leaving other options as default.

Generating and Visualizing Data

Switched to HPPC data, browsed for the folder (same as the working directory), and clicked on generate. Once completed, I accepted the results.

Visualized the curves to see the data and curve fit for 26 different curves.

Adding Components to the Circuit

Closed the Cell Configuration Tool and the Battery Wizard. Now, a battery cell component is available in the components library.

Dragged the battery cell component into the schematic, zoomed in, and rotated it. Then, I started adding components for the circuit:

  1. Added a constant for the temperature and set it to 293.15 Kelvin.
  2. Added an amp meter and rotated it.
  3. Added a volt meter.
  4. Added a current source and rotated it twice.
  5. Added a ground component below.

Connecting Components

  • Connected the temperature constant to the temperature input.
  • Connected the battery positive cell to the amp meter.
  • Connected the voltmeter to the same line.
  • Connected the source to the amp meter and ground.
  • Connected the voltmeter to the negative terminal of the battery.

Configuring the Current Source

Updated the source to be time-controlled with a trapezoidal shape:

  • Amplitude: 10 amps
  • Delay: 20 seconds
  • Rise time: 0.005 seconds
  • Fall time: 0.01 seconds
  • Width: 10 seconds

Defining Results

Right-clicked on results and created a standard report with a rectangular plot. Selected the following quantities:

  • Amp measurement: AM1.i
  • Voltage: VM1.V
  • Battery cell power loss

These reports were created and appeared in the project manager, where they can be renamed as desired.

Running the Analysis

Navigated to Analyze, right-clicked on TR, and clicked on Edit. Changed the following settings:

  • End time: 200 seconds
  • Minimum time step size: 0.01 seconds
  • Maximum time step size: 5 seconds

Returned to analysis, right-clicked on analyze, and waited a few seconds for the run to complete.

Viewing and Exporting Results

Observed the battery cell power loss over time. Opened reports to view current, delay, width, and amplitude. Checked the voltage as well.

Finally, exported the data by right-clicking and selecting export to create a CSV file for use in a spreadsheet.

Conclusion

Thank you for viewing and goodbye.

[This was auto-generated. There may be mispellings.]

Hello and welcome to this video on Ansys Twin Builder for battery cell equivalent circuit modeling using the Battery Wizard. So I've launched Twin Builder. I'll access the Battery Wizard by going to the menu Twin Builder, down to Qkit Battery Wizard.

I've set the working directory to be the directory where I have my HPPC data. Click on Cell Configuration Tool. Since there's no folder there, I'll create a new one. I'll use the 6 parameters for the ECM parameters. Independent variables will be SOC and temperature.

So the HPPC data has 13 levels of SOC values and 2 levels of temperature. I'll update the cell capacity to 56, leave the rest of the options to default.

For cell parameters, I'll switch to HPPC data and then browse for the folder, which should be the same for me as the working directory, and then click on generate. Once that completes, I accept. And one could visualize the curves, so we can see the data as well as the curve fit.

And that would be for, in this case, 26 different curves. So I'll close that, close the Cell Configuration Tool and the Battery Wizard. So now we have a battery cell component within the components library. We'll drag that into the schematic, zoom in a little bit, and then I can rotate.

I'll start adding some components for a circuit. The first one will be a constant for the temperature. We'll change that temperature to 293.15 Kelvin. Okay, then we'll add an amp meter, rotate that as well. Add a volt meter, put that here.

And then a current source, that over here, rotate that one twice. And the last component to add would be a ground. I'll put that below. And now we can start connecting. So connect the temperature constant to the temperature input. Connect the battery positive cell to the amp meter.

Connect the voltmeter to that line. Connect the source to the amp meter. Connect the source to the ground. The source to the amp meter over here, and then the voltmeter to the negative terminal of the battery. We'll update the source to time-controlled with a shape that's trapezoidal.

We use an amplitude of 10 amps, delay of 20 seconds. Keep the rise as 0.005, keep the fall as 0. 01. We'll update the width to 10 seconds. And now we'll go and define our results. So right-click on results and create standard report rectangular plot.

Here in the quantities for the first one, I'll pick the amp measurement AM1.i, do report down here. Then the same thing for the voltage, so VM1.V, new report, and then the battery cell 1 PowerLoss, new report. So we created those three reports. They show up here in the project manager.

One could rename as desired. Then we go up to Analyze, right-click on TR, click on Edit. We'll change the end time to 200 seconds. The minimum time step size 0.01 seconds and the maximum time step size of 5 seconds.

Okay, then back to analysis, right-click analyze and wait a couple of seconds for the run to complete. So now we can see our battery cell power loss over time.

We can go back and do an opening report to see the current, the delay of 20 seconds, the width of 10 seconds, and then the amplitude of 10. and we can check open the voltage as well. And then back here to the battery cell, one thing I like to do is to do an export.

So right-click, export, and then one can export out a CSV file to open in a spreadsheet. That's it. Thank you for viewing and goodbye.