function lines = readlines(filename,maxlinelen)
  % Returns a cell array with the lines of the file
  if nargin<2, maxlinelen=10000; end;
  lines = textread(filename,'%s','whitespace','\n','bufsize',maxlinelen);