Hi,
I am trying to ∫ D(V)*F(V)dV eq1
min=_(0.8e-26) and max=(1.35e-26)
D(t,V)=2*Ps*(1-exp(-(t)./(Vo*exp((Ps*10000000-Wb)*V/(Kb*300))))) and F(V)= Lognormal PDF=(1./(V.*sigma.*sqrt(2.*pi)).*exp(-log(V)-mu).^2/(2.*sigma^2)).*V
Find below, the code I wrote to compute the integral of eq1:
Dp=@(V)(1./(V.*sigma.*sqrt(2.*pi)).*exp(-log(V)-mu).^2/(2.*sigma^2)).*V.*2*Ps*(1-exp(-(t)./(Vo*exp((Ps*10000000-Wb)*V/(Kb*300)))))Dp = function_handle with value: @(V)(1./(V.*sigma.*sqrt(2.*pi)).*exp(-log(V)-mu).^2/(2.*sigma^2)).*V.*2*Ps*(1-exp(-(t)./(Vo*exp((Ps*10000000-Wb)*V/(Kb*300))))) >> integral(Dp,0.8e-26,1.35e-26)
Error message I got were:
Matrix dimensions must agree.Error in@(V)(1./(V.*sigma.*sqrt(2.*pi)).*exp(-log(V)-mu).^2/(2.*sigma^2)).*V.*2*Ps*(1-exp(-(t)./(Vo*exp((Ps*10000000-Wb)*V/(Kb*300)))))Error in integralCalc/iterateScalarValued (line 314) fx = FUN(t);Error in integralCalc/vadapt (line 132) [q,errbnd] = iterateScalarValued(u,tinterval,pathlen);Error in integralCalc (line 75) [q,errbnd] = vadapt(@AtoBInvTransform,interval);Error in integral (line 88)Q = integralCalc(fun,a,b,opstruct);
Please can anyone kindly assist me or advice me?
Thank you
Best Answer