project.email
Member level 4
Dear friends
I'm trying to execute the FDTD code of this book:
"The Finite Difference Time Domain Method for Electromagnetics With MATLAB Simulations"
In the chapter 3 I want to the see the objects defined by the define_geometry.m and show something like the following Figure.
but I really can't do it?!
I attached the whole files of the chapter 3 can anybody help me, please?
Regards.
I'm trying to execute the FDTD code of this book:
"The Finite Difference Time Domain Method for Electromagnetics With MATLAB Simulations"
In the chapter 3 I want to the see the objects defined by the define_geometry.m and show something like the following Figure.
Code:
disp('defining the problem geometry');
bricks = [];
spheres = [];
% define a brick with material type 4
bricks(1).min_x = 0;
bricks(1).min_y = 0;
bricks(1).min_z = 0;
bricks(1).max_x = 24e-3;
bricks(1).max_y = 20e-3;
bricks(1).max_z = 11e-3;
bricks(1).material_type = 4;
% define a brick with material type 2
bricks(2).min_x = -20e-3;
bricks(2).min_y = -20e-3;
bricks(2).min_z = -11e-3;
bricks(2).max_x = 0;
bricks(2).max_y = 0;
bricks(2).max_z = 0;
bricks(2).material_type = 2;
% define a sphere with material type 5
spheres(1).radius = 20e-3;
spheres(1).center_x = 0;
spheres(1).center_y = 0;
spheres(1).center_z = 40e-3;
spheres(1).material_type = 5;
% define a sphere with material type 1
spheres(2).radius = 15e-3;
spheres(2).center_x = 0;
spheres(2).center_y = 0;
spheres(2).center_z = 40e-3;
spheres(2).material_type = 1;
I attached the whole files of the chapter 3 can anybody help me, please?
Regards.