restart;
assume(alph>0);
assume(alph,real);
f_exp:=exp(-alph*r^2);
ff_deriv:=simplify(r^2*f_exp^2);
ff:=simplify(int(ff_deriv,r=0..infinity));
It seems to understand what I'm trying to integrate but when I try and find ff it comes up with an awful expression full of erf functions and with a lim r--> infinity
at the front. However on wolfram alpha I get the answer that I want:sqrt(pi/2)/(8*alpha^(3/2))
.
Can anyone help me with this?
Thank you so much!
The second assume call wipes out the first assumption. As the property > 0 implies real, just drop the second assumption.
assume(alph>0);
f_exp:=exp(-alph*r^2);
ff_deriv:=simplify(r^2*f_exp^2);
ff:=simplify(int(ff_deriv,r=0..infinity));
Will give you the answer you want: (1/16)*sqrt(2)*sqrt(Pi)/alph^(3/2)
You could also use additionally(alph,) if you had needed another property.