Numerical Methods for Grid Equations: Volume I Direct Methods