sci.math.num-analysis SUNA43, Resistor model for 2-D diffusion ======================================== Almost any Finite Element book starts with the assembly of resistor-like finite elements, without approximations (if you consider Ohm's law as being "exact";-) Contained in "An Introduction to Finite Element Analysis", Acad. Press 1978, by Norrie D.H. & de Vries G., is a chapter about "Electrical Networks". The matrix of an electrical resistor is derived _directly_ by applying the laws of Ohm and Kirchhoff, giving: | +1/R -1/R | | -1/R +1/R | where R are the resistances. Further define the connectivity (no coordinates!) of the resistor-network, and apply two voltages. The standard FE assembly procedure can be carried out then. Let us devise for example a triangle, built up from electrical resistors: 3 / \ Opposite sides and vertices are numbered alike, which is 2 / \ 1 nothing but a handsom practice. / \ 1 ----------- 2 3 Assemble the accompanying element-matrices: (1) - (2) (1) - (3) (2) - (3) | +1/R3 -1/R3 0 | | +1/R2 0 -1/R2 | | 0 0 0 | | -1/R3 +1/R3 0 | + | 0 0 0 | + | 0 +1/R1 -1/R1 | | 0 0 0 | | -1/R2 0 +1/R2 | | 0 -1/R1 +1/R1 | Giving: | +1/R3+1/R2 -1/R3 -1/R2 | | -1/R3 +1/R3+1/R1 -1/R1 | | -1/R2 -1/R1 +1/R2+1/R1 | It is trivially seen that: E11 + E12 + E13 = 0 ; E22 + E21 + E23 = 0 ; E33 + E31 + E32 = 0 Compare this result with our findings in SUNA42: | y23.y23 + x23.x23 y23.y31 + x23.x31 y23.y12 + x23.x12 | | y31.y31 + x31.x31 y31.y12 + x31.x12 | / Det | symmetrical y21.y21 + x21.x21 | It is questioned if all terms in a matrix row sum up to zero here too. Well, there are a myriad ways to see that this is indeed the case. According to one of Patankar's "Basic Rules", the coefficients sum up to zero without question. You can work out each term algebraically and check out. A more elegant way is via geometrical interpretation: C Take the third matrix row as an example: /|\ E31 = E13 = - c.a.cos(B) ; E32 = E23 = - c.b.cos(A) b / | \ a E31 + E32 = - c.( AH + BH ) = - c.c = - E33 . Q.E.D. / | \ A -----H----- B c Now identify: (y23.y31 + x23.x31) / Det = -1/R3 or R3 = Det/[a.b.cos(C)] (y23.y12 + x23.x12) / Det = -1/R2 or R2 = Det/[a.c.cos(B)] (y31.y12 + x31.x12) / Det = -1/R1 or R1 = Det/[b.c.cos(A)] Thus we can consider the 3 X 3 matrix for diffusion at a triangle as a super- position of one-dimensional resistor-like elements. An outstanding example of substructuring, anyway. When assembling these triangle matrices into the global system, most resistors have to be replaced by two parallel resistors, one resistor for each side of a triangle, according to the law: 1/Ra + 1/Rb . Exceptions are at the boundary. The main diagonal term in a matrix equals to the sum of the off-diagonal terms. This result can be used as follows: account _only_ for the off-diagonal terms in the first place. At the very end of the F.E. assembly procedure, sum up each matrix row, in order to obtain the main diagonal elements. We end up with a resistor network. I had a pipe dream about these networks, while solving a moderate problem on my PC, drinking a bottle of beer because I had nothing else to do but wait, and wait ... Suppose we could let _grow_ a resistor network with the layout of our mesh and resistors in place of the triangle sides, each with magnitude Det/[a.b.cos(A)]. We would impose the boundary conditions as voltages. After a microsecond, the voltages at the nodal points would be known & A/D convert to the solution ;-) Still another way to look at the diffusion equation is via rubber bands instead of electrical resistors. The variational "integral" of such a network is: Sum 1/2. C(i,j) . [ {x(i) - x(j)}^2 + {y(i) - y(j)}^2 ] = minimum i,j the potential energy of all rubber bands must be a --^ Where C(i,j) = elasticy constant of rubber band between (i) and (j). Differentiation to the unknown positions (x,y) leads to the element matrix: | + C(i,j) - C(i,j) | | - C(i,j) + C(i,j) | Which can be used as a replacement of diffusion triangle side contributions. - * Han de Bruijn; Applications&Graphics | "A little bit of Physics * No * TUD Computing Centre; P.O. Box 354 | would be NO idleness in * Oil * 2600 AJ Delft; The Netherlands. | Mathematics" (HdB). * for * E-mail: Han.deBruijn@RC.TUDelft.NL --| Fax: +31 15 78 37 87 ----* Blood