Solving symbolic Matlab equation in term of two variables (x/Va)
11 次查看(过去 30 天)
显示 更早的评论
Guys/Girls any input will be great. I'm so stuck been spinning my wheels for hours. so.. here is what I got

All i want to do is solve this equation symbolically, for x/va. (the transfer function) so I want matlab to spit out the answer x/Va = blah blah blah. but I'll I get is weird matrices or errors. Honestly any help is appreciated. Thanks again.
0 个评论
采纳的回答
Walter Roberson
2017-10-8
编辑:Walter Roberson
2017-10-8
syms s J B x K kt Va ke Ra La
La = 0;
eqn = (J*(s^2)*x)+ (B*s*x)+ (K*x)== kt*((Va)-(ke*s*x)/(Ra+(La*s)));
syms F
eqn1 = subs(eqn, x, F*Va);
x/Va == simplify( solve(eqn1, F) )
6 个评论
Walter Roberson
2017-10-8
You want F = x/Va . Multiply through by Va, to get F*Va = x. Substitute that F*Va for x in the formula, which gets rid of all of the x in the formula and puts in the new variable F instead, where we know that F = x/Va because that is how we built F. Solve for the variable F, to get something that is implicitly of the form F = SomeSolution. Now expand back F on the left side because that is what you expect to see, so now you have x/Va = SomeSolution
MATLAB cannot solve() for expressions, only for variables, so this is a very common mathematical trick, to take an existing variable that is involved with the formula you want to solve with respect to, and substitute for that variable an expression in a new variable that is the inverse. It is a "change of variables"
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Assumptions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!