General theory of quantum fingerprinting network

The purpose of fingerprinting is to compare long messages with low communication complexity. Compared with its classical version, the quantum fingerprinting can realize exponential reduction in communication complexity. Recently, the multi-party quantum fingerprinting is studied on whether the messages from many parties are the same. However, sometimes it is not enough just to know whether these messages are the same, we usually need to know the relationship among them. We provide a general model of quantum fingerprinting network, defining the relationship function $f^R$ and giving the corresponding decision rules. In this work, we take the four-party quantum fingerprinting protocol as an example for detailed analysis. We also choose the optimal parameters to minimize communication complexity in the case of asymmetric channels. Furthermore, we compare the multi-party quantum fingerprinting with the protocol based on the two-party quantum fingerprinting and find that the multi-party protocol has obvious advantages, especially in terms of communication time. Finally, the method of encoding more than one bit on each coherent state is used to further improve the performance of the protocol.


I. INTRODUCTION
The application of quantum mechanics in the field of communication brings benefits in many aspects, such as security and communication complexity, which is the minimum amount of communication required among participants in order to complete a task. With respect to security, Quantum key distribution (QKD) [1][2][3][4][5][6][7] is a representative example that can provide information-theoretic security, while the security of their classical versions is based on computational complexity. In terms of communication complexity [8,9], compared with the classical version [10,11], quantum fingerprinting can exponentially reduce the amount of information required to communicate, which is very useful in energy-saving communication [12][13][14].
The purpose of the fingerprinting protocol is to compare the two messages x 1 , x 2 ∈ {0, 1} n , where n is the length of the messages, through the transmission of their fingerprints. In the simultaneous message passing model [15], there are two senders that send the fingerprints of the original messages to the Referee, who needs to determine whether x 1 = x 2 within a small error probability P e . The quantum fingerprinting can significantly reduce the communication complexity required to complete the comparison, i.e., the communication complexity of the classical version is O( √ n)-bits [10,11], while that of the quantum version is only O(log 2 n)-qubits [12]. However, the original protocol requires high-dimensional entanglements, which makes its implementation challenging [12]. Fortunately, a quantum fingerprinting protocol based on coherent states is proposed [16] and since then, there have been many advances in theory and experiment [17][18][19]. Recently, in order to reduce the communication time, wavelength division multiplexing (WDM) is used in the quantum fingerprinting and the result shows that not only the communication time is reduced, but also the communication complexity is further reduced [20].
Most studies focus on two-party quantum fingerprinting protocols [16][17][18]20] and there are only two relationships between the two inputs, x 1 = x 2 or x 1 = x 2 . As the amount of messages increases, things get more complicated and interesting. If we need to determine whether N messages are the same, a simple way is to use the twoparty quantum fingerprinting to compare N inputs in pairs, which needs to be done (N − 1) times. So is there a more efficient way? Recently, a multi-party quantum fingerprinting is proposed [21], which only needs to be run once to determine whether N inputs are the same. Obviously, in this case, the quantum fingerprinting network presents a huge advantage. However, the relationship among N inputs is more complex than that between two inputs, and sometimes it is not enough just to know they are different. Usually, we also need to know which of these inputs are different and whether, and by how much, the quantum fingerprinting network still has advantages in this case. Unfortunately, the original protocol [21] can not answer these questions. Therefore, it is of great significance to study the quantum fingerprinting network deeply and solve these problems. In this work, based on the existing framework [21], we solve the above problems by the ingenious design of the decision rules. We can determine the relationship among N inputs by exchanging the interference positions of senders so that the comparison results can correspond to a unique relationship, rather than several possible relationships. In addition, we consider the more general case of asymmetric channels and provide the optimal parameter which minimizes the communication complexity. Moreover, by comparing with the protocol based on two-party quantum fingerprinting, it can be found that the quantum fingerprint network has obvious advantages, especially in communication time. In order to further improve the performance of the protocol, we also use a multi-bit encoding scheme [19], which can further reduce the communication complexity and communication time.
The rest of this paper is arranged as follows. In Sec.II, we present a general N -party quantum fingerprinting protocol. Then a four-party quantum fingerprinting network based on the balanced beam-splitter (BS) is used as an example to show how to determine the relationship among multiple inputs in Sec.III. Moreover, in Sec.IV., we consider the more general case of asymmetric channels and optimize the parameters in this case. After this, we discuss the advantages of the quantum fingerprinting network and use the multi-bits encoding method to further improve the performance of the protocol in Sec.V. Finally, a brief summary is given in Sec.VI.

