A method, apparatus and storage medium for simulating boson sampling
By determining the unitary transformation matrix of the Bose sampling system and converting it into the target matrix, and then calculating the probability of Bose sampling samples using a preset formula, the problem of high-dimensional Bose sampling calculation difficulties was solved, and quantitative evaluation of the output results of the "Jiuzhang" quantum computer was realized.
Patent Information
- Application Number
- CN202310317857.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-28
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2043-03-28
AI Technical Summary
Existing technologies cannot quickly calculate the probability distribution of samples in high-dimensional boson sampling, making it impossible to quantitatively evaluate the output of the "Nine Chapters" quantum computer.
By determining the unitary transformation matrix of the interference network of the Bose sampling system, converting it into the target matrix, and using a preset formula to calculate the probability of the sampled sample, the simulation calculates each sampled sample and its probability in Bose sampling.
Simulation calculations of high-dimensional Boson sampling were achieved, enabling quantitative evaluation of the output results of the "Nine Chapters" quantum computer and reducing computational complexity.
Smart Images

Figure CN116341252B_ABST
Abstract
Description
Technical Field
[0001] This disclosure relates to the fields of optical quantum computing and simulation technology, and in particular to a method, apparatus and storage medium for simulating Bosonic sampling. Background Technology
[0002] In a boson sampling system, the number of input ports and output ports of the interference network are the same. Photons are input from each input port, and the photons input into the boson sampling system will generate random quantum interference in the interference network and then be output from each output port. The number of output photons detected from each output port is random. The sorting of the number of photons detected by all output ports forms a boson sampling sample. Boson sampling generates a random sequence of multiple sampling samples, and this random sequence satisfies a certain probability distribution.
[0003] Calculating the probability of a single sample from a boson sample requires first analyzing the total number of all samples, i.e., how many possible combinations there are when N photons are output from N output ports. Based on permutation and combination calculations, the total number of all samples can be determined as follows: This total increases exponentially with the number of ports N. For example, when the number of photons (i.e., the number of ports) is 100, the total number of different sampled samples is approximately 4.5274 * 10^ ... 58 The "Nine Chapters" Gaussian Bose quantum computer is a Bose sampling system capable of rapidly completing Bose sampling tasks, performing 250,000 sampling processes per second. Even assuming that each sampling process produces different samples, the result would be 4.5274 * 10^9. 58 Generating the total number of samples also requires 5.7425 * 10. 45 The universe is only 13.7 billion years old. Therefore, given the computational resources invested, the probability distribution of samples from lower-dimensional Bose sampling can be calculated, but it is impossible to calculate the probability distribution of samples from higher-dimensional Bose sampling. Consequently, the output of the "Nine Chapters" quantum computer cannot be quantitatively evaluated. Summary of the Invention
[0004] To overcome the problems existing in related technologies, this disclosure provides a method, apparatus and storage medium for simulating boson sampling.
[0005] According to a first aspect of the present disclosure, a method for simulating boson sampling is provided, the method comprising:
[0006] Based on the number of ports N of the interferometric network of the Bose sampling system, the unitary transformation matrix of the interferometric network is determined, and the unitary transformation matrix is an N-order unitary matrix;
[0007] The target matrix is determined based on the unitary transformation matrix, wherein each element in the target matrix is the square of the modulus of the element at the same position in the unitary transformation matrix;
[0008] Based on the target matrix and the preset formula, the probability of the sampled sample in the boson sampling is determined, wherein the preset formula represents the relationship between the target matrix and the probability of the sampled sample;
[0009] The boson sampling includes isophoton boson sampling and isophoton boson sampling.
[0010] In one exemplary embodiment, the preset formula includes a first preset formula;
[0011] The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes:
[0012] Determine the product sum formula of the target matrix;
[0013] The probability of a sample in the boson sampling is determined based on the product of the target matrix and the first preset formula.
[0014] In one exemplary embodiment, determining the product sum of the target matrix includes:
[0015] Generate a set that corresponds one-to-one with the columns of the target matrix, the set comprising N consecutively connected sub-intervals, the set covering [0,1];
[0016] Multiple samples are generated by performing the following sampling process multiple times: generating random probability values corresponding to each column of the target matrix, and determining the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column;
[0017] The probability of a given sample appearing in the plurality of samples is statistically determined, and the probability of appearance is used as the product of the target matrix. The given sample is defined as: any two of the N position identifiers corresponding to the random probability values of the N columns are different.
[0018] In one exemplary embodiment, the method further includes:
[0019] Each sub-interval in each set corresponds one-to-one with an element in the corresponding column, and the position of the sub-interval in the N sub-intervals is the same as the position of the corresponding element in the N elements of the column.
[0020] In an exemplary embodiment, determining the probability of a sampled sample in boson sampling based on the product of the target matrix and the first preset formula includes:
[0021] The first preset formula is:
[0022]
[0023] Among them, S i Pr(S) represents the i-th sampled sample in boson sampling. i B represents the probability of the i-th sample. i The transformation matrix representing the unitary transformation matrix corresponding to the i-th sample, |B i | 2 Let Per(|B) represent the target matrix. i | 2 ) represents the product sum of the target matrix. This represents the number of photons at the k-th output port in the i-th sample.
[0024] In one exemplary embodiment, the preset formula includes a second preset formula;
[0025] The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes:
[0026] Obtain the number of sampling processes that generate each of the sampled samples in the boson sampling process;
[0027] Based on the target matrix, determine the probability of the sampling process for each of the sampled samples;
[0028] The probability of each sample in the boson sampling is estimated based on the number of sampling processes for each sample, the probability of the sampling process, and the second preset formula.
[0029] In one exemplary embodiment, the method further includes:
[0030] The number of sampling processes for each sampled sample is obtained using the following formula:
[0031]
[0032] Among them, S i Num_P(S) represents the i-th sampled sample in boson sampling. i ) represents the number of sampling processes for the i-th sample. This represents the number of photons at the k-th output port in the i-th sample;
[0033] The second preset formula is:
[0034]
[0035] Among them, S iPr(S) represents the i-th sampled sample in boson sampling. i ) represents the probability of the i-th sample, Process i This represents the probability of the first sampling process occurring during the simulation of generating the i-th sample.
[0036] According to a second aspect of the present disclosure, a simulated Bose sampling apparatus is provided, the apparatus comprising:
[0037] The first determining module is configured to determine the unitary transformation matrix of the interferometric network based on the number of ports N of the interferometric network of the boson sampling system, wherein the unitary transformation matrix is an N-order unitary matrix.
[0038] The second determining module is configured to determine a target matrix based on the unitary transformation matrix, wherein each element in the target matrix is the square of the modulus of the elements at the same position in the unitary transformation matrix;
[0039] The third determining module is configured to determine the probability of a sample in the boson sampling based on the target matrix and a preset formula, wherein the preset formula represents the relationship between the target matrix and the probability of the sample.
[0040] The boson sampling includes isophoton boson sampling and isophoton boson sampling.
[0041] According to a third aspect of the present disclosure, a simulated boson sampling device is provided, comprising:
[0042] processor;
[0043] Memory used to store processor-executable instructions;
[0044] The processor is configured to perform the method as described in any one of the first aspects of the embodiments of this disclosure.
[0045] According to a fourth aspect of the present disclosure, a non-transitory computer-readable storage medium is provided, wherein when instructions in the storage medium are executed by a processor of a device, the device is enabled to perform the method as described in any one of the first aspects of the present disclosure.
[0046] The above-described method of this disclosure has the following beneficial effects: This method converts the unitary transformation matrix into a target matrix. Based on the target matrix and the preset formula, it is possible to simulate and calculate each sample of the boson sampling and estimate the probability of each sample, thereby realizing the technical effect of quantitatively evaluating the output results of the "Nine Chapters" quantum computer.
[0047] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description
[0048] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0049] Figure 1 This is a flowchart illustrating a method for simulating boson sampling according to an exemplary embodiment;
[0050] Figure 2 This is a schematic diagram of a boson sampling system according to an exemplary embodiment;
[0051] Figure 3 This is a schematic diagram illustrating the probability distribution of low-dimensional Boson sampling according to an exemplary embodiment;
[0052] Figure 4 This is a schematic diagram of the probability distribution of high-dimensional boson sampling according to an exemplary embodiment;
[0053] Figure 5 This is a method flowchart illustrating step S103, according to an exemplary embodiment, of determining the probability of a sampled sample in boson sampling based on a target matrix and a preset formula.
[0054] Figure 6 This is a schematic diagram of a simulation device according to an exemplary embodiment;
[0055] Figure 7 This is a flowchart illustrating a method for determining the product sum of the target matrix in step S501 according to an exemplary embodiment;
[0056] Figure 8 This is a schematic diagram of line segments illustrating each set according to an exemplary embodiment;
[0057] Figure 9 This is a schematic diagram comparing the calculation results of a matrix product sum according to an exemplary embodiment;
[0058] Figure 10 This is a flowchart illustrating a method for determining the probability of a sampled sample in boson sampling based on a target matrix and a preset formula in step S103, according to an exemplary embodiment.
[0059] Figure 11 This is a block diagram illustrating an apparatus for simulating boson sampling according to an exemplary embodiment;
[0060] Figure 12 This is a block diagram illustrating an apparatus for simulating boson sampling according to an exemplary embodiment. Detailed Implementation
[0061] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the invention as detailed in the appended claims.
[0062] In related technologies, photons with completely identical states are called identical photons. Photons with the same state are indistinguishable and are also known as "bosons" in physics. When the input photon is a boson, the probability of each sample in the boson sampling is determined using the following formula:
[0063]
[0064] Among them, S i Let Pr(Si) represent the probability of the i-th sampled sample in the boson sampling, and B represent the probability of the i-th sampled sample. i Per(B) represents the transformation matrix corresponding to the unitary transformation matrix of the i-th sample. i ) represents the product sum of the transformation matrices. This represents the number of photons at the k-th output port in the i-th sample.
[0065] Due to the limitations of current computing resources, the product of high-dimensional matrices cannot be calculated. Therefore, when the number of input photons is large, it is impossible to calculate the probability of each sample in the boson sampling using the above formula.
[0066] In an exemplary embodiment of this disclosure, to overcome the problem in related technologies that cannot calculate the sample probability distribution of high-dimensional Bose sampling, a method for simulating Bose sampling is provided. Based on the number of ports N of the interference network of the Bose sampling system, the unitary transformation matrix of the interference network is determined. The unitary transformation matrix is an N-order unitary matrix. A target matrix is determined based on the unitary transformation matrix, where each element is the square of the modulus of the element at the same position in the unitary transformation matrix. Based on the target matrix and a preset formula, the probability of a sample in Bose sampling is determined. This method converts the unitary transformation matrix into the target matrix. Based on the target matrix and the preset formula, it can simulate and calculate each sample in Bose sampling and estimate the probability of each sample, thereby achieving a quantitative evaluation of the technical effect of the output results of the "Nine Chapters" quantum computer.
[0067] In an exemplary embodiment of this disclosure, a method for simulating Bose sampling is provided. Figure 1 This is a flowchart illustrating a method for simulating boson sampling according to an exemplary embodiment, such as... Figure 1 As shown, it includes the following steps:
[0068] Step S101: Determine the unitary transformation matrix of the interference network based on the number of ports N of the interference network of the boson sampling system. The unitary transformation matrix is an N-order unitary matrix.
[0069] Step S102: Determine the target matrix based on the unitary transformation matrix. Each element in the target matrix is the square of the modulus of the element at the same position in the unitary transformation matrix.
[0070] Step S103: Determine the probability of the sampled sample in the Boson sampling based on the target matrix and the preset formula. The preset formula represents the relationship between the target matrix and the probability of the sampled sample.
[0071] Boson sampling includes isophoton boson sampling and isophoton boson sampling.
[0072] For simplicity, the boson sampling in this disclosure uses one photon at each input port. It is worth noting that the principles and processes provided in this disclosure also apply to cases where the number of input photons is less than the number of input ports.
[0073] Figure 2 This is a schematic diagram of a boson sampling system according to an exemplary embodiment, such as... Figure 2 As shown, the boson sampling system includes 6 ports. Each input port receives one photon. The input photon undergoes quantum interference through an interference network represented by a unitary transformation matrix, i.e., a unitary transformation, and is output from the output port. The number of photons at each output port is random. Photon detection is performed at the output ports to determine the number of photons at each output port. The sorting of the number of photons detected at all output ports forms an output sample of the boson sampling system. Each output sample is a set of N elements. For example, Figure 2 The sampled samples 0, 1, 2, ... represent the number of photons detected by output ports 1 to 6, respectively. Sampled sample 0 is represented as [1, 1, 1, 1, 1, 1], sampled sample 1 is represented as [2, 0, 1, 0, 1, 2], sampled sample 2 is represented as [1, 0, 3, 1, 0, 1], ...
[0074] When the number of ports of the boson sampling system is N, the sampled sample output by the i-th sampling process is represented as:
[0075]
[0076] in, This represents the number of photons detected from output port k in the output sample of the i-th sampling process. All photon counts satisfy the following relationship:
[0077]
[0078] After multiple sampling processes, a random sequence S1, S2, ..., S of the output samples from the boson sampling can be generated. i ..., each output sample element S in the random sequence i It satisfies a certain probability distribution. It should be noted here that, theoretically, the samples S in the sequence... i Possibly repeated, all distinct output sampled samples S i Form a set with the following number of elements:
[0079]
[0080] in:
[0081] N! = 1 * 2 * 3 * ... * N
[0082] In step S101, the number of ports of the interference network in the Bose sampling system is denoted as N, and the unitary transformation matrix of the interference network is represented by an N-order unitary matrix. Since the sampling probability of low-dimensional Bose sampling can be calculated, this disclosure calculates the sampling probability for high-dimensional Bose sampling. In related technologies, according to tests, sampling problems exceeding 12 dimensions are generally difficult computational tasks for ordinary desktop computer computing platforms. The method of this disclosure can be applied to simulating both high-dimensional and low-dimensional Bose sampling. The unitary transformation matrix is denoted as matrix B, and then the unitary transformation matrix B is expressed as:
[0083]
[0084] Generally, the elements of the unitary transformation matrix B are complex numbers. When the input is identical photons, the unitary transformation matrix B physically represents the complex quantum interference process between photons. When the input is non-identical photons, the unitary transformation matrix B can be explained by an intuitive physical process:
[0085] Among them, |b 11 | 2 |b represents the probability that the first photon is output from the first output port. N1 | 2 |b| represents the probability that the first photon is output from the Nth output port. 1N | 2 |b| represents the probability that the Nth photon is output from the first output port. NN | 2 This represents the probability that the Nth photon is output from the Nth output port.
[0086] To obtain the formula for calculating the probability of the output sample, for different sampled samples, the unitary transformation matrix B needs to be transformed accordingly to determine the transformation matrix corresponding to each sampled sample in the probability calculation formula. The i-th sample S... i The corresponding transformation matrix is denoted as matrix B. i If the i-th sample S i The number of photons detected at the k-th output port If the value is zero, then delete the k-th column of matrix B; if the ith sample S... i The number of photons detected at the k-th output port If the value is not zero, then repeat the k-th column in matrix B. Second-rate.
[0087] For example, when matrix B is a three-dimensional matrix as shown below:
[0088]
[0089] If the i-th sample S i = [2,0,1], meaning the number of photons detected by the first output port is 2, the number of photons detected by the second output port is 0, and the number of photons detected by the third output port is 1. Therefore, the first column of matrix B is repeated twice, the second column is deleted, and the third column is repeated once (i.e., the third column remains unchanged), resulting in the i-th sample S. i The corresponding transformation matrix B i for:
[0090]
[0091] If the i-th sample S i = [0,2,1], meaning the number of photons detected by the first output port is 0, the number of photons detected by the second output port is 2, and the number of photons detected by the third output port is 1. Therefore, the first column of matrix B is deleted, the second column is repeated twice, and the third column is repeated once, meaning the third column remains unchanged, resulting in the i-th sample S. i The corresponding unitary transformation matrix B i for:
[0092]
[0093] In step S102, the target matrix is determined based on the unitary transformation matrix. Each element in the target matrix is the square of the modulus of the element at the same position in the unitary transformation matrix; that is, the target matrix is the square of the determinant of the unitary transformation matrix, and therefore, the target matrix is a non-negative real matrix. Let the target matrix be denoted as matrix A, then matrix A is expressed as:
[0094]
[0095] Since matrix B is a unitary matrix, according to the properties of unitary matrices, |B| 2 The sum of all elements in each column is 1, that is:
[0096]
[0097] Where i represents the i-th row of the matrix, and j represents the j-th column of the matrix.
[0098] In step S103, the preset formula is the relationship between the target matrix and the probability of the sampled sample. Based on the target matrix and the preset formula, the probability of the sampled sample in the boson sampling can be determined.
[0099] The ideal state of an interference network in a boson sampling system includes the following conditions: no photons are lost in the interference network; all photons are in identical states, and photons in the same state are indistinguishable, also known as "bosons" in physics; and all photons are in phase at the interference point. However, due to various imperfect factors in the interference network, not all photons undergo quantum interference, making it very difficult to achieve ideal boson sampling. Photons in the ideal state with all states being identical are called identical photons, or bosons. If all photons are in different states, then each photon is distinguishable, also known as a "fermion" or "completely different photon."
[0100] Since achieving ideal boson sampling is very difficult, the probability of the sample determined in this disclosure based on the target matrix and the preset formula is the probability of each sample of boson sampling under fermions, thereby obtaining the probability distribution of boson sampling under fermions.
[0101] Since the probability distribution of low-dimensional boson sampling under bosons and fermions can be directly calculated, Figure 3 This is a schematic diagram illustrating the probability distribution of low-dimensional boson sampling according to an exemplary embodiment, such as... Figure 3As shown, the probability distributions of boson sampling after unitary transformations using 6D, 7D, 8D, and 9D matrices are illustrated. The horizontal axis represents the sampled data, and the vertical axis represents the sorted sample probabilities. Curve A represents the probability distribution of boson sampling under bosons, and curve B represents the probability distribution of boson sampling under fermions. Analysis of the probability distributions of low-dimensional boson sampling under bosons and fermions reveals that the ranges of probability values are very close after sorting the probabilities of all samples under bosons and fermions. Therefore, the probabilities of high-dimensional boson sampling under fermions can be used as a reference value for the probability range of high-dimensional boson sampling under bosons, thus allowing for quantitative evaluation of boson sampling sequences under bosons. Estimating the probabilities of boson sampling under fermions enables quantitative analysis of the probabilities of samples generated by the "Nine Chapters" computer.
[0102] Based on the probability distribution estimation method of boson sampling under fermions, the probability distribution estimation range of boson sampling with 100 photons and 144 photons was simulated respectively. Figure 4 This is a schematic diagram illustrating the probability distribution of high-dimensional boson sampling according to an exemplary embodiment, such as... Figure 4 As shown, the probability distribution estimates of 100 photons and 144 photons under fermions are presented. The horizontal axis represents the sampled samples, and the vertical axis represents the sample probability after sorting the sample probabilities corresponding to 500,000 sampled samples. The 100 photons and 144 photons boson sampling correspond to "Nine Chapters 1" and "Nine Chapters 2" respectively.
[0103] like Figure 4 As shown, the probability distribution interval of the samples from "Nine Chapters 1" is within 10. -20 and 10 -55 Between these ranges, the probability distribution of the samples from "Nine Chapters 2" falls within a range of 10. -34 and 10 -76 Between. According to classical probability theory, the period of sample repetition is approximately the reciprocal of the probability value. For "Chapter 9-1", the sample with the highest probability requires 10 repetitions to complete once. 7 In 2010, for "Chapter 9-2", the sample with the highest probability required 10 repetitions. 21 Years. Therefore, within the timeframe perceptible to humans, neither "Nine Chapters 1" nor "Nine Chapters 2" can produce duplicate samples. Thus, the outputs of "Nine Chapters 1" and "Nine Chapters 2" can be considered a non-repeating random sequence within a validly measurable timeframe, i.e., conforming to a uniform distribution.
[0104] In an exemplary embodiment of this disclosure, the unitary transformation matrix of the interference network is determined based on the number of ports N of the interference network in the boson sampling system. The unitary transformation matrix is an N-order unitary matrix. A target matrix is determined based on the unitary transformation matrix, where each element is the square of the modulus of the element at the same position in the unitary transformation matrix. Based on the target matrix and a preset formula, the probability of each sample in the boson sampling is determined. This method converts the unitary transformation matrix into the target matrix. Based on the target matrix and the preset formula, it can simulate and calculate each sample in the boson sampling and estimate the probability of each sample, thereby achieving a quantitative evaluation of the technical effect of the output results of the "Nine Chapters" quantum computer.
[0105] In an exemplary embodiment, the preset formula in step S103 includes a first preset formula. Figure 5 This is a method flowchart illustrating step S103, according to an exemplary embodiment, of determining the probability of a sampled sample in boson sampling based on the target matrix and a preset formula, as shown below. Figure 5 As shown, it includes the following steps:
[0106] Step S501: Determine the product sum formula of the target matrix;
[0107] Step S502: Determine the probability of the sampled sample in the boson sampling based on the product sum of the target matrix and the first preset formula.
[0108] In step S501, the product sum of matrix A is denoted as Per(A). According to the definition of the product sum of matrices, the product sum of matrix A is expressed as:
[0109]
[0110] Here, set C represents all permutations of natural numbers from 1 to N, and there are a total of N! permutations and combinations in this set. δ represents any permutation or combination in set C, and δ(i) represents the i-th element in this permutation or combination.
[0111] It is clear that the product sum of matrix A is to calculate the product of any elements that are not in the same row or column, and then add up the N! product results.
[0112] Taking a three-dimensional matrix as an example, the product sum of the target matrix is calculated using the following method:
[0113] Let the three-dimensional matrix be denoted as matrix A3, and expressed as:
[0114]
[0115] According to the definition of the product sum of matrices, the product sum of matrix A3 is expressed as:
[0116] Per(A3) = a 11 ·a22 ·a 33 +a 11 ·a 23 ·a 32 +a 12 ·a 21 ·a 33 +a 12 ·a 23 ·a 31 +a 13 ·a 22 ·a 31 +a 13 ·a 21 ·a 32
[0117] The above product formula is simulated using a device with 3 input ports and 3 output ports. A small ball is placed into any one of the input ports, and the random motion of the ball simulates the behavior of a photon. The ball will fall into any one of the output ports with a certain probability. Let a be the probability that the ball enters from the j-th input port and then falls into the i-th output port. ij Then matrix A3 can represent the probability transition matrix of the simulation device. Each time, three balls are simultaneously placed into the three input ports, and the number of balls falling into the output port is observed, forming a sample. The k-th sample is denoted as... For example, S k =[3,0,0] means that all 3 balls fall into the first output port, S k =[2,0,1] indicates that 2 balls fall into the first output port and 1 ball falls into the third output port.
[0118] When a small ball falls into each output port, the sample is represented by S0 = [1,1,1]. Figure 6 This is a schematic diagram of a simulation device according to an exemplary embodiment, such as... Figure 6 As shown, there are a total of 6 combinations that can generate this sample. The probability of each combination corresponds to a term in the formula for calculating the product of a three-dimensional matrix. Therefore, the probability of sample S0 occurring is the product of matrix A3, which satisfies:
[0119] Pr(S0)=Per(A3)
[0120] Where Pr(S0) represents the probability of sample S0 occurring, and Per(A3) represents the product of matrix A3.
[0121] The method for calculating the product of three-dimensional matrices can be extended to the calculation of the product of high-dimensional matrices A. Therefore, calculating the product of the target matrix is equivalent to calculating the probability of sample S0 occurring, where sample S0 is the result of N balls being placed into N input ports and a ball falling into each of the N output ports. Repeating the above process, the number of samples where S0 = [1,1,1] occurs, divided by the total number of experiments, yields Pr(S0). Let N be the total number of samples. Total The number of times sample S0 appears is denoted as but:
[0122]
[0123] Based on permutations and combinations, the total number of output samples obtained from N input ports and N output ports is: By counting the number of occurrences of sample S0, the product of the target matrix A can be estimated through simulation.
[0124] In step S502, the first preset formula is:
[0125]
[0126] Among them, S i Pr(S) represents the i-th sampled sample in boson sampling. i B represents the probability of the i-th sample. i Let |B| represent the transformation matrix corresponding to the i-th sample. i | 2 Represents the target matrix, Per(|B i | 2 ) represents the product sum of the target matrix. This represents the number of photons at the k-th output port in the i-th sample.
[0127] Based on the number of photons at each output port in the i-th sample and the unitary transformation matrix B, the transformation matrix B corresponding to that sample is obtained. i According to the transformation matrix B i The target matrix A is obtained, i.e., |B i | 2 After calculating the product of the target matrix A using the simulation method described in step S501, the probability of the i-th sample can be calculated according to the first preset formula.
[0128] In one exemplary embodiment, Figure 7 This is a flowchart illustrating a method for determining the product sum of the target matrix in step S501 according to an exemplary embodiment, as shown below. Figure 7 As shown, it includes the following steps:
[0129] Step S701: Generate a set that corresponds one-to-one with the columns of the target matrix. The set includes N consecutively connected sub-intervals and covers [0,1].
[0130] Step S702: Perform the following sampling process multiple times to generate multiple samples: generate random probability values corresponding to the columns of the target matrix, and determine the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column;
[0131] Step S703: Calculate the probability of occurrence of a set sample among multiple samples, and use the occurrence probability as the product of the target matrix. The set sample is: any two of the N position identifiers corresponding to the random probability values of N columns are different.
[0132] Due to the target matrix It is transformed from the unitary matrix B. According to the properties of the unitary matrix, the sum of all elements in each column of the target matrix A is 1, that is:
[0133]
[0134] Where i represents the i-th row of the target matrix, j represents the j-th column of the target matrix, and the matrix element a in the target matrix... ij This represents the probability that the j-th ball will fall into the i-th output port.
[0135] Based on the element values of each column in the target matrix, generate a set that corresponds one-to-one with each column of the target matrix. Within each set, divide the value range [0,1] into N sub-intervals. Each sub-interval is a probability interval formed by the element values of the columns in the target matrix. The length of each sub-interval is a. ij Each sub-interval in each set corresponds one-to-one with an element in the corresponding column, and the position of the sub-interval in the N sub-intervals is the same as the position of the corresponding element in the N elements of the column.
[0136] In one example, Figure 8 This is a schematic diagram of line segments for each set according to an exemplary embodiment, such as... Figure 8 As shown, a set corresponding to the j-th column of the target matrix is generated. This set divides the value range [0,1] into multiple sub-intervals, where sub-interval a... j1 The length of the subinterval a is the value of the first element in the j-th column of the target matrix. j2 The length of is the value of the second element in the j-th column of the target matrix, and the subinterval a jk The length of the subinterval a is the value of the k-th element in the j-th column of the target matrix. jN If the length of the first subinterval is the value of the Nth element in the j-th column of the target matrix, then the range of the first subinterval is [0, a]. j1The range of values for the second subinterval is [a]. j1 a j1 +a j2 The range of values for the k-th subinterval is [a] j1 +a j2 +…++a j(k-1) a j1 +a j2 +…++a jk The range of values for the Nth subinterval is [a] j1 +a j2 +…++a j(N-1) ,1).
[0137] Multiple samples are generated by performing multiple sampling processes: generating random probability values corresponding to each column of the target matrix, and determining the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column.
[0138] In one example, the random probability value p corresponding to the j-th column of the target matrix is generated. j random probability value p j Given a uniform distribution between [0, 1], determine the random probability value p. j The position identifier of the sub-interval in the set corresponding to the j-th column, for example, a. j1 <p j j1 +a j2 If the value is zero, it means that the random probability value belongs to the second sub-interval in the set corresponding to the j-th column. Repeat the above process multiple times to obtain the position identifier of the sub-interval to which the random probability value of each column of the target matrix belongs in the set of the corresponding column.
[0139] The product of the target matrix is equal to the probability of a sample where every output port has a ball. That is, any two positions of the N random probability values corresponding to the N columns of the target matrix are different. Any two positions of the N random probability values corresponding to the N columns are marked as the set sample. The probability of the set sample appearing in the generated samples is calculated. This probability is the product of the target matrix.
[0140] For example, the target matrix is:
[0141]
[0142] The first column of the target matrix corresponds to the set {0.4, 0.2, 0.4}, with the first sub-interval having a length of 0.4 and a value range of [0, 0.4]. The second sub-interval has a length of 0.2 and a value range of [0.4, 0.6]. The third sub-interval has a length of 0.4 and a value range of [0.6, 1]. The second column of the target matrix corresponds to the set {0.3, 0.4, 0.3}, with the first sub-interval having a length of 0.3 and a value range of [0, 0.3]. The length of the first two sub-intervals is 0.4, with a value range of [0.3, 0.7], and the length of the third sub-interval is 0.3, with a value range of [0.7, 1]. The set corresponding to the third column of the target matrix is {0.5, 0.4, 0.1}, with the length of the first sub-interval being 0.5, with a value range of [0, 0.5], the length of the second sub-interval being 0.4, with a value range of [0.5, 0.9], and the length of the third sub-interval being 0.1, with a value range of [0.9, 1].
[0143] For the sample: the random probability value corresponding to column 1 is 0.5, belonging to the second sub-interval; the random probability value corresponding to column 2 is 0.2, belonging to the first sub-interval; and the random probability value corresponding to column 3 is 0.95, belonging to the third sub-interval. Since the position identifier of the sub-interval corresponding to the random probability value generated in each column is different, this sample is the target sample. Multiple random probability values are generated for each column, and the position identifier of the sub-interval to which the random probability value of each column belongs is determined to obtain multiple samples. The probability of occurrence of the target sample is calculated, which is the product sum of the target matrix.
[0144] To verify the accuracy of the above matrix product sum calculation method, the product sums of 6-dimensional to 9-dimensional matrices were calculated using a computing platform, and then the product sums of 6-dimensional to 9-dimensional matrices were obtained using the simulation method described above. Figure 9 This is a schematic diagram comparing the calculation results of the matrix product sum according to an exemplary embodiment, such as... Figure 9 As shown, it can be seen that the matrix product sum calculated by the above simulation method is exactly the same as the matrix product sum calculated by the computing platform. Therefore, the above simulation method can estimate the matrix product sum.
[0145] The above simulation method can be used to estimate the product sum of matrices with dimensions of 12 or more. For example, consider the following 12-dimensional matrix:
[0146]
[0147] The product formula can be estimated to be 1.0630665884e-04 using the method in this disclosure;
[0148] A 15-dimensional matrix as shown below:
[0149]
[0150] The product formula can be estimated as 6.1579271470e-06 using the method described in this disclosure.
[0151] In one exemplary embodiment, the preset formula in step S103 includes a second preset formula. Figure 10 This is a flowchart illustrating a method for determining the probability of a sampled sample in boson sampling based on a target matrix and a preset formula in step S103, according to an exemplary embodiment. Figure 10 As shown, it includes the following steps:
[0152] Step S1001: Obtain the number of sampling processes that generate each sample in the boson sampling;
[0153] Step S1002: Based on the target matrix, determine the probability of the sampling process for each sampled sample;
[0154] Step S1003: Determine the probability of each sample in the boson sampling based on the number of sampling processes for each sample, the probability of the sampling process, and the second preset formula.
[0155] During the generation of sampled samples, multiple sampling processes may output the same sampled sample. Each sampling process generates a different combination of samples. For example, for three-dimensional boson sampling, the sampled sample S0 = [1,1,1] indicates that each output port outputs one photon. Figure 6 It can represent different combinations that generate the sample, and each combination is a sampling process of the sample. Then the number of sampling processes of the sample S0 = [1,1,1] is 6.
[0156] For any sample The number of sampling processes for each sample can be obtained using the following formula:
[0157]
[0158] Among them, S i Num_P(S) represents the i-th sampled sample in boson sampling. i ) represents the number of sampling processes for the i-th sample. This represents the number of photons at the k-th output port in the i-th sample.
[0159] For example, using the above formula, the sample S k When the value is [3,0,0], only one sampling process can generate this sample.
[0160] Each sampling process also has its probability of occurrence, which is the product of the probabilities of the corresponding combined events. For example, a sampling process for sample S0 = [1,1,1] is: the first photon falls into the first output port, the second photon falls into the second output port, and the third photon falls into the third output port. The probability of this sampling process occurring is the product of the probabilities of the first photon falling into the first output port, the second photon falling into the second output port, and the third photon falling into the third output port. Since the element a in the target matrix... ij If we can represent the probability that the j-th photon falls into the i-th output port, then the probability of this sampling process can be expressed as a. 11 ·a 22 ·a 33 Therefore, for any sampled sample Based on its corresponding target matrix, the probability of each sampling process of the sample can be obtained.
[0161] For any sample After obtaining the number of sampling processes and the probability of each sampling process, the probability of a sample in the boson sampling is determined using the following formula, namely the second preset formula:
[0162]
[0163] Among them, S i Pr(S) represents the i-th sampled sample in boson sampling. i ) represents the probability of the i-th sample. Process i This represents the probability of the first sampling process occurring during the process of generating the i-th sample in the simulation.
[0164] It should be noted that we use the probability of a single sampling process. i This method approximates the probability of all sampling processes for the sampled sample, and obtains the upper probability limit of the most probable samples in the sampled sample set.
[0165] It should be noted that in this disclosure, the probability of a Boson sample can be calculated based on both the first and second preset formulas. However, the calculation using the first preset formula is limited by computing resources. The second preset formula simplifies the calculation process and allows for a more convenient estimation of the upper limit of the probability of a higher-dimensional Boson sample.
[0166] In an exemplary embodiment of this disclosure, an apparatus for simulating Bose sampling is provided. Figure 11 This is a block diagram illustrating an apparatus for simulating boson sampling according to an exemplary embodiment, such as... Figure 11 As shown, it includes:
[0167] The first determining module 1101 is configured to determine the unitary transformation matrix of the interferometric network based on the number of ports N of the interferometric network of the boson sampling system, wherein the unitary transformation matrix is an N-order unitary matrix.
[0168] The second determining module 1102 is configured to determine a target matrix based on the unitary transformation matrix, wherein each element in the target matrix is the square of the modulus of the elements at the same position in the unitary transformation matrix;
[0169] The third determining module 1103 is configured to determine the probability of a sample in boson sampling based on the target matrix and a preset formula, wherein the preset formula represents the relationship between the target matrix and the probability of the sample.
[0170] The boson sampling includes isophoton boson sampling and isophoton boson sampling.
[0171] In one exemplary embodiment, the preset formula includes a first preset formula;
[0172] The third determining module 1103 is further configured to:
[0173] Determine the product sum formula of the target matrix;
[0174] The probability of a sample in the boson sampling is determined based on the product of the target matrix and the first preset formula.
[0175] In an exemplary embodiment, the third determining module 1103 is further configured to:
[0176] Generate a set that corresponds one-to-one with the columns of the target matrix, the set comprising N consecutively connected sub-intervals, the set covering [0,1];
[0177] Multiple samples are generated by performing the following sampling process multiple times: generating random probability values corresponding to each column of the target matrix, and determining the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column;
[0178] The probability of a given sample appearing in the plurality of samples is statistically determined, and the probability of appearance is used as the product of the target matrix. The given sample is defined as: any two of the N position identifiers corresponding to the random probability values of the N columns are different.
[0179] In an exemplary embodiment, the third determining module 1103 is further configured to:
[0180] Each sub-interval in each set corresponds one-to-one with an element in the corresponding column, and the position of the sub-interval in the N sub-intervals is the same as the position of the corresponding element in the N elements of the column.
[0181] In an exemplary embodiment, the third determining module 1103 is further configured to:
[0182] The first preset formula is:
[0183]
[0184] Among them, S i Pr(S) represents the i-th sampled sample in boson sampling. i B represents the probability of the i-th sample. i The transformation matrix representing the unitary transformation matrix corresponding to the i-th sample, |B i | 2 Let Per(|B) represent the target matrix. i | 2 ) represents the product sum of the target matrix. This represents the number of photons at the k-th output port in the i-th sample.
[0185] In one exemplary embodiment, the preset formula includes a second preset formula;
[0186] The third determining module 1103 is further configured to:
[0187] Obtain the number of sampling processes that generate each of the sampled samples in the boson sampling process;
[0188] Based on the target matrix, determine the probability of the sampling process for each of the sampled samples;
[0189] The probability of each sample in the boson sampling is determined based on the number of sampling processes for each sample, the probability of the sampling process, and the second preset formula.
[0190] In an exemplary embodiment, the third determining module 1103 is further configured to:
[0191] The number of sampling processes for each sampled sample is obtained using the following formula:
[0192]
[0193] Among them, S i Num_P(S) represents the i-th sampled sample in boson sampling. i ) represents the number of sampling processes for the i-th sample. This represents the number of photons at the k-th output port in the i-th sample;
[0194] The second preset formula is:
[0195]
[0196] Among them, S i Pr(S) represents the i-th sampled sample in boson sampling. i ) represents the probability of the i-th sample, Process i This represents the probability of the first sampling process occurring during the simulation of generating the i-th sample.
[0197] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.
[0198] Figure 12 This is a block diagram of a simulated Bose sampling apparatus 1200 according to an exemplary embodiment.
[0199] Reference Figure 12 The device 1200 may include one or more of the following components: a processing component 1202, a memory 1204, a power supply component 1206, a multimedia component 1208, an audio component 1210, an input / output (I / O) interface 1212, a sensor component 1214, and a communication component 1216.
[0200] Processing component 1202 typically controls the overall operation of device 1200, such as operations associated with display, telephone calls, data communication, camera operation, and recording operations. Processing component 1202 may include one or more processors 1220 to execute instructions to perform all or part of the steps of the methods described above. Furthermore, processing component 1202 may include one or more modules to facilitate interaction between processing component 1202 and other components. For example, processing component 1202 may include a multimedia module to facilitate interaction between multimedia component 1208 and processing component 1202.
[0201] Memory 1204 is configured to store various types of data to support the operation of device 1200. Examples of such data include instructions for any application or method operating on device 1200, contact data, phonebook data, messages, pictures, videos, etc. Memory 1204 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0202] Power supply assembly 1206 provides power to various components of device 1200. Power supply assembly 1206 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to device 1200.
[0203] Multimedia component 1208 includes a screen that provides an output interface between the device 1200 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of the touch or swipe action but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 1208 includes a front-facing camera and / or a rear-facing camera. When the device 1200 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
[0204] Audio component 1210 is configured to output and / or input audio signals. For example, audio component 1210 includes a microphone (MIC) configured to receive external audio signals when device 1200 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 1204 or transmitted via communication component 1216. In some embodiments, audio component 1210 also includes a speaker for outputting audio signals.
[0205] I / O interface 1212 provides an interface between processing component 1202 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.
[0206] Sensor assembly 1214 includes one or more sensors for providing status assessments of various aspects of device 1200. For example, sensor assembly 1214 may detect the on / off state of device 1200, the relative positioning of components such as the display and keypad of device 1200, changes in the position of device 1200 or a component of device 1200, the presence or absence of user contact with device 1200, the orientation or acceleration / deceleration of device 1200, and temperature changes of device 1200. Sensor assembly 1214 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 1214 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 1214 may also include an accelerometer, a gyroscope, a magnetometer, a pressure sensor, or a temperature sensor.
[0207] Communication component 1216 is configured to facilitate wired or wireless communication between device 1200 and other devices. Device 1200 can access wireless networks based on communication standards, such as WiFi, 2G, or 3G, or combinations thereof. In one exemplary embodiment, communication component 1216 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 1216 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
[0208] In an exemplary embodiment, the apparatus 1200 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described above.
[0209] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 1204 including instructions, which can be executed by a processor 1220 of the device 1200 to perform the above-described method. For example, the non-transitory computer-readable storage medium may be a ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, and optical data storage device, etc.
[0210] A non-transitory computer-readable storage medium, when instructions in the storage medium are executed by a processor of a device, enables the device to perform a method of simulating boson sampling, the method comprising any of the methods described above.
[0211] Other embodiments of the invention will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the invention that follow the general principles of the invention and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of the invention are indicated by the following claims.
[0212] It should be understood that the present invention is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of the invention is limited only by the appended claims.
Claims
1. A method for simulating boson sampling, characterized in that, The method includes: Based on the number of ports N of the interferometric network of the Bose sampling system, the unitary transformation matrix of the interferometric network is determined, and the unitary transformation matrix is an N-order unitary matrix; The target matrix is determined based on the unitary transformation matrix, wherein each element in the target matrix is the square of the modulus of the element at the same position in the unitary transformation matrix; Based on the target matrix and the preset formula, the probability of the sampled sample in the boson sampling is determined, wherein the preset formula represents the relationship between the target matrix and the probability of the sampled sample; The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes: determining the product sum of the target matrix; determining the product sum of the target matrix includes: Generate a set that corresponds one-to-one with the columns of the target matrix, the set comprising N consecutively connected sub-intervals, the set covering [0,1]; Multiple samples are generated by performing the following sampling process multiple times: generating random probability values corresponding to each column of the target matrix, and determining the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column; The probability of a given sample appearing in the plurality of samples is statistically determined, and the probability of appearance is used as the product of the target matrix. The given sample is defined as: any two of the N position identifiers corresponding to the random probability values of N columns are different. The boson sampling includes isophoton boson sampling and isophoton boson sampling.
2. The method for simulating boson sampling according to claim 1, characterized in that, The preset formula includes a first preset formula; The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes: The probability of a sample in the boson sampling is determined based on the product of the target matrix and the first preset formula.
3. The method for simulating boson sampling according to claim 2, characterized in that, The method further includes: Each sub-interval in each set corresponds one-to-one with an element in the corresponding column, and the position of the sub-interval in the N sub-intervals is the same as the position of the corresponding element in the N elements of the column.
4. The method for simulating boson sampling according to claim 2, characterized in that, The step of determining the probability of a sample in boson sampling based on the product of the target matrix and the first preset formula includes: The first preset formula is: in, Indicates the boson sampling number One sample, Indicates the first The probability of a sampled item. Indicates the first The transformation matrix of the unitary transformation matrix corresponding to each sampled sample. Represents the target matrix, This represents the product sum of the target matrix. Indicates the first The th sample in the th sampling sample The number of photons per output port.
5. The method for simulating boson sampling according to claim 1, characterized in that, The preset formula includes a second preset formula; The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes: Obtain the number of sampling processes that generate each of the sampled samples in the boson sampling process; Based on the target matrix, determine the probability of the sampling process for each of the sampled samples; The probability of each sample in the boson sampling is determined based on the number of sampling processes for each sample, the probability of the sampling process, and the second preset formula.
6. The method for simulating boson sampling according to claim 5, characterized in that, The method further includes: The number of sampling processes for each sampled sample is obtained using the following formula: in, Indicates the boson sampling number One sample, Indicates the first The number of sampling processes for each sample. Indicates the first The th sample The number of photons per output port; The second preset formula is: in, Indicates the boson sampling number One sample, Indicates the first The probability of a sampled item. The simulation generates the first... The probability of the first sampling process occurring during the sampling process.
7. A device for simulating boson sampling, characterized in that, The device includes: The first determining module is configured to determine the unitary transformation matrix of the interferometric network based on the number of ports N of the interferometric network of the boson sampling system, wherein the unitary transformation matrix is an N-order unitary matrix. The second determining module is configured to determine a target matrix based on the unitary transformation matrix, wherein each element in the target matrix is the square of the modulus of the elements at the same position in the unitary transformation matrix; The third determining module is configured to determine the probability of a sample in the boson sampling based on the target matrix and a preset formula, wherein the preset formula represents the relationship between the target matrix and the probability of the sample. The step of determining the probability of a sample in boson sampling based on the target matrix and a preset formula includes: determining the product sum of the target matrix; determining the product sum of the target matrix includes: Generate a set that corresponds one-to-one with the columns of the target matrix, the set comprising N consecutively connected sub-intervals, the set covering [0,1]; Multiple samples are generated by performing the following sampling process multiple times: generating random probability values corresponding to each column of the target matrix, and determining the position identifier of the sub-interval to which the random probability value belongs in the set corresponding to the column; The probability of a given sample appearing in the plurality of samples is statistically determined, and the probability of appearance is used as the product of the target matrix. The given sample is defined as: any two of the N position identifiers corresponding to the random probability values of N columns are different. The boson sampling includes isophoton boson sampling and isophoton boson sampling.
8. A device for simulating boson sampling, characterized in that, include: processor; Memory used to store processor-executable instructions; The processor is configured to perform the method as described in any one of claims 1-6.
9. A non-transitory computer-readable storage medium, characterized in that, When the instructions in the storage medium are executed by the processor of the device, the device is able to perform the method as described in any one of claims 1-6.
Citation Information
Patent Citations
Glass color sampling simulation method and system considering photon loss and medium
CN112560280A