%WHICH  Locate functions and files.
%   WHICH FUN displays the full pathname of the function with the name
%   FUN.  Variables in the workspace, built-in functions, or loaded
%   Simulink models display a message indicating that NAME is a variable,
%   built-in, or a Simulink model.
%
%   WHICH FUN -ALL  displays the paths to all functions with the name
%   FUN.  The first one in the list is the one that would be normally
%   returned by WHICH.  The others are either shadowed or can be
%   executed in special circumstances.  The -ALL flag can be used with
%   all forms of WHICH.
%
%   WHICH FILE.EXT displays the full pathname of the specified file.
%
%   WHICH FUN1 IN FUN2 displays the pathname to function FUN1 in the
%   context of the m-file FUN2.  While debugging FUN2, WHICH FUN1 does
%   the same thing.  You can use this to determine if a subfunction or
%   private version of a function is being called instead of a
%   function on the path.
%
%   WHICH FUN(A,B,C) displays the path to the given function with the
%   given input arguments.  For example, which feval(g), when
%   g=inline('sin(x)'), indicates that inline/feval.m would be invoked.
%
%   S = WHICH(...) returns the results of WHICH in the string S
%   instead of printing it to the screen.  S will be the string
%   'built-in' or 'variable' for built-in functions or variables in
%   the workspace. You must use the functional form of WHICH when
%   there is an output argument.
%
%   W = WHICH(...,'-all') returns the results of the multiple search
%   version of WHICH in the cell array W.  W will contain the path
%   strings normally printed to the screen.
%
%   See also DIR, HELP, WHO, WHAT, EXIST, LOOKFOR.

%   Copyright (c) 1984-98 by The MathWorks, Inc.
%   $Revision: 5.11 $  $Date: 1997/11/21 23:32:51 $
%   Built-in function.
