Introduction

Wannier functions are real-space representations derived through unitary transformations of corresponding extended Bloch functions as the eigenstates of a periodic system1. WFs have found widespread applications in physics, chemistry, and material sciences, enabling the analysis of material properties in terms of chemical bonding and facilitating high-accuracy calculations2,3. Topological invariants can be directly calculated by integrating Berry connection or Berry curvature derived from WFs4, or by calculating the integral of the Chern-Simons 3-form over a closed 3-dimensional space5,6. It is noteworthy that WFs are not eigenfunctions of the system, and their definition exhibits non-uniqueness due to the phase indeterminacy of Bloch functions at each wave vector within the Brillouin zone. Additionally, it is not always possible to construct a set of exponentially localized WFs (Wannier Obstruction). The chosen set of phases attached to the Bloch functions in the unitary transformation directly leads to topologically distinct phases bound to the localization characteristics of the WFs.

From a practical point of view, the knowledge of the WFs and localized modes provides optimized design and material choices in quasi-periodic structures such as periodically poled lithium niobate (PPLN). Localized modes can possess different effective refractive indices than the bulk propagating modes; therefore, their presence, even if weak, can subtly alter the overall phase matching conditions7. Localized electromagnetic modes where material properties change abruptly can work as a source of solitons, which can lead to new device concepts such as photonic diodes or tunable elements based on domain wall interactions8. Bound states in the continuum, which are perfectly confined modes with energies within the continuous spectrum of radiating waves, can be engineered for extremely high Q-factors and strong field enhancements, potentially boosting nonlinear efficiency9.

Marzari and Vanderbilt developed a method that minimizes the spread of the functional, so-called method of “maximally localized Wannier function”10. This iterative minimization process optimizes the unitary transformation that maps Bloch states to WFs, applicable both to degenerate higher-order and to isolated bands. Beyond their established relevance in electronic band structure analysis, applying WFs to investigate perfect photonic crystal (PhC) structures has been extensively studied. Leung et al. pioneered their application in photonics in 1993, employing vector WFs to study PhCs11. This initial work spurred a series of investigations focused on many different types of PhCs12,13,14,15,16,17,18. Subsequently, various methodologies have been explored to obtain WFs, especially in 1-dimensional (1D) geometries using exponentially localized WFs utilizing coupled-mode theory and symmetry-based determination of Bloch phases19. A system of algebraic equations in eigenform was exploited20. Recently, the transfer matrix method, which is more computationally efficient21, have successfully applied to obtain WFs for photonic structures with inversion symmetry22, with a symmetry-preserving substitutional defect23.

This paper presents a successful construction of localized light states and exponentially localized WFs for defective one-dimensional PhCs with broken crystalline translational symmetry. In the context of 1D photonic crystal defects, which are generally point-defects inducing local structural imperfections, they can be further categorized as symmetry-preserving and symmetry-disrupting structural defects, based on their presence within the lattice. The defects we chose represent local structural perturbations that disrupt the translational symmetry of the otherwise perfect crystal lattice: (1) an increased thickness of a single low-index layer (e.g., glass or air), (2) an increased thickness of a single high-index layer, effectively mimicking a junction between two high-index layers, and (3) a different material embedded at some point between two unit cells mimicking the presence of some impurity. We take an exemplary and well-established electric permittivity value of 12.9, representing Si or GaP at around 750 nm (~ 400 THz) under room temperature, which is commonly used for conventional electronics and photonics. We note that changing materials does not change the physics or analytic nature of the remaining argument. To capture the WF characteristics, we analyze photonic lattices with a half-period lattice shift as representations of the perfect crystal geometries corresponding to each defect lattice. The expansion of localized modes within both lattices is numerically computed and compared with results obtained via transfer matrices. The exponentially localized WFs for the defect crystals are obtained using transfer matrices with deliberately chosen initial Bloch states depending on the defect lattice site. We also obtained the magnetic fields, using a commercial electromagnetic simulator to validate the spatial distribution and localization characteristics as a function of photonic band index. Interestingly, these real-space magnetic fields and the obtained WFs showed good similarities in the lowest lying bands, even though they originate from different mathematical formulations. We also observed that they tend to show deviated features with increasing band indices.

Review of the construction of photonic Wannier functions for perfect crystals

The behavior of light inside a non-magnetic PhC is described by the following wave equations of magnetic field \(\mathbf{H}\left(\mathbf{r}\right)\) or electric field \(\mathbf{E}\left(\mathbf{r}\right)\):

$$\varvec{\nabla} \times \left[\frac{1}{\varepsilon \left(\mathbf{r}\right)} {\varvec\nabla} \times \mathbf{H}\left(\mathbf{r}\right)\right]={\left(\frac{\omega }{c}\right)}^{2}\mathbf{H}\left(\mathbf{r}\right),$$
(1)
$${\varvec\nabla} \times {\varvec\nabla} \times \mathbf{E}\left(\mathbf{r}\right)={\left(\frac{\omega }{c}\right)}^{2}\varepsilon \left(\mathbf{r}\right)\mathbf{E}\left(\mathbf{r}\right),$$
(2)

