Home > freetb4matlab > general > interpn.m

interpn

PURPOSE ^

%

SYNOPSIS ^

function vi = interpn (varargin)

DESCRIPTION ^

% -*- texinfo -*-
% @deftypefn {Function File} {@var{vi} =} interpn (@var{x1}, @var{x2}, @dots{}, @var{v}, @var{y1}, @var{y2}, @dots{})
% @deftypefnx {Function File} {@var{vi} =} interpn (@var{v}, @var{y1}, @var{y2}, @dots{})
% @deftypefnx {Function File} {@var{vi} =} interpn (@var{v}, @var{m})
% @deftypefnx {Function File} {@var{vi} =} interpn (@var{v})
% @deftypefnx {Function File} {@var{vi} =} interpn (@dots{}, @var{method})
% @deftypefnx {Function File} {@var{vi} =} interpn (@dots{}, @var{method}, @var{extrapval})
%
% Perform @var{n}-dimensional interpolation, where @var{n} is at least two. 
% Each element of the @var{n}-dimensional array @var{v} represents a value 
% at a location given by the parameters @var{x1}, @var{x2}, @dots{}, @var{xn}. 
% The parameters @var{x1}, @var{x2}, @dots{}, @var{xn} are either 
% @var{n}-dimensional arrays of the same size as the array @var{v} in 
% the 'ndgrid' format or vectors.  The parameters @var{y1}, etc. respect a 
% similar format to @var{x1}, etc., and they represent the points at which
% the array @var{vi} is interpolated.
%
% If @var{x1}, @dots{}, @var{xn} are omitted, they are assumed to be 
% @code{x1 = 1 : size (@var{v}, 1)}, etc.  If @var{m} is specified, then
% the interpolation adds a point half way between each of the interpolation 
% points.  This process is performed @var{m} times.  If only @var{v} is 
% specified, then @var{m} is assumed to be @code{1}.
%
% Method is one of:
%
% @table @asis
% @item 'nearest'
% Return the nearest neighbor.
% @item 'linear'
% Linear interpolation from nearest neighbors.
% @item 'cubic'
% Cubic interpolation from four nearest neighbors (not implemented yet).
% @item 'spline'
% Cubic spline interpolation--smooth first and second derivatives
% throughout the curve.
% @end table
%
% The default method is 'linear'.
%
% If @var{extrapval} is the scalar value, use it to replace the values
% beyond the endpoints with that number.  If @var{extrapval} is missing,
% assume NA.
% @seealso{interp1, interp2, spline, ndgrid}
% @end deftypefn

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Fri 22-May-2009 15:13:00 by m2html © 2003