Code covered by the BSD License  

Highlights from
Huygens-Fresnel integral approximation, free-form apertures and rough surfaces

image thumbnail

Huygens-Fresnel integral approximation, free-form apertures and rough surfaces

by

 

Simulate wave propagation through free-form apertures, or off rough surfaces.

vector2Matrix(A, m)
function [X, Y, Z] = vector2Matrix(A, m)
% vector2matrix - reshape a 3-by-(m*n) vector to three m-by-n matrices 
%
% X/Y/Z .... [m n] matrix with x/y/z coordinates
% A .... [xi;yi;zi] with (m*n) columns
% m .... [m n] dimensions

X = [];
Y = [];
Z = [];

if size(A,1) == 1
	X = reshape(squeeze(A(1,:)),m(1),[]);
elseif size(A,1) == 3
	X = reshape(squeeze(A(1,:)),m(1),[]);
	Y = reshape(squeeze(A(2,:)),m(1),[]);
	Z = reshape(squeeze(A(3,:)),m(1),[]);
end

Contact us