Syntax:
set cntrparam { {linear | cubicspline | bspline} | points <n> | order <n> | levels {auto} {<n>} | discrete <z1> {,<z2>} ... | incremental {<start>, <incr> {,<end>}} } show cntrparam
This command controls the way contours are plotted. <n> should be an integral constant expression and <z1>, <z2> ... any constant expressions. The parameters are:
linear, cubicspline, bspline — Controls type of approximation or interpolation. If linear, then the contours are drawn piecewise linear, as extracted from the surface directly. If cubicspline, then piecewise linear contours are interpolated to form somewhat smoother contours, but which may undulate. If bspline, a guaranteed-smoother curve is drawn, which only approximates the piecewise linear data.
points — Eventually all drawings are done with piecewise linear strokes. This number controls the number of points used to approximate a curve. It is relevant only for cubicspline and bspline modes.
order — Order of the bspline approximation to be used. The bigger this order is, the smoother the resulting contour. (Of course, higher order bspline curves will move further away from the original piecewise linear data.) This option is relevant for bspline mode only. Allowed values are integers in the range from 2 (linear) to 10.
levels — Approximate number of contour levels. Selection of the levels is controlled by auto (default), discrete, and incremental. For auto, if the surface is bounded by zmin and zmax, contours will be generated at integer multiples of dz between zmin and zmax, where dz is 1, 2, or 5 times some power of ten (like the step between two tic marks). For discrete, contours will be generated at z = <z1>, <z2> ... as specified. The number of discrete levels is limited to MAX_DISCRETE_LEVELS, defined in plot.h to be 30. If incremental, contours are generated at values of z beginning at <start> and increasing by <increment> until <end> is reached. If <end> is not specified, MAX_DISCRETE_LEVELS will be generated.
If the command set cntrparam is given without any arguments specified, the defaults are used: linear, 5 points, order 4, 5 auto levels.
Examples:
set cntrparam bspline set cntrparam points 7 set cntrparam order 10
To select 5 levels automatically:
set cntrparam levels auto 5
To specify discrete levels at .1, .37, and .9:
set cntrparam levels discrete .1,1/exp(1),.9
To specify levels from 0 to 4 with increment 1:
set cntrparam levels incremental 0,1,4
To set the number of levels to 10 (retaining the current settings of auto, discr. and increment's start and increment value, while changing its end):
set cntrparam levels 10
To set the start and increment while retaining the number of levels:
set cntrparam levels incremental 100,50
See also set contour for control of where the contours are drawn, and set clabel for control of the format of the contour labels.