where \(c\) is the speed of light and \(\varepsilon \left(\mathbf{r}\right)\) is the material permittivity as a function of space \(\mathbf{r}\). For a periodic lattice where \(\varepsilon \left(\mathbf{r}+a\right)=\varepsilon \left(\mathbf{r}\right)\) with lattice period \(a\), one may readily apply the Bloch theorem and get the fields in the form of Bloch functions given by,

$${\mathbf{H}}_{j,k}\left(\mathbf{r}\right)={\text{e}}^{\text{i}\mathbf{k}.\mathbf{r}}{{\mathbf{u}}^{H}}_{j,k}\left(\mathbf{r}\right),$$
(3)
$${\mathbf{E}}_{j,k}\left(\mathbf{r}\right)={\text{e}}^{\text{i}\mathbf{k}.\mathbf{r}}{{\mathbf{u}}^{E}}_{j,k}\left(\mathbf{r}\right),$$
(4)

where \({{\mathbf{u}}^{H}}_{j,k}\left(\mathbf{r}\right)\) and \({{\mathbf{u}}^{E}}_{j,k}\left(\mathbf{r}\right)\) are the Bloch functions of band \(j\) with wave vector \(\mathbf{k}\) within the first Brillouin zone \([-\frac{\pi }{a},\frac{\pi }{a}]\). Bloch functions are periodic in real-space i.e., \({\mathbf{u}}_{j,k}\left(\mathbf{r}\right)={\mathbf{u}}_{j,k}\left(\mathbf{r}+a\right)\) as well as periodic in momentum-space i.e., \({\mathbf{u}}_{j,k+2\pi /a}\left(\mathbf{r}\right)={\mathbf{u}}_{j,k}\left(\mathbf{r}\right)\).

The same electromagnetic fields can be expanded in the form of the Fourier series,

$${\mathbf{H}}_{j,k}\left(\mathbf{r}\right)={\sum }_{n}{\text{e}}^{\text{i}kna}{{{\varvec{w}}}^{H}}_{j,n}(\mathbf{r}). \, {\mathbf{E}}_{j,k}\left(\mathbf{r}\right)={\sum }_{n}{\text{e}}^{\text{i}kna}{{{\varvec{w}}}^{E}}_{j,n}(\mathbf{r})$$
(5)

where n is the unit cell index, and the Fourier coefficient \({{\varvec{w}}}_{j,n}(\mathbf{r})\) is the WF of jth band and nth cell. Inverse Fourier transform leads that the corresponding magnetic and electric WFs are simply,

$${{\varvec{w}}}_{j}^{H}\left(\mathbf{r}\right)=\frac{a}{2\pi }{\int }_{-\pi /a}^{\pi /a}{\mathbf{H}}_{j,k}\left(\mathbf{r}\right)dk, \, {{\varvec{w}}}_{j}^{E}\left(\mathbf{r}\right)=\frac{a}{2\pi }{\int }_{-\pi /a}^{\pi /a}{\mathbf{E}}_{j,k}\left(\mathbf{r}\right)dk.$$
(6)

where \({{\varvec{w}}}_{j,n}\left(\mathbf{r}\right)={{\varvec{w}}}_{j}(\mathbf{r}-n\text{a})\).

Smoothly varying Bloch functions for each photonic band over the Brillouin zone can be obtained by choosing the initial phases for the best localization of the WFs. We assume the entire medium is polarized in a single direction; thus, we consider the electromagnetic fields to be z-polarized, i.e., the layer stacking direction as shown in Fig. 1a. Then we can write the magnetic fields as \(\mathbf{H}(\mathbf{r})={H}_{0}\sqrt{a}h\left(z\right)\widehat{y}\), where \({H}_{0}\) is the characteristic field amplitude, \(h\left(z\right)\) is the magnetic-field profile with a dimension of probability density, and \(\sqrt{a}\) is the normalization factor. Also, the electric fields are expressed as, \(\mathbf{E}(\mathbf{r})=\frac{{-iH}_{0}\sqrt{a}f\left(z\right)\widehat{x}}{c{\varepsilon }_{0}}\) , where \(f\left(z\right)=\frac{h^{\prime}(z)c}{\omega \varepsilon (z)}\) with \(h^{\prime}(z)\) as the first derivative of \(h(z)\) in z. Notably, \(f\left(z\right)\) has the same physical dimension as \(h\left(z\right)\) and satisfies the Bloch conditions as well.

Fig. 1
figure 1

