
Research Article Applied Optics 2
images on the camera reveal the gradient of the incident wave-
front by its centroid drifts within the corresponding lenslet area
under the point source illumination as a guide star. However,
this conventional Shack-Hartmann (SH) scheme only represents
the wavefront at one designated field of angle, that is, the angle
of the guide star [
9
]. Besides, the averaged wavefront across the
isotropic zone is represented by the local shifts of the optical spot
images based on the two-photon laser descanning technique [
1
].
In addition, the averaged wavefront across the entire FOV can
also be calculated by the correlation between the subimages with
and without wavefront aberrations under extended source illu-
mination [
10
,
11
]. Similar to obtaining the averaged wavefront,
the difference is that the descanning technique adds all intensi-
ties of the subimages to improve the signal-to-noise ratio since
the fluorescence is very weak, while the correlation method uses
the subimages themselves. However, all these Shack-Hartmann
schemes cannot present a space-variant wavefront.
In this paper, we illustrate an SHWFS scheme to reconstruct
a space-variant wavefront with extended source illumination.
The affine transformation is used to evaluate subimage trans-
formation across the FOV which implies that the wavefront
changes slowly. Furthermore, the zonal and modal methods
that reconstruct the wavefront from the gradient map are both
upgraded to meet the requirement for space-variant wavefront
reconstruction. In particular, a dual-orthogonal model is pro-
posed to represent the space-variant wavefront function, and the
relation between the affine coefficients and the dual-orthogonal
coefficients is derived and used in the modal reconstruction.
Numerical simulations and imaging experiments are both im-
plemented.
2. THEORY
A. Space-variant wavefront function modal
First, let
φ(ξ,η)
denote the wavefront on a circular pupil in the
optical system while moderate enough to be well represented
by a sum of orthogonal polynomials
φ(ξ,η)=
P
∑
p=1
cpRp(ξ,η),(1)
where
(ξ,η)
are the global normalized lateral coordinates of the
pupil plane, or Fourier domain,
Rp(ξ,η)
are the
p
th orthogonal
polynomials
cp
and are the corresponding coefficients, e.g., the
Zernike polynomials
Zp(ξ,η)
for the circular domain or the
Legendre polynomials
Lp(ξ,η)
for the rectangular domain,
P
is
the maximum representation term for the pupil plane.
(x,y) (x,y)
(x,h)
Object
Plane
Image
Plane
Pupil
Plane
Fig. 1. Coordinates defined in the imaging system.
In the case of space-variant wavefront sensing, such as in
deep-tissue imaging, the wavefront varies along different po-
sitions. Mathematically, the constant coefficients
cp
in Eq. (1)
evolve into the space-variant function
cp(x
,
y)
, where
(x
,
y)
is
the lateral coordinates of the object and image plane, also nor-
malized to 1 for orthogonal representation, as shown in Fig. 1;
thus the magnification and the inversion of coordinates on object
and image planes are neglected.
Therefore, we define the space-variant wavefront,
φ(x,y,ξ,η)=
P
∑
p=1
cp(x,y)Rp(ξ,η).(2)
Similarly, we assume that the space-variant function
cp(x
,
y)
varies slowly; thus, the dual-orthogonal modal of the space-
variant wavefront function is given as
φ(x,y,ξ,η)=
Q
∑
q=1
P
∑
p=1
ep,qTq(x,y)Rp(ξ,η),(3)
where
cp(x,y)=
Q
∑
q=1
ep,qTq(x,y),(4)
and
Tq(x,y)
are the
q
th orthogonal polynomials,
ep,q
are the
corresponding coefficients, and
Q
is the maximum representa-
tion term for the pupil plane.. The purpose of our work is to
reconstruct the space-variant wavefront
φ(x,y,ξ,η)
by retriev-
ing the dual-orthogonal coefficients
ep,q
, as the modal method,
or discrete
φxm,yn,ξp,ηq
on position
xm,yn,ξp,ηq
, as the
zonal method.
B. Affine transformation estimation for evaluating the space-
variant function in Shack-Hartmann subapertures
In SH, the light field projects onto a microlens array and forges an
image on the back focal plane with a subimage array, as shown
in Fig. 2(a1-c1). For the scenario of the conventional space-
invariant wavefront, only one gradient vector is obtained from
subimages in one lenslet, as shown in Fig. 2(a2-b2). The centroid
shift or correlation algorithm, depending on which light source
is used, the point or extended, can be used for representing
the local slope. On the other hand, for sensing space-variant
wavefront, the subimages deform as shown in Fig. 2(c2), rather
than just translation, as shown in Fig. 2(b2). We used the affine
transformation to characterize the deformation of the subimages
in one lenslet
x2−x1
y2−y1
1
=
a1a2a3
b1b2b3
0 0 1
x1
y1
1
,(5)
where
(x1
,
y1)
is an arbitrary point on the
(x
,
y)
plane of the cor-
responding lenslet area since the back focal plane of the lenslet is
also the image plane,
(x2
,
y2)
is the coordinate after deformation,
as shown in Fig. 2(c2) and Fig. 3(a,b),
[x2−x1
,
y2−y1]T
presents
the centroid shift of point
(x1
,
y1)
, and
{a1
,
a2
,
a3
,
b1
,
b2
,
b3}
are
the coefficients of an affine transformation. The affine coeffi-
cients from all lenslets can reconstruct the dual-orthogonal coef-
ficients ep,qor discrete φxm,yn,ξp,ηq(details in Appendix).
Various approaches, such as intensity-based optimization,
control points, and feature detection and matching, can be used
to register images on many platforms. In this paper, the MAT-
LAB
®
internal function ‘imregtform’ is used to estimate affine
transformation coefficients, in which the image similarity metric
is optimized during registration.
3. NUMERICAL SIMULATIONS
In this section, the numerical simulations in space-variant Shack-
Hartmann wavefront sensing are given as the simulation config-
uration, the forward process of image formation, and wavefront
reconstruction based on zonal and modal methods.