function D = diffmat1(n)

D = zeros(n);

D(1,1) = 1;

for i=2:n,
    D(i,(i-1):i) = [-1 1];
end

end
