Borrar filtros
Borrar filtros

Construction of Hexagonal Shape Patterns

3 visualizaciones (últimos 30 días)
Pranjal Pathak
Pranjal Pathak el 4 de Oct. de 2013
Editada: Ashish Uthama el 4 de Oct. de 2013
Hi, Here I have added a particular code which generates some circular holograms:
fx = 5:5:20;
fy = 5:5:20;
a=128;
b=128;
c=512;
[x,y] = meshgrid(-1:2/127:+1,-1:2/127:+1);
circ=sqrt(x.^2+y.^2)<1;
for j1 = numel(fx):-1:1
for j2 = numel(fy):-1:1
h{(j1-1)*numel(fy) + j2 } = circ.*cos(pi*(x*fx(j1) + y*fy(j2)))>0;
end
end
M = cell(c/a);
M(:) = h;
M = cell2mat(M');
figure(1)
imagesc(M),colormap gray; axis image; axis off
Likewise, now I want to construct some hexagonal holograms in Matlab which may not be a regular pattern like the circular one. I have no idea how to do this. Can anyone please help me in this regard? N.B.: The hexagonal pattern will be arranged somewhat like the one attached here.

Respuestas (0)

Community Treasure Hunt

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

Start Hunting!

Translated by