% The program creates the I-beam density distribution and saves it
% to a file called data/tomo_phantom.mat for later use. 
%
% Samuli Siltanen September 2006, based on the original code by Erkki
% Somersalo. Last revision March 2010.

N = 64;
phantom = zeros(N,N);
phantom(11:15,25:54) = ones(5,30);
phantom(51:55,25:54) = ones(5,30);
phantom(16:50,38:42) = ones(35,5);
phantom(28:32,11:15) = ones(5,5);

% Save result to file
save data/tomo_phantom phantom N

% Show image of the result
figure(1)
clf
imagesc(phantom);
colormap gray
axis([1 N 1 N])
axis square
box off
set(gca,'xtick',[1 N/2 N])
set(gca,'ytick',[1 N/2 N])

