Lecture 12: Dscrete Laplacan Scrbe: Tanye Lu Our goal s to come up wth a dscrete verson of Laplacan operator for trangulated surfaces, so that we can use t n practce to solve related problems We are mostly nterested n the standard Posson problem: f g We wll frst ntroduce some basc facts and then talk about dscretzaton By the end, we wll be able to derve a dscretzed lnear system from posson problem and calculate the numercal solutons 1 Facts and Tools Laplacan Operator: Laplacan Operator s a lnear functonal on C (), e : f(x) C () f(x) C () If R n, t can be explctly expressed as a dervatve operator 1 : 2 That s to x 2 say, f we have a regon Ω R n and a functon f(x) C (Ω), then f(x) 2 f(x) x 2 If s a surface, whch s more often the case, one standard defnton of Laplacan operator s: f f, where and are dvergence and gradent operator respectvely However, ths defnton s not stragtforward for dscretzaton Alternatvely, we wll avod ths problem wth Galerkn s approach Before we go on, let s brefly talk about why Laplacan operator s mportant Laplacan operator s used n many mportant partal dfferental equatons, whch are the keys to many mathematcal and physcal models Here are some examples: The heat equaton u t u descrbes the dstrbuton of heat n a gven regon over tme The egenfunctons of (Recall that a matrx s a lnear operator defned n a vector space and has ts egenvectors n the space; smlarly, the Laplacan operator s a lnear operator defned n a functon space, and also has ts egenfunctons n the functon space) are the solutons to the equaton u λu If S s a surface and u C (S), the egenfunctons descrbe the vbraton modes of the surface S Galerkn s Approach Gven a functon defned on, e f : R, ts L 2 dual L f s defned on the functon space L 2 () L f : L 2 () R L f [g] fgda, g L 2 () L 2 () s all the square ntegrable functons on ore rgorously, L 2 () {f : R : f 2 < } The functon g s often called a test functon We wll only deal wth the followng set of test functons n our dscusson: {g C () : g 0} Often, we are nterested n a compact surface wthout boundary, so 1 Note that the sgn of Laplacan operator s nconsstent n dfferent lterature
Note that we can also recover the functon f from ts dual L f Fgure 1 gves an ntuton about ths process We can take g to be the square functon and as g approaches a sngle pont when t gets narrow, L f [g] approaches the value of f at that partcular pont Fgure 1: L f f We apply L 2 dual to Laplacan usng the test functons stated above (note that the test functons vansh on the boundary), and use ntegraton by parts: L 2 f [g] g fda boundary terms g fda g fda Notce that we have used Laplacan wthout actually evaluatng t Ths s an example of Galerkn s approach, whch s a class of methods for convertng a contnuous operator problem to a dscrete problem (eg for dscretzng and solvng dfferental equatons) In ths approach we need to decde on a functon space (where functon f come from) and a test functon space (where functon g come from; we can often apply boundary condtons by choosng test functons) We ll see ths method n practce n the next secton 2 Dscretzaton In ths secton, we wll frst pose a dfferent representaton of the Posson problem and then use the tools from the prevous secton to derve a dscretzaton Weak Soluton Consder Posson Equaton f g As stated before, t s hard to drectly derve a good dscretzaton for the equaton Therefore, we seek a dfferent representaton wth the concept of weak soluton The weak solutons for the Posson Equaton are functons f that satsfy the followng set of equatons 2 : φ fda φgda, test functons φ Recall that accordng to Galerkn s method, we need to choose the bass functon for f, g and test functon φ Frst Order Fnte Element Snce we are focusng on the Posson Equaton on a surface, f and g should be functons defned on the surface Therefore we need a set of bass functon on For trangulated surface, the most natural choce of bass functons are the pecewse lnear hat functons h, whch equal one at ther assocated vertex and zero at all other vertces, as shown n Fgure 2 2 The notaton here s dfferent from the last secton Specfcally, f and g are functons we want to dscretze and φ s test functon
Fgure 2: One hat functon per vertex Therefore, f we know the value of f (x) on each vertex, f (v ) a, we can approxmate t wth: X f (x) a h (x) Snce hp a R V Smlarly, we can have (x) are all fxed, we can store f wth only a sngle array ~ g(x) b h (x) Wth the dscretzaton of f and g, usng h as test functons, recall the L2 dual of f and the equatons for weak solutons of Posson Equaton, we can now pose the orgnal Posson problem as a set of V equatons: h gda, {1, 2,, V } h f da For the left hand sde: h f da h fp da h ( a h )da P a h h da Suppose matrx L {L } V V, L h h da Then the left hand sde of the set of P L a 1 P h1 f da L a 2 h2 f da L~a equatons s: P h f da V L V a For the rght hand sde: P h ( b h )da P b h h da h gda Smlarly, suppose matrx A {A } V V, A h h da The rght hand sde of the set of equatons s A~b Now we derve a lnear problem L~a A~b, we only need to calculate the matrces L and A n order to solve ~a Cotan Laplacan We now try to calculate the matrx L by examnng ts element L h h da Snce h are pecewse lnear functons on a trangular face, h s a constant vector on a face, and thus
h h yelds one scaler per face Therefore, to calculate the ntegral above, for each face we multply the scalar h h on that face by the area of the face and then sum the results Let s frst evaluate the gradent Now consder a lnear functon f defned on a trangle so that f(v 1 ) 1, f(v 2 ) f(v 3 ) 0, as shown n Fgure 3a For a lnear functon, we have f(x) f(x 0 ) + f x0 (x x 0 ) Let x 0 v 1, x v 2 and v 3 respectvely, and notce that f les wthn the trangle face, we get: f (v 1 v 3 ) 1 f (v 1 v 2 ) 1 f n 0 Ths yelds: f (v 2 v 3 ) 0 Therefore, f s perpendcular to the edge v 2 v 3, as shown n Fgure 3a (a) Evaluatng gradent (b) Case 1: Same vertex (c) Case 2: Dfferent vertces Fgure 3 Now we know the drecton of the gradent, we wll go on to evaluate ts magntude 1 f (v 1 v 3 ) f l 3 cos( π 2 θ 3) f l 3 sn θ 3 f 1 l 3 sn θ 3 1 h where h s the heght of the trangle correspondng to edge v 2 v 3 Recall that trangle area A 1 2 v 2v 3 h, thus f e 23 2A e 23 s the vector from v 2 to v 3 rotated by a quarter turn n the counter-clockwse drecton Now we have the gradent vectors on a face, we need to take dot products of them to get the scalar assocated wth each face There are two dfferent cases Let s stll look at a sngle trangle face and functons defned on t for now The frst case s when two functons are defned on the same vertex
T f, f dt A f 2 A b h 2 (h cot α+h cot β) 2h (cot α + cot β) 1 2 The second case s when two functons are defned on dfferent vertces (but of the same edge) T f α, f β dt A f α, f β 1 4A e 31, e 12 l 1l 2 cos θ 4A (h/ sn β)(h/ sn α) cos θ 2bh h cos θ 2(h cot α+h cot β) sn α sn β cos θ 2(cos α sn β+cos β sn α) cos θ 2 sn(α+β) cos θ 2 sn θ 1 2 cot θ Now we can apply these results on hat functons {h } by smply summng around each vertex 2h (a) Case 1: Same vertex (b) Case 2: Dfferent vertces Fgure 4: Summng around each vertex h p, h p 1 (cot α + cot β ) 2 h p, h q 1 2 (cot θ 1 + cot θ 2 ) Fnally, we get the cotangent Laplacan matrx L: 1 2 (cot α + cot β ), f L 1 2 (cot α + cot β ), f 0, otherwse (1) means that vertex and vertex are adacent ass atrx For the rght hand sde, we need to calculate the matrx A, whch s often called the mass matrx As t nvolved the product of h and h, the result would be quadratc There are several approaches to deal wth t A straghtforward and consstent approach s to ust do the quadratc ntegral Smlarly to the approach to calculate L, we fst ntegrate on a sngle trangle A trangle { area/6 area/12 f f Then we can sum up around each vertex There are two cases as shown n Fgure 4 (2) A { one rng area 6 f adacent area 12 f (3)
Some propertes of the mass matrx constructed ths way: each row sums to one thrd of the one-rng area of the vertex correspondng to that row; to construct the mass matrx t nvolves only vertex and ts neghbors; t parttons surface area as the weght to assgn to each vertex The matrx can be used for calculatng ntegraton (notce that h 1): f a h a h ( A a h ) 1 T A a Settng a 1 wll gve us the surface area However, there s one drawback of ths approach The mass matrx constructed s not dagonal whch means t s often hard to manpulate t We can turn t nto a dagonal matrx by ntroducng certan approxmatons From the prevous example, we have seen that the mass matrx s actually ntegratng a functon on the surface Therefore, we can try to fnd dfferent ways to do the ntegraton For example, the lumped mass matrx fnds the dual cells of each vertex and approxmate the dagonal of A wth the areas of each cell: a Area(cell ) Fgure 5: Lumped ass atrx wth dual cells Such approxmaton won t make a dfference for smooth functons Intutvely, the functon values of adacent vertces are very close for a smooth functons, so the result won t change a lot f we add them all to the dagonal eanwhle, as the mesh gets more and more refned, we can argue that the result would converge Fgure 6: Barycentrc Lumped ass atrx There are many ways to choose the dual cell One smple soluton s the barycentrc lumped mass matrx We assgn the dual of each face to be the barycentrc of the trangle Therefore, each vertex has a thrd of ts one-rng area assgned to t The resultng cells are lkely to be of rregular shapes One alternatve approach s to take Vorono Cells and use the areas accordngly