# Sub-Terahertz Computer Generated Hologram with Two Image Planes
## 2 Results  
In order to obtain good quality image reconstruction, firstly, we should carry out a proper design process. Thus, in this article, we decided to use an iterative method of calculating hologram phase distribution based on the Gerchberg-Saxton algorithm [29], but using more planes and propagation between them instead of Fourier transforms, called the ping-pong algorithm [30]. It performed iterative propagations between two object and one hologram planes with phase preservation and forcing desired amplitude distributions. In image planes, amplitude distributions were forced to have the shape of the designed images, and in hologram plane, the amplitude was unified (set to one); see Figure 1. In such a way, a kind of synthetic Fresnel hologram could be obtained, previously described for visible light [31]. In the original Gerchberg-Saxton algorithm, the iterations were realized only between two planes (one hologram and one image), and fast-Fourier transform (FFT) was used. Here, we created an iteration process between three planes with the assumption that the light field was propagated between planes using the modified convolution method [32], making our solution closer to the ping-pong algorithm. The number of iterations was limited to 25, which was based on the convergence of algorithm used [33]. For clarity, the simplified pseudocode is provided (see Algorithm 1). ```
1:procedureModifiedGS
2:initial steps:
3:\(illumination\leftarrow planewave\)
4:\(amp\leftarrow Object2\)\(\triangleright\) plane with \"square\"
5:OfAxisPropagation(-150)\(\triangleright\) argument in mm
6:\(amp\leftarrow Object1\)\(\triangleright\) plane with \"cross\"
7:OfAxisPropagation(-150)\(\triangleright\) amplitude equalization; phase not changed
8:\(amp\gets 1\)\(\triangleright\) amplitude equalization; phase not changed
9:loop through planes:
10:for i = 0; i<= 20; ++i do
11:OffAxisPropagation(150)
12:\(amp\gets Object1\)\(\triangleright\) plane with \"cross\"
13:OffAxisPropagation(150)
14:\(amp\gets Object2\)\(\triangleright\) plane with \"square\"
15:OffAxisPropagation(-150)
16:\(amp\gets Object1\)\(\triangleright\) plane with \"cross\"
17:OffAxisPropagation(-150)
18:\(amp\gets 1\)\(\triangleright\) hologram plane
19:end:
20:save(phase)\(\triangleright\) save hologram
```  
**Algorithm 1** Modified Gerchberg-Saxton algorithm. Moreover, we decided to use the off-axis approach due to the assumed relatively small size of the hologram of 100 mm and the large image size at close distances. Thus, choosing two images--a cross  
Figure 1: Designing a synthetic hologram: numerical simulation scheme. _Prop_ indicates propagation at particular distance. having a size of 150 mm and a square having a size of 60 mm--distant from the hologram plane at \(z_{1}=150\) mm and \(z_{1}+z_{2}=300\) mm, respectively, violates the assumption of the paraxial approach (Figure 2). Therefore, the numerical description was conducted in the off-axis regime [34]. All design procedures concerning diffractive optics (here, our hologram) by definition assumed using perfectly temporally-coherent illumination with a plane wave. For this reason, we designed the hologram structure in such a regime. Nevertheless, we were able to conduct additional simulations taking into account different shapes and divergences of the experimental beam. Due to a lack of a priori information about the shape of the beam in the experimental setup, first, simulations were performed for plane wave illumination, and also, the hologram structure was manufactured for such assumptions. Later, to obtain simulations corresponding to the experimental data, we carried out additional simulations taking into account different shapes of the beam based on data obtained from the optical setup (Figure 3). The first setup (A) consisted of an emitter, a hologram placed 790 mm after, and a detector (both based on frequency multipliers and Schottky diodes), as shown in Figure 2a.