필터 지우기
필터 지우기

How to change a Decaster coordinate to Polar coordinat plot

조회 수: 1 (최근 30일)
viet le
viet le 2016년 10월 26일
편집: viet le 2016년 10월 26일
Hello everyone. I want to change plot from Descartes coordinate (code) to polar coordinate,
grid_num1=72; % system matrix size
grid_num2=46; % system matrix size
yn=xlsread('source position.xlsx'); % input file
sys=xlsread('system matrix.xlsx'); % system matrix
iteration_num=5000; % iternation number
yn_1=[yn(1:180,:);yn(1:180,:)];
sys_1=[sys(1:180,:);sys(1:180,:)];
tic
figure;
lamda=ones(grid_num1*grid_num2,1);
I=ones(360,1);
cal=sys_1'*I;
iii3=0;
pre_lamda=0.01*ones(grid_num1*grid_num2,1);
iii=0;
output_image=zeros(grid_num1,grid_num2,iteration_num);
tic
while(iii3<iteration_num)
A_lamda=sys_1*lamda;
lamda=lamda.*(sys_1'*(yn_1./(A_lamda)))./(cal);
iii3=iii3+1;
output_image(:,:,iii3)=reshape(lamda,[grid_num1 grid_num2]);
end
time=toc;
reshape_lamda=reshape(lamda,[grid_num2 grid_num1]);
xx=[0 360];
yy=[0 90];
imagesc(xx,yy,reshape_lamda);
title(['Reconstructed Image Using MLEM'])
xlabel('Phi [degree]')
ylabel('Rho [degree]')
colormap hot
colorbar;
toc
Descartes plot:
Polar plot that I expect: In Polar plot, I want to see 2 white rectangles in Descartes plot.
Thank for your time

답변 (0개)

카테고리

Help CenterFile Exchange에서 Polar Plots에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by