# how to solve the nonlinear equatios?

1 view (last 30 days)
M.Rameswari Sudha on 2 Jan 2020
syms T v
p=30;a=7;d=1;lamda=0.8;c=10;r=35;h=0.05;w=200;k=0.02;b=7;
M=k*a;
%eqn1=(1/T)*(p*d-((lamda*p*d*v)/T)-(d*exp(-(w-k)*v)-(d*v/T))*c-d*((v/T)-1)*r-(d/(w-k))*(1-exp(-(w-k)*v)*h)))==0'
%eqn2=((1/T)*(-(d*c*v*exp(-(w-k)*v)*M/(w-k))+(((d*c*(1-exp(-(w-k)*v))+h*d*v*(1+exp(-(w-k)*v)))*M)/(w-k)^2)+((2*h*d*(exp(-(w-k)*v)-1)*M)/(w-k)^3)-1))== 0
eqns = solve('((1/T)*(p*d-((lamda*p*d*v)/T)-(d*exp(-(w-k)*v)-(d*v/T))*c-d*((v/T)-1)*r-(d/(w-k))*(1-exp(-(w-k)*v)*h)))==0','((1/T)*(-(d*c*v*exp(-(w-k)*v)*M/(w-k))+(((d*c*(1-exp(-(w-k)*v))+h*d*v*(1+exp(-(w-k)*v)))*M)/(w-k)^2)+((2*h*d*(exp(-(w-k)*v)-1)*M)/(w-k)^3)-1))== 0');
solve(eqns,T,v)
M.Rameswari Sudha on 2 Jan 2020
Edited: M.Rameswari Sudha on 2 Jan 2020
I have two equations equation1 & equation2. I couldn't find the value of T and v.
p=30;d=1;lamda=0.8;c=10;r=35;h=0.05;chi=200;k=0.02;b=7;a =0.01;
W= k*(1-exp(-a*chi));
M=k*a;
equation1=(1/T)*[(p*d-((lamda*p*d*v)/T)-(d*exp(-(w-k)*v)-(d*v/T))*c-d*((v/T)-1)*r-(d/(w-k))*(1-exp(-(w-k)*v)*h))]=0
equation2=(1/T)*[-(d*c*v*exp(-(w-k)*v)*M/(w-k))+(((d*c*(1-exp(-(w-k)*v))+h*d*v*(1+exp(-(w-k)*v)))*M)/(w-k)^2)+((2*h*d*(exp(-(w-k)*v)-1)*M)/(w-k)^3)-1]= 0
solve equation1 and equation2 and find the value of T and v from equation1 and equation2

KSSV on 2 Jan 2020
Try this.
syms v T
p=30;d=1;lamda=0.8;c=10;r=35;h=0.05;chi=200;k=0.02;b=7;a =0.01;
w = k*(1-exp(-a*chi));
M=k*a;
equation1=(1/T)*[(p*d-((lamda*p*d*v)/T)-(d*exp(-(w-k)*v)-(d*v/T))*c-d*((v/T)-1)*r-(d/(w-k))*(1-exp(-(w-k)*v)*h))]==0 ;
equation2=(1/T)*[-(d*c*v*exp(-(w-k)*v)*M/(w-k))+(((d*c*(1-exp(-(w-k)*v))+h*d*v*(1+exp(-(w-k)*v)))*M)/(w-k)^2)+((2*h*d*(exp(-(w-k)*v)-1)*M)/(w-k)^3)-1]== 0 ;
eqns = [equation1, equation2] ;
S = solve(eqns,[ T v]) ;
M.Rameswari Sudha on 2 Jan 2020
Again I get the same problem. I got the output as S =
[ empty sym ]

### Categories

Find more on Solver Outputs and Iterative Display in Help Center and File Exchange

### Community Treasure Hunt

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

Start Hunting!

Translated by