Entangled Boltzmann Machine Apparatus and Method
Entangled Boltzmann machines simulate quantum tunneling effects and utilize probabilistic superposition states to achieve multi-node entanglement, solving the problems of slow convergence speed and high cost in combinatorial optimization problems, and achieving efficient and low-cost global optimal solutions.
Patent Information
- Application Number
- CN202411464525.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-21
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2044-10-21
AI Technical Summary
Existing technologies for solving combinatorial optimization problems, especially large-scale problems, suffer from slow convergence speed, high cost, and sensitivity to environmental noise, making it difficult to efficiently find the global optimal solution.
An entangled Boltzmann machine is used to simulate the quantum tunneling effect through a probabilistic qubit node array, a random sampling device, a probability calculation device, and a driving device. Entanglement between multiple nodes is achieved by utilizing probabilistic superposition states, which guides the solution of combinatorial optimization problems.
It significantly improves the efficiency and success rate of solving combinatorial optimization problems on classical computers, reduces costs, and enhances the ability to obtain the global optimal solution.
Smart Images

Figure CN119416832B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to an entangled Boltzmann machine apparatus and method, which is applicable to solving combinatorial optimization problems. Background Technology
[0002] Combinatorial optimization problems (COPs) are widespread in many scientific research and engineering applications, including logistics optimization, network design, resource allocation, scheduling problems, and machine learning. The essence of combinatorial optimization is to find the global optimum from a large set of discrete candidate solutions. Because combinatorial optimization problems typically have high dimensionality and complex constraints, the difficulty of solving them increases exponentially with the problem size. These problems can often be reduced to an energy model, with the candidate solution set corresponding to an energy phase space. In this large and rugged energy phase space, many local optima exist. Any algorithm that relies solely on local energy gradient updates will likely get trapped in local optima. Therefore, efficient algorithms for solving such problems need to be able to overcome energy barriers and reach the global optimum.
[0003] Currently, there are two main approaches to escape local optima: classical thermal excitation and quantum tunneling. The former can be implemented in the simulated annealing (SA) algorithm, and its core step is to determine the probability of accepting a new solution using the Metropolis rule: p = min{1, exp(-ΔE / k)} B T)}, where ΔE=E new -E old k represents the energy difference between the new and old solutions. B Let be the Boltzmann constant, and T be the system temperature. If ΔE < 0, p = 1, then the new solution will be accepted absolutely; otherwise, p = exp(-ΔE / k). B If the temperature T is low, the algorithm will use random probability sampling to decide whether to accept a new solution. As the temperature T decreases, the algorithm gradually reduces the probability of accepting worse solutions, eventually converging to the global optimum or a near-optimal solution. However, in actual annealing processes, SA suffers from slow convergence speed and divergence at extremely low temperatures. Another method is achieved through quantum tunneling, typically used in quantum annealing machines or quantum computers. Taking a quantum annealing machine as an example, it applies an additional strong transverse magnetic field H to the classical Ising Hamiltonian. x To achieve quantum superposition states, in H x As the system gradually decreases to 0, it escapes local optima through quantum tunneling and eventually reaches H. x The state obtained when = 0 is estimated as the global optimal solution. However, quantum annealing requires a highly precise quantum system to achieve quantum tunneling under harsh physical conditions such as low temperatures, which is costly and highly sensitive to environmental noise.
[0004] Therefore, there is still a need for a solution device and method that can solve combinatorial optimization problems at low cost and high efficiency. Summary of the Invention
[0005] To address the above problems, this invention is proposed.
[0006] One embodiment provides an entangled Boltzmann machine device, comprising: a probability bit node array including a plurality of probability bit nodes, each probability bit node being used to generate a true random number with a desired probability; a random sampling device for sampling the current state of the plurality of entangled probability bit nodes in the probability bit node array; a probability calculation device for calculating the entanglement probability distribution of the plurality of entangled probability bit nodes based on their current states; a decision device for deciding whether to change the current state of the plurality of entangled probability bit nodes to a target state based on the entanglement probability distribution of the plurality of entangled probability bit nodes; and a driving device for adjusting the driving signals of the plurality of entangled probability bit nodes to achieve the target state in response to the decision device deciding to change the current state of the plurality of entangled probability bit nodes to the target state.
[0007] In one example, the probabilistic bit node includes a magnetic tunnel junction configured to receive a critical switching voltage or current to enable random switching between a high-resistivity state and a low-resistivity state, and also to receive a bias voltage or current to control the switching probability.
[0008] In one example, the probability calculation device includes: a conditional probability calculation unit, configured to calculate the conditional probability of each entangled probability bit node based on the current state of a plurality of entangled probability bit nodes, the conditional probability indicating the probability that one or more of the plurality of entangled probability bit nodes will have a state given that one or more of the plurality of entangled probability bit nodes have a predetermined state; and an entanglement probability calculation unit, configured to calculate the entanglement probability distribution of the plurality of entangled probability bit nodes in various states based on the conditional probability of each entangled probability bit node.
[0009] In one example, the entanglement probability calculation unit includes: a transition matrix calculation module, used to determine the probability superposition state of each entangled probability bit node based on the conditional probability of each entangled probability bit node, and calculate the probability transition matrix between the probability superposition states of the plurality of entangled probability bit nodes; and an entanglement probability calculation module, used to calculate the steady-state entanglement probability distribution or the non-steady-state entanglement probability distribution of the plurality of entangled probability bit nodes in various states when or before the probability transition process between the probability superposition states of the plurality of entangled probability bit nodes reaches stability.
[0010] In one example, the decision-making device is configured to normalize the steady-state or non-steady-state entanglement probabilities of two or more target states among various states of the plurality of entangled probability bit nodes, and to perform binary sampling on the normalized probabilities to determine whether to change the current state of the plurality of entangled probability bit nodes to a different target state.
[0011] In one example, the decision-making device further includes: an energy calculation unit, configured to calculate the total system energy corresponding to the changed target state when the decision-making device decides to change the current state of the plurality of entangled probability bit nodes to a different target state; an optimal solution determination unit, configured to compare the total system energy corresponding to the target state with a previously determined optimal total energy, and determine the changed target state as the optimal solution when the total system energy corresponding to the target state is better than the previously determined optimal total energy; an optimal solution storage unit, configured to store the target state as the updated optimal solution and its corresponding total system energy as the optimal total energy; and an output unit, configured to output the optimal solution and the optimal total energy when the determined optimal solution or optimal total energy satisfies a predetermined convergence condition, and to stop the sampling operation of the current state of the plurality of entangled probability bit nodes in the probability bit node array.
[0012] In one example, the driving device is configured to adjust the bias voltage or current of the magnetic tunnel junction in the plurality of entangled probability bit nodes to achieve the target state with an entanglement probability corresponding to the target state.
[0013] Another embodiment provides a method for operating an entangled Boltzmann machine, comprising: generating a true random number with a desired probability using each of a plurality of probabilistic bit nodes included in a probabilistic bit node array; sampling the current state of the plurality of entangled probabilistic bit nodes in the probabilistic bit node array using a random sampling device; calculating the entanglement probability distribution of the plurality of entangled probabilistic bit nodes based on their current states using a probability calculation device; determining whether to change the current state of the plurality of entangled probabilistic bit nodes to a target state based on the entanglement probability distribution of the plurality of entangled probabilistic bit nodes using a decision device; and adjusting the drive signals of the plurality of entangled probabilistic bit nodes to achieve the target state in response to the decision device's decision to change the current state of the plurality of entangled probabilistic bit nodes to the target state using a driving device.
[0014] In one example, the probabilistic bit node includes a magnetic tunnel junction configured to receive a critical switching voltage or current to enable random switching between a high-resistivity state and a low-resistivity state, and also to receive a bias voltage or current to control the switching probability.
[0015] In one example, using a probability calculation device to calculate the entanglement probability distribution of multiple entangled probability bit nodes based on their current states includes: calculating the conditional probability of each entangled probability bit node based on its current state by a conditional probability calculation unit, wherein the conditional probability indicates the probability that one or more other entangled probability bit nodes will have a state given that one or more of the multiple entangled probability bit nodes have a predetermined state; and calculating the entanglement probability distribution of the multiple entangled probability bit nodes in various states by the entanglement probability calculation unit based on their conditional probabilities.
[0016] In one example, the entanglement probability calculation unit calculates the entanglement probability distribution of the multiple entanglement probability bit nodes in various states based on the conditional probability of each entanglement probability bit node. This includes: the transition matrix calculation module determining the probability superposition state of each entanglement probability bit node based on its conditional probability, and calculating the probability transition matrix between the probability superposition states of the multiple entanglement probability bit nodes; and the entanglement probability calculation module calculating the steady-state or non-steady-state entanglement probability distribution of the multiple entanglement probability bit nodes in various states when or before the probability transition process between the probability superposition states of the multiple entanglement probability bit nodes reaches stability.
[0017] In one example, using a decision-making device to determine whether to change the current state of the plurality of entangled probability bit nodes to a target state based on the entanglement probability distribution of the plurality of entangled probability bit nodes includes: normalizing the steady-state or non-steady-state entanglement probabilities of two or more target states among the various states of the plurality of entangled probability bit nodes, and performing binary sampling on the normalized probabilities to determine whether to change the current state of the plurality of entangled probability bit nodes to a different target state.
[0018] In one example, the method further includes: when the decision-making device decides to change the current state of the plurality of entangled probability bit nodes to a different target state, the energy calculation unit calculates the total system energy corresponding to the changed target state; the optimal solution determination unit compares the total system energy corresponding to the target state with the previously determined optimal total energy, and when the total system energy corresponding to the target state is better than the previously determined optimal total energy, the changed target state is determined as the optimal solution; the optimal solution storage unit stores the target state as the updated optimal solution and its corresponding total system energy as the optimal total energy; and when the determined optimal solution or optimal total energy satisfies a predetermined convergence condition, the output unit outputs the optimal solution and the optimal total energy, and stops sampling the current state of the plurality of entangled probability bit nodes in the probability bit node array.
[0019] In one example, using a driving device to adjust the driving signals of the plurality of entangled probability bit nodes to achieve the target state in response to the decision device's decision to change the current state of the plurality of entangled probability bit nodes to a target state includes: adjusting the bias voltage or current of the magnetic tunnel junctions in the plurality of entangled probability bit nodes to achieve the target state with an entanglement probability corresponding to the target state. Attached Figure Description
[0020] Figure 1A This is a schematic diagram of a Boltzmann machine model;
[0021] Figure 1B This is a schematic diagram of a restricted Boltzmann machine;
[0022] Figure 2 This is a schematic diagram of the Boltzmann machine model used to solve the traveling salesman problem;
[0023] Figure 3 These are energy probability curves obtained at different temperatures when solving the traveling salesman problem using a conventional Boltzmann machine and the entangled Boltzmann machine of this invention.
[0024] Figure 4 This is an energy curve obtained by using the entangled Boltzmann machine of the present invention to solve the traveling salesman problem, guided by optimization based on the non-steady-state entanglement probability.
[0025] Figure 5 This is a schematic diagram of the hardware architecture of an entangled Boltzmann machine according to an embodiment of the present invention. Detailed Implementation
[0026] Exemplary embodiments of the present invention will now be described.
[0027] The Boltzmann Machine (BM) is a neural network model proposed by Hinton and Sejnowski in 1986. It consists of a visible layer (also called the input layer) and a hidden layer, such as... Figure 1A As shown, the neurons between layers adopt a fully connected structure, and there are connections between neurons within a layer. These neurons have only two states: inactive and activated, generally represented by binary 0 and 1, and the state value is determined by probability statistics. Boltzmann machines have powerful unsupervised learning capabilities and can learn complex rules in data, but their training (learning) time is very long. Furthermore, it is impossible to accurately calculate the distribution represented by Boltzmann (BM), and even obtaining random samples that follow the distribution represented by BM is difficult.
[0028] To overcome this problem, Smolensky introduced a Restricted Boltzmann Machine (RBM), such as... Figure 1B As shown. With Figure 1A Compared to the Boltzmann machine shown, the neurons in the visible and hidden layers of the Restricted Boltzmann Machine (RBM) are independent of each other, with no connections between them. Therefore, given the state of a visible layer unit (input data), the activation conditions of each hidden unit are independent; conversely, given the state of a hidden unit, the activation conditions of the visible layer units are also independent. This allows for the acquisition of random samples following the distribution represented by the RBM through parallel Gibbs sampling. In 2006, Hinton et al. proposed Deep BeliefNets (DBNs), which consist of a stack of several RBMs that can be trained layer by layer from low to high. The bottom RBM is trained using the original input data, and the features extracted from the bottom RBM are used as input data for the top RBM. This training framework bypasses the high complexity of training a complete DBN, simplifying it to the training of multiple RBMs, reducing computational cost, and solving the problem of slow model training speed, laying the foundation for the development of large models.
[0029] In the following text and in the claims of this application, when Boltzmann machines are mentioned, it may refer to conventional Boltzmann machines (e.g., such as...). Figure 1A As shown), it can also refer to a restricted Boltzmann machine (e.g., as shown). Figure 1B (As shown).
[0030] The Boltzmann machine and the Ising model have similar energy expressions: E = Σw ij x i x j +Σb i x i , where x i and x j Let represent the state values, also known as decision values, of the i-th and j-th neurons, respectively, with values of 0 or 1. For simplicity, we use 'x' to represent a neuron node here, without distinguishing between hidden and visible nodes. ij From node x i to node x j The connection weight, b i It is node x i The Boltzmann machine updates nodes using the Gibbs sampling rule, and while keeping the states of other nodes unchanged, updates the target node x according to the fully conditional probability p. i Probability sampling is performed using either 0 or 1, as shown in the following formula:
[0031]
[0032] Where ΔE i ≡E(x i =1|x j≠i)-E(x i =0|x j≠i )=Σ j≠i w ij x j +b i k B Let represent the Boltzmann constant, and T represent temperature. Similar to the Metropolis rule, the final energy distribution of a Boltzmann machine based on Gibbs sampling will approach the Boltzmann distribution, hence the name Boltzmann machine. Note that node x... j≠i Other nodes x can only be accessed through their current actual state (0 or 1). i This method of interaction between nodes exerts influence, and it applies to all classical bits. In stark contrast, qubits (q-bits) can simultaneously encode superposition states 0 and 1. More importantly, the interaction of qubits can occur before the superposition collapses (measurement or sampling), which explains the tunneling mechanism in quantum systems, something impossible in classical systems.
[0033] This application proposes a novel algorithm based on Markov chains and Boltzmann machines (BMs)—entangled Boltzmann machines—which can simulate quantum tunneling on a classical computer. This application also proposes a hardware probabilistic computation architecture, including a probability qubit node array, a random sampling device, a probability computation device, a decision-making device, and a driving device, which can efficiently solve combinatorial optimization problems. In this application, a probability superposition state (PSS) is introduced. i =p|1>+(1-p)|0> into the Gibbs sampling of the Boltzmann machine, thereby realizing probabilistic entanglement between multiple nodes, simulating the tunneling effect in the quantum system in the classical system, and ultimately significantly improving the success rate of obtaining the global optimal solution.
[0034] The principle of two-node entanglement will be described first, which can serve as the basis for implementing entanglement of more nodes. Unlike Gibbs sampling, which updates one node at a time, two-node entanglement allows for simultaneous updates of the states of both nodes. For a Boltzmann machine with two nodes x... i and x j For each node in two states, 0 and 1, Gibbs sampling is performed on the other node in both states, 0 and 1, resulting in four conditional probabilities represented by the following formula (2), i.e., x j When x is 1 and 0, i The probability of x being 1, and x i When x is 1 and 0, j The probability of being 1:
[0035]
[0036] Where E mn x represents i =m,x j =n, β≡1 / k B T. Based on the above conditional probabilities, a probability superposition state (PSS) for each entangled node can be established, i.e., x i =p(x i =1)|1>+p(x i =0)|0> and x j =p(x j =1)|1>+p(x j =0)|0>, and then using Bayesian theory, the entanglement between these two probabilistic superposition states PSS can be determined, as shown in formulas (3a) and (3b) below:
[0037]
[0038] Using the entanglement relationship between two probabilistic superposition states expressed by formulas (3a) and (3b), the Markov transition process of each probabilistic superposition state can be established, as shown in formulas (4a) and (4b) below:
[0039]
[0040] Where n I p represents the number of iterations of the Markov chain. ini p represents the initial probability. s This represents the probability that the iteration converges to a steady state. and This represents the steady-state PSS sampling probability of two entangled objects.
[0041] Based on the two entangled steady-state PSS sampling probabilities obtained from the above analysis, entanglement of more nodes can be established, thereby solving practical combinatorial optimization problems. Taking four-node entanglement as an example, consider x... i x j x k and x l The entanglement of the four nodes divides them into two groups, for example, suppose x i and x j They are two nodes on the same level, x k and x l These are two nodes on another layer. If node x is known... i and x j The state value of node x can then be determined using the two-node entanglement method described above. k and x l The conditional probability p(x) k =1xi ,x j ) and p(x l =1x i ,x j As shown in formula (5) below:
[0042]
[0043] Where m and n represent the allowed state values of node x, i.e., 0 and 1. Considering all possible combinations of (m, n), formula (5) has a total of 16 conditional probabilities. According to Bayesian theory, we can obtain the following from (x i x j ) to (x k x l The probability transition matrix T ij , and from (x k x l ) to (x i x j The probability transition matrix T kl As shown in Formula 6 below:
[0044]
[0045] Similar to the two-node entanglement described above, through the iterative probability transition process shown in formula (6), until a steady state is reached, we will obtain (x i x j ) and (x k x l The steady-state probability distribution of ) can be obtained by solving the matrix T1≡(T ij T kl ) and T2≡(T kl T ij The eigenvectors with eigenvalues of 1 are used to obtain the column vectors corresponding to the steady-state transition matrix, as shown in formula (7) below:
[0046]
[0047] After obtaining the steady-state probability distribution in formula (7) through numerical calculation, the probability p of the four-node entanglement mentioned above can be used as a basis. s Simultaneous sampling (x) i x j x k x l Four nodes are used to achieve steady-state entanglement sampling.
[0048] The following describes an exemplary embodiment of applying the entangled Boltzmann machine of this application to solve combinatorial optimization problems. The Traveling Salesman Problem (TSP) is a classic combinatorial optimization problem. Given several cities and the distances or costs between them, the goal is to find the shortest route such that a traveler starts from a city, visits each city exactly once, and finally returns to the starting city. Taking an N-city TSP problem as an example, we first introduce how to transform it into a traditional Boltzmann machine model. Figure 2 As shown, the TSP problem is encoded as an N×N network, where each node x in the network... ij Let x represent the probability that the traveling salesman visits the j-th city on day i. ij =1, which indicates a visit to the city; if x = 1, then the city is visited; ij =0 indicates that the city will not be visited. Therefore, we can define a matrix X = {x ij The entire scheduling can be represented by}. Map information can be defined as a distance matrix D = {d ij}, where d ij This represents the distance from the i-th city to the j-th city. Furthermore, an N×N constant delay matrix R can be defined to simplify the calculation of the total distance for a route:
[0049]
[0050] Therefore, the total distance E can be calculated. d =Tr(X·D·X) R T ), where X R =R·X. Besides the contribution of distance, some constraints can be added to the Boltzmann machine model to meet the requirements of the TSP problem, such as the constraint that each city must be visited once and only one city can be visited per day, i.e. and The contribution of these constraints to the total energy can be represented by a penalty term. In other words, the magnitude of the penalty factor λ determines whether these constraints are relaxed or strengthened. The final total energy of the system is E = E0 p +E d After simplification, it can be expressed as the energy representation of a Boltzmann machine. If a traditional Boltzmann machine is used to solve this problem at a single temperature, that is, by continuously sampling the nodes according to the Gibbs sampling rule, the probability of the final system energy occurrence conforms to the Boltzmann distribution.
[0051] Compared to traditional Boltzmann machines, the entangled Boltzmann machine of this invention can solve the traveling salesman problem more efficiently. It still uses the same network structure as traditional Boltzmann machines (e.g., Figure 2As shown in the diagram, the penalty factor λ is used as the entanglement constant between nodes of the entangled Boltzmann machine to adjust the strength of entanglement or association. The specific process of the algorithm is as follows: Under a suitable temperature, the N×N network is initialized to any reasonable solution of the TSP problem, that is, each row and each column has exactly one node with a value of 1, and the rest have values of 0. Then, an iterative loop is performed. In each loop, two rows of the network model are arbitrarily selected, and the transition from one reasonable solution to another is completed by swapping the node values of these two rows. It can be understood that the row swapping operation will change the values of the four nodes in the network model, so the steady-state probability of the four-node entanglement described above can be used to guide the decision. As mentioned earlier, the conditional probability between the four selected nodes is first calculated to establish the corresponding probability transition matrix, and then the steady-state probability distribution of the transition matrix is calculated, from which the steady-state probabilities corresponding to the 16 states of the four nodes can be obtained. Since the four nodes can only be in two states before and after the row swap operation, the sampling probabilities corresponding to these two states are normalized twice. The normalized probability result is used to guide whether to execute the row swap operation (i.e., perform a binary sampling with known probabilities, where the sample value is 0 or 1; 1 means execute the swap operation, and 0 means do not execute it). Finally, the total system energy after this operation is calculated. If it is smaller than the optimal energy found in the previous loop, it means that the network node value after this swap operation is the newly obtained optimal solution, which is saved as the current optimal solution, and the optimal energy value is updated. If the total system energy after the swap operation is greater than the optimal energy found in the previous loop, it means that the network node value after this swap operation is not the optimal solution, and it is not necessary to save it as the optimal solution or update the optimal energy value. This completes one loop. The above loop process is repeated until a solution with a total energy (total path) that meets the requirements or a known global optimal solution is found. Then the loop stops, and the optimal solution and the corresponding path selection are output.
[0052] The following is a pseudocode example of an entangled Boltzmann machine:
[0053] Input: N×N network model, distance matrix D={d ij}, temperature T, entanglement constant λ, total energy of the optimal solution E_best_solution, convergence condition ε, where the distance matrix D={d ij The total energy of the optimal solution, E_best_solution, is given by the Bays29 instance (number of cities N=29) in the Traveling Salesman Problem library TSP-LIB. The range of values for the two parameters, temperature T and entanglement constant λ, depends on the specific Traveling Salesman Problem instance. Different examples may correspond to different parameter ranges. The optimal values can be determined empirically, and the convergence condition ε can also be determined empirically.
[0054] Initialization: For the N×N network model, there is an initial arbitrary reasonable solution X0, corresponding to the total energy E0. Let the optimal energy E_min = E0, and the optimal solution X min = X0;
[0055] While |E_min - E_best_solution| > ε (that is, if the convergence condition is not satisfied, perform the following loop operation):
[0056] Randomly select any two rows i, j (1 ≤ i, j ≤ N, and i ≠ j), and determine the four relevant nodes whose values will change when these two rows are exchanged;
[0057] Calculate the conditional probabilities p, q, P, Q between the four selected nodes,
[0058] Establish a probability transition matrix;
[0059] Calculate the steady-state probability distribution of the probability transition matrix;
[0060] Perform quadratic normalization on the steady-state probabilities of the two target states;
[0061] According to the normalized probabilities, perform binary sampling to decide whether to exchange row i and row j;
[0062] If the exchange operation is performed, update the network structure to the exchanged X’, and calculate the corresponding total system energy E_new;
[0063] If E_new < E_min, save the current network structure X’ as the optimal solution X min , that is X min
[0064] = X’, and save the corresponding total system energy E_new as the optimal total energy E_min, that is E_min
[0065] [[ID=3৮]]= E_new;
[0066] If E_new ≥ E_min, it means that the exchanged network structure X ’ is not the optimal solution, and there is no need to perform the operation of saving the optimal solution and the corresponding optimal total energy;
[0067] Output: The optimal solution X[[ID=۴۷]] min , the corresponding optimal total energy E_min.
[0068] Using the entanglement Boltzmann machine algorithm of the present invention, the global optimal solution 2020 of the Bays29 problem instance (the number of cities is 29) in the traveling salesman problem library TSP-LIB was successfully found in the above example. Moreover, at the same temperature, for example, T = 100K, the energy probability distribution of the entanglement Boltzmann machine is much better than that of the traditional Boltzmann machine, such as Figure 3 As shown, a traditional Boltzmann machine must be cooled to T = 35K to achieve an energy probability distribution comparable to that of an entangled Boltzmann machine at T = 100K. This indicates that the entangled Boltzmann machine significantly outperforms the traditional Boltzmann machine in solving global optimization problems.
[0069] The study also found that even when the Markov process representing the probability transition matrix in Equation 7 above is not yet stable, non-steady-state entanglement can still be established to guide optimization. In practice, reducing the iteration number n of the Markov chain transition matrix... I At the same temperature, unsteady entanglement sampling can achieve optimization at an equivalent lower temperature, meaning that low-energy solutions have a higher population probability. For example... Figure 4 The graph shows the number of iterations in the aforementioned cyclic process on the horizontal axis and the total energy of the optimal solution on the vertical axis. In the iterative process, Gibbs sampling is initially used (i.e., no entanglement is introduced), followed by entangled sampling, specifically non-steady-state entangled sampling. The length of the Markov chain (i.e., the number of probability transition iterations) is n. I As the value gradually decreases from 600 to 50, it can be seen that the corresponding energy shows a decreasing trend. Therefore, the unsteady-state probability of the probabilistic superposition state (PSS) can be used similarly to guide the row swapping operation, thus... Figure 4 The results demonstrate an annealing-like effect achieved at the same temperature. This showcases the superior performance of the entangled Boltzmann machine and the unique ability to simulate quantum tunneling effects.
[0070] The hardware implementation of the entangled Boltzmann machine of the present invention is described below. Figure 5 The hardware architecture 500 of an entangled Boltzmann machine according to an embodiment of the present invention is shown, which mainly includes a probability bit node array 510, a random sampling device 520, a probability calculation device 530, a decision device 540, and a driving device 550.
[0071] The probabilistic bit node array 510 comprises an array of multiple probabilistic bit node units 512, such as an array arranged in rows and columns or other predetermined formats / layouts. Each probabilistic bit node unit 512 is formed as a hardware node of an entangled Boltzmann machine, capable of generating truly random numbers, such as 0 and 1, with predetermined probabilities, and generating truly random numbers through real physical processes. In some embodiments, a magnetic tunnel junction (MTJ) can be used as the probabilistic bit node unit 512, which mainly comprises a ferromagnetic metal free layer, a non-magnetic insulating barrier layer, and a ferromagnetic metal reference layer. The resistance of the magnetic tunnel junction is determined by the relative alignment direction of the magnetic moments of the ferromagnetic metal free layer and the ferromagnetic metal reference layer; parallel alignment corresponds to a low-resistance state (e.g., 0), and antiparallel alignment corresponds to a high-resistance state (e.g., 1). By applying a spin-orbit torque (SOT) generated by a flip voltage / current in the write layer or a spin-transfer torque (STT) generated by a flip voltage / current along the longitudinal direction of the magnetic tunnel junction, the magnetic moment direction of the ferromagnetic metal free layer can be flipped, thereby achieving the switching between high and low resistance states of the magnetic tunnel junction. For the SOT flip-over method, the magnetic tunnel junction also includes a spin Hall effect (SHE) layer adjacent to and in contact with the free magnetic layer, such as Pt, Ta, W, or alloys thereof, which generates a spin-orbit torque when an in-plane current is applied to flip the magnetic moment direction of the free layer. Due to the random nature of the free layer magnetic moment flip under critical conditions, the magnetic tunnel junction has been shown to be a physical entropy source for generating truly random numbers.
[0072] like Figure 5 As shown, a critical switching voltage V can be applied to the magnetic tunnel junction that forms the probabilistic bit node unit 512. DD (or current), which generates a low-resistivity state 0 and a high-resistivity state 1 with a 50% probability each; in addition, a bias voltage Vin (or current) is applied, which controls the probability of generating 0 and 1 bits in the magnetic tunnel junction. Note that the critical switching voltage V... DD The application of the bias voltage Vin (or current) and the method of applying the bias voltage Vin (or current) are not limited to... Figure 5 The illustrated embodiment. For a SOT-type magnetic tunnel junction, the critical switching current is an in-plane current applied to the SHE layer. The bias current can be a vertical current, directed upwards or downwards, to control the switching probability through the STT effect. Alternatively, the bias current can also be an in-plane current applied to the SHE layer, directed parallel or perpendicular to the switching current, to control the switching probability through the SOT effect. Similarly, for an STT-type magnetic tunnel junction, the switching current is a vertical current applied to the magnetic tunnel junction. The bias current can be either a vertical current or an in-plane current applied to the SHE layer, to control the switching probability through the STT or SOT effect. It can be understood that the critical switching voltage V... DDThe bias voltage Vin (or current) and the bias current Vin (or current) can be applied simultaneously to generate a random number 0 or 1 with a predetermined probability. The probability P of generating the random number 0 or 1 can be controlled by controlling the magnitude and / or direction (e.g., positive and negative) of the bias voltage Vin (or current). 0 / 1 The flipping probability P of the magnetic tunnel junction can be predetermined. 0 / 1 By calibrating the dependency between the bias voltage Vin (or current), a probabilistic bit node unit 512 that generates 0 / 1 random numbers with arbitrary probability can be constructed. After the toggle operation, a read voltage V can be applied. R (or current) is used to read the resistance state of the magnetic tunnel junction (e.g., high-resistance state 1 or low-resistance state 0), and the voltage V is read. R (or current) is generally much smaller than the switching voltage V. DD (or current), therefore it does not affect the resistive state of the magnetic tunnel junction. For example... Figure 5 As shown, each magnetic tunnel junction can also be connected in series with a switching element, such as an NMOS transistor 514, to control the read and write operations of the magnetic tunnel junction.
[0073] Various embodiments using magnetic tunnel junctions as probabilistically controllable true random number generators can be found in the applicant's patent application No. 202111072657.5, entitled "Probabilistically Controllable Spin Random Number Generator," filed September 14, 2021; and patent application No. 202310147344.4, entitled "Magnetic Junction, Magnetic Random Access Memory, Microwave Oscillator and Detector, Electronic Device," filed February 14, 2023; and patent application No. 202310147344.4, filed May 8, 2023. The contents of patent application No. 202310508761.7 entitled "True Random Number Generator" and patent application No. 202410527496.1 entitled "True Random Number Generator and Self-calibration Method and Electronic Device", filed on April 29, 2024, are incorporated herein by reference. Therefore, detailed descriptions of various embodiments of using a magnetic tunnel junction to form a probability-controllable true random number generator, i.e., probability bit node unit 512, are omitted here.
[0074] Continue to refer to Figure 5 The random sampling device 520 is used to sample each probability bit node unit 512, that is, to read the random number 0 or 1 generated by the probability bit node unit 512. For example... Figure 5 As shown, the random sampling device 520 may include an array of comparators 522, corresponding to an array of probability bit node units 512, wherein the inverting input of each comparator 522 may be connected to one end of a magnetic tunnel junction in the probability bit node unit 512. Figure 5The low-voltage terminal is shown, but it can also be connected to the high-voltage terminal to read its resistance state. Its non-inverting input can receive a reference voltage Vref. The magnetic tunnel junction is determined to be in a high-resistance or low-resistance state by comparing the voltage at one end of the magnetic tunnel junction with the reference voltage Vref, i.e., generating a random number 1 or 0. It should be understood that during operation, the random sampling device 520 can sample the outputs of multiple entangled nodes 512 during each loop iteration.
[0075] The probability calculation device 530 may include a conditional probability calculation unit 532 and an entanglement probability calculation unit 534. The conditional probability calculation unit 532 is used to calculate the corresponding conditional probabilities based on the output values of multiple entangled nodes 512 obtained by the random sampling device 520. Here, conditional probability refers to the probability that the corresponding entangled node takes certain values when one or more nodes take specific values (i.e., conditions), for example, as described above in conjunction with Equations 2 and 5. However, it should be understood that the embodiments of the present invention are not limited to the two-node entanglement and four-node entanglement cases described above in conjunction with Equations 2 and 5, but can employ entanglement of more nodes, depending on the specific model structure, or in other words, the specific combinatorial optimization problem that the model aims to solve.
[0076] The entanglement probability calculation unit 534 may include a transition matrix calculation module 535, which determines the probability superposition state (PSS) of each entangled node based on the conditional probabilities of multiple entangled nodes. This PSS represents the probability of a node being in various possible states, also referred to here as the PSS probability. Furthermore, it determines the Markov chain probability transition matrix between the PSS probabilities of the entangled nodes, as described above with reference to formulas 3a, 3b, and 6, thereby establishing the entanglement relationship between the nodes. Specifically, the probability superposition state (PSS) of each entangled node can be determined based on the calculated conditional probabilities. For example, each node can be represented as the superposition of a probability of 0 and a probability of 1. This allows for the determination of the probability transition matrix between entangled nodes, for example, used to transfer the probability of node (x...) to... i ,x j The PSS probability of ) is transformed into node (x) k ,x l The first transition matrix of the PSS probability of ) and the matrix used to transfer the node (x) k ,x l The PSS probability of ) is transformed into node (x) i ,x j The second transition matrix of the PSS probability.
[0077] The entanglement probability calculation unit 534 may further include an entanglement probability calculation module 537, which determines the steady-state entanglement probability of each entangled node when the probability transfer process reaches equilibrium, or the non-steady-state entanglement probability of each entangled node before the probability transfer process reaches equilibrium (e.g., when the transfer iteration reaches a predetermined number of times), based on the determined probability transfer matrix. In one embodiment, the entanglement probability calculation module 537 may iteratively execute the probability transfer process between entangled nodes using matrix multiplication until the transfer matrix reaches equilibrium to determine the steady-state entanglement probability of each node, or execute the probability transfer process a predetermined number of times (before reaching equilibrium) to determine the non-steady-state entanglement probability of each node. In another embodiment, the entanglement probability calculation module 537 may calculate the steady-state entanglement probability using an eigenvector solution method. Unlike traditional Gibbs sampling, the present invention determines the entanglement probability of multiple entangled nodes by referring to the probability distribution of multiple nodes being in multiple target states, rather than determining the probability of a single node being in a certain state as in Gibbs sampling. For example, for four entangled nodes, each node may be in two states, 0 and 1, resulting in 16 possible states. The entanglement probability calculation module 537 can determine the probability distribution of these 16 states.
[0078] The decision-making device 540 can determine the final state of each entangled node based on its steady-state or non-steady-state entanglement probability, for example, by setting the value to 0 or 1. In other words, it determines whether the state of each entangled node needs to be changed. In one embodiment, the decision-making device 540 can obtain the steady-state or non-steady-state entanglement probability distribution of the entangled nodes, normalize the steady-state or non-steady-state entanglement probabilities of two or more target states (for example, for the four entangled nodes in the traveling salesman problem, due to the restriction that there is exactly one node in each row and each column that is in state 1, there are only two target states) and perform binary sampling (i.e., sampling value is 0 or 1) on the normalized probabilities to determine the final state, that is, whether the state of each entangled node needs to be changed.
[0079] In one embodiment, the decision-making device 540 may further include an energy calculation unit 542, which calculates the total system energy after the node states are changed when the decision-making device 540 decides to change the states of each entangled node. It is understood that the energy calculation unit 542 may calculate the total system energy based on the node states (e.g., 0 or 1) and the weight values between nodes (e.g., the distance values described above, or other weight values set depending on the specific problem). The decision-making device 540 may further include an optimal solution determination unit 544, which compares the calculated total system energy with a previously determined optimal energy; when the calculated total system energy is better than the previously determined optimal energy, the current system state is determined as the optimal solution; and an optimal solution storage unit 546, which stores the current system state as the optimal solution in a memory, and also stores the corresponding optimal system energy.
[0080] The driving device 550 can drive each entangled node according to the decision made by the decision-making device 540. For example, when the decision-making device 540 decides not to change the state of each entangled unit, the driving device 550 can maintain the original driving state unchanged; when the decision-making device 540 decides to change the state of each entangled unit, the driving device 550 can adjust the driving signal of each entangled node, such as the bias voltage Vin (i.e., probability control voltage / parameter), so as to generate the target state (i.e., output 0 or 1) with the determined entanglement probability.
[0081] It is understood that the entangled Boltzmann machine hardware architecture 500 can cyclically perform operations from random sampling to updating the driving signal (e.g., bias voltage Vin) to traverse various states of the probability bit node array 510 and find the optimal solution corresponding to the optimal (e.g., minimum) energy. In one embodiment, the decision-making device 540 may further include an output unit 548, which outputs the optimal solution and the corresponding optimal energy when the determined optimal solution satisfies the convergence condition, and stops the cyclic operation from random sampling to updating the driving signal. In other words, if the currently determined optimal solution does not satisfy the convergence condition, the cyclic operation can continue to be performed to find more optimal solutions. The convergence condition may be, for example, that the currently calculated optimal solution is the same as or close to the known optimal solution, or that the energy no longer decreases after a certain number of cycles, etc.
[0082] It should be understood that the probabilistic bit node unit 512 in the entangled Boltzmann machine of the present invention can use not only magnetic tunnel junctions, but also other probabilistically controllable true random number generators such as memristors as entropy sources. Furthermore, the entangled Boltzmann machine of the present invention, including its algorithm and hardware architecture, is applicable not only to solving combinatorial optimization problems, but also to tasks such as training and inference of neural networks.
[0083] An embodiment of the present invention also provides a method for operating an entangled Boltzmann machine, which has been described above regarding... Figure 5 The above has been discussed in the description, and will not be repeated here for the sake of brevity.
[0084] Unless the context explicitly requires otherwise, throughout the specification and claims, the words “comprising,” “including,” “comprise,” “including,” etc., shall be interpreted in an inclusive sense, rather than an exclusive or exhaustive sense. That is, they mean “including but not limited to.” The term “connection” as commonly used herein refers to two or more elements that can be directly connected or connected via one or more intermediate elements. Furthermore, when used in this application, the terms “this,” “above,” “below,” and similar terms shall refer to the entire application and not any particular part thereof. Where the context permits, the term “or” refers to a list of two or more items, encompassing all of the following interpretations: any item in the list, all items in the list, and any combination of items in the list.
[0085] Furthermore, unless otherwise specifically stated or otherwise understood in the context in which they are used, the conditional language used herein, such as “can,” “may,” “possibly,” “can,” “for example,” “likely,” “such as,” etc., is generally intended to express that certain embodiments include certain features, elements, and / or states, while other embodiments do not. Therefore, such conditional language is not generally intended to imply that one or more embodiments require features, elements, and / or states in any way, or that one or more embodiments must include logic for making a decision, with or without author input or prompts, that determines whether such features, elements, and / or states are included in or will be performed in any particular embodiment.
[0086] While certain embodiments have been described, these embodiments are presented by way of example only and are not intended to limit the scope of this disclosure. In fact, the novel facilities, methods, and systems described herein can be embodied in a variety of other forms; furthermore, various omissions, substitutions, and changes can be made to the form of the methods and systems described herein without departing from the spirit of this disclosure. For example, although blocks are presented in a given arrangement, alternative embodiments may perform functions similar to different components and / or circuit topologies, and some blocks may be deleted, moved, added, subdivided, combined, and / or modified. Each of these blocks can be implemented in a variety of different ways. Any suitable combination of elements and actions of the various embodiments described above can be combined to provide further embodiments. The appended claims and their equivalents are intended to cover these forms or modifications that fall within the scope and spirit of this disclosure.
[0087] The above description has been given for purposes of illustration and description. Furthermore, this description is not intended to limit the embodiments of the invention to the forms disclosed herein. Although numerous exemplary aspects and embodiments have been discussed above, those skilled in the art will recognize certain variations, modifications, alterations, additions, and sub-combinations therein.
Claims
1. An entangled Boltzmann machine device, comprising: A probability bit node array, comprising multiple probability bit nodes, each of which is used to generate a true random number with a desired probability; A random sampling device is used to sample the current state of multiple entangled probability bit nodes in a probability bit node array; A probability calculation device for calculating the entanglement probability distribution of multiple entangled probability bit nodes based on their current states; A decision-making device is used to determine whether to change the current state of the plurality of entangled probability bit nodes to a target state based on the entanglement probability distribution of the plurality of entangled probability bit nodes. as well as A driving device, configured to adjust the driving signals of the plurality of entangled probability bit nodes to achieve the target state in response to the decision-making device's decision to change the current state of the plurality of entangled probability bit nodes to a target state. The probability bit node includes a magnetic tunnel junction configured to receive a critical switching voltage or current to achieve random switching between a high-resistivity state and a low-resistivity state, and also to receive a bias voltage or current to control the switching probability.
2. The entangled Boltzmann machine apparatus as described in claim 1, wherein, The probability calculation device includes: A conditional probability calculation unit is used to calculate the conditional probability of each entangled probability bit node based on the current state of multiple entangled probability bit nodes. The conditional probability indicates the probability that one or more other entangled probability bit nodes will have a certain state given that one or more of the multiple entangled probability bit nodes have a predetermined state. The entanglement probability calculation unit is used to calculate the entanglement probability distribution of the multiple entanglement probability bit nodes in various states based on the conditional probability of each entanglement probability bit node.
3. The entangled Boltzmann machine apparatus as described in claim 2, wherein, The entanglement probability calculation unit includes: The transition matrix calculation module is used to determine the probability superposition state of each entangled probability bit node based on its conditional probability, and to calculate the probability transition matrix between the probability superposition states of the multiple entangled probability bit nodes; and The entanglement probability calculation module is used to calculate the steady-state or non-steady-state entanglement probability distribution of the multiple entangled probability bit nodes in various states when or before the probability transition process between the probability superposition states of the multiple entangled probability bit nodes reaches stability.
4. The entangled Boltzmann machine apparatus as described in claim 3, wherein, The decision-making device is configured to normalize the steady-state or non-steady-state entanglement probabilities of two or more target states among the various states of the plurality of entangled probability bit nodes, and to perform binary sampling on the normalized probabilities to determine whether to change the current state of the plurality of entangled probability bit nodes to a different target state.
5. The entangled Boltzmann machine apparatus as described in claim 4, wherein, The decision-making device further includes: An energy calculation unit is used to calculate the total system energy corresponding to the changed target state when the decision-making device decides to change the current state of the plurality of entangled probability bit nodes to a different target state. The optimal solution determination unit is used to compare the total system energy corresponding to the target state with the previously determined optimal total energy, and when the total system energy corresponding to the target state is better than the previously determined optimal total energy, the changed target state is determined as the optimal solution; The optimal solution storage unit is used to store the target state as the updated optimal solution, and its corresponding total system energy as the optimal total energy; and The output unit is used to output the optimal solution and the optimal total energy when the determined optimal solution or optimal total energy satisfies the predetermined convergence condition, and to stop the operation of sampling the current state of multiple entangled probability bit nodes in the probability bit node array.
6. The entangled Boltzmann machine apparatus as described in claim 5, wherein, The driving device is configured to adjust the bias voltage or current of the magnetic tunnel junction in the plurality of entangled probability bit nodes, thereby achieving the target state with an entanglement probability corresponding to the target state.
7. A method for operating an entangled Boltzmann machine, comprising: Generate true random numbers with the desired probability using each of the multiple probability bit nodes included in the probability bit node array; The current state of multiple entangled probability bit nodes in the probability bit node array is sampled using a random sampling device. The probability calculation device is used to calculate the entanglement probability distribution of multiple entangled probability bit nodes based on their current states; The decision-making device uses the entanglement probability distribution of the plurality of entangled probability bit nodes to determine whether to change the current state of the plurality of entangled probability bit nodes to the target state. as well as In response to the decision of the decision-making device to change the current state of the plurality of entangled probability bit nodes to a target state, the driving device adjusts the driving signals of the plurality of entangled probability bit nodes to achieve the target state. The probability bit node includes a magnetic tunnel junction configured to receive a critical switching voltage or current to achieve random switching between a high-resistivity state and a low-resistivity state, and also to receive a bias voltage or current to control the switching probability.
8. The method of claim 7, wherein, The entanglement probability distribution of multiple entangled probability bit nodes is calculated using a probability calculation device based on their current states, including: The conditional probability calculation unit calculates the conditional probability of each entangled probability bit node based on the current state of multiple entangled probability bit nodes. The conditional probability indicates the probability that one or more other entangled probability bit nodes will have a certain state given that one or more of the multiple entangled probability bit nodes have a predetermined state; and The entanglement probability calculation unit calculates the entanglement probability distribution of the multiple entanglement probability bit nodes in various states based on the conditional probability of each entanglement probability bit node.
9. The method of claim 8, wherein, The entanglement probability calculation unit calculates the entanglement probability distribution of the multiple entanglement probability bit nodes in various states based on the conditional probability of each entanglement probability bit node, including: The transition matrix calculation module determines the probability superposition state of each entangled probability bit node based on its conditional probability, and calculates the probability transition matrix between the probability superposition states of the multiple entangled probability bit nodes; and When the probability transition process between the probability superposition states of the multiple entangled probability bit nodes reaches stability, or before it reaches stability, the entangled probability bit nodes are in various states of steady-state entanglement probability distribution or unsteady-state entanglement probability distribution.
10. The method of claim 9, wherein, Using a decision-making device to determine whether to change the current state of the multiple entangled probability bit nodes to the target state based on the entanglement probability distribution of the multiple entangled probability bit nodes includes: The steady-state or non-steady-state entanglement probabilities of two or more target states among the various states of the plurality of entangled probability bit nodes are normalized, and the normalized probabilities are binary sampled to determine whether to change the current state of the plurality of entangled probability bit nodes to a different target state.
11. The method of claim 10, further comprising: When the decision-making device decides to change the current state of the plurality of entangled probability bit nodes to a different target state, the energy calculation unit calculates the total system energy corresponding to the changed target state. The optimal solution determination unit compares the total system energy corresponding to the target state with the previously determined optimal total energy, and when the total system energy corresponding to the target state is better than the previously determined optimal total energy, the changed target state is determined as the optimal solution; The target state is stored in the optimal solution storage unit as the updated optimal solution, and the corresponding total system energy is stored as the optimal total energy. as well as When the determined optimal solution or optimal total energy satisfies the predetermined convergence condition, the output unit outputs the optimal solution and the optimal total energy, and stops sampling the current state of multiple entangled probability bit nodes in the probability bit node array.
12. The method of claim 11, wherein, In response to the decision of the decision-making device to change the current state of the plurality of entangled probability bit nodes to a target state, the driving device adjusts the driving signals of the plurality of entangled probability bit nodes to achieve the target state, including: The bias voltage or current of the magnetic tunnel junction in the plurality of entangled probability bit nodes is adjusted to achieve the target state with an entanglement probability corresponding to the target state.
Citation Information
Patent Citations
Spin random number generator with controllable probability
CN115809044A
True random number generator
CN116521132A
Magneton junction, magneton random access memory, microwave oscillator, microwave detector and electronic equipment
CN118510374A
True random number generation device, self-calibration method thereof and electronic equipment
CN118550502A
Channel modeling method based on quantum generative adversarial network
CN113676266A