symbolic equation system solving with a lot of simple equations
Mostra commenti meno recenti
I have got a lot of very simple symbolic equations and i want to solve the equation system for the vars but for some reason i cannot succed in it. Here is an example:
syms u1 u2 I1 I2 I3 I4 C1 C2 R1 R2 a b e1 e2 e3 e4 e5 e6 e7 e8 e9 e10 e11 e12 e13 e14 e15 e16 f1 f2 f3 f4 f5 f6 f7 f8 f9 f10 f11 f12 f13 f14 f15 f16 dx1 dx2 dx3 dx4 dx5 dx6 X1 X2 X3 X4 X5 X6
eqns = [e1==u1, e1==e2+e3+e4, f1==f2, f2==f3, f3==f4, e2==R1*f2, e3==dx1, f3==X1/I1, e4==a*f5, f4==e5/a, e5==e6+e7+e8, f5==f6, f6==f7, f7==f8, e6==R2*f6, e7==dx2, f7==X2/I2, e8==b*e9, f8==f9/b, e9==e10, e10==e11, f9==f10+f11, e10==X3/C1, f10==dx3, e11==e12+e13+e14, f11==f12, f12==f13, f13==f14, e12==u2, e13==dx4, f13==X4/I3, e14==e15, e15==e16, f14==f15+f16, e15==X5/C2, f15==dx5, e16==dx6, f16==X6/I4];
var = [dx1 dx2 dx3 dx4 dx5 dx6];
sol=solve(eqns,var)
As you can see i've got a lot of variables too and i want to eliminate all of the e. and f. -s (e1,e2,...e16,f1,f2,...,f16) and get is solved for dx.-es. I can solve it by hand so it shouldn't be an issue with matlab (this is the result: "Empty sym: 0-by-1"), possibly i just missed some important step.
Do you think it is even possible to solve the symbolic equations this way or should i try some different method?
Risposta accettata
Più risposte (0)
Categorie
Scopri di più su Assumptions in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!