Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

FEA Programming

Status
Not open for further replies.

ctmfab

Mechanical
Oct 1, 2002
21
0
0
US
I am looking for any books with a focus or chapters on FEA programming (or any reference). That is, any with examples or methods shown in theory and code. I am writing a simple program to solve truss models to further my understanding of the methods. Any language is fine, but VB is what I am using.

The basics such as matrix methods and solving F=kD aren’t necessary, I have these covered. But I would like to see how banded solutions are used and other issues that aren’t readily apparent.
 
Replies continue below

Recommended for you

You should look for the book Numerical Recipes in Fortran or C for banded solution. visit Or search in Amazon. For other fem coding, you should follow your own algorithm, there is no "The" algorithm for fem, all depends upon your requirement. Read the theory first and start coding in your own language. Following a book's own code will severely affect your understanding in coding.
 
Bhat165,

Thanks for your help. I actually saw your suggestion for Numerical Recipes in another post. This is a very helpful reference and contains lots of theory and practical methods for coding your own program.

I agree that there is no single algorithm and that copying code is the wrong approach. From what I have learned, it is more difficult to try to "cut-and-paste" code than it is to just write your own. However, it is often helpful to at least get a feel for what various algorithms and codes are used.

For small models, say less than 2,000 elements, do you feel that banded matrix storage is necessary? With current computer speed and memory, it seems like some of the optimiztion methods might not be requried for simplified programs or small models.
 
It all depends upon your ram and other configuration. If you run in x386 system, probably it will take a lot of time depending on your problem. For linear system, with P4 processor or above, it should take few seconds. But I believe as a good programer who is learning new methods, he should try which is "standard" in practice. Commercial softwares use either banded or sparse solver or coupled banded with sparse. Banded includes Cholesky method with banded matrix. They also use frontal solver. Even Skyline solution is also used. These are standard method and no matter what is the system size one should use standard method. This is what I feel. But you are right, for small size matrix and with fast processor, you can even try direct inversion of matrix !!
 
Try a book by Hinton and Owen: Programming the Finite Element Method (which is Fortran based). It has very detailed explanations and example subroutines for linear FE analysis. It also contains explanations and source code of a frontal solver. It might be a good idea to add a routine to optimize either element or node numbering scheme (depending on the type of solver you decide to implement).

 
bkal,

You are right, I forgot to mention that book. It has a chapter on basic programing techniques. Also in every chapter it gives coding side by side with theory. You also know how to code nonlinear problem efficiently with this book, since this is basically a nonlinear fem book. Great book. Also you can see Belegundu and Chandrupatla (I may be wrong in spelling), this is a good book for intial programmers, but written in basic.
 
Status
Not open for further replies.
Back
Top