(a) The schematic representation of the two perfect PhC lattices L1 and L2 with identical lattice period \(a\) where L2 is \(a\)/2 shifted from L1. The red dashed arrow denotes the \(z\) = 0 point. \({d}_{A}\) and \({d}_{B}\) are the individual layer thicknesses. (b) The transmission spectrum of the finite PhC lattice. (c) The variation of the elements of \(M\left(\omega \right)\) as a function of normalized frequency. The shaded regions enclosed within the ± 1 range correspond to the four photonic bands associated with the first Brillouin zone.

We can construct transfer matrices for a stratified periodic medium with interfaces requiring continuity of the fields. Equations (1) and (2) can be written in matrix form as a first-order differential equation, considering the propagation of light in the z-direction only:

$$\frac{d}{dz}\left(\begin{array}{c}h\left(z\right)\\ f\left(z\right)\end{array}\right)=\left(\begin{array}{cc}0& \varepsilon \left(z\right)\frac{\omega }{c}\\ -\frac{\omega }{c}& 0\end{array}\right)\left(\begin{array}{c}h\left(z\right)\\ f\left(z\right)\end{array}\right).$$
(7)

Now we solve the field values \(\left(\begin{array}{c}h\left(z\right)\\ f\left(z\right)\end{array}\right)\) of Eq. (7) at discretized points in real-space along the z-direction.

Thus, one may write,

$$\left(\begin{array}{c}h\left(z\right)\\ f\left(z\right)\end{array}\right)=T\left(\omega ,z,{z}_{0}\right)\left(\begin{array}{c}h\left({z}_{0}\right)\\ f\left({z}_{0}\right)\end{array}\right),$$
(8)

where \(T(\omega ,z,{z}_{0})\) is the transfer matrix at frequency \(\omega\) to evaluate the field values on translating from \({z}_{0}\) to \(z\) such that \({z}_{0}<z\). The discretized \(z\)-points should be such that the permittivity remains the same during the field propagation. Also, the field continuity across the material interfaces drops the requirement of interface matrices. The transfer matrix simplifies to \(T\left(\omega ,z,{z}_{0}\right)={T}_{N}.{T}_{N-1}\dots {T}_{2}.{T}_{1}\) with \(N\) number of discretized points between \({z}_{0} \text{and} z\), which is also true for \({z}_{0}>z\) provided propagation is from right to left. Therefore, within the lattice period \(a\) one may write,

$$M\left(\omega \right)=T\left(\omega ,a,0\right)={T}_{B}\left(\omega ,{d}_{B}\right)\cdot {T}_{A}\left(\omega ,{d}_{A}\right).$$
(9)

\(M\left(\omega \right)\) gives the field values over a single unit cell and thus is solved to get the relation between \(\omega\) and \(k\) as \(m\left(\omega \right)=\mathit{cos}\left(ka\right)\) where \(m\left(\omega \right)\) is the semi-trace of the matrix \(M\left(\omega \right)\). Eventually, the solution to \(m\left(\omega \right)\) leads to an infinite set of functions \({\omega }_{j}\left(k\right)\) for each band denoted by \(j\) and each wave vector \(k\) in the first Brillouin zone \([-\frac{\pi }{a},\frac{\pi }{a}]\) and form the photonic band structure of the crystal. The magnetic and the electric Bloch functions corresponding to each solution \({\omega }_{j}\left(k\right)\) are denoted by \({h}_{j,k}\left(z\right)\) and \({f}_{j,k}\left(z\right)\), respectively, which satisfy the orthonormal conditions.

Using the set of Eqs. (5) and (6), one may express the magnetic and the electric WFs for a particular photonic band \(j\) as,

$${w}_{j}^{\left(h\right)}\left(z\right)=\frac{a}{2\pi }{\int }_{-\frac{\pi }{a}}^{\frac{\pi }{a}}{h}_{j,k}\left(z\right)dk,$$
(10)

and

$${w}_{j}^{\left(f\right)}\left(z\right)=\frac{a}{2\pi }{\int }_{-\frac{\pi }{a}}^{\frac{\pi }{a}}{f}_{j,k}\left(z\right)dk,$$
(11)

respectively. They also satisfy the orthonormalization condition as is given by,

$$\mathop \smallint \limits_{ - \infty }^{ + \infty } \left[ {w_{j,n}^{\left( h \right)} \left( z \right)} \right]^{*} w_{{j^{\prime } ,n^{\prime } }}^{\left( h \right)} \left( z \right)dz = \delta_{{j,j^{\prime } }} \delta_{{n,n^{\prime } ,}}$$
(12)
$$\mathop \smallint \limits_{ - \infty }^{ + \infty } \left[ {w_{j,n}^{\left( f \right)} \left( z \right)} \right]^{*} w_{{j^{\prime } ,n^{\prime } }}^{\left( f \right)} \left( z \right)\varepsilon \left( z \right)dz = \delta_{{j,j^{\prime } }} \delta_{{n,n^{\prime } }} .$$
(13)

