hello,I have difine a 512*512*512 kgird and my initial pressure distribution(get from MCmatlab,also 512*512*512 grids) ,then I define a CartBowl senser by makeCartBowl,but when I run the program finally with kspaceFirstOrder3DG,I get a error:"The optional input 'SaveToDisk' is currently only compatible with forward simulations using a non-zero binary sensor mask."
my total code following:
clc; clear all; close;
Nx = 512; % number of grid points in the x (row) direction
Ny = 512; % number of grid points in the y (column) direction
Nz = 512; % number of grid points in the x (row) direction
x = 4e-2; % [m]
dx = x/Nx; % grid point spacing in the x direction [m]
dy = dx; % grid point spacing in the y direction [m]
dz = dx; % grid point spacing in the y direction [m]
kgrid = makeGrid(Nx, dx, Ny, dy, Nz, dz);
load("P0.mat");
source.p0 = p0;
medium.sound_speed = 1500*ones(Nx, Ny,Nz); % [m/s]
medium.density = 1040; % [kg/m^3]
% define sensor
bowl_pos = [-1.5e-2, 0e-2, 0e-2];
radius = Inf;
diameter = 4e-2;
focus_pos = [0e-2,0e-2,0e-2];
num_points= 256;
sensor.mask = makeCartBowl(bowl_pos, radius, diameter, focus_pos, num_points);
sensor_data = kspaceFirstOrder3DG(kgrid, medium, source, sensor);