Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Tridiagonal Algoritm

Status
Not open for further replies.

Giupo

Programmer
Mar 4, 2008
2
IT
I need to solve a tridiagonal linear sistem of partial differential equations using the tridiagonal algoritm. I used that described in "Numerical Recipes", but I think it doesn't work very well. I'm looking for an alternative solving way.

Thank you
 
Have you tried a google search? Seems to be lots of hits.
 
The book "Introduction to Fortran 90 for Scientists and Engineers" has also an example and FORTRAN code for solving tridiagonal system. You can check it.
 
The easiest way is the Thomas Algorithm. You basically sweep down the i-1 diagonal by using the i (main) diagonal. Then back substitute when you get to the bottom.

They are quite easy to code once you get a pseudo-code going of what you need to do.
 
Status
Not open for further replies.

Similar threads

Part and Inventory Search

Sponsor

Back
Top