Hello together,
right now I am building a model of a battery in PSpice. I use a two RC-branch equivalent model as can be seen on https://de.mathworks.com/examples/simscape/mw/simscape_product-ssc_lithi.... In this model, the values of the Rs and Cs change depending on the State of Charge and temperature.
I use the SLPS interface in combination with LUTs in Simulink to update the values of my Rs and Cs in PSpice (there I use ZX and YX components for the variable).
Using the same data (for the LUTs and current/voltage signals) as in the Matlab example, I did get different results for the Simulink model and my PSpice model. After analyzing the problem, I realized, that Simulink uses the formula I = C *dv/dt for the current in the capacitor. If I change it to the formula I = C * dv/dt + v * dC/dt, I get the same results as in PSpice. So I assume that PSpice uses the second formula.
As the Matlab example represents a real battery, I tried to fit the values of the LUTs (through parameter optimization), so that the PSpice model (or Simulink model with formula I = C * dv/dt + v * dC/dt) gives the same results as the Matlab example, but I could not achieve a satisfying behaviour...
So now my question is, can I change the formula in PSpice? So that it is using I = C *dv/dt instead of I = C * dv/dt + v * dC/dt? Then I would have the same results in Matlab and PSpice.
If so, how is it possible?
Thank you very much for your help.
P-Diz
Copyright © 2020 Cadence Design Systems, Inc. All rights reserved.
Yes. You can model controlled or nonlinear impedances in PSpice using behavioral models. You can refer an application note under Learning PSpice - PSpice Application notes section. You can access Learning PSpice from Help menu in Capture. Click on the schematic image in application note to open design in capture. I think nonlinear capacitor model topic under Modelling voltage controlled capacitor application note should be helpful.