Interpolate the supplied imat_fn.
g=interp(f,100)
g=interp(f,NPOINTS,SCALES,METHOD)
g=interp(f,'inc',INCREMENT)
g=interp(f,'inc',INCREMENT,SCALES,METHOD,EXTRAPTYPE)
INTERP will generate linear- or log-spaced abscissa values for the provided function, then pair each point with an interpolated ordinate value. INTERP uses theMATLAB INTERP1 function to perform the interpolation. If the function is complex, INTERP will interpolate the magnitude according to the specified SCALES, and will interpolate the phase linearly.
NPOINTS is a number specifying how many abscissa values to generate, or a vector of abscissa values at which to interpolate. If the string 'values' is supplied,then NPOINTS is always interpreted as abscissa values. This is necessary if NPOINTS is a scalar abscissa value. If the string 'inc' is supplied, then INCREMENT is a number specifying the spacing between consecutive abscissa values.
SCALES is an optional string specifying whether the abscissa/ordinate values should use linear or logarithmic scaling for the abscissa and ordinate, respectively. Possible values are 'lin' (default), 'linlog', 'loglin', and 'loglog'.
METHOD is an optional string, passed to INTERP1 to control the method of interpolation. Values accepted by INTERP1 include 'nearest', 'linear', 'spline', 'pchip', 'cubic', and 'v5cubic'. The default is 'linear'. An empty string specifies the default method.
EXTRAPTYPE is an optional numeric scalar, passed to INTERP1 to control the value to be used for extrapolated data. If specifying EXTRAPTYPE, you must also specify METHOD.
INTERP will automatically set the abscissa spacing of the output function to 'Even' if the difference between the abscissa data points is within 1000*eps. If this tolerance is too tight, you can always force the spacing to be even by changing the AbscissaSpacing of your output function.
>> g=interp(f,'inc',0.05,'lin');
>> g=interp(f,100,'linlog');
>> g=interp(f,100,'loglog','cubic');
>> g=interp(f,100,'linlog','cubic',0);
>>