function drawCache(loc)
%Recursively calls itself to display the contents of the cache
global cache free
indentLevel =blanks(cache(loc).i+2);
fprintf('%s %u: x= %u, X=%u, D=%u, A=%u, T=%u\n',indentLevel,...
    cache(loc).i+1,cache(loc).size, cache(loc).X,cache(loc).D,...
    cache(loc).A, cache(loc).T);
for i=1:numel(cache(loc).child)
    drawCache(cache(loc).child(i))
end
end