# Tunable Beam Splitter Based on Acoustic Binary Metagrating
## 2 Materials and Methods
It should be noted that in our proposal, the two-dimensional system is the \(x\)-\(z\) plane [see Figure 2a], whereas in the numerical model of COMSOL Multiphysics, the two-dimensional system is the \(x\)-\(y\) plane [see Figure 3]. Thus, the magnetic field (0, 0, 1) in the numerical model corresponds to (0, 1, 0) in our proposal, i.e., \(H_{y}=~{}1\). The angle of incidence is set as 0 (normal incidence). Two diffraction orders are added at this port with the in-plane vector of \(m=-1\) and \(m=1\). The left and right boundaries are set as the period condition, with the Floquet periodicity from the periodic port. The bottom boundary is set as the perfect electric conductor, which is analogous to the sound hard boundary in acoustics [20; 21; 22]. The reflection as a function of the ratio \(t/a\) in the case of \(a=1.4\lambda_{0}\) is calculated and shown in Figure 2b. The reflection as a function of the ratio \(t/a\) in the case of \(a=1.8\lambda_{0}\) is calculated and shown in Figure 2c. In the two cases, it is noted that when \(t/a=0.5\) (marked by the red arrows), there are \(R_{0}=~{}0\) and \(R_{-1}=~{}R_{1}=~{}0.5\), which correspond to the beam splitting. When a given acoustic wave (normal incidence of \(\theta_{i}=~{}0\)) arrives at the ABM, it is split into two predesigned directions of the diffracted waves of \(n=-1\) (split beam 1, \(-x\) direction) and \(n=1\) (split beam 2, \(+x\) direction), and the specular reflection of the diffracted wave of \(n=0\) is totally suppressed. In other words, when the widths of the element \"0\" and the element \"1\" are equal to each other, the beam splitting occurs. Such a structure can be demonstrated by the general grating theory. When the acoustic waves impinge on the ABM with the incident angle of \(\theta_{i}\), the total pressure field above the ABM can be expressed as [1; 3; 8]:  
\[P_{1}(x,z)~{}=~{}e^{-\beta_{0}x\sin\theta_{i}}e^{\beta_{0}z\cos\theta_{i}}+~{} \sum_{n}r_{n}e^{-j(k_{0}\sin\theta_{i}+nG)x}e^{-jk_{z,n}z} \tag{15}\]  
where \(r_{n}\) is the reflection coefficient of the \(n\)-th order diffracted waves. \(k_{z,n}=\sqrt{k_{0}^{2}~{}-~{}\left(k_{0}\sin\theta_{i}+nG\right)^{2}}\) is the wave number component in the \(z\) direction for the \(n\)-th order diffracted waves. The pressure field in the grooves can be expressed as the superposition of the waveguide modes as:  
\[P_{2}(x,z)~{}=~{}\sum_{m}H_{m}\mathrm{cos}\,\alpha_{m}x[e^{~{}j\beta_{m}x}+e^ {~{}-j\beta_{m}(z+2d)}] \tag{16}\]  
Figure 3: The numerical model to calculate the reflection of the diffracted waves of \(n=0\), \(n=-1\), and \(n=1\) as a function of the ratio \(t/a\) performed using the COMSOL Multiphysics electromagnetic waves module. where \(H_{m}\) is the amplitude of the \(m\)-th order waveguide mode. \(\alpha_{m}=m\pi/t\) and \(\beta_{m}=\sqrt{k_{0}^{2}}~{}-~{}\alpha_{m}^{2}\) are the wave number component of the \(m\)-th waveguide mode in the \(x\) and \(z\) directions, respectively. The velocity fields are then obtained from \(v_{z}=\frac{j}{\rho\omega}\frac{\partial p}{\partial z}\). Here, \(\rho\) and \(\omega\) are the mass density of the air and the angular frequency of the waves, respectively. By using the continuum condition for the pressure field \(P\) and the surface-normal velocity field \(v_{z}\) at the interface \(z=0\), the following equations relating the coefficients \(r_{n}\) and \(H_{m}\) can be obtained:  
\[ \begin{array}{c}\int_{0}^{t}e^{-j\omega_{0}x\sin\theta_{i}}\mathrm{cos}\, \alpha_{m}xdx+\sum\limits_{n}\int_{0}^{t}r_{n}e^{-j(k_{0}\sin\theta_{i}~{}+~{} nG)x}\mathrm{cos}\,\alpha_{m}xdx\\ =\sum\limits_{m}H_{m}[1~{}+~{}e^{-2j\beta_{m}d}]\int_{0}^{t}\mathrm{cos}\, \alpha_{m}x\,\mathrm{cos}\,\alpha_{m}xdx\end{array}  \tag{17}\]  
and:  
\[