You did nothing wrong; your workaround of using a symbolic constant is OK. Alternatively, you might try replacing
3.1415.. with %pi (assuming this is what you intend). Generally, when doing calculus-like things, it's best to
avoid introducing floating point numbers--or at least delaying this until the end of the calculation. Using %pi and
%e instead of decimal approximations (3.141..., 2.718...) is the way to go. Another possibility is to use the function
rationalize to change all floats to rational numbers; simple example:
(%i3) integrate(x * sin(3.14157 * x),x);
Evaluation took 185.7500 seconds (185.7500 elapsed)
(%o3) (10000000000*sin((314157*x)/100000)-31415700000*x*cos((314157*x)/100000))/98694620649
(%i4) integrate(rationalize(x * sin(3.14157 * x)),x);
Evaluation took 0.0200 seconds (0.0200 elapsed)
(%o4) (5070602400912917605986812821504*(sin((7074186740679165*x)/2251799813685248)-(7074186740679165*x*cos((7074186740679165*x)/2251799813685248))/2251799813685248))/50044118042000907675005465097225
The calculation is about 9,000 faster after converting the float to its exact rational representation.
Maxima could (and should) do a better job with thing such as integrate(x * sin(3.14157 * x),x). Although there are good
reasons to avoid floats while doing symbolic calculations, think about (-1)^(2/3) (using the real branch rule) vs (-1)^*0.66666...7.
--Barton
________________________________________
changing the constant inside the sin() with a symbolic constant
enables maxima to solve this?!?!?!?