function y = sumv(x)
%SUMV Sum of elements of a vector
%   y = sumv(x) returns the sum of the elements of the vector x.

y = 0;
for i = 1:numel(x)
    y = y + x(i);
end

