I would like to solve a 2x2 system of equations. Can anyone help me please?

1 view (last 30 days)
Hello, i have 2 equations with two unknowns. How matlab can solve the system?
The equations are:
1) (t-0.1)sqrt(1-(121-(t-0.1)^2*400*cos(theta0))=(8.66*t-10)/(20cos(theta0))
2) cos(theta0)=sqrt(1-(8.66*t-4.9*t^2+4.9*(t-0.1)^2)/((t-0.1)^2*400))
The unknowns are theta0 and t.
I am looking forward for your information.
Thank you in advance for any help you can provide.

Accepted Answer

Torsten
Torsten on 17 May 2017
Did you try MATLAB's "solve":
https://de.mathworks.com/help/symbolic/solve.html
?
Best wishes
Torsten.
  1 Comment
Amy Tsigouris
Amy Tsigouris on 17 May 2017
Thank you for your reply.
I tried "solve" in this form:
syms theta0 u0
eqns=[ (t-0.1)sqrt(1-(121-(t-0.1)^2*400*cos(theta0))= =(8.66*t-10)/(20cos(theta0)) , cos(theta0)= = sqrt(1-(8.66*t-4.9*t^2*(t-0.1)^2*400)))];
vars=[theta0 u0];
[soltheta0,solu0]solve(eqns,vars);
From MathWorks:
syms u v eqns = [2*u^2 + v^2 == 0, u - v == 1];
vars = [v u];
[solv, solu] = solve(eqns, vars)
But it gives me error. What I am doing wrong?
Thank you for your time.

Sign in to comment.

More Answers (1)

Torsten
Torsten on 17 May 2017
syms theta t
eqns=[ (t-0.1)*sqrt(1-(121-(t-0.1)^2*400*theta)==(8.66*t-10)/(20*theta) , theta == sqrt(1-(8.66*t-4.9*t^2*(t-0.1)^2*400)))];
vars=[theta t];
[soltheta,solt]=solve(eqns,vars);
Then theta0=acos(soltheta) and t=solt are solutions of your system.
Best wishes
Torsten.
  3 Comments

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!