view poly_mat.m @ 2:e2b116f3b69b

fixed reallocate and pinv_2_fast to work on Octave added short example very quickly, might not be working properly
author smusevic
date Thu, 25 Jul 2013 13:07:07 +0100
parents 462de60d7e94
children
line wrap: on
line source
function t_mat = poly_mat(tt, dgr, N)
t_mat = ones(dgr,N);
if dgr > 1
  t_mat(2,:) = tt;
  for k=3:dgr
    t_mat(k,:) = t_mat(k-1,:) .* tt;
  end
end