CT Projection Simulator

버전 1.2.0.0 (95.4 KB) 작성자: Robert Alvarez
Computes the parallel beam 2D projections of an object specified as a set of geometric shapes
다운로드 수: 1.1K
업데이트 날짜: 2011/9/21

라이선스 보기

Specifying an object as a shape results in fewer edge artifacts in the reconstructed image than with projections from radon.m, which specifies the object as an image.

A comparison of reconstructed images with CTProjSim and radon.m is given at
http://aprendtech.com/wordpress/?p=89

The object starts as empty and then shapes with specified dimensions and density can be added.
The projections are the product of the length through the instances of all shape times their density.
Different instances of each shape can have different density.
The density can be a vector quantity so the projections are a
(ndetectors, nangles, ndensity) matrix.

The shapes are specified by optional parameters of one or more pairs
'shape',spec where shape can be one of 'ellipse', 'gaussian', or 'polygon'
the spec parameter depends on the shape--see the function help
The lines are equally spaced around the origin and start parallel to the y-axis.

Here is an example of a Shepp-Logan phantom with a square in the middle

% projections for Shepp-Logan phantom
% the spec is for phantom in air .. not water
s = [ ...
0,0,0.92,0.69,90,2; ...
0,-0.0184,0.874,0.6624,90,-0.98; ...
0.22,0,0.31,0.11,72,-0.02; ...
-0.22,0,0.41,0.16,108,-0.02; ...
0,0.35,0.25,0.21,90,0.01; ...
0,0.1,0.046,0.046,0,0.01; ...
0,-0.1,0.046,0.046,0,0.01; ...
-0.08,-0.605,0.046,0.023,0,0.01; ...
0,-0.605,0.023,0.023,0,0.01; ...
0.06,-0.605,0.046,0.023,90,0.01; ...
];

% add a small square at the center
% polygon vertexes are specified as complex vectors: x + iy
% exp(1i*pi/4) rotates the square by 45 degrees
pgon.vertex = 0.1*exp(1i*linspace(0,2*pi,5))*exp(1i*pi/4);
pgon.density = -0.1;

pjn = CTProjSim(0.0025,240,'ellipse',s,'polygon',pgon);

img = CTrecon(pjn); % see http://aprendtech.com/wordpress/?p=74 for CTrecon code
% can also use iradon but it will be slow
% nangles = 240;
% angles = linspace(0,180,nangles+1);
% img = iradon(pjn,angles(1:end-1));
imshow(img,[0.8 1.2])
-------
for more information see
http://aprendtech.com/wordpress/?p=159
http://aprendtech.com/wordpress/?p=166

인용 양식

Robert Alvarez (2025). CT Projection Simulator (https://kr.mathworks.com/matlabcentral/fileexchange/32925-ct-projection-simulator), MATLAB Central File Exchange. 검색 날짜: .

MATLAB 릴리스 호환 정보
개발 환경: R2007b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
버전 게시됨 릴리스 정보
1.2.0.0

fixed a bug with the ndetectors parameter
demo code tests for CTrecon function and uses iradon if not available

1.1.0.0

I added a link to a comparison of reconstructed images with CTProjSim.m and radon.m

1.0.0.0