Solving non linear equation for a constant
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Rakesh Jain
le 10 Fév 2017
Réponse apportée : Torsten
le 10 Fév 2017
I have got(after writing some code) 1) y = A1/2 - (A1*exp(-(2*t)/3))/2 and yred = exp(-2*t)/2 - exp(-t) + 1/2. I need to equate the constants and find A1. It is possible that there might be some other y and yred if some other inputs are given by users.As an example here A1/2 = 1/2, therefore A1= 1. So in in any case I need to equate the 2 constants in these two equations. How should I do it. Note that even approximate answers(like A1 = 0.99 instead of 1) are fine with me. I can think of two approaches, one either separate the constants somehow and equate them or take large t for eg 10000 and then equate both equations, that will also give almost exact A1. How should I translate any of the approach into matlab. Or in other words, how should I solve the above problem
0 commentaires
Réponse acceptée
Torsten
le 10 Fév 2017
syms A t
y = A/2-(A*exp(-(2*t)/3))/2;
z = exp(-2*t)/2-exp(-t)+1/2;
eqn = limit(y,t,inf)==limit(z,t,inf);
solA = solve(eqn,A);
Best wishes
Torsten.
0 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Calculus dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!