Numerical Methods for Supercomputers Graphics Assignment 3 Dr. Ed Donley Due ***
Suppose a unit square metal plate is in an environment in which the edges are kept at temperatures f1, f2, f3, and f4, as in the illustration below
and the two unit-square faces are insulated. Once the temperature has reached a steady state, the temperature at any point in the square satisfies Laplace's equation,

An approximation to the temperature can be obtained by partitioning the square with a lattice, say with N+1 intervals in each direction and replacing the partial derivatives above with second centered differences, as discussed in class.
Write a program which will solve the resulting system of linear equations for
any N using SOR with red-black coloring. Use any functions you want for u1,
u2, u3, and u4. For this approximation to Laplace's equation it has been shown
that the optimal value of omega is
where
and
.
Furthermore, for this value of omega,
. Solve the problem
for N = 50 and generate a color animation showing SOR converging to the
solution using colors to represent temperatures. Hand in your source program
and the name of the CGM graphics metafile so that I can see your plot.