I have the following very simple code. A power series in a-parameter, function f[x], is integrated with respect to x, and the result is expanded as a power series around a=0.

The result that "Mathematica" gives is wrong (it gives only the first term ignoring the other terms).


f[x_] := f0[x] + a f1[x] + a^2 f2[x] + a^3 f3[x]
Integrate[ f[x], x]
Series[%, {a, 0, 2}]
Out[1]= \[Integral](f0[x] + a f1[x] + a^2 f2[x] + a^3 f3[x]) \[DifferentialD]x
Out[2]= \[Integral]f0[x] \[DifferentialD]x
  • $\begingroup$ Hi, welcome to Mathematica.SE, please consider taking the tour so you learn the basics of the site. Once you gain enough reputation by making good questions you will be able to vote up and down both questions and answers. When you see good ones, please vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge. As you receive help, try to give it too, by answering questions in your area of expertise. $\endgroup$
    – rhermans
    Oct 23, 2014 at 8:26
  • $\begingroup$ The integration does not even do anything. Why even worry about what Series does? What is Series supposed to be when given an un-evaluated integral anyway? Is this even defined somewhere? Series work on functions. $\endgroup$
    – Nasser
    Oct 23, 2014 at 8:37
  • 2
    $\begingroup$ Strange, it works if you force Distributivity Series[Distribute[Integrate[f[x], x]], {a, 0, 2}]. I disagree with @Nasser, what it should do is well defined, and should be the same as in Series[Sum[Subscript[c, i] a^i, {i, 0, 3}], {a, 0, 2}] . Or am I thinking this wrong? Bug? $\endgroup$
    – rhermans
    Oct 23, 2014 at 8:56
  • $\begingroup$ @rhermans I only studies Series expansion for functions at school. Teacher never mentioned series expansion for integrals. So I do not know. You could be right. I'll ask the teacher tomorrow when I go to school. $\endgroup$
    – Nasser
    Oct 23, 2014 at 9:41
  • $\begingroup$ @KDH, It seems that no one answers, the link explains what to do. $\endgroup$
    – rhermans
    Oct 24, 2014 at 9:26

1 Answer 1


Response from WRI:

Thank you for bringing this issue to our attention.

I reproduced the behavior you describe and it appears to be an incorrect result. I have sent a note about this issue to our development team.

We are always interested in improving Mathematica and I want to thank you again for taking the time to contact us about this issue.

So it's reasonable to consider it as a bug.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.