problem with ilaplace when i useit with exponential function

syms kp ki kd L s t lambda;
p=(12*s+8)/(20*s^4+113*s^3+147*s^2+62*s+8)*exp(-5*s);
td=(1/(lambda*s+1))*((1-L*s/2)/(1+L*s/2));
r=1/s*exp(-10*s);
c0=0.1+0.1/s+0.1*s/(gamma*s+1);
c=kp+ki/s+kd*s/(gamma*s+1);
u0=c0/(1+c0*p)*r;
y0=c0*p/(1+c0*p)*r;
ref=1/c*u0+y0;
e=y0-td*ref
et=vpa(ilaplace(e,s,t))
Error using gamma
Not enough input arguments.
>> syms kp ki kd L s t lambda gamma;
>>
>>
p=(12*s+8)/(20*s^4+113*s^3+147*s^2+62*s+8)*exp(-5*s);
td=(1/(lambda*s+1))*((1-L*s/2)/(1+L*s/2));
r=1/s*exp(-10*s);
c0=0.1+0.1/s+0.1*s/(gamma*s+1);
c=kp+ki/s+kd*s/(gamma*s+1);
u0=c0/(1+c0*p)*r;
y0=c0*p/(1+c0*p)*r;
ref=1/c*u0+y0;
e=y0-td*ref;
et=vpa(ilaplace(e,s,t))
and the answer is
e =
(((exp(-10*s)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(s*((exp(-5*s)*(12*s + 8)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(20*s^4 + 113*s^3 + 147*s^2 + 62*s + 8) + 1)*(kp + ki/s + (kd*s)/((9*s)/5 + 1))) + (exp(-15*s)*(12*s + 8)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(s*((exp(-5*s)*(12*s + 8)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(20*s^4 + 113*s^3 + 147*s^2 + 62*s + 8) + 1)*(20*s^4 + 113*s^3 + 147*s^2 + 62*s + 8)))*((L*s)/2 - 1))/(((L*s)/2 + 1)*(lambda*s + 1)) + (exp(-15*s)*(12*s + 8)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(s*((exp(-5*s)*(12*s + 8)*(s/(10*((9*s)/5 + 1)) + 1/(10*s) + 1/10))/(20*s^4 + 113*s^3 + 147*s^2 + 62*s + 8) + 1)*(20*s^4 + 113*s^3 + 147*s^2 + 62*s + 8))
et =
1.2*heaviside(1.0*t - 15.0)*ilaplace(s/((gamma*s + 1)*((exp(-5*s)*(12*s + 8)*(s/(10*(gamma*s + 1)) + 1/(10*s).........
et has s and t sym.
I want to find the equation of et (e in time domain) that has only t syms. how I should do ?
thank you

Respuestas (1)

Walter Roberson
Walter Roberson el 11 de Nov. de 2016
With difficulty.
Notice that where s occurs in et, it is inside ilaplace() . The reason for that is that ilaplace decided it did not know how to take the inverse laplace of a portion of your expression, and instead of returning an error message, returned an ilaplace() call
It is not always possible to find the inverse laplace of function.

Etiquetas

Preguntada:

el 11 de Nov. de 2016

Respondida:

el 11 de Nov. de 2016

Community Treasure Hunt

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

Start Hunting!

Translated by