Quantum circuit simulation of linear optics using fermion to qubit encoding

This work proposes a digital quantum simulation protocol for the linear scattering process of bosons, which provides a simple extension to partially distinguishable boson cases. Our protocol is achieved by combining the boson-fermion correspondence relation and fermion to qubit encoding protocols. As a proof of concept, we designed quantum circuits for generating the Hong-Ou-Mandel dip by varying particle distinguishability. The circuits were verified with the classical and quantum simulations using the IBM Quantum and IonQ cloud services.


I. INTRODUCTION
Quantum simulation imitates an evolution of one quantum system with another artificially organized quantum system, i.e., quantum simulator [1].Digital quantum simulators with qubits can encode an arbitrary quantum system comprising various particles, such as spins, fermions, and bosons, either exactly or approximately, depending on the particle nature.Qubits can be realized with several physical systems, such as trapped ions [2,3], nuclear magnetic resonance [4,5], superconducting circuits [6,7], quantum dots [8], and photons [9].Therefore, we can simulate any quantum system with digital quantum simulators using proper qubit encoding protocols regardless of the physical nature of the simulator.Among various many-particle quantum systems, bosonic systems are considered to have the significant benefit from digital quantum simulations.Knill, Laflamme and Milburn (KLM) showed that the postselected linear optics is capable of universal quantum computing [10].Also, boson sampling proposed by Aaronson and Arkhipov [11] is a strong candidate for demonstrating the computational superiority of quantum devices.The boson sampling problem is believed to belong to classically hard sampling problems.
Inspired by the computational power of noninteracting bosonic systems, several boson to qubit encoding (B2QE) protocols have been proposed to simulate bosonic problems with digital quantum com-puters [12][13][14][15][16][17][18].The majority of studies discretize bosonic creation and annihilation operators directly using unary or binary qubit representations of the Fock states as qubit encoding protocols.Ref. [15] presents a method for the digital quantum simulation of linear and nonlinear optical elements.Ref. [17] simulated the beam-splitting and squeezing operators with IBMQ.The required resources, such as the numbers of qubits and gates, vary according to the encoding protocols.Ref. [18] compared the resource efficiency among encoding protocols.
In this paper, we propose an alternative manyboson digital simulation method by combining the boson-fermion correspondence analyzed by Shchesnovich [19] and fermion to qubit encoding (F2QE) protocols [20,21].Specifically, our protocol transforms bosonic states into fermionic states with internal degrees of freedom, which are then transformed to qubit states via a F2QE procotol (JW transformation).With our simulation model, quantum circuits with M bundles of N qubits can simulate the number-conserving scattering process of N bosons in M modes.Our protocol is summarized in Fig. 1.The most significant advantage of our protocol is that it can simulate non-ideal partially distinguishable bosons, i.e., bosons with internal degrees of freedoms, using a direct extension of qubit numbers.
As a proof of concept, we generate the Hong-Ou-Mandel (HOM) dip [22] with our protocol.The HOM effect is important in optical quantum systems that provide the elementary resource for logic gates in the linear optical quantum computing systems.The formal connection between the HOM effect and the qubit-based SWAP test was discussed in Ref. [23].To simulate HOM dip, we need a method to add an internal degree of freedom to photons.It FIG.1: Our protocol for digital simulation of multi-boson systems.Using antisymmetrically entangled fermions as effective bosons, we can design digital quantum circuit to simulate multi-bosonic system via JW transformation.is easily achieved in our case by increasing the qubit number twice, which shows that our protocol is suitable for simulating partially distinguishable bosons.We verified the validity of our circuit using the IBM Quantum and IonQ cloud services.
This paper is organized as follows: Section II explains our digital boson simulation protocol.After reviewing the boson-fermion transformation protocol, we show how to combine this transformation with the JW transformation for the digital bosonic simulation.In section III, we apply our model to the HOM dip experiment.We simulate the two-photon partial distinguishability with an eight-qubit-circuit.Finally, section IV concludes our present work and discusses its possible future extensions.

II. DIGITIZING BOSONIC SYSTEMS
In this section, we explain our B2QE protocol to simulate many-boson systems with qubits.Our protocol consists of two steps: First, we express the number-conserving bosonic systems with entangled multi-fermions with an internal degree of freedom.Second, we map the translated multi-fermionic system to a qubit system using a well-known F2QE protocol, the JW transformation [20].

