Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Find a solution to the given initial-value problem using Green's functions

$$y"+3y'+2y= \frac{1}{1+e^x}; y(0)=0,y'(0)=1$$

So I have figured out that

$$y_c=e^{-x}-e^{-2x}$$

Now I am having issues figuring out what $y_p$ is. This is what I have so far:

$$y_1=e^{-x}, y_2=e^{-2x},$$

so

$$W(y_1, y_2)=-e^{-3x}.$$

$$G(x,t)=\frac{e^{-t}e^{-2x}-e^{-x}e^{-2t}}{-e^{-3x}} = -e^{-t}e^{x}+e^{-2t}e^{2x}$$

$$y_p=\int^x_0 G(x,t)f(t)dt$$

$$y_p=-e^x \int^x_0 \frac{e^{-t}}{1+e^t}dt+e^{2x} \int^x_0 \frac{e^{-2t}}{1+e^t}dt$$

So

$$y_p=-\ln(e^{-x}+1)(e^x+e^{2x})-\frac{e^{2x}}{2}+\frac{1}{2}+(e^{x}+e^{2x})\ln(2)$$

Is this correct?

share|improve this question
    
I am now beginning to doubt that :) –  math101 Jun 18 '13 at 21:04
    
Yes I have used them –  math101 Jun 18 '13 at 21:06
    
Oh yup. My mistake there. Thanks for pointing that out:) –  math101 Jun 18 '13 at 21:10
    
@Amzoti what about $y_p$ –  math101 Jun 18 '13 at 21:21
    
Is that better? –  math101 Jun 18 '13 at 21:46

2 Answers 2

up vote 3 down vote accepted

We are given:

$$y''+3y'+2y= \dfrac{1}{1+e^x}, ~ y(0)=0, ~y'(0)=1$$

The homogeneous (complementary) solution is given by: $y_c=e^{-x}-e^{-2x}$

For variation of parameters, we take: $y_1=e^{-x}, ~~y_2= -e^{-2x}$

Thus, the Wronskian $= W(y1, y2) = W(e^{-x},-e^{-2x}) = e^{-3x}$, so

$\displaystyle G(x,t)= \frac{y_1(t)y_2(x) - y_1(x)y_2(t)}{W(x)} = \frac{e^{-t}(-e^{-2x}) - e^{-x}(-e^{-2t})}{e^{-3x}} = e^{2x}e^{-2t} - e^xe^{-t}$, thus:

$\displaystyle y_p=\int^x_0 G(x,t)f(t)dt = -e^x \int^x_0 \frac{e^{-t}}{1+e^t}dt+e^{2x} \int^x_0 \frac{e^{-2t}}{1+e^t}dt$

We have:

  • $\displaystyle -e^x \int^x_0 \frac{e^{-t}}{1+e^t}dt = -e^{-x}\left[\ln(e^{-t}+1)-e^{-t}\right]$ evaluated over $(t, 0, x)$, yields: $\displaystyle-e^{-x}\left[\left(\ln(e^{-x} + 1)-e^{-x}\right) - \left(\ln(2) - 1\right)\right]$
  • $\displaystyle e^{2x} \int^x_0 \frac{e^{-2t}}{1+e^t}dt = e^{2x}\left[-\frac{e^{-2t}}{2}+e^{-t}-\ln(e^{-t} +1) \right]$, evaluated over $(t, 0, x)$, yields: $\displaystyle e^{2x}\left[\left(-\frac{e^{-2x}}{2} + e^{-x} - \ln(e^{-x}+1)\right) - \left(-\frac{1}{2} + 1 - \ln 2\right) \right]$

Do you see the issues now over those limits? Can you now do the algebra to combine all like terms and find:

$$y = y_c + y_p?$$

The final answer should be (after simplifications) and you can compare to the other answer:

$$y(x) = \left(e^{-x}+e^{-2 x}\right) \ln\left(\dfrac{1}{2} (e^x+1)\right)$$

share|improve this answer
    
@math101: Please see my posting (after all the discussions we had, you got most things correct). You really need to watch signs and algebra issues as they will really play tricks on you and mess up answers! Regards –  Amzoti Jun 19 '13 at 1:30
    
Nice work (indeed messy!)!! (+) –  amWhy Jun 19 '13 at 1:40
    
@Amzoti Wow, Thanks so much. I really appreciate that. Now I see where I went wrong :) –  math101 Jun 19 '13 at 1:51
    
@math101: I am very glad to hear that and you are doing great! You had the entire approach correct, just those silly algebra errors (I can't even add two numbers together), but just watch those and you'll be fine. now finish up the algebra and cleanup and see if you get the final result (which you can verify using the DEQ itself). Regards –  Amzoti Jun 19 '13 at 1:54

You are doing fine except that you should delay finding the constants untill you construct the final solution

$$ y = y_c + y_p = \ln \left( {{\rm e}^{x}}+1 \right) { {\rm e}^{-x}}+\ln \left( {{\rm e}^{x}}+1 \right) {{\rm e}^{-2\,x}}-{ c_1{\rm e}^{-2\,x}}+c_2{{\rm e}^{-x}}\longrightarrow(1).$$

You should have the following answer

$$ y \left( x \right) = ({{\rm e}^{-x}}+{\rm e}^{-2x} )\ln \left( {{\rm e}^{x}}+1 \right)-{{\rm e}^{-2\,x}}\ln \left( 2 \right) -{{\rm e}^{-x}}\ln \left( 2 \right). $$

Added: Here is how you advance. Using the first initial condition, subs $x=0$ in $(1)$ and equate it tozero gives

$$ c_1-c_2=2\ln(2). $$

Diff. $(1)$ and using the second initial condition yields the second equation

$$ 2c_1-c_2=3\ln(2). $$

Now, just solve the two equations to find $c_1,c_2$ and subs back in $(1)$ to get the desired answer.

share|improve this answer
    
I am not all that knowledgeable in this area but in my textbook we find the constants in the beginning. Also have you used Green's Function since I am not sure how you got a totally different $y_p$ than I have. Did you simplify the answer? –  math101 Jun 18 '13 at 21:14
    
@math101: As I said you were doing fine. You found the solution of the homogenous ode and the particular solution using Green's function technique. Note that, you are not solving a homogenous ode with initial condition instead you are solving a non homogenous ode with initial conditions and I already pointed out how you should have advanced. –  Mhenni Benghorbal Jun 18 '13 at 21:54
    
But How did you get $y_p=\ln(e^x+1)(e^{-x}+e^{-2x})$ –  math101 Jun 18 '13 at 22:29
    
@math101: Make sure you got the right $y_p$. I did not have a close look at your Green's function technique. However there are other techniques to find $y_p$. –  Mhenni Benghorbal Jun 18 '13 at 22:34
1  
Thanks for helping me :) I really appreciate it –  math101 Jun 18 '13 at 22:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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