For a perfect (without defect) PhC, \({h}_{j,k}\left(z\right)\) and \({f}_{j,k}\left(z\right)\) satisfy two different eigenvalue problems. For magnetic fields, the eigenvalue equation \({h}_{j,k}\left(z\right)\) should satisfy,

$${\widehat{O}}^{p}{h}_{j,k}\left(z\right)=\frac{{\omega }_{j}^{2}(k)}{{c}^{2}}{h}_{j,k}\left(z\right),$$
(14)

where the operator \({\widehat{O}}^{p}=-\frac{d}{dz}\frac{1}{\varepsilon (z)}\frac{d}{dz}\) is Hermitian under the Bloch condition, and \(\varepsilon \left(z\right)\) is the permittivity of the perfect PhC. Similarly, the magnetic field profile \(h\left(z\right)\) of each localized mode in the defect PhC satisfies the eigenvalue problem,

$${\widehat{O}}^{d}h\left(z\right)=\frac{{\omega }^{2}}{{c}^{2}}h\left(z\right)$$
(15)

where \({\widehat{O}}^{d}=-\frac{d}{dz}\frac{1}{{\varepsilon }^{d}(z)}\frac{d}{dz}\) and \({\varepsilon }^{d}(z)\) is the permittivity of the defect PhC usually expressed as, \({\varepsilon }^{d}\left(z\right)=\varepsilon \left(z\right)+\delta \varepsilon (z)\). The solutions of Eq. (15) can be expanded based on the magnetic WFs of the perfect PhC as given by,

$$h\left(z\right)=\sum_{j,n}{q}_{j,n}{w}_{j,n}^{h}\left(z\right)=\sum_{j,n}{q}_{j,n}{w}_{j}^{h}\left(z-na\right),$$
(16)

where \({w}_{j}^{h}\left(z-na\right)\) is the magnetic WFs of the band index \(j=\text{1,2},3,\dots\) and unit cell index \(n=0,\pm 1,\pm 2,\dots\) as obtained from Eq. (10), and \({q}_{j,n}\) are the coefficients. Substituting Eq. (16) into Eq. (1), we get the tight-binding representation of the wave equation for the magnetic fields based on WFs that can be expressed in the matrix form as:

$$\mathop \sum \limits_{{j^{\prime } ,n^{\prime } }} O_{{\left( {j,n} \right),\left( {j^{\prime } ,n^{\prime } } \right)}}^{d} q_{{j^{\prime } ,n^{\prime } }} = \frac{{\omega^{2} }}{{c^{2} }}q_{j,n} ,$$
(17)

with \({O}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})}^{d}\) having two parts—one part contains the on-site energy terms accounting for the WFs of the same energy bands and the other part accounts for the hopping parameters between WFs of different bands and cells. The coefficient matrix of Eq. (17) can be written as,

$${O}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})}^{d}={O}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})}^{p}+{W}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})},$$
(18)

where

$${O}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})}^{p}=\left[\frac{a}{\pi }\sum_{k=0}^{\pi /a}{(\frac{{\omega }_{j,k}}{c})}^{2}\text{cos}[(n-{n}^{\prime})ka]\right]{\delta }_{j,{j}^{\prime}},$$
(19)

and

$${W}_{\left(j,n\right),\left({j}^{\prime},{n}^{\prime}\right)}=\underset{-\infty }{\overset{\infty }{\int }}\left[{\left[\frac{d}{dz}{w}_{j}^{h}\left(z-na\right)\right]}^{*}\left[\frac{d}{dz}{w}_{{j}^{\prime}}^{h}\left(z-{n}^{\prime}a\right)\right]\left(\frac{1}{{\varepsilon }^{d}\left(z\right)}-\frac{1}{\varepsilon \left(z\right)}\right)\right]dz.$$
(20)

Equation (19) accounts for the onsite energies for each band at each cell, whereas Eq. (20) accounts for the inter-cell couplings. Solutions of Eq. (17) readily give us the coefficient matrix \({q}_{j,n}\) which when plugged into Eq. (16) and summed over all the cells and bands, results in the localized modes.

Results and discussions

Magnetic Wannier functions of a binary photonic crystal

First, we construct WFs of a perfect crystal with a lattice period \(a=\) 1 µm, made of two different materials: one with a high index layer with permittivity \(\varepsilon =\) 12.9, denoted by A, and with thickness dA = 0.5 µm, and the other one with a low index of permittivity \(\varepsilon =\) 1, denoted by B, with layer thickness dB = 0.5 µm. For the wavelength region considered here, various transparent materials such as glasses have permittivity values close to 1. Then this structure works as a transmissive high-contrast notch filter or Raman filter in the wavelength region from the visible to the near-infrared. The two layers indicated by the red dashed arrow are shown as L1 or L2 in Fig. 1a, depending on the choice of the origin. Then L2 simply becomes the lattice with + \(a\)/2 shifted along the z-direction to L1.

