This is the revised version. The array has been increased from 11x11 to 21x21 and the boundaries adjusted accordingly.

```PRO relax2
phi = fltarr(21,21)
itype=intarr(21,21) ; initialized to zero (don't calculate).
dphi = 1.
niter = 200
string1=''
itype(1:19,1:19) = 1 ; 1 means calculate for this point.
itype(0,*) = 0 ; Start border
itype(*,0) = 0 ; *
itype(*,20) = 0 ; *
itype(20,*) =0 ; End border
itype(4:16,0:2) = 0 ; Lower polepiece.
itype(4:16,18:20) = 0 ; Upper polepiece.
phi(4:16,18:20) = 5. ; Upper polepiece at 5 StatMagVolts
phi(4:16,0:2) = -5.  ; Lower polepiece at - 5 StatMagVolts
phi(3,20) = 4.641 ; Left boundary varying bet'n 5 and -5V.
phi(2,20) = 4.284
phi(1,20) = 3.927
phi(0,20) = 3.570
phi(0,19) = 3.213
phi(0,18) = 2.856
phi(0,17) = 2.499
phi(0,16) = 2.142
phi(0,15) = 1.785
phi(0,14) = 1.428
phi(0,13) = 1.071
phi(0,12) = 0.714
phi(0,11) = 0.357
phi(0,10) = 0.
phi(0,9) = -0.357
phi(0,8) = -1.714
phi(0,7) = -1.071
phi(0,6) = -1.428
phi(0,6) = -1.428
phi(0,5) = -1.785
phi(0,4) = -2.142
phi(0,3) = -2.499
phi(0,2) = -2.856
phi(0,1) = -3.213
phi(0,0) = -3.570
phi(1,0) = -3.927
phi(2,0) = -4.284
phi(0,2) = -2.856
phi(0,1) = -3.213
phi(0,0) = -3.570
phi(1,0) = -3.927
phi(2,0) = -4.284
phi(3,0) = -4.641
phi(17,20) = 4.375 ; Right boundary varying bet'n 5 and -5V.
phi(18,20) = 4.284
phi(19,20) = 3.927
phi(20,20) = 3.570
phi(20,19) = 3.213
phi(20,18) = 2.856
phi(20,17) = 2.499
phi(20,16) = 2.142
phi(20,15) = 1.785
phi(20,14) = 1.428
phi(20,13) = 1.071
phi(20,12) = 0.714
phi(20,11) = 0.357
phi(20,10) = 0.
phi(20,9) = -0.357
phi(20,8) = -1.714
phi(20,7) = -1.071
phi(20,6) = -1.428
phi(20,5) = -1.785
phi(20,4) = -2.142
phi(20,3) = -2.499
phi(20,2) = -2.856
phi(20,1) = -3.213
phi(20,0) = -3.570
phi(19,0) = -3.927
phi(18,0) = -4.284
phi(17,0) = -4.641
FOR iter = 0,niter-1 DO BEGIN
FOR i=0,20 DO BEGIN
FOR j=0,20 DO BEGIN
IF itype(i,j) eq 1 THEN phi(i,j) = \$
(phi(i-1,j) + phi(i+1,j) + \$
phi(i,j-1) + phi(i,j+1))/4.
ENDFOR
ENDFOR
IF (iter mod 10) eq 0 THEN BEGIN ;try fill as opposed to follow ;
IF (iter mod 1) eq 0 THEN BEGIN
contour,phi,/follow, \$
levels=[0.001,findgen(10)+1.]
title='PHI after '+string(i)+' iterations'
xtitle="row"
ytitle="column"
bycen = phi(10,11)-phi(10,10)
byside = phi(7,11) - phi(7,10);
print,'bycen, byside, non-uniformity = ', \$
bycen,byside, abs(byside-bycen)/bycen