# Quantum Photonic Simulation of Spin-Magnetic Field Coupling and Atom-Optical Field Interaction
## 2 Mechanical Interacting Systems
### Spin-I/2 Particle Interacting with a Magnetic Field  
The Hamiltonian of a spin particle interacting with a magnetic field is given by \(\hat{H}=-\mathbf{\mu}\cdot\mathbf{B}\), where \(\mathbf{\mu}\) is the magnetic moment of the particle, which is proportional to the spin operator, and \(\mathbf{B}\) is the magnetic field. Let us consider a spin-\(\frac{1}{2}\) particle, then \(\mathbf{\mu}=\frac{1}{2}\mu\sigma\), where \(\mu=\hbar\gamma_{p}\), with \(\gamma_{p}\) the gyromagnetic ratio of the particle (\(p=\text{e}\) for an electron, \(p=\text{n}\) for a neutron, etc. ), and \(\mathbf{\sigma}=(\sigma_{x},\sigma_{y},\sigma_{z})\) are the Pauli matrices. Moreover, we choose a time-dependent magnetic field, which, by assuming a sinusoidal dependence in time with frequency \(\omega\), is written as \(\mathbf{B}=B_{0}(\sin\theta\cos\omega t,-\sin\theta\sin\omega t,\cos\theta)\), representing a magnetic field of modulus \(B_{0}\) rotated an angle \(\theta\) with respect to the \(z\)-axis and spinning around this same axis with a frequency \(\omega\). We can then write the well-known spin-magnetic Hamiltonian as (see for instance [8]):  
\[\hat{H}(t)=-\frac{\hbar}{2}\gamma_{p}B_{0}\cos\theta\sigma_{z}-\frac{\hbar}{2} \gamma_{p}B_{0}\sin\theta(\cos\omega t\,\sigma_{x}-\sin\omega t\,\sigma_{y}). \tag{1}\]  
By taking into account the expressions of the Pauli matrices, then the above Hamiltonian gives rise to the following time-dependent Schrodinger equation:  
\[i\hbar\frac{\partial}{\partial t}|\Psi(t)\rangle=-\frac{\hbar}{2}\gamma_{p}B_ {0}\left( \begin{array}{cc}\cos\theta&\sin\theta\exp\left(i\omega t\right)\\ \sin\theta\exp\left(-i\omega t\right)&-\cos\theta\end{array} \right)|\Psi(t)\rangle=\]  
\[\equiv\hat{H}(t)|\Psi(t)\rangle. \tag{2}\]  
This time-dependent Hamiltonian is enough for our simulation purposes. Note that for the neutron case, we have the well-known Nuclear Magnetic Resonance (NMR). The solution of the equation above can be obtained as a time-dependent linear combination of down and up spin states, \(|0\rangle\) and \(|1\rangle\), of the particle, that is \(|\Psi(t)\rangle=c_{o}(t)|0\rangle+c_{1}(t)|1\rangle\). Thus, by using the vector representation of \(|\Psi(t)\rangle\) and the matrix Hamiltonian given by Equation (2), the Schrodinger equation can be rewritten as follows:  
\[i\hbar\frac{\text{d}c_{n}(t)}{\text{d}t}=E_{n}\cos\theta c_{n}(t)+i\sum_{n \
eq m}C_{nm}(t)c_{m}(t). \tag{3}\]with \(n=0,1\), \(E_{o}=-\frac{\hbar\gamma_{P}}{2}B_{o}\) and \(E_{1}=\frac{\hbar\gamma_{P}}{2}B_{o}\) the eigenvalues of spin states when a static magnetic field along \(z\)-direction is applied, and \(C_{01}(t)=C_{10}^{*}(t)=-\frac{\hbar\gamma_{P}}{2}B_{o}\sin\theta\exp(i\omega t)\) the coupling coefficients. On the other hand, it is interesting, for the sake of expositional convenience, to present the main results about the dynamics of the system. First of all, in order to simplify things, we can shift to a reference frame that is rotating at a frequency \(\omega\) by means of the following unitary transformation:  
\[|\eta(t)\rangle=\hat{U}(t,\omega)|\Psi(t)\rangle=\exp{(-i\omega \sigma_{z}t/2)}|\Psi(t)\rangle; \tag{4}\]  
therefore, by inserting \(|\Psi(t)\rangle=\exp{(i\omega\sigma_{z}t/2)}|\eta(t)\rangle\) into the Schrodinger equation, we obtain, after some simple calculations, the following Hamiltonian acting on \(|\eta(t)\rangle\):  
\[\hat{H^{\prime}}|\eta(t)\rangle=\frac{\hbar}{2}\left( \begin{array}{cc}- \gamma_{p}B_{0}\cos\theta+\omega&-\gamma_{p}B_{0}\sin\theta\\ -\gamma_{p}B_{0}\sin\theta&\gamma_{p}B_{0}\cos\theta-\omega\end{array}  \right)|\eta(t)\rangle.