%% Downsample the Jet Colormap
% Get a downsampled version of the jet colormap containing only ten colors. Then display the contours of the peaks function by applying the colormap and interpolated shading.

c = jet(10);
surf(peaks);
colormap(c);
shading interp;

% Copyright 2012 The MathWorks, Inc.