void PatchMatL (*zmat, *x, nx, *y, ny, *minv, *maxv, type, 
         *intensity, nintensity, nsmear) 

void PatchMatN (*zmat, *x, nx, *y, ny, *values, type, *intensity,
         nintensity, nsmear)

float *zmat zmat[y][x] is the array of values to be plotted in the x-y plane. If smearing is used (see 
nsmear below), zmat will be changed to reflect the smearing. zmat must be allocated as a single piece of memory.
float *x The x input vector.
int nx Dimension of the x input vector.
float *y The y input vector.
int ny Dimension of the y input vector.
float *minv, *maxv minv and maxv are the minimum and maximum values used in the linear level intensity array. If minv = maxv, the routine is self-scaling. They are passed into PatchMatL() 
as pointers so that if the self-scaling options is used, minv and maxv can be used in a subsequent call to ColorKeyL().
float *values An array of level change demarkation points used for nonlinear scaling of color assignments. The dimension of values should be one more than the number of colors used, namely nintensity + 1. values must be in ascending order. If zmat has values below (above) the range given by values, these data points will be assigned to the first (last) color value. 
int type There are four type options;
 = c fills a cell with the average of the four corners.
 = g centers a panel on each grid point and uses the value on the grid point.
 = l  fills a cell with the value at the lower-left corner. In this case, the x and y vectors must be of dimension nx+1 and ny+1, one larger than the matrix of values in order to define the last cell.
 = a generates a smeared filled contour plot.
int *intensity An array of GraphiC colors (-150, 50174, 200447) or filling patterns (115) to be used to display the different function levels. The first element corresponds to the smallest value of the function represented by zmat.
int nintensity The dimension of the intensity array.
int nsmear Optionally, the input data may be smeared to adjacent grid points to prevent large jumps. nsmear is the number of times that process is carried out. The algorithm used is as follows:
=   1/2  of the value of each grid point remains at the point.
=   1/12 of the value of each grid point is placed on the nearest 4 grid points.
=    1/24 of the value of each grid point is placed on the next nearest 4 grid points.
At the borders, ghost points are used. Note that the maximum and minimum values will be changed by the smearing process (less dynamic range), but the integrated density 
of the plotted quantity will be preserved.
PatchMatL() and PatchMatN() are used to create patch plots. Each cell in the grid is filled with a panel whose color is related to the values on the grid. The a option allows the user easily to make a smeared contour plot as well. Patch plots should be used when the function to be plotted is not a representation of a smooth function. These issues are discussed in the example TZTEST.C.

The difference between them is that PatchMatL() assumes that the color demarkations occur at linearly-spaced intervals from minv to maxv. It can be self-scaling. PatchMatN() uses the array values[nintensity+1] to determine these demarkation boundaries. The ability to specify the color demarkations provides the capability 
of increasing the resolution (number of colors) in regions where zmat is of greater interest.

If you want a color key on your plot, you should call either ColorKeyL() or ColorKeyN() according to whether you are using linear or nonlinear color demarkations. You may want to use physor() or orel() to move your axes so that there is sufficient room for the color key.