- #1
sgvaibhav
- 68
- 0
Hi,
I was solving questions on engineering mechanics
I came up with 6 equations and 6 unkowns
I used the solve function, but its not giving me the proper answer (it works very will with 3 unknowns and 3 equations)
This is my input
syms AX AY BX BZ CY CZ
Fx = sym('AX + BY = -125');
Fy = sym('AY + CY = 59');
Fz = sym('BZ + CZ = 388.87');
Mx = sym('-0.3*BZ - 0.4*AY = -212.2');
My = sym('0.5*CZ + 0.4*AX = 0');
Mz = sym('-0.5*CY + 0.3*BX + 0.5*AX = 0');
[AX,AY,BX,BZ,CY,CZ] = solve(Fx,Fy,Fz,Mx,My,Mz)
_____________________________________________________________
This is my output
AX =
398.07916666666666666666666666667-1.6666666666666666666666666666667*AY
AY =
1.1111111111111111111111111111111*AY-565.13194444444444444444444444444
BX =
-523.07916666666666666666666666667+1.6666666666666666666666666666667*AY
BZ =
-1.3333333333333333333333333333333*AY+707.33333333333333333333333333333
CY =
-1.*AY+59.
CZ =
-318.46333333333333333333333333333+1.3333333333333333333333333333333*AY
___________________________________
How is that happening?
I was solving questions on engineering mechanics
I came up with 6 equations and 6 unkowns
I used the solve function, but its not giving me the proper answer (it works very will with 3 unknowns and 3 equations)
This is my input
syms AX AY BX BZ CY CZ
Fx = sym('AX + BY = -125');
Fy = sym('AY + CY = 59');
Fz = sym('BZ + CZ = 388.87');
Mx = sym('-0.3*BZ - 0.4*AY = -212.2');
My = sym('0.5*CZ + 0.4*AX = 0');
Mz = sym('-0.5*CY + 0.3*BX + 0.5*AX = 0');
[AX,AY,BX,BZ,CY,CZ] = solve(Fx,Fy,Fz,Mx,My,Mz)
_____________________________________________________________
This is my output
AX =
398.07916666666666666666666666667-1.6666666666666666666666666666667*AY
AY =
1.1111111111111111111111111111111*AY-565.13194444444444444444444444444
BX =
-523.07916666666666666666666666667+1.6666666666666666666666666666667*AY
BZ =
-1.3333333333333333333333333333333*AY+707.33333333333333333333333333333
CY =
-1.*AY+59.
CZ =
-318.46333333333333333333333333333+1.3333333333333333333333333333333*AY
___________________________________
How is that happening?