MATLAB image transformation four

I = fitsread('solarspectra.fts');% read fts format image
I = mat2gray(I);% converted to gray image
BW = edge(I);% converted to binary image
subplot(121), imshow( I), subplot(122),imshow(BW)
theta = 0:179;
[R,xp] = radon(BW,theta);% Find the Radon transformation between [0°179°]
figure, imagesc(theta , xp, R);
colormap(gray);
xlabel('\theta (degrees)'); ylabel('x\prime');
title('R_(\theta) (x\prime)'); colorbar
Insert picture description here
Insert picture description hereP = phantom(256);% Generate skull image
theta1 = 0:10:170; %Calculate the Radon transform under three sets of theta values
[R1,xp] = radon(P,
theta1 ); theta2 = 0:5:175;
[R2 ,xp] = radon(P,theta2);
theta3 = 0:2:178;
[R3,xp] = radon(P,theta3);
figure, imagesc(theta3,xp,R3);% display the third group of theta value Radon transform value under
colormap(hot); colorbar
xlabel('\theta'); ylabel('x\prime');
I1 = iradon(R1,10);% Image reconstruction based on projection data
I2 = iradon(R2,5);
I3 = iradon(R3,2) ;
figure,
subplot(221), imshow§; subplot(222), imshow(I1);
subplot(223), imshow(I2); subplot(224), imshow(I3);

Insert picture description here
Insert picture description here

Guess you like

Origin blog.csdn.net/m0_38127487/article/details/115185856