1
$\begingroup$

A mid-step in solving a pde requires integrating the function $$f'(-x) = -2x + e^x$$ with respect to $x$. What do you do differently when integrating a function of $-x$ rather than of $x$? Am I allowed to set say $y = -x$ and so it becomes $$f'(y) = 2y + e^{-y}$$ which gives $$f(y) = y^2 - e^{-y} + c$$ and then substitute back in $-x$?

2 Answers 2

3

$$f(x) = \int f'(x) \mathrm{d}x = -\int f'(-x)\mathrm{d}x = \int (2x-e^{x})\mathrm{d}x = x^2 - e^{x} + C$$

  • 0
    So you're saying that $f'(x) = -f'(-x)$, but $-(-2x + e^x) \neq 2x + e^{-x}$ ?2012-05-18
  • 0
    @morphism it was a silly error, I corrected it.2012-05-19
1

I think you missed something in the integral. Integrating with a function of $-x$ instead of $x$ is done by changing either the function's variable $(-x)$ or the differential $(dx)$, so that they match. $$\int f'(-x) dx=\int -f'(y)dy$$ since $y=-x \Leftrightarrow dy=-dx$. You got:

$$\int -f'(y)dy=\int 2y+e^{-y}dy=y^2-e^{-y}+c=x^2-e^x+c$$

  • 1
    $\int 2y dy = y^2$ , you should correct that2012-05-18