American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) ISSN (Print) 2313-4410, ISSN (Online) 2313-4402 Β© Global Society of Scientific Research and Researchers http://asrjetsjournal.org/ Solution of Laplace`s Equation Using Numerical Methods Eltigani Ismail Hassan* Department of Mathematics and Statistics, College of Science, Al Imam Mohammad Ibn Saud Islamic University, Riyadh 11642, KSA. Department of Mathematics, College of applied science and industrial, University of Bahri Email: ttfsr555@gmail.com Abstract This paper is simple review of the solution of Laplace`s equation in rectangular coordinates system, cylindrical polar coordinates system and spherical polar coordinate system. It also covers numerical method in the solution of Laplace`s equation. Keywords: Laplace equation; Numerical method; Laplacian difference; Uniform grid. 1. Introduction During the last two centuries several methods have been advanced for solving partial differential equations. Among these we consider only two techniques known as the method of separation of variables and Laplace transformation , the method of separation of variables is perhaps the oldest systematic method for solving partial differential equations. It has been considerably refined and generalized in meantime and remains a method of great importance to day. In this study we will review how the method of separation of variables. In solving this problem it is eventually necessary to consider the equations of whether an essentially arbitrary function can be expressed as an infinite series of sine and cosine functions. Series of this kind are called Fourier series, then we will come across to in some typical problems as the Laplace`s equation solving it by separation of variables and Fourier series .By the other hand we will explain in following: ------------------------------------------------------------------------ *Corresponding author. 178 http://asrjetsjournal.org/ American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 In first we define rectangular coordinate system βˆ‡2π‘ˆ = πœ•2𝑒 πœ•π‘₯2 + πœ•2𝑒 πœ•π‘¦2 = 0 In second we transform the rectangular coordinates system to cylindrical coordinates system is which comes as: π‘ˆ(π‘₯,𝑦. 𝑧) = (𝜌𝜌,πœƒπœƒ, 𝑧) and its solution given by: πœ•2𝑣 πœ•πœŒπœŒ2 + 1 ρ πœ•π‘£ βˆ‚Ο + 1 ρ2 πœ•2𝑣 βˆ‚ΞΈ2 + πœ•2𝑣 βˆ‚z2 = 0 In third we also transform the rectangular coordinates system to spherical polar coordinates system which comes as: π‘ˆ = (π‘₯,𝑦, 𝑧) = (π‘Ÿ,πœƒπœƒ,πœ™πœ™) βˆ‡2π‘ˆ = πœ•2u βˆ‚r2 + 2 r πœ•u βˆ‚r + 1 r2 sin ΞΈ βˆ‚ βˆ‚ΞΈ (sinπœƒπœƒ πœ•π‘’ πœ•πœƒπœƒ ) + 1 π‘Ÿ2 1 sin2ΞΈ βˆ‚2u βˆ‚ΞΈ2 = 0 In fourth we explain computerized computation method to solve general solution of Laplace`s equation by finite different equation. 2. Two dimensional heat flow Consider the flow of heat in a metal plate of uniform thickness 𝛼𝛼(π‘π‘š), density (𝜌𝜌 π‘”π‘Ÿβ„ π‘π‘š3⁄ ) ,specific heat 𝑆(π‘π‘Žπ‘™. π‘”π‘Ÿβ„ . deg)and thermal conductivity 𝐾(π‘π‘Žπ‘™ π‘π‘šβ„ . deg) . Let 𝑋 ∘ π‘Œplane be taken in face the point [1]. If temperature at any point is independent of the 𝑍coordinate and depends only on 𝑋,π‘Œ and time 𝑑. Then the flow is said to be two dimensional .In this case, the heat flow is in the π‘‹π‘Œ-plane only and is zero along the normal to the π‘‹π‘Œ-plane. Consider a rectangular element𝐴𝐡𝐢𝐷 of the plane with sides as shown in figure. By 𝐴on the amount of heat entering the element, from the side AB = βˆ’kΞ±βˆ‚y οΏ½βˆ‚u βˆ‚x οΏ½ x . The quantity of heat flowing out through the side 𝐢𝐷 per second = βˆ’π‘˜π›Όπ›Όπœ•π‘₯ οΏ½πœ•π‘’ πœ•π‘¦ οΏ½ 𝑦+πœ•π‘¦ (1) and the quantity of heat flowing out through the side 𝐡𝐢 per second = βˆ’π‘˜π›Όπ›Όπœ•π‘¦ οΏ½πœ•π‘’ πœ•π‘₯ οΏ½ π‘₯+πœ•π‘₯ (2) Hence the total gain of heat by rectangular element per second 179 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 = βˆ’π‘˜π›Όπ›Όπœ•π‘₯ οΏ½πœ•π‘’ πœ•π‘¦ οΏ½ 𝑦 βˆ’ π‘˜π›Όπ›Όπœ•π‘¦ οΏ½πœ•π‘’ πœ•π‘₯ οΏ½ π‘₯ + π‘˜π›Όπ›Όπœ•π‘₯ οΏ½πœ•π‘’ πœ•π‘¦ οΏ½ 𝑦+πœ•π‘¦ + π‘˜π›Όπ›Όπœ•π‘¦ οΏ½πœ•π‘’ πœ•π‘₯ οΏ½ π‘₯+πœ•π‘₯ = π‘˜π›Όπ›Όπœ•π‘₯ οΏ½ οΏ½πœ•π‘’πœ•π‘₯οΏ½π‘₯+πœ•π‘₯ βˆ’οΏ½πœ•π‘’πœ•π‘₯οΏ½π‘₯ πœ•π‘₯ + οΏ½πœ•π‘’πœ•π‘¦οΏ½π‘¦+πœ•π‘¦ βˆ’οΏ½πœ•π‘’πœ•π‘¦οΏ½π‘¦ πœ•π‘¦ οΏ½ Also the rate of gain of heat by the element = πœŒπœŒπœ•π‘₯πœ•π‘¦π›Όπ›Όπ‘  πœ•π‘’ πœ•π‘‘ Thus equating (1) and (2) = π‘˜π›Όπ›Όπœ•π‘₯πœ•π‘¦ οΏ½ οΏ½πœ•π‘’πœ•π‘₯οΏ½π‘₯+πœ•π‘₯ βˆ’οΏ½πœ•π‘’πœ•π‘¦οΏ½π‘₯ πœ•π‘₯ + οΏ½πœ•π‘’πœ•π‘₯�𝑦+πœ•π‘¦ βˆ’οΏ½πœ•π‘’πœ•π‘¦οΏ½π‘¦ πœ•π‘¦ οΏ½ = πœŒπœŒπœ•π‘₯πœ•π‘¦π›Όπ›Όπ‘  πœ•π‘’ πœ•π‘‘ (3) Dividing both sides by π›Όπ›Όπœ•π‘₯πœ•π‘¦ and taking limit as β†’ 0 , we get: π‘˜ οΏ½ πœ•2𝑒 πœ•π‘₯2 + πœ•2𝑒 πœ•π‘¦2 οΏ½ = πœŒπœŒπ‘  πœ•π‘¦ πœ•π‘‘ πœ•π‘’ πœ•π‘‘ = 𝐢2 οΏ½πœ• 2𝑒 πœ•π‘₯2 + πœ•2𝑒 πœ•π‘¦2 οΏ½ (4) where 𝐢2 = π‘˜/πœŒπœŒπ‘  is the diffusivity. Hence the equation (4) gives the temperature distribution of plane in the transit state [1]. 3. The diffusion equation in two-dimensions When cylindrical co-ordinates 𝜌𝜌,πœƒπœƒ, 𝑧 are used see [2],we have π‘₯ = 𝜌𝜌 cos πœƒπœƒ , y = ρ sinπœƒπœƒ , z = zand the equation of the conduction of heat comes πœ• 2𝑣 πœ•πœŒ2 + 1 ρ πœ•π‘£ βˆ‚Ο + 1 ρ2 πœ•2𝑣 βˆ‚ΞΈ2 + πœ•2𝑣 βˆ‚z2 = 0 (5) Let us first consider solutions which are independent of 𝑧 𝐢(π‘₯ + πœ•π‘₯,𝑦) + πœ•π‘¦) 𝐡(π‘₯ + πœ•π‘₯,𝑦 ) 𝐷(π‘₯, 𝑦) 𝐴(π‘₯,𝑦) Figure1 180 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 πœ•2𝑣 πœ•πœŒπœŒ2 + 1 ρ πœ•π‘£ βˆ‚Ο + 1 ρ2 πœ•2𝑣 βˆ‚ΞΈ2 = 0 (6) the equation for 𝑅 is πœ• 2𝑅 πœ•πœŒ2 + 1 ρ πœ•π‘… βˆ‚Ο + 1 ρ2 πœ•2𝑅 βˆ‚ΞΈ2 = 0 (7) By separation of variables π‘…βˆ–βˆ–πœ“πœ“ + 1 𝜌𝜌 π‘…βˆ–πœ“πœ“ + 1 𝜌𝜌2 π‘…πœ“πœ“βˆ–βˆ– = 0 (8) π‘…πœ“πœ“ π‘…βˆ–βˆ– 𝑅 + 1 𝜌𝜌 π‘…βˆ– 𝑅 + πœ“πœ“βˆ–βˆ– πœ“πœ“ = βˆ’πœ† (9) 𝜌𝜌2 π‘…βˆ–βˆ– 𝑅 + ρ π‘…βˆ– 𝑅 + Ξ»2ρ2 βˆ’ πœ“πœ“βˆ–βˆ– πœ“πœ“ = πœ‡πœ‡2 (10) from (10),we πœ‡πœ‡2πœ“πœ“ = 0 (11) 𝜌𝜌2π‘…βˆ–βˆ– + πœŒπœŒπ‘…βˆ– + (Ξ»2ρ2 βˆ’ πœ‡πœ‡2)𝑅 = 0 (12) The solution of (11) and (12) given respectively by : πœ“πœ“(πœƒπœƒ) = 𝐴1 cosπœ‡πœ‡πœƒπœƒ + 𝐴2 sin πœ‡πœ‡πœƒπœƒ (13) 𝑅(𝜌𝜌) = 𝐡1π½πœ‡(πœ†πœŒπœŒ) + 𝐡2π‘Œπœ‡(πœ†πœŒπœŒ) (14) The general solution is 𝑉(𝜌𝜌,πœƒπœƒ) = [𝐴1 cos πœ‡πœ‡πœƒπœƒ + 𝐴2 sin πœ‡πœ‡πœƒπœƒ]�𝐡1π½πœ‡(πœ†πœŒπœŒ) + 𝐡2π‘Œπœ‡(πœ†πœŒπœŒ)οΏ½ (15) Since 𝑉 is bounded 𝜌𝜌 = 0 then 𝐡2 = 0 gives 𝑉(𝜌𝜌,πœƒπœƒ) = [𝐴1 cos πœ‡πœ‡πœƒπœƒ + 𝐴2 sin πœ‡πœ‡πœƒπœƒ]�𝐡1π½πœ‡(πœ†πœŒπœŒ)οΏ½ (16) An initial distribution of concentration, let 𝑉 = 𝑓(𝜌𝜌,πœƒπœƒ) when 𝑑 = 0 ,we may try to satisfy the condition ,when πœ‡πœ‡ = 𝑛 and V must have period 2πœ‹πœ‹ in the variable πœƒπœƒ. (17) 𝑉(𝜌𝜌,πœƒπœƒ) = [𝐴1 cos πœ‡πœ‡πœƒπœƒ + 𝐴2 sin πœ‡πœ‡πœƒπœƒ]�𝐡1π½πœ‡(πœ†πœŒπœŒ)οΏ½ Now by substituting boundary condition 𝑉(1, πœƒπœƒ) =0 181 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 𝑉(𝜌𝜌,πœƒπœƒ) = [𝐴1 cosπ‘›πœƒπœƒ + 𝐴2 sinπ‘›πœƒπœƒ][𝐡𝐽𝑛(πœ†πœŒπœŒ)] (18) Now equation (17) can be expressed us 𝑉(𝜌𝜌,πœƒπœƒ) = [𝐴 cosπ‘›πœƒπœƒ + 𝐡 sinπ‘›πœƒπœƒ][𝐽𝑛(πœ†π‘šπ‘›πœŒπœŒ)] (19) By using super position 𝑉(𝜌𝜌,πœƒπœƒ) = βˆ‘ βˆ‘ [Amncosπ‘›πœƒπœƒ + Bmn sinπ‘›πœƒπœƒ]𝐽𝑛(πœ†π‘šπ‘›πœŒπœŒ)∞ m=0 ∞ 𝑛=0 (20) We let 𝑉 = 𝑓(𝜌𝜌,πœƒπœƒ) gives 𝑓(𝜌𝜌,πœƒπœƒ) = βˆ‘ π·π‘›βˆž n=0 cosπ‘›πœƒπœƒ + 𝐸𝑛 sinπ‘›πœƒπœƒ(21)Formula (21) represent Fourier Series of𝑓(𝜌𝜌,πœƒπœƒ) with period 2πœ‹πœ‹ 𝐷𝑛 = 1 πœ‹ ∫ 𝑓(𝜌𝜌,πœƒπœƒ) cosπ‘›πœƒπœƒ π‘‘πœƒπœƒ2πœ‹ 0 and𝐸𝑛 = 1 πœ‹ ∫ 𝑓(𝜌𝜌,πœƒπœƒ) sinπ‘›πœƒπœƒ π‘‘πœƒπœƒ2πœ‹ 0 for 𝑛 = 1,2, … We have π΄π‘šπ‘› = 2 𝐽𝑛+1 2 (πœ†π‘šπ‘›)∫ πœŒπœŒπ½π‘›(πœ†π‘šπ‘›πœŒπœŒ)π·π‘›π‘‘πœŒπœŒ 1 0 And π΅π‘šπ‘› = 2 𝐽𝑛+1 2 (πœ†π‘šπ‘›)∫ πœŒπœŒπ½π‘›(πœ†π‘šπ‘›πœŒπœŒ)πΈπ‘›π‘‘πœŒπœŒ 1 0 4. The elementary solution If we solve βˆ‡2π‘ˆ = 0 in spherical coordinates (π‘Ÿ,πœƒπœƒ,πœ™πœ™) βˆ‡2π‘ˆ = 1 β„Ž1β„Ž2β„Ž3 [ πœ• πœ•π‘ž1 [ β„Ž2β„Ž3 β„Ž1 πœ•π‘’ πœ•π‘ž1 ] + πœ• πœ•π‘ž2 [ β„Ž1β„Ž3 β„Ž2 πœ•π‘’ πœ•π‘ž2 ] + πœ• πœ•π‘ž3 [ β„Ž2β„Ž1 β„Ž3 πœ•π‘’ πœ•π‘ž3 ] whereβ„Ž1 = 1, β„Ž2 = π‘Ÿ and β„Ž3 = π‘Ÿ sinπœƒπœƒ and π‘ž1 = π‘Ÿ, π‘ž2 = πœƒπœƒ , and π‘ž3 = πœ™πœ™.If π‘ˆ is independent ofπœ™πœ™ with boundary condition π‘ˆ(1,πœƒπœƒ) = 𝑓(πœƒπœƒ) the solution of βˆ‡2π‘ˆ = 0 in spherical coordinates which is independent of πœ™πœ™ expressed as: π‘Ÿ2 πœ•2𝑒 πœ•π‘Ÿ2 + 2π‘Ÿ πœ•π‘’ πœ•π‘Ÿ + 1 sin πœƒπœƒ πœ• πœ•πœƒπœƒ οΏ½sinπœƒπœƒ πœ•π‘’ πœ•πœƒπœƒ οΏ½ = 0 ( 22) Take 𝑒(π‘Ÿ,πœƒπœƒ) = 𝑅(π‘Ÿ)πœ“πœ“(πœƒπœƒ)(23) We get π‘Ÿ2𝑅\\πœ“πœ“ + 2π‘Ÿπ‘…\πœ“πœ“ + 𝑅 sinπœƒπœƒ πœ• πœ•πœƒπœƒ οΏ½sin πœƒπœƒ πœ“πœ“\οΏ½ = 0 182 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 Dividing the above equation by π‘…πœ“πœ“ ,then we get π‘Ÿ2 𝑅\\ 𝑅 + 2π‘Ÿ 𝑅\ 𝑅 = βˆ’ 1 πœ“πœ“ sinπœƒπœƒ πœ• πœ•πœƒπœƒ οΏ½sin πœƒπœƒ πœ“πœ“\οΏ½ = πœ†2 π‘Ÿ2𝑅\\ + 2π‘Ÿπ‘…\ + πœ†2𝑅 = 0 (24) And πœ• πœ•πœƒπœƒ οΏ½sinπœƒπœƒ πœ“πœ“\οΏ½ βˆ’ πœ†2ψ sin ΞΈ = 0 sinπœƒπœƒ πœ•2πœ“πœ“ πœ•πœƒπœƒ2 + cos πœƒπœƒ πœ•πœ“πœ“ πœ•πœƒπœƒ βˆ’ πœ†2πœ“πœ“ sinπœƒπœƒ = 0 (25) the solution of (24) is given by 𝑅(π‘Ÿ) = π΄π‘Ÿπ‘› + 𝐡 π‘Ÿπ‘›+1 (26) whereπœ†2 = βˆ’π‘›(𝑛 + 1) (27) from (27) and equation(25) sinπœƒπœƒ πœ•2πœ“πœ“ πœ•πœƒπœƒ2 + cos πœƒπœƒ πœ•πœ“πœ“ πœ•πœƒπœƒ + 𝑛(𝑛 + 1) sin πœƒπœƒ πœ“πœ“ = 0 (28) Equation (28) is a Legendre ODE, with general solution πœ“πœ“(πœƒπœƒ) = 𝐢𝑃𝑛(cos πœƒπœƒ) + 𝐷𝑄𝑛(cos πœƒπœƒ) (29) 𝑒(π‘Ÿ,πœƒπœƒ) = οΏ½π΄π‘Ÿπ‘› + 𝐡 π‘Ÿπ‘›+1 οΏ½ [𝐢𝑃𝑛(cos πœƒπœƒ) + 𝐷𝑄𝑛(cos πœƒπœƒ)] (30) If 𝑒(π‘Ÿ,πœƒπœƒ) represent temperature on sphere radius with center at origin, there the heat must be bounded. When πœƒπœƒ = 0 orπœ‹πœ‹ (along 𝑍 - axis in spherical coordinates) when 𝑄𝑛(1) β†’ ∞ this provided that 𝐷 = 0 ( 31) To avoid infinitely temperature at center of sphere π‘Ÿ = 0 we take 𝐡 = 0 (32) Now from (31) and (32) the solution is given by (30) 𝑒(π‘Ÿ,πœƒπœƒ) = πΈπ‘Ÿπ‘›π‘ƒπ‘›(cos πœƒπœƒ) (33) 183 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 By the supper position (33) can be written as 𝑒(π‘Ÿ,πœƒπœƒ) = οΏ½πΈπ‘›π‘Ÿπ‘›π‘ƒπ‘›(cosπœƒπœƒ) (34) ∞ 𝑛=0 By applying the boundary condition 𝑒(1,πœƒπœƒ) = 𝑓(πœƒπœƒ) into (34). 𝑓(πœƒπœƒ) = οΏ½ EnPn(cos ΞΈ) (35) ∞ 𝑛=0 Let πœ‡πœ‡ = cos πœƒπœƒ,thenπœƒπœƒ = π‘π‘œπ‘ βˆ’1πœ‡πœ‡ 𝑓(π‘π‘œπ‘ βˆ’1πœ‡πœ‡) = οΏ½ EnPn(Β΅) (36) ∞ 𝑛=0 Now 𝐸𝑛 = (2𝑛 + 1) 2 �𝑓(π‘π‘œπ‘ βˆ’1πœ‡πœ‡)𝑃𝑛(πœ‡πœ‡)π‘‘πœ‡πœ‡ (37) 1 βˆ’1 From (34), we have 𝑒(π‘Ÿ,πœƒπœƒ) = οΏ½οΏ½ (2𝑛 + 1) 2 �𝑓(πœƒπœƒ)𝑃𝑛(cos πœƒπœƒ) sinπœƒπœƒπ‘‘πœƒπœƒ πœ‹ 0 οΏ½ [π‘Ÿπ‘›π‘ƒπ‘›(cos πœƒπœƒ)] ∞ 𝑛=0 . 5. The Laplacian Difference Equation Central differences based on the grid and scheme used for the finite - difference solution in two independent variables such as the Laplace equation [3]. πœ•2𝑇 πœ•π‘₯2 = 𝑇𝑖+1,𝑗 βˆ’ 2𝑇𝑖,𝑗 + π‘‡π‘–βˆ’1,𝑗 βˆ‡π‘₯2 (38) And πœ•2𝑇 πœ•π‘¦2 = 𝑇𝑖,𝑗+1 βˆ’ 2𝑇𝑖,𝑗 + 𝑇𝑖,π‘—βˆ’1 βˆ‡π‘¦2 (39) respectively which have errors of O[βˆ‡(π‘₯)2] and O[βˆ‡(𝑦)2] Substituting these expressions into equation into equation 184 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 πœ•2𝑇 πœ•π‘₯2 + πœ•2𝑇 πœ•π‘¦2 = 0 Gives 𝑇𝑖+1,𝑗 βˆ’ 2𝑇𝑖,𝑗 + π‘‡π‘–βˆ’1,𝑗 βˆ‡π‘₯2 + 𝑇𝑖,𝑗+1 βˆ’ 2𝑇𝑖,𝑗 + 𝑇𝑖,π‘—βˆ’1 βˆ‡π‘¦2 = 0 (40) For the square grid, βˆ‡π‘₯ = βˆ‡π‘¦ and by collection of terms ,the equation becomes 𝑇𝑖+1,𝑗 + Tiβˆ’1,j + Ti,j+1 + Ti,jβˆ’1 βˆ’ 4Ti,j = 0 (41) This relationship, which holds for all interior points on the plate, is referred to as the Laplacian different equation. A heated plate where boundary temperature are hold at const balance ant levels. This called adirichlet boundary condition. Where the edges are hold at constant temperature for the case illustrated in figure 2 balance figurec1 is ,according to equation (41) 𝑇21 + T01 + T12 + T10 βˆ’ 4T11 = 0 (42) and T10 = 0However, T01 = 75 therefore equation πœ• 2𝑇 πœ•π‘₯2 + πœ•2𝑇 πœ•π‘¦2 = 0, can be expressed as βˆ’4𝑇11 + 𝑇12 + 𝑇21 = βˆ’75 Similar equation can be developed for the other interior points. the result is the following set of nine simultaneous equations with nine unknowns. 4𝑇11 βˆ’ 𝑇21 βˆ’ 𝑇12 = 75 βˆ’π‘‡114𝑇21βˆ’π‘‡11βˆ’π‘‡22 = 0 βˆ’π‘‡214𝑇31βˆ’π‘‡32 = 50 (1,3) (2,3) (1,2) (2,2) (3,2) (1,1) (2,1) (3,1) 100 75C 50C Ω’β—Œ 0C Ω’β—Œ Figure 2 185 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 βˆ’π‘‡11 4𝑇12βˆ’π‘‡22βˆ’π‘‡13 = 75 βˆ’π‘‡21βˆ’π‘‡124𝑇22βˆ’π‘‡32βˆ’π‘‡23 = 0 βˆ’π‘‡31βˆ’π‘‡224𝑇32𝑇33 = 50 βˆ’π‘‡124𝑇13βˆ’π‘‡23 = 175 βˆ’T22βˆ’T134𝑇23βˆ’T33 = 100 βˆ’T32βˆ’π‘‡234𝑇33 = 150 5.1 Example Temperature of heated plate with fixed boundary conditions problem statement [4]. Use Lobmann's method (Gauss-Seidel) to solve for temperature of the heated in figure (4.2).Employ over relaxation with a value of 1.5 for the weighting factor and iterate πœ€πœ€π‘Ž = 1%. solution From equation 𝑇𝑖,𝑗 = 𝑇𝑖+1,𝑗+π‘‡π‘–βˆ’1,𝑗+𝑇𝑖,𝑗+1+𝑇𝑖,π‘—βˆ’1 4 at𝑖 = 1, 𝑗 = 1 is𝑇11 = 0+75+0+0 4 =18.75 and applying relaxation yield 𝑇11 = 1.5(18.75) + (1 βˆ’ 1.5)0 = 28.125 𝑇21 = 0 + 28.125 + 0 + 0 4 = 7.03125 𝑇21 = 1.5(7.03125) + (1 βˆ’ 1.5)0 = 10.54688 𝑇31 = 50 + 10.54688 + 0 + 0 4 = 15.13672 𝑇31 = 1.5(15.13672) + (1 βˆ’ 1.5)0 = 22.70508 The computation is repeated for other rows to give 𝑇12 = 38.67188 𝑇22 = 18.45703 𝑇32 = 34.18579 𝑇13 = 80.12696 𝑇23 = 74.46900 𝑇33 = 96.99554 186 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 Because all the 𝑇𝑖,𝑗`𝑠 are initially zero, all πœ€πœ€π‘Ž for the first iteration will be 100%. For the second iteration the results are: 𝑇11 = 32.51953 𝑇21 = 22.35718 𝑇31 = 28.60108 𝑇12 = 57.95288 𝑇22 = 61.63333 𝑇32 = 71.86833 𝑇13 = 75.21973 𝑇23 = 87.95872 𝑇33 = 67.68736 The error for𝑇11 can be estimated as equation βˆ’πœ•π‘ž πœ•π‘₯ βˆ’ πœ•π‘ž πœ•π‘ž = 0 οΏ½(πœ€πœ€π‘Ž)𝑖,𝑗� = οΏ½ 32 βˆ’ 1953 βˆ’ 28 βˆ’ 12500 32 βˆ’ 51953 οΏ½ 100% = 13.5% Because this value is the stopping criterion of 1% the computation is continued. The ninth iteration gives the result: 𝑇11 = 43.0061 𝑇21 = 33.29755 𝑇31 = 33.88506 𝑇12 = 63.21152 𝑇22 = 56.11238 𝑇32 = 52.33999 𝑇13 = 78.58718 𝑇23 = 76.06402 𝑇33 = 69.71050 where the maximum error is 0.71%. 6. Explicit Solution for uniform grid increments Consider a rectangular domain where the increments in both π‘₯ and 𝑦 are uniform [5]. The appropriate equation to use for an explicit solution to the Laplace equation is 𝑇𝑖𝑗 = π‘‡π‘–βˆ’1,𝑗+𝑇𝑖+1,𝑗+𝛽2�𝑇𝑖,𝑗+1+𝑇𝑖,𝑗+1οΏ½ 2(1+𝛽2) (43) Where 𝛽𝛽 = Ξ”π‘₯ Δ𝑦 The solution will start by loading the boundary conditions, and then calculating the values of 𝑇𝑖𝑗 in the interior points of domain. While we are initially temped to calculate𝑇𝑖𝑗 only once with equation (43), it should be mentioned that these values are only a fist approximation to the solution .We should, therefore , add additional index ,π‘˜, representing the current iteration, to each solution value .The solution values will now be referred to as π‘‡π‘–π‘—π‘˜ , and equation (43) will be modified to read: 187 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 𝑇𝑖,π‘—π‘˜+1 = π‘‡π‘˜π‘–βˆ’1,𝑗+π‘‡π‘˜π‘–+1,𝑗+𝛽2οΏ½π‘‡π‘˜π‘–,π‘—βˆ’1+π‘‡π‘˜π‘–,𝑗+1οΏ½ 2(1+𝛽2) (44) The iterative process should be repeated until convergence is achieved in every interior point of the domain , or until a maximum number of iterations , say 100 , have been performed . Convergence can be achieved ,for example ,if ,given a tolerance value πœ€πœ€ maximum difference two consecutive iterations is less than the tolerance , ,i.e., if max 𝑖,𝑗 �𝑇𝑖,π‘—π‘˜+1 βˆ’ π‘‡π‘˜π‘–,𝑗� ≀ πœ€πœ€. Consider , as an example ,a rectangular domain of length 𝐿 = 5π‘π‘š , and height 𝐻 = 3.5π‘π‘š , with increments βˆ†π‘₯ = 1π‘π‘š, π‘Žπ‘›π‘‘ βˆ†π‘¦ = 0.5π‘π‘š , as illustrated in the figure blow. There will be 𝑛 = 𝐿 βˆ†π‘₯οΏ½ sub-intervals in π‘₯ , andπ‘š = 𝐻 βˆ†π‘¦οΏ½ sub-intervals in , with π‘₯𝑖 = (𝑖 βˆ’ 1)βˆ†π‘₯, π‘“π‘œπ‘Ÿ 𝑖 = 1,2, … ,𝑛 + 1, and 𝑦𝑗 = (𝑗 βˆ’ 1)βˆ†π‘¦ , π‘“π‘œπ‘Ÿ 𝑗 = 1,2, … ,π‘š + 1 The boundary conditions are given as follows: 𝑇𝑖𝑗 = 5 along the left and right sides of the domain , while the temperature are given by the function 𝑇𝑏(π‘₯) = 5. π‘₯. (1 βˆ’ π‘₯) for the top and bottom sides of the domain ,respectively [5]. Solution is achieved by using function LaplaceExplicit.min Matlab : 188 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 function [x,y,T]= LaplaceExplicit(n,m,Dx,Dy) echo off; numgrid(n,m); R = 5.0; T = R*ones(n+1,m+1); % All T(i,j) = 1 includes all boundary conditions x = [0:Dx:n*Dx];y=[0:Dy:m*Dy]; % x and y vectors for i = 1:n % Boundary conditions at j = m+1 and j = 1 6 T(i,m+1) = T(i,m+1)+ R*x(i)*(1-x(i)); T(i,1) = T(i,1) + R*x(i)*(x(i)-1); end; TN = T; % TN = new iteration for solution err = TN-T; % Parameters in the solution beta = Dx/Dy; denom = 2*(1+beta^2); % Iterative procedure epsilon = 1e-5; % tolerance for convergence imax = 1000; % maximum number of iterations allowed k = 1; % initial index value for iteration % Calculation loop while k<= imax 189 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 for i = 2:n for j = 2:m TN(i,j)=(T(i-1,j)+T(i+1,j)+beta^2*(T(i,j-1)+T(i,j+1)))/denom; err(i,j) = abs(TN(i,j)-T(i,j)); end; end; T = TN; k = k + 1; errmax = max(max(err)); if errmax< epsilon [X,Y] = meshgrid(x,y); figure(2);contour(X,Y,T',20);xlabel('x');ylabel('y'); title('Laplace equation solution - Dirichlet boundary conditions - Explicit'); figure(3);surfc(X,Y,T');xlabel('x');ylabel('y');zlabel('T(x,y)'); title('Laplace equation solution - Dirichlet boundary conditions - Explicit'); fprintf('Convergence achieved after %i iterations.\n',k); fprintf('See the following figures:\n'); fprintf('==========================\n'); fprintf('Figure 1 - sketch of computational grid \n'); fprintf('Figure 2 - contour plot of temperature \n'); fprintf('Figure 3 - surface plot of temperature \n'); 190 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 return end; end; fprintf('\n No convergence after %i iterations.',k); To activate the function for the case illustrated in the figure above we use: ≫ [𝑋,π‘Œ,𝑇] = πΏπ‘Žπ‘π‘™π‘Žπ‘π‘’πΈπ‘₯𝑝𝑙𝑖𝑐𝑖𝑑(5,7,1,0.5) The solution is returned in the vectors π‘₯ and 𝑦 ,and in matrix 𝑇 .The function produces three plots: a sketch of the grid (similar to the figure above),the solution as a contours, and the solution as a surface .The last two figures are shown next: Laplace equation solution –Dirichletboundary conditions-Explicit Laplace equation solution - Dirichletboundary conditions - Explicit 191 American Scientific Research Journal for Engineering, Technology, and Sciences (ASRJETS) (2016) Volume 16, No 1, pp 178-192 7. Conclusion and Recommendation This paper showed that Numerical methods are usually easier to use in the solution of Laplace's equation. We notice that our results agree with other works cited in article. It is aim to continue higher order for two dimensional. References [1] Partial Differential equations Of Mathematical Physics.1969. pp 120-126. [2] Paul W. Berg& James L. MC Gregor Elementary differential equation 1960, pp55. [3] Steven C. Chapra &Roymond P- Canale Numerical methods for Engineers 2002.pp 40. [4] Grewal M.A. ph. D. Higher Engineering Methematics 1990.pp 86-99. [5] Numerical Solution of Laplace Equation By Gilberto. Urroz,October 2004. pp 4-7. 192