function pi = polyint(p,k)
%POLYINT Integrate polynomial analytically.
%   POLYINT(P,K) returns a polynomial representing the integral
%   of polynomial P, using a scalar constant of integration K.
%
%   POLYINT(P) assumes a constant of integration K=0.
%
% See also POLYDER, POLYVAL, POLYVALM, POLYFIT.

%   Copyright 1984-2000 The MathWorks, Inc.
%   $Revision: 1.4 $  $Date: 2000/01/31 04:12:23 $

if nargin<2, k=0; end
pi = [p./(length(p):-1:1) k];

% [EOF] polyint.m
