<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.2" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>k-Wave User Forum &#187; Topic: Problem in 3D time reversal reconsturction in planar detection geometry</title>
		<link>http://www.k-wave.org/forum/topic/problem-in-3d-time-reversal-reconsturction-in-planar-detection-geometry</link>
		<description>Support for the k-Wave MATLAB toolbox</description>
		<language>en-US</language>
		<pubDate>Wed, 13 May 2026 01:51:32 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.2</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.k-wave.org/forum/search.php</link>
		</textInput>
		<atom:link href="http://www.k-wave.org/forum/rss/topic/problem-in-3d-time-reversal-reconsturction-in-planar-detection-geometry" rel="self" type="application/rss+xml" />

		<item>
			<title>wangk524 on "Problem in 3D time reversal reconsturction in planar detection geometry"</title>
			<link>http://www.k-wave.org/forum/topic/problem-in-3d-time-reversal-reconsturction-in-planar-detection-geometry#post-7690</link>
			<pubDate>Sun, 05 Jul 2020 22:11:13 +0000</pubDate>
			<dc:creator>wangk524</dc:creator>
			<guid isPermaLink="false">7690@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Thank you Dr. Treeby.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Bradley Treeby on "Problem in 3D time reversal reconsturction in planar detection geometry"</title>
			<link>http://www.k-wave.org/forum/topic/problem-in-3d-time-reversal-reconsturction-in-planar-detection-geometry#post-7563</link>
			<pubDate>Sat, 06 Jun 2020 14:50:02 +0000</pubDate>
			<dc:creator>Bradley Treeby</dc:creator>
			<guid isPermaLink="false">7563@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;The simulation is unstable (a warning is printed to the command line). You need to decrease the CFL / time step.&#60;/p&#62;
&#60;p&#62;Brad.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>wangk524 on "Problem in 3D time reversal reconsturction in planar detection geometry"</title>
			<link>http://www.k-wave.org/forum/topic/problem-in-3d-time-reversal-reconsturction-in-planar-detection-geometry#post-7528</link>
			<pubDate>Wed, 27 May 2020 07:25:43 +0000</pubDate>
			<dc:creator>wangk524</dc:creator>
			<guid isPermaLink="false">7528@http://www.k-wave.org/forum/</guid>
			<description>&#60;p&#62;Hi,&#60;/p&#62;
&#60;p&#62;I am trying to generate a basic TR reconstruction (3d) for planar geometry. Although, my problem involves reconstructing metal-tissue interface, I am at first trying to get reconstructions for homogenous domain settings. &#60;/p&#62;
&#60;p&#62;I am getting a very poor reconstruction for a data-rich problem. I do expect limited view artifacts, but this is much worse than that. Please let me know if I am doing something wrong here? How can I improve my reconstructions?&#60;br /&#62;
Also, while carrying out reconstruction for heterogeneous case (sound speed and density can be upto 4-6 times of that of water) can I expect a good reconstruction?? Please give me insights on this aspect as well.&#60;/p&#62;
&#60;p&#62;Sincerely,&#60;br /&#62;
Kevin&#60;/p&#62;
&#60;p&#62;The problem setting, true PA source, and reconstruction are uploaded at:&#60;br /&#62;
&#60;a href=&#34;https://imgur.com/a/XGRelbN&#34; rel=&#34;nofollow&#34;&#62;https://imgur.com/a/XGRelbN&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;%% ************ Code TR - homogeneous SOS and density ********************&#60;/p&#62;
&#60;p&#62;% =========================================================================&#60;br /&#62;
% SIMULATION&#60;br /&#62;
% =========================================================================&#60;/p&#62;
&#60;p&#62;% % assign the grid size and create the computational grid&#60;br /&#62;
domain_size=2e-2;&#60;br /&#62;
PML_size = 20;                  % size of the PML in grid points&#60;/p&#62;
&#60;p&#62;dx =0.1e-3;                 % grid point spacing in the x direction [m]&#60;br /&#62;
dy =0.1e-3;                 % grid point spacing in the y direction [m]&#60;br /&#62;
dz =0.1e-3;                 % grid point spacing in the y direction [m]&#60;/p&#62;
&#60;p&#62;Nx = round(domain_size/dx); % number of grid points in the x direction&#60;br /&#62;
Ny = round(domain_size/dx/5) ; %number of grid points in the y direction&#60;br /&#62;
Nz = round(domain_size/dx); % number of grid points in the z direction&#60;/p&#62;
&#60;p&#62;kgrid = makeGrid(Nx, dx, Ny, dy, Nz, dz);&#60;/p&#62;
&#60;p&#62;p0 = zeros(Nx,Ny,Nz);&#60;br /&#62;
medium.sound_speed = 1500*ones(Nx,Ny,Nz);   %% background&#60;br /&#62;
medium.density = 1000*ones(Nx,Ny,Nz);   %% background&#60;/p&#62;
&#60;p&#62;metal_sze = 2e-3; % side length of the metal cube&#60;br /&#62;
sz_vox = round(metal_sze/dx);&#60;/p&#62;
&#60;p&#62;tissue_sze = 1e-3;&#60;br /&#62;
tissue_vox = tissue_sze/dx;&#60;/p&#62;
&#60;p&#62;for i = 1:Nx&#60;br /&#62;
    for j=1:Ny&#60;br /&#62;
        for k=1:Nz&#60;br /&#62;
            if abs(Nx/2-i)&#38;lt;= sz_vox/2 &#38;amp;&#38;amp; abs(Ny/2-j)&#38;lt;=sz_vox/2 &#38;amp;&#38;amp; abs(Nz/2-k)&#38;lt;=sz_vox/2&#60;br /&#62;
            p0(i,j,k)=2;&#60;br /&#62;