The transmission spectrum of a finite lattice of the chosen 1D PhC can be calculated by the transfer matrices. The first four transmission bands on a normalized frequency scale are depicted in Fig. 1b. The regions with maximum transmission denote the band positions, whereas the minimum transmission regions correspond to the bandgaps. Since the a/2 lattice shift keeps the transmission bands unaffected, Fig. 1b shows the same for both L1 and L2 PhCs.

The magnetic WFs of the two perfect lattices L1 and L2 can be obtained from the Bloch functions in Eq. (10). Since the Bloch functions are determined up to a \(k\)-dependent phase, the WFs are also not unique. To impose uniqueness on the WFs, one could choose the phases of the Bloch functions according to the iterative procedure for only real and maximally localized WFs10. Instead, we use a more computationally efficient method described in the literature21 to obtain a set of not maximally, but exponentially localized WFs, which is also more suitable for constructing WFs dealing with absorptive materials.

Owing to the local inversion symmetry of the PhC, Eq. (9) becomes \(M\left(\omega \right)={T}_{B}\left(\omega ,{d}_{B}/2\right)\cdot {T}_{A}\left(\omega ,{d}_{A}/2\right)\) and the four matrix elements \({M}_{ij}\) as a function of frequency \(\omega\) are shown in Fig. 1c. The initial Bloch functions can be set from the zeros of Eq. (9) transfer matrix elements, where the field values are evaluated over half-lattice period (\(a\)/2) instead of the whole unit cell. The zeros of \({M}_{ij}\) indicate the band edges, and the photonic bands belong to the range ± 1; the shaded regions are the four photonic bands corresponding to the bands shown in Fig. 1b. The band edges corresponding to the vanishing \({M}_{ij}\) classify the bands in four types—there are two Г (\(k=0\)) point types based on the zero of \({M}_{21}\) or \({M}_{12}\) with even and odd symmetry of the Bloch function, respectively; similarly, the X (\(k=\pi /a\)) point indicates two band edges based on the zeros of \({M}_{11}\) or \({M}_{22}\) with even and odd symmetry, respectively.

We set the initial field values with \({M}_{21}=0\), \({h}_{j,k}\left({z}_{0}\right)=\sqrt{-\frac{{M}_{12}(\omega ,{z}_{0})}{{\beta }_{k}}}\), \({f}_{j,k}\left({z}_{0}\right)=\frac{{\alpha }_{k}{h}_{j,k}\left({z}_{0}\right)}{{M}_{12}{M}_{pp}}\), and with \({M}_{12}=0\), \({f}_{j,k}\left({z}_{0}\right)=\sqrt{\frac{{M}_{21}(\omega ,{z}_{0})}{{\beta }_{k}}}\), \({h}_{j,k}\left({z}_{0}\right)=\frac{{\alpha }_{k}{f}_{j,k}\left({z}_{0}\right)}{{M}_{21}{M}_{pp}}\) with \({\alpha }_{k}=i\text{sin}\left(ka\right)/2\), \({\beta }_{k}=cm^{\prime}(\omega )/2\) where \(m\left(\omega \right)=\text{cos}(ka)\), and \(p=1, 2\) according to the X point type. \({z}_{0}\) can be either the inversion center of A layer or that of B layer. Also, the particular choice of initial \({h}_{j,k}\left({z}_{0}\right)\) introduces a factor of \(\sqrt{a}\) in the denominator leaving the generally dimensionless \({h}_{j,k}(z)\) with the dimension of probability density.

The magnetic WFs of the first four photonic bands of the L1 lattice are shown in Fig. 2. The magnetic WFs obtained by employing the above initialization formulas are real and exponentially localized. The \(z\) = 0 denotes the junction of layers A and B. The centers of the WFs (denoted by the red dashed line in Fig. 2) are shifted according to the lattice geometry. For example, the Wannier center of the first photonic band (\(j=1\)) is moved to the left of \(z\) = 0, whereas that for the second band (\(j=2\)) is shifted to the right. Such a shift of the Wannier center is also notable for other bands. The magnetic WFs’ symmetry and the Wannier centers’ location depend on the band type and the initial field values. Here, the first, second, and fourth bands show even WFs, whereas the WF of the third band has an odd symmetry. The WFs of the first four bands for the L2 lattice are identical to those of the L1 lattice, as shown in Fig. 2, except that the Wannier centers are readjusted according to the lattice construction. These two perfect lattice geometries lead us to precisely capture the features of the WFs in the following defective crystal, breaking translational symmetry.

Fig. 2
figure 2

Magnetic Wannier functions of the first four bands of the L1 lattice. The red dashed line denotes the center of the Wannier functions, which are shifted across the \(z=0\) position according to the lattice type. The grey-shaded regions denote the high index layer A.

Defective photonic crystals: localized states, Wannier functions, and magnetic fields

