Undefined variable error while performing numerical integration in MATLAB -


for matlab question, need integrate fun2 = @(x) 1/(sigma2*(2*pi)^(.5))*exp(-.5*((x-xbar2)/sigma2)^2), sigma2=50, xbar2=1500.

the area under curve should 0.05, set solve(integrate(fun2,-inf,u)==.05,u) error "undefined function or variable 'u'."

what can make work?

so here go:

syms x u fun = int(1./(50.*(2.*pi).^(.5)).*exp(-.5.*((x-1500)./50).^2),-inf,u) - .05; double(solve(fun,u)) 

Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -