When we study the finite element course, we do another job, solve a simple finite element problem with C/C + + programming, as a programming example of finite element learning, to better understand the finite element theory, and to lay the foundation for the further use of large finite element software. The basic theory of finite element in this paper refer to the finite element method in fluid mechanics (Zhang Benzha), which is pp.156-165 by Mr.
One or two-dimensional heat transfer problem
As shown in Figure one:
Fig. One or two dimensional heat transfer problem
Ii. Process of solving problems
1, the structure is discretized, the structure to be analyzed from the geometry of the line or plane divided into a finite unit, according to the different structure and analysis requirements, select different forms of units, in the cell boundary set up nodes, and write numbering. COMPUTE node coordinates
2, Unit Analysis: Try to derive the relationship between the node displacement and the Nodal force, and establish the stiffness matrix of the element.
Calculation of element stiffness matrix:
For equations
Using Galerkin weak-Solution expression
(*)