II. N -PARTY QUANTUM FINGERPRINTING PROTOCOL
(1) There are N senders S 1 , S 2 , . . . , S N , each of which holds a string of messages x k ∈ {0, 1} n , k = 1, 2, . . . , N, to be compared, where n represents the length of the input messages, as shown in Fig.1.
(2) The N senders use the error correction code (ECC) E(x k ) ∈ {0, 1} m to encode input messages, where m = cn is the length of the E(x k ), c > 1, and δ is the smallest relative Hamming distance of any two different messages. The ECC is used to increase the hamming distance between different inputs. For k = k ′ , E(x k ) and E(x k ′ ) have at least δm different bits.
(3) Each sender S k encodes the coherent state according to E(x k ), then sends them to the Referee.
We can call |s k the fingerprint state, which contains m coherent states. The amplitude of each coherent state is α k √ m and the phase depends on E(x k ) j .
In practice, the impact of the channel loss on the protocol needs to be considered, so we use the η k to represent the losses experienced by these fingerprint states respectively. If the channel is symmetric, η k = η. More generally, the loss of different channels is not equal, which will affect the selection of optimal parameters.
(4) The Referee uses the device consisting of several BSs and N detectors D 1 , D 2 , . . . , D N to perform the interference measurement with the N fingerprint states.
(5) The Referee records the total counts on N detectors, which are C 1 , C 2 , . . . , C N , and selects appropriate thresholds C th 1 , C th 2 , . . . , C th N . Then, the Referee compares C k with C th k . If C k < C th k , the Referee records the result as the number 0, otherwise, records it as the number 1.
(6) The Referee can draw a conclusion about the following contents under the condition that error probability P e ≤ ε (ε is the maximum error probability that the protocol can tolerate) according to the corresponding decision rules.
All-equality function [22] : Determine whether the N messages are the same, Exists-equality function [22]: Determine whether there is an equal pair of input messages, Relationship function : Determine the relationship among the N input messages, where v i,j k represents different values of f R and we write different inputs in different parentheses, where subscripts are used to distinguish the different parentheses. There are j such groups and G j represents the same N j inputs of the total N inputs, which satisfies N 1 ≥ N 2 ≥ · · · ≥ N j and j j0=1 N j0 = N . We define N 1 = i, which means at most i inputs are the same, i = N − (j − 1), N − (j − 1) − 1, . . . , ⌈ N j ⌉. k = 1, 2, . . . , k i,j t , where k i,j t is the total number of cases for the same (i, j). We provide the expression for k i,j t in the Appendix A. In function f R , for example, v N −1,2 1 represents the first relationship among N inputs when there are two groups and at most (N − 1) inputs are the same, i.e., (x 1 , . . . , x N −1 ) 1 , (x N ) 2 . When N = 4, the form of f R is shown in the last column of Table I.
Decision rules of the f AE : The device in the Referee has the feature that there is only one detector D 1 has clicks if all inputs are equal and all detectors are likely to have clicks as long as there are different inputs, ideally. The Referee can determine whether the N inputs are equal, according to the results of comparison between total counts on detectors and the threshold C th 1 or C th sum [21]. If C 1 > C th 1 or C sum < C th sum , where C sum = C 2 + · · · + C N , N inputs are equal (f AE = 1). If C 1 < C th 1 or C sum > C th sum , N inputs are different (f AE = 0). Decision rules of the f R : The Referee can determine the relationship among N inputs based on the comparison results of C k and C th k . If the result of the first run of the protocol corresponds to a unique relationship, then the calculation of f R is complete. Otherwise, we need to exchange the interference positions of senders and run the protocol several times until the comparison results can correspond to a unique relationship, rather than several possible relationships. As shown in Table I, FIG. 2: Determine the relationships among N messages based on the quantum fingerprinting network composed of balanced BSs, N = 2 s , s ∈ Z + . S1, S2,. . . ,SN are N senders who hold the messages to be compared. Each bracket, which is equivalent to a balanced BS in the Fig. 3, compares the input of the two parts. The first layer shows the comparison results of E(x k ) and E(x k+1 ), k = 1, 3, . . . , N − 1; the second layer shows the comparison results of E(x k ) + E(x k+1 ) and E(x k+2 ) + E(x k+3 ), k = 1, 5, . . . , N − 3, and so on, and the sth layer shows the comparison results of in this work, we analyze in detail how to calculate f R in the four-party quantum fingerprinting protocol (N = 4).
From Eq.(2)-Eq.(4), we can find that as long as we calculate f R , we can know the values of f AE and f EE , and conversely, this is not the case, so the calculation of f R is very important. In the following, we mainly consider the calculation of f R .
The design of N -party quantum fingerprinting network based on balanced BSs. We show in Fig.2 how to determine the relationships among N inputs based on quantum fingerprinting network composed of balanced BSs, N = 2 s , s ∈ Z + . Each bracket, which is equivalent to the BS in the Fig.3, compares the input of the two parts. The first layer shows the comparison results of E(x i ) and E(x i+1 ), i = 1, 3, . . . , N −1; the second layer shows the comparison results of E(x i )+E(x i+1 ) and E(x i+2 )+E(x i+3 ), i = 1, 5, . . . , N −3, and so on, and the sth layer shows the comparison results of Swapping interference positions is equivalent to changing the content of the comparison to get a new set of comparison relationships. We need to swap the interference position of different senders until we can determine a unique relationship, not just a few possible relationships, based on the comparison results.
Communication Complexity. When determining whether the N inputs are equal (calculating f AE ), the total communication complexity of the classical optimal fingerprinting protocol C AE o and the classical limit C AE l are as follows [21,22] where P e is the error probability of the fingerprinting protocol.
Determining the relationship among multiple inputs is more difficult than determining whether they are equal, so the following relationship should exist where C R o and C R l represent the optimal communication complexity in classical version and classical limit when calculating f R , respectively.
In quantum fingerprinting based on coherent states [16], the total communication complexity Q AE when calculating f AE can be written as where µ k = |α k | 2 represents the total photon number of the fingerprint state. According to the decision rules of f R , the maximum total communication complexity Q R can be written as where t max represents the maximum number of times the protocol need to be run in order to calculate f R . In order to compare the performance of the multiparty quantum fingerprinting protocol with the classical version in terms of communication complexity when calculating f R , we need to compare C R o , C R l and Q R . However, there are very few studies on the communication complexity C R o and C R l . Therefore, in this work, we choose to compare C AE o , C AE l and Q R . When Q R < C AE l < C AE o , then combined with (7), it is obvious that Q R < C R l < C R o can be concluded, which can reflect the advantage of multi-party quantum fingerprint protocol in communication complexity.
Four-party quantum fingerprinting of symmetric channels (η k = η, k = 1, 2, 3, 4) based on balanced BSs. S1, S2, S3, S4 are four senders, who hold the messages to be compared. D1, D2, D3 and D4 are four detectors in the Referee, who can determine the relationship among four inputs according to the decision rules of f R .
There are 15 kinds of relationships among the four inputs x 1 , x 2 , x 3 and x 4 , as shown in the first column of Table I. The relationship among {x k } is the same as the relationship among {E(x k )}. The same letters represent the same inputs and different letters represent different inputs. For example, AAAA means that the four inputs are equal and ABCD means that they are completely different. Among them, AABC and ABCD are more complicated, as analyzed in Fig. 4. E(x 1 ) is all white, indicating the reference message. The white part of E(x 2 ), E(x 3 ) and E(x 4 ) represents the same part to E(x 1 ), and the black part represents the different part to E(x 1 ). For the convenience of expression, E(x k ) are shown as above. The order of the actual E(x k ) may not be the same as the Fig. 4, but we only care about the total counts C k on the detectors, so the order does not affect the decision rules. In AABC, Based on the above analysis, we can list the probability of observing a click on detectors D 1 , D 2 , D 3 , and D 4 for each pulse sent under all relationships, as shown in table II. δ tol represents the proportion of events except for E( , in E(x k ), k = 1, 2, 3, 4. δ 1,2 represents the relative distance between E(x 1 ) and E(x 2 ). Similarly, δ 3,4 represents the relative distance between E(x 3 ) and E(x 4 ). δ 1 12,34 represents the proportion of events, where the relationship among E( represents the proportion of events, where the relation- . For example, if the relationship is AABC, where P d represents the dark count probability of detectors.
We can calculate f R according to the probability of observing a click on detectors D 2 , D 3 and D 4 in Fig.3.
Decision rules of f R in four-party quantum fingerprinting: . 4: In the four-party quantum fingerprinting protocol, the left relationship is AABC and the right relationship is ABCD. m is the length of the E(x k ), k = 1, 2, 3, 4, and δ ′ and δ ′′ represent the relative Hamming distance. In the relation- Select the threshold C th 2 , C th 3 , C th 4 and compare the total counts C 2 , C 3 , C 4 of the three detectors with corresponding thresholds respectively. As shown in table I, R1 represents the comparison results after the first run of the protocol. The number 0 means the total counts are less than the threshold, and the number 1 means the total counts are greater than the threshold. For example, if C 2 < C th 2 , C 3 < C th 3 and C 4 < C th 4 , we record it as R1=000. On the first run of the protocol, if the result on D 2 is 0, then it means E( . When we run the protocol once, we can identify two of the relationships, i.e., f R = 14 (AAAA) and f R = 9 (AABB), for which the results of comparison are R1=000 and R1=010, respectively. If R1=011, then it corresponds to three possible relationships AAAB, AABA and AABC. To determine which relationship it is, we need to swap the interference positions of S 2 and S 3 and run the protocol for the second time.
On the second run of the protocol, if the result on D 2 is 0, then it means E( R2=011, then f R = 13 (AAAB). If we still can not determine the unique relationship according to R1 and R2 (for example, R1=R2=111), we need to exchange the interference positions of S 3 and S 4 on the basis of the second swapping, and then run the protocol for the third time.
On  The probability PD 1 , PD 2 , PD 3 ,PD 4 of observing a click on detectors D1, D2, D3, D4 under all relationships in four-party quantum fingerprinting. δ tol represents the proportion of events except for E(x1)j = E(x2)j = E(x3)j = E(x4)j , j ∈ [1, m], in E(x k ), k = 1, 2, 3, 4. δ1,2 represents the relative distance between E(x1) and E(x2). Similarly, δ3,4 represents the relative distance between E(x3) and E(x4). δ 1 12,34 represents the proportion of events, where the relationship among E(x1)j, E(x2)j, E(x3)j , E(x4)j ∈ {AAAB, AABA, ABAA, BAAA} in entire E(x k ); δ 2 12,34 represents the proportion of events, where the relationship among E(x1)j , E(x2)j, E(x3)j, E(x4)j ∈ {AABB}, in entire E(x k ). In short, we can determine the relationship among four inputs by exchanging the interference positions of senders to compare different parts. Whether the latter run is needed depends on the previous results. That is to say, whether the second run is needed depends on R1, and whether the third run is needed depends on R1 and R2. When the comparison result corresponds to only one relationship, instead of several possible relationships, the calculation of f R is completed.
Then, we show how to choose appropriate thresholds C th 2 , C th 3 and C th 4 and total photon number µ of the fingerprint state. The total number of clicks on the detectors is approximated by a binomial distribution C k,u ∼ Bin(m, P u k ), where k ∈ {2, 3, 4} and u ∈ {E, D}. The probabilities of observing a click on three detectors D 2 , D 3 and D 4 are as follow when the inputs are equal and different, where P d represents the dark count probability of detectors, µ is the total mean photon number of the fingerprint state, δ represents the minimum relative distance of ECC and η describes the channel loss. The error probability P e of the protocol can be defined as follows With the proper selection of µ and threshold C th 2 , C th 3 and C th 4 , we can make Q R as small as possible under the condition that P e ≤ ε. If µ is too small, Q R can be small, but no matter how to choose the threshold, P e may be very large, which cannot meet the requirements of the protocol. Conversely, if µ is too large, then Q R will be large even if the appropriate threshold can make P e small. Therefore, we should choose appropriate µ and C th 2 , C th 3 and C th 4 to balance the relationship between Q R and P e .
We can see from table III that when η = 0.1 and P e ≤ 10 −2 , the total number of photons sent by each sender µ = 4961, the thresholds of the three detectors are chosen as C th 2 = 602, C th 3 = 553 and C th 4 = 602, respectively, and the maximum total communication complexity Q R = 2.57 × 10 6 , which is four orders of magnitude smaller than the classical optimal protocol C AE o = 1.29 × 10 10 . Meanwhile, Q R also breaks the classical limit C AE l = 3.04 × 10 6 . To sum up, they satisfy Q R < C AE l < C AE o , and combined with (7), we can conclude that Q R < C R l < C R o . This shows the advantages of the quantum fingerprint network in communication complexity compared with the classical version.
In conclusion, as shown in Table I, we provide an efficient way to determine the relationships among four messages and we can easily obtain the values of f AE and f EE with the knowledge of f R .

IV. QUANTUM FINGERPRINTING PROTOCOL OF ASYMMETRIC CHANNELS
We consider the more general cases of asymmetric channels. Whether the channel is symmetric does not change the decision rules of the Referee. However, it affects the probability of observing a click on the detectors for each pulse when the inputs are equal and different, which has an impact on choosing the appropriate fingerprint states and thresholds to minimize communication complexity.
A. Two-party quantum fingerprinting protocol of asymmetric channels The communication complexity Q R should be taken as the objective function to optimize the parameters α 1 , α 2 and C th 2 under the condition of P e ≤ ε. In Table IV, we show the results of parameter optimization in two-party quantum fingerprinting of asymmetric channels. The details are in the Appendix B. When √ η 1 = 0.3 and √ η 1 = 0.4, the total amplitude of the two fingerprint states can be set to α 1 = 85 and α 2 = 78 respectively, and the threshold value D th 2 = 1685. At this time, the communication complexity Q R = 5.52 × 10 5 . Not only is it about five orders of magnitude less than the classical communication complexity C AE o = 1.24 × 10 10 , but it also breaks the classical limit C AE l = 1.46 × 10 6 . They satisfy Q R < C AE l < C AE o and combined with (7), we can obtain Q R < C R l < C R o . Therefore, compared with the classical version, the twoparty quantum fingerprinting has great advantages in terms of communication complexity.

B. Four-party Quantum fingerprinting of asymmetric channels
We show how the Referee can determine the relationship among four inputs of asymmetric channels. The decision rules of the Referee are the same as those of the symmetric channels, as shown in Table I. The difference lies in the probabilities of observing a click on detectors when the inputs are equal and different, which affects the selection of the thresholds. The detailed analysis is in the Appendix B and the results are shown in Table V. In the process of parameter optimization, it should be noted that the fingerprint states and thresholds of each run can be different, as long as P e ≤ ε. As shown in table V, when √ η 1 = 0.3, √ η 2 = 0.4, √ η 3 = 0.5, √ η 4 = 0.6, on the first run of the protocol, the total amplitudes and thresholds can be set to α 1 = 109, α 2 = 109, α 3 = 69, α 4 = 69, C th 2 = 5367, C th 3 = 5700, C th 4 = 5332. If the relationship cannot be determined by R1, then the interference positions of S 2 and S 3 needs to be exchanged and we need to run the protocol again. On the second run of the protocol, the total amplitudes and thresholds can be set to α 1 = 97, α 2 = 77, α 3 = 99, α 4 = 78, C th 2 = 5519, C th 3 = 5600, C th 4 = 5439. If f R still cannot be calculated based on R1 and R2, then positions of S 3 and S 4 need to be exchanged. On the third run of the protocol, the total amplitudes and thresholds can be set to α 1 = 90, α 2 = 84, α 3 = 85, α 4 = 91, C th 2 = 5699, C th 3 = 5600, C th 4 = 5347. We can find that the maximal total communication complexity Q R = 4.43 × 10 6 is five orders of magnitude less than C AE o = 1.01 × 10 11 of classical optimal fingerprinting. Moreover, it breaks the classical limit C AE l = 1.19 × 10 7 . In short, they satisfy Q R < C AE l < C AE o and combined with (7), it can be concluded that Q R < C R l < C R o . This shows the advantage that the quantum fingerprint network can reduce the communication complexity compared with the classical version.

V. DISCUSSION
In this work, we demonstrate the advantages of quantum fingerprinting networks in the field of communication complexity compared with classical versions according to Q R < C AE l < C AE o . It is important to note that the actual advantages (the difference among Q R , C R l and C R o ) will be greater than that shown by the above comparison method because C R o > C AE o and C R l > C AE l . The comparison between multi-party protocols and two-party protocols. For simplicity, we call the multi-party quantum fingerprinting protocol the multiparty protocol and we call the protocol, which uses the VI: The comparison of the N -party quantum fingerprinting and two-party protocol when N = 2 s , s ∈ Z + . QF M N refers to the N -party quantum fingerprinting protocol based on balanced BSs and QF T N refers to the two-party protocol, which compares N inputs in pairs. f is the function that the protocol needs to compute and tmax represents the maximum number of times the protocol needs to be run.
two-party quantum fingerprinting to compare N inputs in pairs, the two-party protocol.
If the Referee needs to calculate f R , when the relationship is AABB (or AAAA), the four-party protocol only needs to be run once, t M = 1, Q R = 1.55 × 10 6 (the parameters are shown in Table V and Q R is the communication complexity of the first run of the four-party protocol), while the two-party protocol needs to run multiple times, t T = 4 (or 3), Q R = 3.19 × 10 6 (or 2.75 × 10 6 ). Therefore, the four-party protocol shows advantages in terms of communication time and communication complexity. As shown in Table C1 in Appendix C, it can be found that no matter what the relationship is, the number of runs t M required by the four-party protocol is lower than t T required by the two-party protocol.
Furthermore, in Table VI, we compare the N -party quantum fingerprinting based on balanced BSs and the protocol based on two-party fingerprinting when N = 2 s , s ∈ Z + . When calculating f AE , the multi-party protocol only needs to run once, while the two-party scheme needs to be run up to (N − 1) times. When calculating f R , the multi-party protocol only needs to be run up to (N − 1) times, while the two-party scheme needs to run up to 1 2 N (N − 1) times. To sum up, the multi-party protocol has obvious advantages over the two-party protocol, especially in terms of communication time.
Multi-bits encoding Methods. To further improve the performance of the protocol, multiple bits of E(x k ) can be encoded on each coherent state [19]. Different from (1), the fingerprint state of the kth sender is prepared in the following form where The total communication complexity of the single-bit encoding method is Q R single−bit = 5.52 × 10 5 (as shown in the table IV), while that of the two-bit encoding method  is smaller, Q R two−bits = 3.91 × 10 5 , as shown in table VII. In either case, the total communication complexity of the quantum fingerprinting is about five orders of magnitude smaller than that of the classical optimal protocol, C AE o = 1.24 × 10 10 . Moreover, the communication complexity of both schemes breaks the classical limit C AE l = 1.46 × 10 6 . They satisfy Q R two−bits < Q R single−bit < C AE l < C AE o , combined with (7), we can conclude that Q R two−bits < Q R single−bit < C R l < C R o , which reflects the advantage of quantum fingerprinting in communication complexity. Besides, in the two-bits encoding method, the number of fingerprinting states sent by the senders is half that of the single-bit encoding method, which means in terms of communication time, the two-bit encoding method also has more advantages.
Of course, it does not mean that the more bits are encoded in each coherent state, the better. If all bits are encoded in one coherent state, the communication time is undoubtedly minimal, but the error probability P e may be very high. Therefore, it is important to find a balance among the communication complexity, error probability and communication time.
Our analysis above is based on ideal balanced BSs. In practice, the interference visibility ν < 1 (ν = 0.99 in [17]), but this does not affect the analysis of decision rules. We consider the impact of interference visibility ν in the Appendix D. It can be found that the there is a slight effect on parameter selections and the communication complexity Q R increase a little, but they still satisfy Q R < C R l < C R o . This means that the quantum fingerprinting still has obvious advantages over the classical version in terms of communication complexity after considering the effect of ν.
The device composed of balanced BS used in N -party quantum fingerprinting, N = 2 s , s ∈ Z + , can also be used in M -party quantum fingerprinting, M < N , which is analyzed in the Appendix E. Compared with the extendable design for M -party quantum fingerprinting (M = 3) [21], we only need balanced BSs and the number of runs needed to compute f R is smaller, which is very beneficial to the experiment.
When the Referee needs to calculate f AE , the protocol only needs to be run once. In addition to the two decision rules proposed in [21], we provide another decision rule to calculate f AE . As shown in the second column R1 in Table I, the Referee can only observe two detectors D2, D3 (or D3, D4) and only if C 2 , C 3 (or C 3 , C 4 ) are all less than the corresponding threshold respectively, f AE = 1; otherwise, f AE = 0.
The characteristic of our method of exchanging interference positions to determine the relationship among N inputs is that the latter run depends on the results of the previous runs. When N is larger, we may be able to design more flexible steps. For example, according to the results of the previous runs, the latter run only requires some of the N senders to send fingerprint states for comparison, so as to further reduce the communication complexity.

VI. CONCLUSION
We provide a general theory of quantum fingerprinting network, which can determine the relationship among multiple messages, and choose the optimal parameters to minimize the communication complexity in the case of asymmetric channels. We take the four-party quantum fingerprinting protocol as an example to analyze in detail how to calculate f R by exchanging the interference position of different senders. Moreover, we demonstrate the advantages of quantum networks, especially in terms of communication time, by comparing quantum fingerprinting networks with the two-party protocol. To further improve the performance of the protocol, we use the multi-bits scheme, in which multiple bits are encoded in each coherent state. It is important to find a good balance among communication complexity, error probability and communication time. There are j groups and G j represents the same N j inputs of N inputs which satisfies N 1 ≥ N 2 ≥ · · · ≥ N j , j = 1, 2, . . . , N . We define N 1 = i, which means at most i inputs are the same, is the total number of cases for the same (i, j), where N 2 + N 3 + · · · + N j = N − i; s G represents the effect of the repeat count due to the same number of elements in different groups. For example, when N = 4, i = 2, j = 2, (x 1 , x 2 ) 1 , (x 3 , x 4 ) 2 and (x 3 , x 4 ) 1 , (x 1 , x 2 ) 2 represent the same relationship. So, we need to use s G to eliminate the effect of this type of repeat count. When N is large, the relationship among N inputs is complicated, i.e., f R has many values. For instance, when N = 8, i = 4, j = 3, k 3,4 Appendix B: Quantum fingerprinting protocol of asymmetric channels Whether the channel is symmetrical does not change the decision rules of the Referee. However, it affects the expression of the probability of observing a click on the detectors for each coherent state when the inputs are equal and different. Therefore, it has an impact on choosing the appropriate fingerprint states and thresholds to minimize communication complexity. So, we focus on analyzing the probability of observing a click on the detectors for each coherent state in different protocols.
Two-party quantum fingerprinting protocol of asymmetric channels When N = 2, there are two detectors D 1 and D 2 on the Referee and ideally, when x 1 = x 2 , only D 1 has clicks; when x 1 = x 2 , both D 1 and D 2 have clicks. The probabilities of observing a click for each pulse sent on D 2 are P E 2 and P D 2 when the input information is equal and different.
In addition, it can also be determined by the detector D 1 . The analysis is similar.
To further improve the performance of the protocol, we consider the multi-bits encoding scheme. The following is the corresponding probability of two-bits encoding scheme Four-party quantum fingerprinting protocol of asymmetric channels Similar to the decision rules shown in table I, we can determine the relationship among four inputs according to the detector D 2 , D 3 and D 4 . The probability of observing a click on D 2 , D 3 and D 4 for each pulse when the inputs are equal and different are as follows where s = 1, 2, 3, (i, j) (k, l)= (1, 2) (3, 4), (1, 3)(2, 4), (1, 4)(2, 3) and This means that we can change the amplitude of coherent states and thresholds of detectors in each run with the purpose of minimizing Q R under the condition that P e ≤ ε.
Appendix C: Compare the number of runs between a multi-party protocol and a two-party protocol We can use a two-party quantum fingerprinting protocol to perform pairwise comparison to determine the relationship among four inputs, as shown in Table C1. The two-party protocol must be run at least three times and at most six times to determine f R . The blank sections in the table indicate that this run is not required. The number 0 means the total counts are less than the threshold, and the number 1 means the total counts are greater than the threshold. t T stands for the number of times to be run when using the two-party protocol, t M stands for the number of times to be run when using the four-party quantum fingerprinting protocol of which the decision rules are based on three detectors D 2 , D 3 and D 4 .
It can be seen from the Table C1 that no matter what the relationship is, the number of runs t M required by the four-party protocol is lower than t T required by the twoparty protocol. For example, if the relationship is AABB, the protocol needs to be run four times, t T = 4, using two-party protocol. However, the protocol only needs to be run once, t M = 1, to identify AABB by four-party protocol.
visibility is slightly lower, for example ν = 0.99 in [17]. We can make some modifications to the probability of observing a click on detectors when considering the impact of ν. Take the two-party quantum fingerprinting as example.
The probability of observing a click on detectors D 2 for each pulse when the inputs are equal and different becomes The comparison of the first row in Table IV and Table D1 shows that there is a slight effect on parameter selections after considering the interference visibility ν and the communication complexity Q R increases a little, but they still satisfy Q R < C AE l < C AE o . Based on this, and combined with (7), we can obtain Q R < C R l < C R o , which means that the communication complexity of the quantum fingerprinting protocol is lower than that of the classical version.
The analysis in the multi-party quantum fingerprinting protocol is similar. The device composed of balanced BSs, which can be used for N -party quantum fingerprinting, N = 2 s , s ∈ Z + , can also be used for M -party quantum fingerprinting, where M < N . We show how to determine the relationship among three inputs using the device shown in Fig.3, which is the device used for four-party quantum fingerprinting.
Different from four-party quantum fingerprinting, when N = 3, the sender S 1 prepares the same two sets of fingerprint states according to E(x 1 ), one is still sent to the interference position of S 1 and the other is sent to the interference position of S 4 in the Fig.3. The Referee can determine the relationship among the three inputs according to the comparison results of the total counts C 2 , C 3 , C 4 and corresponding thresholds C th 2 , C th 3 , C th 4 , respectively. As shown in Table E1, each comparison result corresponds to a unique relationship, so the Referee only needs to run the protocol once to calculate f R . For example, if the results is R1=011, then the relationship is AAB.
The three-party quantum fingerprinting based on extendable design [21] needs to exchange the interference position to determine the relationship, which can only be completed for three times at most. The method above can calculate f R in one run and does not require unbalanced BSs, which is very beneficial for experiments.