Good evening everyone,
I must solve this system of two non linear equations:
0.00014/(3.85E-05*cos((x-y)*0.006))-(0.196*0.026*tan((x-y)*0.0062)*tanh(x*0.026))/0.006+0.196-0.00014/3.85E-05=2.0051
2.005+(y-300)*((y-300)*6.31E-05/2-((0.196*3.85E-05-0.00014)*sin((x-y)*0.0062))/0.0062+0.196*0.026*cos((x-y)*0.0062)*tanh(x*0.026))=2.9905
What is the best approach to obtain a solution? I know that x and y should be in the range of (0,300), and x is lower than y.
Thanks in advance

1 commentaire

if x and y are limited in the range of [0,300], the result will be:
x: 106.852495887777
y: 221.905657509353

Connectez-vous pour commenter.

 Réponse acceptée

syms x y real
eq1 = 0.00014/(3.85E-05*cos((x-y)*0.006))-(0.196*0.026*tan((x-y)*0.0062)*tanh(x*0.026))/0.006+0.196-0.00014/3.85E-05 == 2.0051;
eq2 = 2.005+(y-300)*((y-300)*6.31E-05/2-((0.196*3.85E-05-0.00014)*sin((x-y)*0.0062))/0.0062+0.196*0.026*cos((x-y)*0.0062)*tanh(x*0.026)) == 2.9905;
sol = vpasolve([eq1,eq2],[x y],[0 300;0 300])
sol = struct with fields:
x: 106.85249588777741184146319523654 y: 221.90565750935273789837170961006
% verify
vpa(subs(lhs([eq1;eq2]),sol)-rhs([eq1;eq2]))
ans = 

Plus de réponses (0)

Catégories

En savoir plus sur Symbolic Math Toolbox dans Centre d'aide et File Exchange

Produits

Version

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by