CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Main CFD Forum

comparision between TDMAand gauss elimination

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   April 6, 2007, 06:27
Default comparision between TDMAand gauss elimination
  #1
ADITYA
Guest
 
Posts: n/a
friends, I would like to know how many transformations or calculations we are saving by using Thomas algorithm instead of Gauss elimination approch if any one know mathematial derivation of this plz directly mail t o aditya_jayanthi1986@yhaoo.com
  Reply With Quote

Old   April 6, 2007, 08:36
Default Re: comparision between TDMAand gauss elimination
  #2
pc
Guest
 
Posts: n/a
Basically you have far less work and less storage with TDMA. You only need to store 3 vectors for the diagonal and off-diagonal terms, not the full matrix.

You can find details on TDMA in any introductory CFD text.
  Reply With Quote

Old   April 6, 2007, 13:00
Default Re: comparision between TDMAand gauss elimination
  #3
opaque
Guest
 
Posts: n/a
Dear ADITYA,

Mostly you are saving storage since you require only 3 vectors for diagonal, and a RHS vector.

The number of operations saved is dependent of what you mean by Gaussian elimination. For Gaussian elimination w/o partial/total pivoting, you are only saving the logical decisions of not processing the 0's on the even lower triangular part of the full matrix when doing the forward elimination. Similar when doing the back susbtitution.

Thomas' algorithm is just a minimal storage version of Gaussian elimination. However, they are only identical if pivoting is not used.

I do not recall exactly, but if your equations are not diagonally dominant you may find a round off propagation/truncation error that Gaussian elimination with pivoting does not have.

Opaque.
  Reply With Quote

Old   April 6, 2007, 18:52
Default Re: comparision between TDMAand gauss elimination
  #4
Trinity
Guest
 
Posts: n/a
TDMA involves O(n) operations, while Gauss elimination involves O(n3) operations, if n is the size of the matrix to be inverted.
  Reply With Quote

Old   April 7, 2007, 11:19
Default Re: comparision between TDMAand gauss elimination
  #5
Opaque
Guest
 
Posts: n/a
Dear Trinity,

For a full nxn matrix, you are correct.. Just run through the Gauss algorithm for the 3 diagonals, and count the operations..Recall that when doing the forward elimination (for most implementations) there is no cost when eliminating a row with leading zero coefficient since they are skipped.

The problem might be in the back substitution.. Most implementations run from column j--> n w/o checking for zero coefficients.

My point was (at least I intended to) that Thomas algorithm is just Gauss Elimination reduced to 3 diagonals. It is not a "different" method..

  Reply With Quote

Old   April 7, 2007, 11:54
Default Re: comparision between TDMAand gauss elimination
  #6
Trinity
Guest
 
Posts: n/a
You are right absolutely right Opaque, I had never thought about the possibility of zero coefficients. I guess partly because I have only dealt with 'nice' matrices, that are diagonally dominant. The type you get when discretizing the laplacian.

So TDMA just 'honors' the fact that the matrix is tridiagonal (and diagonally dominant) and applies GE with that understanding. But in certain non-linear problems i suppose, the matrix may not be as nicely behaved (and thanks for pointing that out to me! )

But in most 'beginner' problems, if there is a choice between TDMA and GE, TDMA is the way to go. Even when used iteratively, for example in solving poisson equation in 2d, TDMA is orders of magnitude faster. It is a pain to implement the boundary conditions sometimes, but nothing as compared to the pain of seeing the simulation run for half the day as with GE.
  Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Buoyancydriven cavity results for comparision kar OpenFOAM 0 April 14, 2008 09:04
Partial Elimination Algorithm alberto OpenFOAM Running, Solving & CFD 0 February 15, 2007 10:55
CFD-newbie software comparision questions jazz Main CFD Forum 0 May 9, 2006 23:34
Comparision of CFX and Fluent Spark Main CFD Forum 2 July 29, 2004 13:21
Comparision of FLUENT $ CFX Congli Cheng CFX 2 September 15, 2002 23:06


All times are GMT -4. The time now is 02:22.