Question: Numerical integration of numerical solution of differential equation

I solve numerically very simple boundary value problem for the following ordinary diff. equation:


y(0)=1, y(1)=0.

So := dsolve([-1.2*diff(y(x), x$2)+0.8*y(x) = 2, y(0)=1, y(1)=0], y(x), 'numeric', 'output' = listprocedure);

Solution looks as needed

u := unapply(rhs(So[2])(x), x): plot(u(t), t=0 .. 1);

and can be numerically integrated in usual way:

evalf(int(u(t), t = 0..1));


But integral of u^2(t)  (evalf(int(u(t)^2, t = 0..1))) returns:


How to avoid this issue?

Please Wait...