implementing arbitrary transfer function in Simscape Electrical

Yahav Morag on 1 Jun 2019
Latest activity Reply by Joel Van Sickel on 4 Jun 2019

Hi, In my circuit, I have an element for which I don't have its equivalent circuit. What I have is a lookup table of its frequency response (magnitude and phase), which is complicated and cannot be represented by a lumped parameters equivalent circuit, and also some of its elements are frequency-dependent. Even if I do obtain somehow its transfer function Laplace representation (using e.g. "System identification" toolbox, and I want to add it to my circuit simulation (Simscape Electrical) as a block.

Does anyone have an idea how to do it? Thank you!

Joel Van Sickel
Joel Van Sickel on 3 Jun 2019

Hello Yahav,

this response won't give you a step by step process, but at a high level, there are 2 options you could consider.

1. - use sys ID to get transfer functions, and implement the transfer functions manually in simscape. (see this post on how to do this: https://www.mathworks.com/matlabcentral/answers/224015-how-to-put-a-transfer-function-into-a-simscape-model ) You can link it to the circuit with controlled sources and measurement blocks.

2. - utilize the RF toolbox and RF blockset as they use frequency domain simulations.

Yahav Morag
Yahav Morag on 4 Jun 2019

Thank you very much Joel for your help,

For the first option: converting to Simulink signal, connect to transfer function and then connecting to a controlled voltage source, I think it is a good idea and I will try it. However, I think that the drawback is that the controlled source is ideal, and the source circuit no longer coupled to the second circuit. What do you think?

For the 2nd option: I will look into the toolbox (I am not familiar with it), to learn how to connect it to the Simscape signal.

Thanks!

Joel Van Sickel
Joel Van Sickel on 4 Jun 2019

For the 1st option, I would use the simscape blocks to manually build a transfer function, and use controlled sources on both sides. This would have them be coupled. You can output a voltage from the transfer function, and read the current, and attatch a controlled current source on the other side and feed this current into that.