MATLAB 中如何使用符号数学工具箱(Symbolic Math Toolbox)来求解任意 RLC 电路的传递函数?
21 views (last 30 days)
Show older comments
MathWorks Support Team
on 7 Nov 2019
Answered: MathWorks Support Team
on 7 Nov 2019
我有一个RLC电路,基尔霍夫方程是:
I1 = V1/R2;
I2 = (V2 - V1)/(L*s + R1);
I3 = (V2 - V1)*s*C;
I1 = I2 + I3;
我该如何用符号数学工具箱来求得V1到V2的传递函数?
Accepted Answer
MathWorks Support Team
on 7 Nov 2019
参考代码如下:
>> syms R1 R2 L C V2 V1 s;
>> eqns = [V1/R2 == (V2 - V1)/(L*s + R1) + (V2 - V1)*s*C]; % s域中的方程 I1 = I2 + I3
>> V2tmp = solve(eqns, V2); % 将V2求出来给V2tmp
>> TF = simplify(V2tmp/V1) % 求传递函数,并化简
0 Comments
More Answers (0)
See Also
Categories
Find more on Symbolic Math Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!