Now we introduce two structural defects with broken crystalline translational symmetry, as shown in Fig. 3a. One defect lattice constitutes a doubled thickness of a single layer B between two layers of A, and we name it the ABBA defect lattice. In this case, the B layer between A and B can be regarded as a defect layer. The other option has a single layer A with doubled thickness between two layers of B, and we denote it as the BAAB lattice. For the same reason, the A layer between the A and B layers can be regarded as a defect layer. We can always choose the origin \(z=0\) position at the center of the defects. Such structural defects can be regarded as point defects that occur at a single site, leading to the electromagnetic wave localization like a photonic dopant. Then, a single defect level should appear in a transmission or an absorption spectrum within the bandgap of the PhC.

Fig. 3
figure 3

(a) The schematic of the two photonic crystals with the structural defect. The upper panel shows the defect lattice with a doubling of the thickness of layer B across the \(z=0\) position, thus we denote this lattice as ABBA. The lower panel shows the second defect lattice with a doubling of the thickness of layer A across the \(z=0\) position; we denote this lattice as BAAB. The defect states (enclosed in the dashed box) of (b) ABBA lattice and (c) BAAB lattice in the first photonic bandgap are shown in the transmission spectra as obtained from the finite lattice transfer matrix calculation.

We calculated the transmission spectra of the ABBA and BAAB lattices with 30 unit cells as shown in Fig. 3b, c, respectively. The first photonic bandgap is formed between 290 and 495 THz. These show the two different defect configurations (enclosed in the dashed box) within the photonic bandgaps, emulating doping energy levels in the electronic band structures of typical semiconductors. For the ABBA lattice, the defect level is close to the higher band edge, like a lightly doped n-type defect. For the BAAB lattice, on the other hand, the defect energy level lies around 332 THz, which forms a red-shifted transmission peak from the center of the photonic bandgap, resembling a heavily doped p-type semiconductor.

Let us consider the BAAB lattice first. The magnetic fields \(h(z)\) s at the frequencies obtained from transmission spectra can be obtained by constructing transfer matrices as described in the previous section. The green solid curve in Fig. 4a shows the magnetic mode in the first bandgap of the BAAB. Here, the field was normalized with the initial choice of \(h\left({z}_{0}\right)=1, f\left({z}_{0}\right)=0\). The resultant magnetic field shows a good localized nature at the defect layer.

Fig. 4
figure 4

The magnetic field of the localized modes of (a) BAAB and (c) ABBA crystals with a defect in the first photonic bandgap. The green solid lines are the curves obtained from the transfer matrices, and the dashed lines are the results obtained from the expansion of the WFs of the counterpart perfect lattices. The grey-shaded regions denote the high index layer A. The convergence of the localization frequency with an increasing number of unit cells N with WFs of 4 bands is shown for (b) BAAB and (d) ABBA, where the grey line indicates the exact frequency obtained from direct calculation.

Now we construct the localized magnetic field of the same BAAB lattice from the WFs of L1 perfect PhC using Eq. (16). We obtained the field by expanding it in terms of WFs of the first 4 bands with 59 unit cells i.e., \(j=\text{1,2},\text{3,4}\) and \(n=0,\pm 1,\pm 2, \dots , \pm 29\). As a result, a total of 236 matrix elements in \({O}_{\left(j,n\right),({j}^{\prime},{n}^{\prime})}^{d}\) was used. The blue dashed curve in Fig. 4a is the magnetic field obtained in this way and overlaid on top of the magnetic fields \(h(z)\) from transfer matrices. Both the magnetic fields show good agreement, which reveals a good accuracy in estimating the localized modes induced by the A defect. We note that this coincidence is physically reasonable, although the magnetic fields and the magnetic WFs originate from different mathematical backgrounds. We will discuss later.

We note that the localized magnetic modal frequency obtained from Eq. (17) is around 326 THz, slightly red-shifted from the exact value. This frequency shift can be understood as the truncation of the z-space to |Na| where N is the number of unit cells. A larger set of WFs yields the closest agreement, but at the expense of increased computational effort. Notably, the estimation of Eq. (20) for the inter-cell coupling terms is the most important in our geometries, where the defect is breaking the lattice’s translational symmetry, and a truncated set of WFs is used instead of its original limit to infinity.

For a substitutional defect without breaking translational symmetry, one may choose only two unit cells across the \(z=0\) position, i.e., with the derivative of WFs from \(-a\) to \(a\) (as shown by red dashed lines in Fig. 3) to reduce the computational efforts23. However, with broken translational symmetry, which is the insertion of another layer that practically shifts all the layers after the defect from their original positions, one should include the change in refractive index over the whole region. This summation (or numerical integration) can be effectively performed by trying several larger spatial domains instead of summing up over the entire z-space. However, this significantly affects the convergence of the localized mode frequency calculation and its asymptotic behavior as a function of the number of unit cells.

