functions:interpolation

INTERP

 syntax:  INTERP( x,y,xout )            ! spline (mono. incr. data)
          INTERP( x,y,xout,`FC' )       ! monotone piecewise cubic
          INTERP( x,y,xout,`LINEAR' )   ! linear
          INTERP( x,y,xout,`LAGRANGE' ) ! general Lagrange
 keyword values:  SPLINE, LINEAR, FC, LAGRANGE
 keyword default: SPLINE

 This function interpolates the data contained in vectors x and y. The
 vector x must be strictly monotonically increasing. The interpolant
 locations are given in vector xout. This function will return the
 interpolated values as a vector with the same length as vector xout. An
 interpolated curve will always pass through the original data points.
 The algorithm that is employed depends on the keyword that is used. The
 default is to use interpolating splines.

 See also the SPLINTERP, SMOOTH, SPLSMOOTH and SAVGOL functions.

Additional Information on:

  • SPLINE
  • FC
  • LINEAR
  • LAGRANGE
  • SPLINTERP

     syntax:  SPLINTERP( x,y,n ) ! spline (no restrictions on x)
    
     This function interpolates the data contained in vectors x and y. The
     vector x need not be monotonically increasing. The interpolated curve
     will always pass through the original data points. The number of
     output interpolant locations is given in scalar n. The points are first
     parameterized in terms of normalized arc length. A spline under tension
     is calculated for x versus arc length and y versus arc length. The x
     and y values are interpolated separately and then combined to form the
     output interpolant.  The output of this function is a matrix with n rows
     and 2 columns. The first column will contain the locations and the
     second column the interpolated values.
    
     See also the INTERP, SMOOTH, SPLSMOOTH and SAVGOL functions.
    

    Additional Information on:

  • arc_length