LAT Hologramm-Software 2.0
Loading...
Searching...
No Matches
GA_Zernike.m
Go to the documentation of this file.
1zernike = 13;
2n_fraction = 15;
3n_exponent = 8;
4bias = (2^(n_exponent-1)-1);
5depth = 1+n_fraction+n_exponent;
6population = 1;
7
8
9
10n0 = round(rand(zernike,depth,population));
11
12w = zeros(zernike,population);
13s = zeros(zernike,population);
14exponent = zeros(zernike,population);
15fraction = zeros(zernike,population);
16
17s(:,:) = (-1.*ones(zernike,population)).^reshape(n0(:,1,:),[zernike,population]);
18
19
20for n=2:1+n_exponent
21 exponent(:,:) = double(exponent(:,:) + 2^(n-2)*reshape(n0(:,n,:),[size(n0,1),size(n0,3)]));
22end
23for n=2+n_exponent:depth
24 fraction(:,:) = double(fraction(:,:) + 2^-(n-10)*reshape(n0(:,n,:),[size(n0,1),size(n0,3)]));
25end
26
27for z=1:1:zernike
28 w=s.*(1+fraction).*2.^(exponent-bias)
29end
30
31img = Zernike(w);
32imshow(Phase_Image(img));
function Phase_Image(in image)
Gibt die Phase eines Hologramms als Graustufenmatrix aus.
function Zernike(in weighting)
Ermöglicht die Wellenfrontkorrektur für ein SLM-Bild durch Angabe der Gewichtungsfaktoren der einzelnen Zerni...