I have another homework question that I'm struggling a bit to understand exactly what I'm asked to do. I understand what an initial condition is, but I'm not quite sure how I specify such a condition. So, here's the problem:

$y = -1 + \int_1^x{(t - y(t)) dt}$

I am supposed to write an equivalent first order differential equation and specify an initial condition. I worked out the first part and my first order differential equation is:

$\frac{dy}{dx} = x - y$

However, understanding how to specify the initial condition has me stumped. All of the examples in the section specify the condition. As I write this question, it occurs to me that perhaps I must solve my differential equation. Doing so produces:

$$ \begin{array}{rcl}\frac{dy}{dx} & = & x - y \\ dy + y & = & xdx \\ \int{y+1 dy} & = & \int{x dx} \\ y^2 + 2y & = & x^2 \end{array} $$

However, this doesn't seem to be right either (or I'm just missing it). It would seem that I must know what the definition of $y$ is for this to work. Indeed, it would seem that such a definition is provided at the outset: namely $y = -1 + \int_1^x{(t - y(t)) dt}$. Yet, I'm not sure how to integrate $y(t)$.

At any rate, this also happens to be an odd numbered problem and so I already know what the authors got, but I don't quite see how to get it.

Thanks for the help, Andy


Hint: What happens to the RHS when $x=1$?

The following is the error in your solution to the differential equation $$\int y+dy \neq \int(y+1)dy$$

Here is a correct solution:

$$\frac{dy}{dx}=x-y \implies \frac{dy}{dx}+y=x$$ Multiply through by the integrating factor $e^{\int1dx}=e^{x}$, to get $$e^{x}\frac{dy}{dx}+e^{x}y=\frac{d}{dx}(ye^{x})=xe^{x}$$ Integrating, $$ye^{x}=\int xe^{x}dx=xe^{x}-\int e^{x}dx=xe^{x}-e^{x}+c$$ In other words, $y=x-1+ce^{-x}$
Combined with the initial condition of $(0,-1)$, $c=0 \implies y=x-1$

  • $\begingroup$ Sorry for the delay in marking this as the answer. Thank you for the hint. I get it now: a zero-width integral is 0. Thus, $y_0 = -1$. Interesting you solution to this DE. Section 9.2 introduced integrating factors: this was 9.1. Thanks again. $\endgroup$ Mar 9 '13 at 1:29
  • $\begingroup$ I wanted to solve it in a systematic way, but really the way I would solve this equation would be to 'guess' $y=ax+b$, and then equating coefficients gives $a=1,b=-1$. If the initial condition had been anything else, though, I don't see how it could be solved without an integrating factor. $\endgroup$ Mar 9 '13 at 13:29

Your Answer

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

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