2018-12-05 10:47:39 -0500 received badge ● Student (source) 2018-10-11 11:53:41 -0500 received badge ● Famous Question (source) 2018-10-11 11:53:41 -0500 received badge ● Notable Question (source) 2013-06-05 11:59:19 -0500 received badge ● Popular Question (source) 2012-08-16 23:01:14 -0500 commented answer assume() command with functions I do not really understand the implications of this, even reading the reference. Is there any way to accomplish what I am trying to do? p0 und p2 are just real positive constants the value of which I do not know. 2012-08-16 22:59:07 -0500 commented answer assume() command with functions I do not really understand the consequences implied (I read the reference). Is there a way to do what I wanted to do? p0 and p2 are meant to be just real positive constants smaller one, for which I do not know the value. 2012-08-16 04:46:09 -0500 answered a question assume() command with functions I guess my problem is related to this one: var('Nr N1 N2 yr x1 x2 y2 Pr p0 P1 p2') assume(N1>0, N2>0, Nr>0, Pr>0, p0>0, p2>0, p0+p2-1<0); assume(P1-Nr*p2+p2-Nr*p0+p0+Nr-1>0) h1 = 1/sqrt(2*pi*Nr)*exp(-(yr-(x1+x2))^2/(2*Nr))/sqrt(2*pi*N2)*exp(-(y2-sqrt(Pr/((1-p0)(Nr+P1/(1-p0-p2))))*yr)^2/(2*N2))*(y2-sqrt(Pr/((1-p0)(Nr+P1/(1-p0-p2))))*yr)/Nr*sqrt(Pr/((1-p0)*(Nr+P1/(1-p0-p2))))*yr*(1/(2*(1-p0))-P1/(2*(1-p0-p2)^2*(P1/(1-p0-p2)+Nr)))+1/sqrt(2*pi*N2)*exp(-(y2-sqrt(Pr/((1-p0)(Nr+P1/(1-p0-p2))))*yr)^2/(2*N2))/sqrt(2*pi*Nr)*exp(-(yr-(x1+x2))^2/(2*Nr))*(yr-(x1+x2))/Nr*x1^3/(2*P1); h1 h2 = 1/2*h1(x2=0,x1=sqrt(P1/(1-p0-p2)))+1/2*h1(x2=0,x1=-sqrt(P1/(1-p0-p2))); h2 py2x1x2 = integrate(h2,yr,-oo,oo); py2x1x2 Traceback (click to the left of this block for traceback) ... Is p2+p0-1 positive or negative?  The important parts are assume(p0+p2-1<0);  and Is p2+p0-1 positive or negative?  obviously. Did I get you right, this is not supposed to work? Thank you 2012-08-12 12:07:36 -0500 answered a question definite integral and indefinite integral different (~Gaussian) Oh: you are correct, I also get 40.686. The 9.7 is when I have a different step f3 between f2 and f4. I had written this straight after your post, but forgotten to press "send", sorry I had you wonder about this... 2012-08-12 10:39:43 -0500 received badge ● Supporter (source) 2012-08-12 10:39:25 -0500 answered a question definite integral and indefinite integral different (~Gaussian) Thank you for the answers, both of you! 2012-08-12 04:05:30 -0500 received badge ● Editor (source) 2012-08-12 04:03:51 -0500 asked a question definite integral and indefinite integral different (~Gaussian) Hello, I get strange behaviour on the following function. It persists when changing constants, but is not present for very simple functions, so any hint for a limit would be appreciated. f1 = exp(-1/2*(y-a)^2/N)+exp(-1/2*(y+a)^2/N); f1 f2 = f1*y^2; f2 f4 = f2(a=3,N=0.7); f4 >(e^(-0.714285714285714*(y - 3)^2) + e^(-0.714285714285714*(y + 3)^2))*y^2 Z = integral(f4,y,-100,100); Z.n(digits=5) >9.7000 F = integrate(f4,y); H = F(y=100) - F(y=-100); H.n(digits=5) >-2.4622e-2917  As you see, I get right results when using the definite integral, while calculation the indefinite integral and manually evaluating it gains wrong results. By the way, when integrating from -inf to inf, I should get N+a^2. Is there any way to see this?