Solving two equations with 2 unknows

Dear All,
I have two equations:
Cp(t)=(Ka*D0/Vd*(Ka-Ke)) * (exp^(-Ka*t)+exp^(-Ke*t))
t=1/(Ke-Ka)* log(Ke/Ka)
D0=500; Cp=30; t=8; Vd=10;
I need to find Ka and Ke.
Please help me!
Thank you in advance :)

Respuestas (1)

madhan ravi
madhan ravi el 12 de Jun. de 2020
x = fsolve(@RootS, [1; 2])
function X = RootS(x)
D0 = 500;
Cp = 30;
t = 8;
Vd = 10;
Ka = x(1);
Ke = x(2);
eq1 = 1/(Ke - Ka) * log(Ke / Ka) - t;
eq2 = (Ka*D0 / Vd * (Ka - Ke) ) * ( exp(-Ka * t) + exp(-Ke * t)) - Cp;
X = [eq1; eq2];
end

Preguntada:

el 12 de Jun. de 2020

Respondida:

el 12 de Jun. de 2020

Community Treasure Hunt

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

Start Hunting!

Translated by