This example shows, step by
step, how the XtremeFringe® library can be used to automatically demodulate the
phase from a single fringe pattern in just three steps
The image to be processed
is an isochromatic fringe pattern of a disk diametrally-loaded. The sample was obtained with a circular
polariscope in the circular dark field configuration.
clear all;
close all
clc;
I=double(imread('Delta7DisNa.tif'));I=I(:,:, 1); figure; imagesc(I); colormap gray; axis equal; title('fringe pattern');

As can be seen in the image
there is a high spatial frequency variation from the loading points to the
middle of the disk. The demodulation of the phase of this fringe pattern is not
possible by conventional techniques like Fourier transform or spatial
demodulation methods.
Before the demodulation, it
is necessary that the fringe pattern is normalized, that is, eliminate the
background and normalize the fringe modulation. This can be done easily with
the XtremeFringe® Normalize function. This function has only two parameters,
the fringe pattern to normalize and the radius (in fringes/field) of a
pass-band filter used to eliminate the background and high frequency noise. In
our example the average spatial frequency is about 25
fringes/field. Therefore the second parameter is set to 25.
IN=Normalize(I, 25); figure; imagesc(IN); colorbar; axis equal; colormap gray; title('normalized fringe pattern');

As can be seen in the
figure, the fringe pattern is normalized but also the high spatial frequencies
of the loading points are filtered out. In principle this will imply the
necessity of a processing mask, but as we will see the XtremeFringe® methods
can deal with this problem automatically.
Once the fringe pattern is
normalized we can use the XtremeFringe® DemIQT
function to demodulate automatically the phase. This function can work without
mask and the only parameter we use is the normalized fringe pattern. The
function returns the wrapped phase and its modulation information
[wPhi, wMod]=DemIQT(IN); figure; imagesc(wPhi); colormap gray; axis equal; title('wrapped phase');

Note that the phase has
been demodulated correctly even in the presence of the broken fringes near the
loading points and the big areas with no fringe pattern at the sides of the
image.
Finally, if we need the
continuous phase we must unwrap the phase returned by DemIQT.
This can be done with the XtremeFringe® PUMD function. As before, we do not
have a processing mask so we must process the whole phase map.
uPhi=PUMD(wPhi);
figure; imagesc(uPhi); colormap jet; colorbar; axis equal; title('unwrapped phase');

As can be seen, even in the
presence of broken fringes and areas without phase information, the phase map
has been correctly unwrapped.
figure; imagesc(I); colormap gray; title('fringe pattern');
figure; imagesc(IN); colormap gray; title('normalized fringe pattern');
figure; imagesc(wPhi); colormap gray; title('wrapped phase');
figure; imagesc(uPhi); colormap jet; colorbar; axis equal; title('unwrapped phase');
figure; imagesc(cos(uPhi)); colormap gray; title('cosine of unwrapped phase');




