%% Polynomial Division
% Create two vectors u and v containing the coefficients of the polynomials 2x^3 + 7x^2 + 4x + 9 and x^2 + 1, respectively. Divide the first polynomial by the second by deconvolving v out of u, which results in quotient coefficients corresponding to the polynomial 2x + 7 and remainder coefficients corresponding to 2x + 2.

u = [2 7 4 9];
v = [1 0 1];
[q,r] = deconv(u,v)

% Copyright 2012 The MathWorks, Inc.