Simscape Electrical is not compiling my SPICE netlist.

Hello everyone. I am new to Simscape Electrical and SPICE. I understand that you can interface SPICE netlists with Simscape Electrical. However, when I use the relevant command, subcircuit2ssc, I return the below set of errors. I came across this post from someone else who ran into the same error, but I don't think their solution applies to my situation because the only parameter I call in is "TJ" and that is defined in my first subcircuit. I have attached my netlist as a .txt file. Thank you in advance for your help!
Index exceeds the number of array elements (5).
Error in spiceVCVS
Error in spiceSubckt/getElements
Error in spiceSubckt/loadSubckt
Error in spiceSubckt
Error in subcircuit2ssc
Error in subcircuit2ssc (line 29)
[subcircuitArray, unsupportedInfo] = subcircuit2ssc(netlist,target);

回答 (1 件)

Sabin
Sabin 2022 年 12 月 22 日

0 投票

I was able to modify slightly the netlist you attached such that the conversion will work. The issue was the missing label for subcircuits A and B in the main subcircuit. I have attached the updated file. I hope this helps.

カテゴリ

製品

リリース

R2020b

質問済み:

2022 年 6 月 23 日

回答済み:

2022 年 12 月 22 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by