When we have a function like $f(x) = x^2-1$ and we expand it in a power series about some $x = x_0$, does Mathematica automatically assume that $x$ is real valued?

  • $\begingroup$ Welcome to Mathematica.SE! I hope you will become a regular contributor. To get started, 1) take the introductory tour now, 2) when you see good questions and answers, 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, 3) remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign, and 4) give help too, by answering questions in your areas of expertise. $\endgroup$
    – bbgodfrey
    Oct 16 at 13:18
  • $\begingroup$ I do not believe so. However, if f[x] is not analytical x0, the result depends on the direction in the complex plain at which x0 is approached. See the documentation. $\endgroup$
    – bbgodfrey
    Oct 16 at 13:22
  • 1
    $\begingroup$ If you have a function like your example $f$, the power series will be the same polynomial whether we assume $x$ is real or complex. You might want to give an example in which it matters in the same way it matters in your actual problem. For instance, Abs[x]; try Series on it with and without the assumption that $x$ is real. $\endgroup$
    – Michael E2
    Oct 16 at 18:40
  • $\begingroup$ Thanks to both for your contribution. @Michael E2, I have tried with your example and indeed it has a difference in that case. My specific example turns out to be the one in my OP. I guessed that by expanding about x = 1, I'm implying to Mathematica that x is real. What do you think? $\endgroup$
    – dekees
    Oct 16 at 21:50
  • $\begingroup$ I don't think it implies x is real for Mathematica. What does it matter, though? The answer for x is real is the same as the answer for x is complex. You could add Assumptions -> Element[x, Reals], if you want to indicate that x may be assumed to be real. $\endgroup$
    – Michael E2
    Oct 17 at 2:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.