MATLAB: Variable resistance in Simscape

Simscapesimulink

Hello, I am building a Simulink model where I need to add a variable resistance element whose resistance depends on some conditions. There is no variable resistor in SimPowerSystems and when I used the variable resistor in Simscape\Foundation LIbrary\Electrical\Electrical Elements it would not connect to it. Probably its because of the mismatch in SimPower and Electrical Element library I guess.
Is there way to be solve this issue or am I doing something wrong?
Thanks in advance.

Best Answer

You're right... However, you can make your own custom variable resistor in SimPowerSystems by measuring the voltage and applying a current.
Look at the power_VariableInductor shipping example, which shows how you could make a variable inductor. A resistor would be easier.
- Sebastian
Related Question