# Predictive Modeling of Light-Matter Interaction in One Dimension: A Dynamic Deep Learning Approach
## 3 Results  
### Frequency Generation via Optical Wave Mixing in a Micro-Resonator  
#### 3.1.1 Difference Frequency Generation Process  
The first optical process that we model using a three-layer network is the difference frequency generation process, which is a nonlinear process that occurs when two high-amplitude waves \(E_{1}\) and \(E_{2}\) are simultaneously fed into a cavity. Here, the cavity is composed of two perfectly reflective walls and a Gallium-Arsenide interaction medium that is inserted between the cavity walls. The excited waves are given as follows:  
\[E_{1}(x=0\ \mu\mathrm{m},t=0\ \mathrm{s})=4\times 10^{8}\times sin\big{(}2\pi \big{(}2.5\times 10^{14}\big{)}t\big{)}\ \mathrm{V/m}\ \ \ \ (Infrared\ wave\ at\ 250\ \mathrm{THz})\]  
\[E_{2}(x=0\ \mu\mathrm{m},t=0\ \mathrm{s})=3\times 10^{8}\times sin\big{(}2\pi \big{(}1.5\times 10^{14}\big{)}t\big{)}\ \mathrm{V/m}\ \ \ \ (Infrared\ wave\ at\ 150\ \mathrm{THz})\]  
Hence, the total excitation wave at t = 0 s is given as follows:  
\[E_{total}(x=0\ \mu\mathrm{m},t=0\ \mathrm{s})\]  
\[=4\times 10^{8}\times sin\big{(}2\pi\big{(}2.5\times 10^{14}\big{)}t\big{)} \mathrm{V/m}+3\times 10^{8}\times sin\big{(}2\pi\big{(}1.5\times 10^{14} \big{)}t\big{)}\ \mathrm{V/m}\]  
The simulation setting and the properties of the interaction medium are given as follows:  
_Spatial and temporal discretization_ : \(0\leq x\leq 5\ \mu\mathrm{m}\), \(0\leq t\leq 5\ \mathrm{ps}\), \(\Delta x=10\ \mathrm{nm}\), \(\Delta t=0.025\ \mathrm{fs}\)  
_Interaction medium resonance frequency_ : \(f_{r}=3.45\times 10^{14}\ \mathrm{Hz}\), _Conductivity_ : \(\sigma=10^{-4}\ \mathrm{S/m}\)  
_Polarization damping rate of the interaction medium_ : \(\gamma=1\times 10^{10}\ \mathrm{Hz}\)  
_Background permittivity_ : \((\varepsilon_{\infty})=13\varepsilon_{0}\), _Atomic diameter_ : \(d=0.3\ \mathrm{nanometers}\)  
\[\varepsilon_{0}:Free\ space\ permittivity\]  
\[Cavity\ range:0\ \mu\mathrm{m}<\mathrm{x}<5\ \mu\mathrm{m}\]  
, _Electron density_ : \(\mathrm{N}=1.76\times 10^{29}/\mathrm{m}^{3}\)  
As a result of the high optical intensity and the inherent nonlinearity of Gallium-Arsenide atoms, after a certain time, new harmonics will be generated at 100 THz (difference harmonic, mid-infrared) and 400 THz (sum harmonic, red) due to the nonlinear (cross) polarization terms in Equation (2). At the end of the simulation, the final spectrum of the intracavity wave (magnitude of the Fourier transform) is as given in Figure 3.  
The modeling of the wave mixing process is computationally costly, and the cost of computation grows exponentially with increasing simulation duration. The efficiency of our three-layer neural network is tested in this case by predicting the temporal behavior of the electric field amplitude of the difference frequency (100 THz) from t = 5 ps to t = 8.5 ps. The formulations in Equations (43)-(45) are applied with n = 42,500, M = 25,000, \(K_{3}=4\), \(K_{2}=4\), and \(K_{1}=4\) (each layer has four coefficients). Hence, the available training data consist of M = 25,000 samples, and the number of samples to be predicted is 17,500 (n-M). The resulting prediction is shown in Figure 4. In this case, the prediction is highly accurate, with less than 0.08% relative error (RE). A comparison with the theoretical results is also given in Figure 5 regarding the electric field amplitude, based on the given formulation in [39]. The comparison is performed by considering the simulation duration as the total number of roundtrips multiplied by two times the cavity length times the square root of the background permittivity of the medium, divided by the speed of light. Figure 4: Prediction of the electric field amplitude for the generated difference–frequency (100 THz) wave from t = 5 ps to t = 8.5 ps. Figure 5: Electric field amplitude variation versus time for the generated difference harmonic (**a**). Zoomed-in view (**b**).