function mat = matquasiper3(l)

mat = [];
n = length(l);

for k = 1:(n-1)
        mat(k+1,k) = -1;
end

for k = 1:(n-1)
        mat(k,k+1) = -1;
end

for  k = 1:n
        mat(k,k) = 2+l(k);
end

res = mat;

end