Figure 4b shows the change of mode frequency obtained from the WF expansion approach as a function of the number of unit cells N, satisfying \(z\le |Na|\). We obtained the localized modes and the corresponding frequencies between N = 14 and 29, i.e., from 29 to 59 unit cells in total, with magnetic WFs of 4 bands. The size of the truncated set of WFs affects the calculation of Eq. (20). Therefore, the frequency approaches asymptotically towards the exact mode frequency (the gray straight lines) obtained from the transfer matrix calculation, with an increase in the number of unit cells.

Similarly, we obtained the magnetic field \(h(z)\) of the localized mode for the ABBA defect lattice. The green solid curve in Fig. 4c is the magnetic field obtained from the transfer matrices at localization frequency 477 THz. The red dashed curve is the same mode obtained from the expansion of the WFs of the L2 perfect crystal. The magnetic WFs of the first 4 bands (as shown in Fig. 2) and 59 unit cells were also chosen. The summation of Eq. (20) was done over the whole domain. The mode frequency obtained from the expansion method is approximately 471 THz, slightly lower than that obtained from direct calculation. Figure 4d shows the modal frequencies as a function of the number of unit cells, which asymptotically approach 471 THz with increasing number of unit cells.

The WFs with a higher number of photonic bands and a smaller number of unit cells tend to slow down the convergence, and we also observed a similar tendency in23. The \(h(z)\) field profile obtained from the expansion of the first 6 photonic bands and 29 cells of the perfect crystal has lower convergence compared to the results shown in Fig. 4. Moreover, during the expansion, one may choose the WFs that are of the same symmetry as the localized mode for a faster convergence without loss of any generality. This comes from the fact that the WFs are associated with some weightage of their contribution to the expansion process. This weightage can be estimated during the calculation, and the lowest contributing WFs can be removed from the expansion. It is notable to remark on the symmetry of the WFs. Generally speaking, the bands adjacent to the bandgap of the localized mode tend to contribute more to the calculation of the WFs. However, our results show that the localized mode of the defective lattice is still an asymmetric odd function, even though the WFs of the first and the second bands are even.

Employing the same technique, we studied the construction of a localized state that appears due to the presence of an impurity material within the PhC lattice. Figure 5a depicts the schematic of the defective lattice where a third material layer C is present within the L1 lattice, eventually breaking the translational and inversion symmetry locally. The refractive index of material C is considered slightly higher than the high-index layer of the PhC. Figure 5b shows the transmission spectrum of the defect lattice around the first photonic bandgap with the localized state at 320 THz indicated by the dotted box. Using the magnetic WFs of L1 lattice with the first 4 photonic bands and 57 unit cells, we construct the magnetic field of the localized state as shown in Fig. 5c (the blue dashed curve). The magnetic field component obtained from the transfer matrix approach is also shown in Fig. 5c (green solid) to compare with that from the WF expansion method. Also, the computed angular frequency is 323 THz, which is slightly higher than that obtained from the transfer matrix. This explicitly shows that the WF expansion method indeed has a wide applicability, irrespective of the type of lattice defects usually encountered in practice.

Fig. 5
figure 5

(a) The schematic of the defective PhC where a third high-index material C is embedded between two unit cells. The width of material C is equal to that of A and B. (b) The transmission spectrum of the defective lattice with the localized state in the first bandgap at 320 THz, shown by the brown dotted box. (c) The two magnetic fields of the localized state obtained from the transfer matrix (green) and WF expansion (blue dotted). The yellow strip shows the defective layer.

Further, we construct the WFs of the photonic bands for the two defect lattice configurations. Here, we employed the method of initial Bloch state fixation in transfer matrices to realize the exponential localization of the WFs. The initial choice of Bloch states depends on the defect site and the band index. The calculated magnetic WFs of the first 6 bands of the ABBA lattice geometry are shown as blue solid lines in Fig. 6. The unit of the WFs is probability density, assigned to the left y-axis. It is interesting to see how the WFs form a localized shape across the defect region. The magnetic WF of the first band (j = 1) of the ABBA lattice shows an even symmetry as observed in the case of the perfect crystal counterpart with the Wannier center shifted to \(z=0\). Interestingly, magnetic WFs of other bands, with \(j=\text{2,3},\text{4,5},6\) band indices have an inversion symmetry at \(z=0\). Moreover, only the third band shows an odd symmetry, whereas the second, fourth, fifth, and sixth bands show even symmetries. The Wannier centers of the first, fourth, fifth, and sixth bands appear to be nonzero at \(z=0\). However, those of the second and third bands are uncertain. As expected, all the functions are localized exponentially around the lattice center, aligning well with the fundamental concept of WFs.

Fig. 6
figure 6

The magnetic WFs (blue solid) of the first six bands of the ABBA defect lattice and the corresponding magnetic field components (green dashed) across the defect region. The grey-shaded areas denote the high index layer A.

