Help with implicit euler method

Hey
I don't understand this backward euler solution, in particular why the f(y,t+h) is equal to y(t+2)
 

Attachments

19,447
3,890
Hey
I don't understand this backward euler solution, in particular why the f(y,t+h) is equal to y(t+2)
Because it's wrong.

It should be:

y(t+2)=y(t)+y'(t+2)h

Since, in this problem y'=-y, you have:

y(t+2)=y(t)-y(t+2)h

Solving for y(t+2) gives:
[tex]y(t+2)=\frac{y(t)}{1+2h}[/tex]
Chet
 

D H

Staff Emeritus
Science Advisor
Insights Author
15,329
681
Because it's wrong.
I agree with you there!

It should be:

y(t+2)=y(t)+y'(t+2)h
Actually, it should be y(t+h)=y(t)+h*y'(t+h). Given that y'(t)=-y(t), this becomes y(t+h)=y(t)-h*y(t+h), or y(t+h)=y(t)/(1+h).

Solving for y(t+2) gives:
[tex]y(t+2)=\frac{y(t)}{1+2h}[/tex]
Chet
Better: ##y(t+2)=\frac {y(t)}{3}##.

You've already set h=2.
 
19,447
3,890
I agree with you there!

Actually, it should be y(t+h)=y(t)+h*y'(t+h). Given that y'(t)=-y(t), this becomes y(t+h)=y(t)-h*y(t+h), or y(t+h)=y(t)/(1+h).


Better: ##y(t+2)=\frac {y(t)}{3}##.

You've already set h=2.
Thanks DH. I'm usually more careful about checking over what I've written before I submit my replies. I hope I didn't confuse the OP too much.

Chet
 

Related Threads for: Help with implicit euler method

Replies
2
Views
561
  • Last Post
Replies
2
Views
2K
  • Last Post
Replies
5
Views
4K
  • Last Post
Replies
3
Views
2K
  • Last Post
Replies
12
Views
8K
Replies
1
Views
2K
Replies
7
Views
15K

Hot Threads

Top