A. Effective bosonic states of multi-fermions
We first explain how a specific form of entangled multi-fermions can effectively behave as multibosons.In the second quantization language, the bosonic creation and annihilation operators â † i and âi (i = 1, • • • , M ) obey the following commutation relations: while the fermionic operators b † i and bi obey the anticommutation relations: where { Â, B} ≡ Â B + B Â. The above relations satisfy the Pauli exclusion principle for fermions, which prohibits the superposition of two fermions in the same state.Indeed, we see that b † i |vac = 0 by Eq. ( 2), where |vac is a vacuum state.On the other hand, if the fermions have internal degrees of freedom, such as spin, fermionic modes with different internal states can occupy the same spatial mode.By denoting a K-dimensional internal degree of freedom as µ (µ = 0, • • • K − 1), a fermionic operator with internal degrees of freedom µ is defined as b †µ i and bµ i .The anticommutation relations for the operators are as follows: In such a case, the fermions can condensate in the same spatial mode up to K. We aim to employ this feature of multi-fermionic states for mimicking the Bose-Einstein condensation (BEC) with the cutoff K. Fig. 2 explains the concept of fermionic condensation.
On the other hand, for the fermionic condensation to operate like the BEC, we must properly consider the fundamental differences between bosons and fermions, i.e., the exchange symmetry and antisymmetry indicated in Eqs. ( 1) and (2).Shchesnovich [19] showed that the interchangeability of entanglement and exchange symmetry can render entangled multi-fermions symmetric under the exchange of spatial modes.Here, we introduce the effective bosonic state of multi-fermions with the condensation limit K in the second quantization language, which offers a more refined explanation than of the first quantization language used in Ref. [19].
Let us consider an N -fermionic state, b †µ1 This state is always antisymmetric under the FIG.2: M -fermionic modes with K internal states.Fermions can condensate in the same mode up to K. If a fermion state is entangled in Eq. ( 5), we can simulate BEC with the condensation cutoff K.
exchange of the total indices (µ, i).However, if K ≥ N , we can obtain a symmetric state under the spatial modes i α by suitably superposing fermionic states as follows: (a square bracket [, ] on the upper indices means that the indices are antisymmetrized.For the simplest example, b †[µ1 holds for any α and β for 1 (a brace {, } on the lower indices on the right hand side denotes that the indices are symmetrized.
For the simplest example, b †µ1 ).Therefore, we can consider Eq (5) to be an effective N -boson state with the condensation limit K.
As a simple example, when N = 2, Eq. ( 5) becomes By exchanging the mode indices i 1 and i 2 , we have where the second line is obtained by changing the order of fermionic operators.
Since the antisymmetrical entanglement of the fermions is essential for effective bosonic states to behave like bosons, the exchange symmetry of the state must be preserved under evolutions.In other words, if we want to simulate the bosonic scattering process with fermions, the transformation operators of fermions must preserve the antisymmetrical entanglement.We observe that some transformation operators satisfy this restriction.We first consider a bosonic operator T of the following form: where t is the evolution time and Φ jk ∈ C. We note that jk Φ jk â † j âk (11) behaves as the Hamiltonian of the given system by setting Φ jk = Φ * kj .Then, the transformation of â † i under T is given by where Φ is a Hermitian matrix whose elements are Φ ij and j u ij u * kj = δ ik .In the fermionic system, the corresponding operator T f is expressed as follows: which gives Then, the state Eq. ( 5) evolves via T f as follows: The second line of the above equation shows that the transformed state is a linear combination of effective multi-boson states, which itself is an effective multiboson state.In a more general form, we see that any number-conserving Hamiltonian looks like H = jk Φ jk â † j âk + c.c.. Finally, we check whether the measurement of the state Eq. ( 5) that evolves with Eq. ( 10) is effectively bosonic, i.e., the scattering probability is proportional to the absolute square of the transformation matrix permanent.Suppose first that we postselect terms without bunching, irrespective of what the internal states of the particles are.Without loss of generality, we can assume the boson number distribution vector as follows: Then, the scattering probability is given with a projector Using the relation, we have where u is an N ×N matrix whose entries are u ij and perm(u) denotes the permanent of u, as expected for a bosonic systems with T [11,24].If the postselected states permit bunching, the probability becomes proportional to the permanent of the submatrix of u as expected [25][26][27][28].

B. Simulating multi-boson systems with qubits
Since a fermionic state of the form indicated in Eq. ( 5) can simulate a linear scattering of bosons, we conclude that digital quantum computers can also simulate the same system using the JW transformation.Before explaining how we actually organize quantum circuits and algorithms for such a simulation, we first review the JW transformation, which maps fermions to qubits [20].
In the JW transformation, qubit states |0 and |1 correspond to the empty and occupied states of fermions for a given mode, i.e., the following isomorphism should hold: The left and right hand side denotes an N -qubit state and an N -fermionic state, respectively, and ∼ = represents that the two sides are in a correspondence relationship with each other.For this relationship to hold, there must be operators acting on the Nqubit system that play the roles of creation and annihilation operators.Indeed, we can construct such operators by combining the Pauli operators X j , Y j and Z j (j = 1, We can see that | n and b † j (X, Y, Z) must satisfy the following conditions: comes from the anticommutation property of the creation-annihilation operators.

It can easily be verified that bj
(σ + ≡ |1 0| and σ − ≡ |0 1|) satisfy the above conditions.One can also check that Eq. ( 21) satisfies the anticommutation relations, i.e., { bj , b † The state transformation of Eq. ( 20) and operator transformations in Eq. ( 21) define the JW transformation for the digital simulation of fermionic systems.FIG.3: N M qubits that can simulate N bosons in M modes.Each bundle of N qubits behaves as a mode that can contain up to N bosons.Using M bundles of N qubits, we can simulate N -boson scattering process in M modes.
By combining the JW transformation and the results of Section II A, we can see that N bosons in M modes can be simulated with N M qubits (see Fig. 3).To impose this correspondence, consider an M N -qubit state where n µ i = 0, 1 and each bracket (n 1 i , n 2 i , • • • , n N i ) denotes the state of a bundle of N qubits.
If n µ i = 1, then it is considered in the fermion picture that a fermion exists in the ith mode with internal state j.Any state of this kind can be generated Now we can express an effective multi-boson state described in Eq. ( 5), which is entangled as antisymmetric under the internal states in the qubit space.As an example, consider the case with N bosons when all bosons from 1 to N are in different modes with respect to each other.Using Eq. ( 7), such a state can be expressed as 1 ), the state can be expressed in the N M qubit space as follows: where S N is the permutation group On the other hand, if all the bosons are in the same mode, e.g., the first mode, the state can be written as follows: For the case with N = 2 and M = 3, Eq. ( 24) takes the following form: which corresponds to the bosonic state â † 1 â † 2 |vac , while Eq. ( 25) becomes |11, 00, 00 , which corresponds to the bosonic state 1 √ 2 (â † 1 ) 2 |vac .Since Eqs. ( 22) and ( 23) represent a mapping from bosonic systems to qubits, we can digitally simulate multi-boson systems with the following process: 1. Preparation of the initial state: We first need to prepare the initial states of the form shown in Eq. ( 7), which can be achieved by adopting one of the known antisymmtrization algorithms, e.g., those in Refs.[29,30].On the other hand, we can find optimal algorithms for the states with small N case-by-case.

Evolution:
The unitary operations can be executed by substituting Eq. ( 23) into the Hamiltonian operator of Eq. ( 11).
3. Measurement: While the order of the excited states is unimportant, the number of excited states in each bundle is crucial because it determines the distributions of boson numbers.For example, if N = 3, (100), (010), and (001), in all cases a mode has one particle with different internal state.Nevertherless, we only record that one of three qubit states in the bundle is excited.Eq. ( 17) represents such a measurement process.

III. APPLICATION: HONG-OU-MANDEL DIP
In this section, we use our protocol to simulate the HOM effect for N = 2 [22].We first simulate ideal photon case (with no internal degree of freedom), which is then generalized to non-ideal photons with a two-dimensional internal degree of freedom.This generalization shows our protocol can simulate nonideal bosons simply with a direct extension of qubit numbers.

A. HOM experiment with ideal photons
Since two qubits can represent a bosonic mode with a maximal photon number of two, our protocol needs four qubits here.
Preparation.-Using the notations given before Eq. ( 24), we prepare the following initial state |Ψ i : Evolution.-For the case of HOM scattering, we set in Eq. ( 10) which produces the following transformation operator T H : In the fermion system, T H is given as follows: Using the JW transformation, we obtain b †1 in the qubit system.Since X ⊗ Z ⊗ X and Y ⊗ Z ⊗ Y commute, T H can be further decomposed follows: Note that we have not used the Trotter decomposition, because all the terms in the exponential terms commute with each other.This is true for the general linear optical transformations [15].
Measurement.-Thefinal state transformed by Eq. ( 29) is given by The interpretation of the above state is that two bosons always bunch, i.e., the HOM effect occurs.The full circuit for the HOM digital simulation is shown in Fig. 4. We used ibmq london on IBM Quantum and ionq qpu on IONQ for the digital quantum simulation.The results are shown in Fig. 5.

B. HOM dip
We will now simulate the HOM dip (see, e.g., [31] for a pedagogic review) with a two-dimensional internal degree of freedom that creates distinguishability.By denoting the internal state of bosons as s (= 0, 1), the creation and annihilation operators are written as â † is and âis with [â is , â † jr ] = δ ij δ sr .Then, an N -boson state â † effectively be expressed as a fermionic state as follows: Therefore, the general initial state for the HOM dip with two photons can be written as follows: where |s and |r are the general internal states of the form ζ|0 + ξ|1 (ζ, ξ ∈ C and |ζ| 2 + |ξ| 2 = 1).
To simulate this type of HOM dip, we need eight qubits, which are displayed in Fig. 6.Each qubit corresponds to the particle states (i, µ, s) as indicated in the figure .FIG. 4: Full circuit for HOM experiment.As seen in figures in the second line, T H given by Eq. ( 32) is further decomposed into one-or two-qubit gates.We set, for example, where the index indicates the operator in the exponent.Preparation.-Withoutloss of generality, we can assume the internal state of the photons as |s = |0 and |r = ζ|0 + ξ|1 .Therefore, the initial state for partially distinguishable photons can be described as follows: We can prepare this state by first creating and then applying the following gates: between (2, 0, 1) and (2, 1, 1) and between (2, 0, and (2, 1, 2).The above gates can be represented in a matrix form as follows: For two indistinguishable bosons (ideal photons), i.e., ζ = 1, and the initial state is as follows: On the other hand, if two bosons are fully distinguishable, i.e., ξ = 1, the initial state can be given without loss of generality as follows: Evolution.-Theevolution operator with distinguishability is simply obtained by generalizing Eq. ( 30) as follows: i.e., two particles are always in the same mode and the coincidence probability (the probability that each mode simultaneously detect particles) becomes zero.
When they are distinguishable, the final state |Ψ dis f is given as follows: which means that each particle can arrive at each of the two detectors with probability 0.5.In general, the final state with an arbitrary distinguishability (|r = ζ|0 + ξ|1 ) is given by We can predict that the coincidence probability for the photons varies from 0 (fully indistinguishable) to 0.5 (fully distinguishable).The increase in the circuit's width corresponds to the rise in the depth for simulating the scattering process of partially distinguishable photons, which causes a significant error in the quantum simulation.Therefore, we executed a classical simulation with qasm to show the validity of our method.Fig. 7 reveals a clear pattern of the HOM dip.

IV. CONCLUSIONS
We have proposed an alternative method for the digital simulation of linear-optical networks by using FIG.7: HOM dip classical simulation graph according to variation of θ from −π to π.The interval between angles is π/100.All simulations were performed using Qiskit's qasm simulator.the property that suitably entangled fermions can effectively behave like bosons.Unlike other existing B2QE protocols, our approach provides a simple and intuitive extension of an ideal bosonic system to a non-ideal one by introducing additional internal degrees of freedom.As a proof of concept, we designed quantum circuits for generating the Hong-Ou-Mandel dip by varying particle distinguishability.We successfully executed a digital simulation using the IBM Quantum and IonQ cloud services for the ideal boson case.For the partially distinguishable boson case, we showed the validity of our scheme with a classical simulation using Qiskit's qasm.
The obvious extension of our B2QE approach would be the non-number-conserving bosonic system simulations, such as Gaussian boson sampling [32] and molecular simulations [33].However, confining the infinite bosonic Hilbert space to the finite qubit Hilbert space will intrinsically generate errors for the non-number-conserving bosonic problems.In future work, we will attempt to optimize the required resources and errors induced by the confinement.We also intend to develop another efficient quantum algorithm for computing the matrix permanent [34] based on our B2QE protocol.With the help of the new B2QE protocol, we envisage developing efficient qubit-based quantum algorithms for bosonic systems, e.g., the boson sampling with nonideal photons, the Bose-Hubbard model, and the spin-boson model.

2 .FIG. 6 :
FIG.6: Qubit representation of two photons in two modes with two-dimensional internal degree of freedom.