Figure 7 shows the magnetic WFs of the first 6 bands of the BAAB lattice. Interestingly, the first band appears to have a very different feature compared to that of a perfect crystal. The magnetic WF of the first band exhibits a peak in the central high-index layer region with a very weak localization within the lattice, contrasting with the WF’s localization in the low-index region of its counterpart of the perfect PhC. However, the magnetic WFs of the second, third, fourth, fifth, and sixth bands are well localized at \(z=0\). The first, second, and fourth bands exhibit even symmetry, while the third, fifth, and sixth bands display odd symmetry at the lattice center.

Fig. 7
figure 7

The magnetic WFs (red solid) of the first six bands of the BAAB defect lattice and the corresponding magnetic field components (green dashed) across the defect region are calculated from a commercial electromagnetic simulation software (COMSOL Multiphysics). The grey-shaded areas denote the high index layer A.

We simulated the magnetic field components of the ABBA and BAAB lattices using a commercially available software (COMSOL Multiphysics®) and obtained the field distributions hy(z) across the defect region for different photonic bands. These results are shown as the green dashed lines in Figs. 6 and 7 after normalization with a unit on the right y-axis. We note that the magnetic WFs and the magnetic fields are actually Fourier transform conjugates, as shown from Eq. (16), meaning that they do not necessarily have the same spatial distribution. For the ABBA lattice, we find that the WFs across the defect region closely mimic the magnetic fields within the defect up to the band index j = 4, as shown in Fig. 6. However, this tendency of localization weakens for the magnetic fields of the fifth and sixth bands, whereas the magnetic WFs of the same bands still keep exponential localization. For the BAAB lattice, the normalized magnetic fields hy(z) and the WFs show excellent agreement for the lowest two bands, as shown in Fig. 7.

Even though the mathematical derivation of the classical electromagnetic fields and the quantum mechanical WF descriptions originates from entirely different backgrounds, the similarities between the magnetic fields and the magnetic WFs are not as surprising as in the perfect crystal cases. For perfect binary crystals without absorptive material, there are no localized magnetic fields. The electromagnetic fields over a certain volume represent the electromagnetic energy, whereas the WFs are regarded as electronic or photonic wave functions representing charges. With a single defect site, as in our case, the energy localization from the electromagnetic fields and charge localization from the WFs are likely to occur at the same defect site. However, our work explicitly shows that the meaningful similarities in spatial distribution only hold for low bands, and more discrepancies emerge with increasing band indices j. In the low-energy limit, WFs have been treated as the system’s eigenfunctions representing electric charges or orbitals. However, the characteristics of the WFs for higher bands should not be interpreted as the defect state’s eigenfunction.

We expect the analytically constructed photonic WFs of the lattices with more defects would lead to larger deviations from the electromagnetic fields across these defects. In principle, increasing the volume in the integration for WFs construction would always provide a solution, but the computational time also significantly increases with the power law. Even though our system is perfectly Hermitian, the inclusion of a single defect with broken translational symmetry leads to the breakdown of the Bloch theorem and its unitary Wannier counterpart. One of the plausible solutions to reduce these discrepancies may be to introduce a non-Bloch band formalism with a complexified description of the wave vector in higher dimensions24. Higher-dimensional formalism also becomes beneficial to extract topological behaviors for non-Hermitian or symmetry-deficient systems.

Summary and outlook

In this work, we successfully constructed the localized defect states and exponentially localized WFs of a defective crystal with broken crystalline translational symmetry. Two configurations of the defect lattices were considered, each with an increment of layer thickness either in a single high-index or a single low-index layer across the lattice center. Such structural defects inherently express the attributes of specific photonic structures, such as notch filters or Raman filters. Based on the magnetic WFs of the chosen perfect lattice geometries, the magnetic field of the localized modes in the first photonic bandgap was reconstructed for each defect lattice. We clarified all the symmetries of each WF and Wannier centers, revealing topologically trivial phases, up to the sixth photonic band for both lattices. The characteristics of the obtained magnetic WFs were compared with those obtained from the direct transfer matrix calculation and the magnetic fields obtained by a commercial electromagnetic simulator, as a function of band index.

Notably, this work focuses on a single aspect of the defect in 1D PhCs, which deals with the structural deformation that breaks the crystalline translational symmetry. Exploring other types of PhC defects, both structural and material-based, as well as investigating photonic topological crystals, could further enhance the understanding of WFs as a versatile and effective mathematical tool. It is even more interesting to figure out the topological conditions of Wannier obstruction with an increasing number of defects. The relation between the localized symmetric WFs and the topological phases associated with photonic bands provides a deeper understanding of the boundary modes25. The quantitative description of a localized mode in a structure like PPLN can lead to design tolerance and optimization to enhance the nonlinear process by overlapping high-intensity regions with the interacting waves in a controlled manner. We anticipate that the WFs of defective crystals will serve as a suitable basis for analyzing the quantum mechanical behavior of light near the defect and the topologically protected edge states.