Example 6.  Solve Laplace's equation over the square [Graphics:Images/EllipticPDEMod_gr_92.gif] where the boundary conditions are  

     [Graphics:Images/EllipticPDEMod_gr_93.gif],  [Graphics:Images/EllipticPDEMod_gr_94.gif],  for  [Graphics:Images/EllipticPDEMod_gr_95.gif],  
and  
     [Graphics:Images/EllipticPDEMod_gr_96.gif],  for  [Graphics:Images/EllipticPDEMod_gr_97.gif].

Solution 6.

First set up the boundary values.
[Graphics:../Images/EllipticPDEMod_gr_98.gif],  [Graphics:../Images/EllipticPDEMod_gr_99.gif],  for  [Graphics:../Images/EllipticPDEMod_gr_100.gif],  and  [Graphics:../Images/EllipticPDEMod_gr_101.gif],  for  [Graphics:../Images/EllipticPDEMod_gr_102.gif].

 

[Graphics:../Images/EllipticPDEMod_gr_103.gif]

Next, solve it.

[Graphics:../Images/EllipticPDEMod_gr_104.gif]

[Graphics:../Images/EllipticPDEMod_gr_105.gif]

Plot the solution.

[Graphics:../Images/EllipticPDEMod_gr_106.gif]


[Graphics:../Images/EllipticPDEMod_gr_107.gif]

 

 

 

We can make a contour plot of the solution.  However, to get the orientation like the table and the 3D figure requires reversing the rows in the matrix.

[Graphics:../Images/EllipticPDEMod_gr_108.gif]


[Graphics:../Images/EllipticPDEMod_gr_109.gif]

 

 

The boundary function is continuous for this problem and Mathematica has no trouble computing the contours.  

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

(c) John H. Mathews 2004