   function T = tridiag(a, b, c, n)
%% function T = tridiag(a, b, c, n)
%% makes the matrix tridiag(a,b,c) of size n x n 
%%  a = sub. b = diag, c = super
 sub = diag(ones(n-1,1),-1);
 T = b*eye(n) + a .* sub + c .* sub';
% 
