closed form solution in a system of equation

5 Ansichten (letzte 30 Tage)
Mahsa Babaee
Mahsa Babaee am 28 Feb. 2021
Kommentiert: Walter Roberson am 28 Feb. 2021
Dear friends, Hi
I am trying to find closed form solution for a system of equations (8 equations and 8 variables). All the equations are both non-linear and parametric.
I used "solve" in coding but I faced this massage: no explicit solution.
How could I improve my codes for having the parametric solution? Is there any other function?
  1 Kommentar
Mahsa Babaee
Mahsa Babaee am 28 Feb. 2021
syms X1 X2 X3 X4 X5 X6 X7 X8 X9;
syms h k1 Lz1 k21 Lz2 k32 Lz3 a1 a2 a3 b1 b2 b3 w1 w2 w3 r1 r2 r3;
eq1 = X1-1 == 0;
eq2 = h*X1-k1*X7*X4==0;
eq3 = X1*cos(X7*Lz1)+X4*sin(X7*Lz1)-X2==0;
eq4 = -X1*X6*sin(X7*Lz1)+X4*X6*cos(X7*Lz1)-X8*X5*k21==0;
eq5 = X2*cos(X8*Lz2)+X5*sin(X8*Lz2)-X3==0;
eq6 = -X2*X8*sin(X8*Lz2)+X5*X8*cos(X8*Lz2)-X9*X6*k32==0;
eq7 = X3*cos(X9*Lz3)+X6*sin(X9*Lz3)==0;
eq8 = (a1/a2)*(b1^2+r1^2+X7^2+w1^2)-b2^2-r2^2-w2^2-X8^2 ==0;
eq9 = (a1/a3)*(b1^2+r1^2+X7^2+w1^2)-b3^2-r3^2-w3^2-X9^2 ==0;
sol = solve([eq1,eq2,eq3,eq4,eq5,eq6,eq7,eq8,eq9],[X1 X2 X3 X4 X5 X6 X7 X8 X9]);

Melden Sie sich an, um zu kommentieren.

Akzeptierte Antwort

Walter Roberson
Walter Roberson am 28 Feb. 2021
There are four families of solutions.
[X1 == 1,
X2 == (cos(Lz1*h*sin(RootOf(Lz1^2*cos(Z)^2*h^2+cos(Z)^2*Z^2*k1^2-Lz1^2*h^2))/cos(RootOf(Lz1^2*cos(Z)^2*h^2+cos(Z)^2*Z^2*k1^2-Lz1^2*h^2))/k1)*sin(RootOf(Lz1^2*cos(Z)^2*h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
X6 == 0,
X7 == h*sin(RootOf(cos(Z)^2*(Lz1^2*cos(Z
)^2*h^2+cos(Z)^2*Z^2*k1^2-Lz1^2*h^2)))/cos(RootOf(cos(Z)^2*(Lz1^2*cos(Z)^2*
h^2+cos(Z)^2*Z^2*k1^2-Lz1^2*h^2)))/k1,
X8 == RootOf(-a1*b1^2*k1^2-tan(RootOf(
Lz1*tan(Z)*h-Z*k1))^2*a1*h^2-a1*k1^2*r1^2-a1*k1^2*w1^2+a2*b2^2*k1^2+a2*k1^2*
r2^2+a2*k1^2*w2^2+Z^2*a2)/k1,
X9 == RootOf(-a1*b1^2*k1^2-tan(RootOf(Lz1*tan(Z)
*h-Z*k1))^2*a1*h^2-a1*k1^2*r1^2-a1*k1^2*w1^2+a3*b3^2*k1^2+a3*k1^2*r3^2+a3*k1^2
*w3^2+Z^2*a3)/k1]
In the above, RootOf(expression,Z) stands for the set of values of Z such that the expression becomes zero -- the roots of the equations.

Weitere Antworten (0)

Kategorien

Mehr zu Symbolic Math Toolbox finden Sie in Help Center und File Exchange

Produkte


Version

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by