%             medium.sound_speed(i,j,k)=1500; %6000;&#60;br /&#62;
%             medium.density(i,j,k)= 1000; %3000;&#60;br /&#62;
            elseif abs(Nx/2+sz_vox/2-i)&#38;lt;=tissue_vox &#38;amp;&#38;amp; abs(Ny/2-j)&#38;lt;=sz_vox/2 &#38;amp;&#38;amp; abs(Nz/2-k)&#38;lt;=sz_vox/2&#60;br /&#62;
            p0(i,j,k)=1;&#60;br /&#62;
%             medium.sound_speed(i,j,k)=1500; %1600;&#60;br /&#62;
%             medium.density(i,j,k)= 1000; %1500;&#60;br /&#62;
            end&#60;br /&#62;
        end&#60;br /&#62;
    end&#60;br /&#62;
end&#60;/p&#62;
&#60;p&#62;% smooth the initial pressure distribution and restore the magnitude&#60;br /&#62;
source.p0 = smooth(kgrid, p0, true);&#60;/p&#62;
&#60;p&#62;% medium.sound_speed = smooth(kgrid, medium.sound_speed, true);&#60;br /&#62;
% medium.density = smooth(kgrid, medium.density, true);&#60;/p&#62;
&#60;p&#62;p_slice = p0(:,:,round(Nz/2));&#60;br /&#62;
figure, imagesc(p_slice)&#60;/p&#62;
&#60;p&#62;% Detection setting and measurement generation :----&#60;/p&#62;
&#60;p&#62;% define a binary planar sensor&#60;br /&#62;
    sensor.mask = zeros(kgrid.Nx, kgrid.Ny, kgrid.Nz);&#60;/p&#62;
&#60;p&#62;sensor.mask(:,1,:) = 1;&#60;/p&#62;
&#60;p&#62;%% create the time array&#60;br /&#62;
% [kgrid.t_array, dt] = makeTime(kgrid, medium.sound_speed);&#60;br /&#62;
dt = 1/8e6;&#60;br /&#62;
kgrid.t_array= 0:dt:100*dt; &#60;/p&#62;
&#60;p&#62;% set the input arguements&#60;br /&#62;
input_args = {'PMLSize', PML_size, 'PMLInside', false, ...&#60;br /&#62;
    'PlotPML', false, 'Smooth', false, 'DataCast', 'single'};&#60;/p&#62;
&#60;p&#62;% run the simulation&#60;br /&#62;
tic&#60;br /&#62;
sensor_data = kspaceFirstOrder3D(kgrid, medium, source, sensor, input_args{:});&#60;br /&#62;
toc&#60;/p&#62;
&#60;p&#62;% reset the initial pressure&#60;br /&#62;
source.p0 = 0;&#60;/p&#62;
&#60;p&#62;% assign the time reversal data&#60;br /&#62;
sensor.time_reversal_boundary_data = sensor_data;&#60;/p&#62;
&#60;p&#62;% run the time-reversal reconstruction&#60;br /&#62;
p0_recon = kspaceFirstOrder3D(kgrid, medium, source, sensor, input_args{:});&#60;/p&#62;
&#60;p&#62;% add first order compensation for only recording over a half plane&#60;br /&#62;
p0_recon = 2 * p0_recon;&#60;/p&#62;
&#60;p&#62;% apply a positivity condition&#60;br /&#62;
p0_recon(p0_recon &#38;lt; 0) = 0;&#60;/p&#62;
&#60;p&#62;p_rec_slice = p0_recon(:,:,round(Nz/2));&#60;/p&#62;
&#60;p&#62;figure, imagesc(p_rec_slice)
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
