This application is based upon and claims the benefit of priority from Japanese Patent Application No. 2022-099193, filed on Jun. 20, 2022; the entire contents of which are incorporated herein by reference.
Embodiments disclosed herein relate generally to a processing circuit, a logic gate, an arithmetic processing method, and a non-transitory computer readable storage medium.
As an approach to solving the inverse problem, a method of using invertible logic gates is employed. Invertible logic gates are elements that operate by updating signal values of nodes according to a Hamiltonian defined for each gate, so that after a sufficient time has elapsed, a state of the signal values of the nodes satisfies the minimum energy state defined by the Hamiltonian with a high probability.
On the other hand, in circuits combining invertible logic gates, the signal values of the nodes may be trapped in a local minimum energy state during time evolution and unable to escape, resulting in failure to transition to a global minimum energy state that is the true calculation result.
A processing circuit provided in one aspect of the present embodiment is formed in combination of a plurality of logic gates each of which probabilistically determines, based on signal values of one or two or more input nodes and output nodes at a certain time, signal values at at least one of the input nodes and the output nodes at a subsequent time, in which the processing circuit controls the signal values based on a relationship to be satisfied between at least some nodes of the input nodes and the output nodes.
Hereinbelow, an embodiment of a processing circuit, a logic gate, an arithmetic processing method, and a computer program will be described in detail with reference to the drawings.
In
Returning to
As illustrated in
Returning to
The data input function 151, the data output function 155, and the invertible logic gate processing function 160 are each an example of a control unit. The input node data retention function 152, the intermediate node data retention function 153, and the output node data retention function 154 are each an example of a retention unit.
The term “processor” used in the above description refers to, for example, central processing unit (CPU), graphical processing unit (GPU), or application specific integrated circuit (ASIC), computer programmable logic devices (for example, simple programmable logic device (SPLD), complex programmable logic device (CPLD), and field programmable gate array (FPGA)), and other circuits. The processor reads and executes the computer programs stored in the memory 120 to implement the functions.
Instead of storing the computer programs in the memory 120, a configuration in which the computer programs are incorporated directly into a circuit of the processor may be adopted. In this case, the processor reads and executes the computer programs incorporated into the circuit of the processor to implement the functions.
The data input function 151 is a function of inputting input data to be calculated. Specifically, the processing circuit 150 acquires input data to be calculated from the input device 110 or the memory 120 by the data input function 151 and inputs the input data to the output nodes 13 in the processing circuit 150. The processing circuit 150 of the embodiment is to solve the inverse problem. That is, input data is input to the output nodes 13, and output data is output from the input nodes 11 and 12.
The data output function 155 is a function of outputting output data of the calculation results to an external device. Specifically, the processing circuit 150 transmits, by the data output function 155, the output data of the calculation results retained at the input nodes 11 and 12 to the memory 120 or causes the display 130 to display the output data of the calculation results.
The processing circuit 150 also retains data of the input nodes 11 and 12, the intermediate nodes 14, and the output nodes 13 by the input node data retention function 152, the intermediate node data retention function 153, and the output node data retention function 154, respectively.
The processing circuit 150 performs processing using the invertible logic gates to solve the inverse problems by the invertible logic gate processing function 160.
Next, an invertible logic gate and a circuit with the invertible logic gate will be briefly described with reference to
In the normal logic gate, when an input signal is input to an input node, an output signal uniquely corresponding to the input signal is output from an output node. For example, in an OR logic gate, in a case in which a signal value of a first input node is “1”, and a signal value of a second input node is “0”, output nodes output signal values “1”, which are output signals uniquely corresponding to these input signals.
In contrast, in the invertible logic gate, input signals that are consistent with given output signals are output with high probability as the input signals. As an example, in an invertible OR logic gate, in a case in which the signal value of the output node is “1”, it may be considered, as a set of the input signal that is consistent with the signal value of this output node, with any one of the following cases: a signal value of the first input node is “1”, and a signal value of the second input node is “0”; the signal value of the first input node is “0”, and the signal value of the second input node is “1”; or the signal value of the first input node is “1”, and the signal value of the second input node is “1”. Thus, in the invertible logic gate, any one set of the signal value of the input node that is consistent with the signal value of the output node is given to the input node with high probability.
Here, unlike the case of the normal logic gate, in the invertible logic gate, the signal value of the input node is not uniquely determined for the signal value of the output node, because there are a plurality of sets of the input signal that is consistent with the signal value of the output node. Thus, in the invertible logic gate, the signal value that is consistent with the signal value of the output node is probabilistically given as the signal value of the input node.
In addition, in the invertible logic gate, any set of the signal value of the input node that is consistent with the signal value of the output node is given to the input node with high probability, but the probability that a signal value of the input node that is inconsistent with the signal value of the output node is given to the input node is not excluded. For example, in the invertible OR logic gate, the probability that the signal value of the first input node is “0”, and the signal value of the second input node is “0” is not excluded even though the signal value of the output node is “1”. In other words, in the invertible logic gate, a relationship between the signal value of the input node and the signal value of the output node as the normal logic gate is not necessarily satisfied at each time.
However, in the invertible logic gate, processing of periodically updating the signal value of each node is performed by the processing described later. In this case, a Hamiltonian described later is introduced for each logic gate to perform processing of differentiating the probability of updating the signal values between the set of the input node and output node that satisfies the logical relationship as the normal logic gate, and the set of the input node and output node that does not satisfy the logical relationship as the normal logic gate. According to this, the set of the input signals that satisfy the logical relationship as the normal logic gate is selected with high probability at a time when a sufficient amount of time has elapsed from the initial state.
That is, in the invertible logic gate, even though the logical relationship between the input node and the output node as the normal logic gate is not necessarily ensured at each time, the set of the input signals that satisfies the logical relationship as the normal logic gate is selected with high probability after a sufficient amount of time has elapsed from the initial state. In this way, it is thought that the invertible logic gate can output an input signal with respect to an output signal. Therefore, the configuration in which the circuit is formed of the invertible logic gates in combination enables output of the input signals to be the given output signals, and the processing circuit 150 to solve the inverse problem.
The logical relationship described above is, for example, a correspondence relationship in inputs and outputs illustrated in the truth tables of logical operations (such as AND, OR, XOR, and NOT). The relationship described herein can also be considered, for example, as a relationship to be satisfied between input and output nodes in units of blocks composed of a plurality of logic gates, rather than in units of logical operations (logic gates). The invertible logic gate may be implemented by predetermined hardware such as CPU, GPU (or ASIC), a computer programmable logic device (for example, SPLD, CPLD, or FPGA), or as software on hardware.
A schematic diagram of an invertible logic gate 10 is illustrated in
The Hamiltonian Hgate of the Ising model represented by the following equation (1) is defined for the invertible logic gate 10.
Here, i and j are the subscripts of each of the nodes, and mi is a spin representation of a signal value of the i-th node. hi is a coefficient for the i-th node, and is a quantity representing the magnetic field about the i-th node in the Ising model. Jij is also a coefficient between the i-th node and the j-th node, and is a quantity representing exchange interaction between the i-th node and the j-th node in the Ising model.
Corresponding to this Hamiltonian, the invertible logic gate 10 retains information corresponding to coefficients 2a, 2b, and 2c, which are respectively coefficients for the nodes, and information corresponding to coefficients 3a, 3b, and 3c, which are coefficients between the nodes, as illustrated in
The coefficients 2a, 2b, 2c, and coefficients 3a, 3b, 3c are predetermined values depending on the type of the invertible logic gate 10 as a logic gate. These numbers are invariant to changes in time and are independent of a signal value of each node.
Assuming that the invertible logic gate 10 serving as a normal logic gate, these coefficients are designed so that an evaluation value of the Hamiltonian in the state in which the logical relationships to be satisfied between the nodes are satisfied (valid state) is smaller than that in the state in which the logical relationships to be satisfied between the nodes are not satisfied (invalid state). In other words, the Hamiltonian given by equation (1) is designed so that the evaluation value of the Hamiltonian in the valid state in the invertible logic gate 10 is smaller than the evaluation value of the Hamiltonian in the invalid state.
A more specific configuration example of the invertible logic gate will be described with reference to
That is, as illustrated in
Furthermore, in an invertible AND logic gate 10b illustrated in
That is, as illustrated in
Furthermore, for example, other types of the invertible logic gate 10, such as an invertible XOR logic gate and an invertible NOR logic gate, can also be configured in the same way by adopting appropriately configured Hamiltonian coefficient values.
The Hamiltonian of the invertible logic gate 10 illustrated in equation (1) can be decomposed into the sum of the portion Hi pertaining to the node i in the Hamiltonian, as illustrated in the following equation (6).
Specifically, the portion Hi of the Hamiltonian of the invertible logic gate 10, which pertains to the node i, is represented by the following equation (7).
That is, the Hamiltonian of the invertible logic gate 10 can be decomposed into the sum of components for individual nodes, as appropriate. Each of these components of the Hamiltonian decomposed into components for individual nodes is incorporated into the first term and second term on the right side of equation (8) described later, and used in the processing of updating a signal value at each node.
Next, the processing performed at the invertible logic gate 10 will be described with reference to
In the embodiment, a plurality of the invertible logic gates 10 are usually combined to form the processing circuit 150. The case in which the invertible logic gates 10 are combined is described below, and a case in which the processing circuit 150 is composed of a single invertible logic gate 10 is described herein.
First, at step S100, the processing circuit 150 inputs an initial value to the output node 1c at time t=0 by the data input function 151. Specifically, the processing circuit 150 inputs the initial value to the output node 1c of the invertible logic gate 10 by the data input function 151. As an example, in a case in which the initial value input to the output node 1c is “1” at time t=0, the processing circuit 150 inputs the initial value, “1”, to the output node 1c of the invertible logic gate 10 by the data input function 151. In this case, a signal value of the output node 1c is m3=1.
The processing then proceeds to step S200, where the processing circuit 150 updates a signal value at each node at regular time intervals. That is, the processing circuit 150 probabilistically determines, based on a signal value mi(t) of the node i at a certain time t, where i is the node number, and a signal value mj(t) of the other node j (the node j is a different node from the node i, and is adjacent to the node i), a signal value mi(t+1) at a subsequent time t+1, by the invertible logic gate processing function 160.
As an example, in
Specifically, the processing circuit 150 gives, by the invertible logic gate processing function 160, the signal value mi(t+1) of the node i at time t+1 with the following equations (8) to (10).
Here, in equation (8), t is time, i and j are node numbers, hi is the coefficient for the i-th node in the first term on the right side of equation (1), Jif is the coefficient between the i-th node and the j-th node in the second term on the right side of equation (1), nrnd is a constant that represents the magnitude of the random number, ri(t) is the random number given to the i-th node at time t. That is, function Ii(t) at time t+1 in the i-th node is obtained by the evaluation of the right side of equation (8).
Function Itanhi(t+1) at time t+1 in the i-th node can be evaluated by equation (9) with the function Ii(t). Here, I0 is a predetermined threshold value. I0 is a quantity that has the meaning of the inverse of temperature in the spin system. The function Itanhi(t) is a function named in the sense that its behavior is similar to that of the tanh function, but is a function that is determined sequentially by the recursion formula in equation (9), not the tanh function itself.
With the above-described function Itanhi(t), the signal value mi(t+1) at the i-th node at time t+1 is given by equation (10) described above.
The details of such steps are illustrated in
First, at step S210, the processing circuit 150 calculates a first evaluation value determined based on a signal value at each node by the first evaluation value generation function 161.
The first evaluation value generation function 161 has a Hamiltonian coefficient retention function 161a of retaining coefficients of the Hamiltonian for each gate, and a Hamiltonian evaluation function 161b of evaluating the Hamiltonian based on the coefficients of the Hamiltonian retained by the Hamiltonian coefficient retention function 161a. The processing circuit 150 retains values of the coefficient hi for each node and the coefficient Jif between nodes by the Hamiltonian coefficient retention function 161a. The processing circuit 150 also calculates the first evaluation value, which is the sum of the first term on the right side and the second term on the right side of equation (8), based on the values of the retained coefficient hi for each node and the retained coefficient Jif between nodes, by the Hamiltonian evaluation function 161b.
Such a process is illustrated in
Next, at step S220, the processing circuit 150 calculates a second evaluation value by the second evaluation value generation function 162.
Here, the second evaluation value generation function 162 has the target gate determination function 162a, the valid state determination function 162b, the random number coefficient determination function 162c, and the random number generation function 162d. However, regarding the example in
Next, the processing circuit 150 calculates the second evaluation value, which is the third term on the right side of equation (8), by multiplying the fixed random number coefficient nrnd in the third term on the right side of equation (8) by the random number ri(t), by the second evaluation value generation function 162. In an area indicated by arrow 6 in
Then, at step S230, the processing circuit 150 updates the signal values by the evaluation value addition function 163 and the node data update function 164. The evaluation value addition function 163 is a function of adding the first evaluation value generated by the first evaluation value generation function 161 and the second evaluation value generated by the second evaluation value generation function 162.
That is, the processing circuit 150 generates a value of function Ii(t+1) by adding the first evaluation value, which is the first term and the second term on the right side of equation (8), and the second evaluation value, which is the third term on the right side of equation (8), by the evaluation value addition function 163. As an example, the processing circuit 150 generates a value of function Ii(t+1) by adding an evaluation value of the first term on the right side of equation (8) indicated by arrow 4, an evaluation value of the second term on the right side of equation (8) indicated by enclosure line 5, and an evaluation value of the third term on the right side of equation (8) indicated by arrow 6 by the addition circuit 8 functioning as the evaluation value addition function 163.
The node data update function 164 is a function of updating the signal values based on the value of the generated function Ii(t). That is, the processing circuit 150 updates, based on the value of the function Ii(t) generated by the evaluation value addition function 163, the signal value mi at the i-th node according to equations (9) and (10) by the node data update function 164. As an example, the processing circuit 150 calculates, by using a circuit 9a that performs processing corresponding to equation (9), a value of the function Itanhi based on the value of the function Ii generated by the evaluation value addition function 163. The processing circuit 150 updates, based on a circuit 9b that performs processing corresponding to equation (10), the signal value mi. That is, the circuit 9a and circuit 9b are examples of the node data update function 164.
At step S230, the processing circuit 150 may update the signal values in only some nodes, instead of updating the signal values in all nodes.
As an example, the processing circuit 150 may update the signal values in a forward mode where the signal values of the input nodes are fixed and only the signal value of the output node is updated by the node data update function 164. In this case, the processing circuit 150 may update only the signal value m 3 of the output node 1c, and may fix the signal value mi of the first input node 1a and the signal value m2 of the second input node 1b and may not perform the update for those signal values by the node data update function 164.
As another example, the processing circuit 150 may update the signal values in a reverse mode where the signal value of the output node is fixed and only the signal values of the input nodes are updated by the node data update function 164. In this case, the processing circuit 150 may update only the signal value mi of the first input node 1a and the signal value m2 of the second input node 1b by the node data update function 164, and may fix the signal value m3 of the output node 1c and may not perform the update for the signal value. Furthermore, as another example, the processing circuit 150 can update both the signal value of the output node and the signal values of the input nodes, or combine the forward mode and the reverse mode described above (for example, both modes are alternately performed) by the node data update function 164.
The convergence test function 165 is a function of performing a convergence test, and the calculation accuracy calculation function 166 is a function of calculating calculation accuracy, in each iteration step. Here, the convergence test is a function of determining whether calculation results, that is, signal values at the individual nodes converge to a certain value or not. The term “calculation accuracy” means a numerical value that represents that to what extent the data of the input node, which is a solution candidate for the inverse problem at that time, satisfies the relationship of the inverse problem to be satisfied. The processing circuit 150 may perform the convergence test as appropriate or calculate the calculation accuracy as necessary in each iteration step by the convergence test function 165 or the calculation accuracy calculation function 166.
As described above, at step S200, the processing circuit 150 updates the signal value mi for each node by the node data update function 164.
Returning to
In a case in which the processing circuit 150 determines that the end determination condition has not been satisfied by the invertible logic gate processing function 160 (No at step S300), the processing returns to step S200, and the processing circuit 150 updates the signal value mi at each node. In contrast, in a case in which the processing circuit 150 determines that the end determination condition has been satisfied by the invertible logic gate processing function 160 (Yes at step S300), the processing proceeds to step S400.
Next, at step S400, the processing circuit 150 outputs signal values of the input nodes as calculation results by the data output function 155. As an example, the invertible logic gate 10 outputs the signal value of the first input node 1a and the signal value of the second input node 1b as the calculation results. In the invertible logic gate 10, in a case in which assuming that the invertible logic gate 10 for the signal value of each input node is a normal logic gate, the relationship to be satisfied is satisfied, the Hamiltonian, which is the evaluation value used to define the update probability of the signal value mi, is designed to employ a smaller value as compared with a case in which the relationship is not satisfied. As a result, after the time for a sufficient number of cycles has elapsed, the signal value at each input node satisfies the relationship to be satisfied with high probability.
Next, the processing circuit 150 will be described with the case in which the invertible logic gates are combined.
In
That is, in order to produce a circuit for solving the inverse problem by using the invertible logic gates, the forward problem may be represented in combination of normal logic gates, and the normal logic gates may be then replaced by the corresponding invertible logic gates.
Hereinbelow, such a circuit configuration will be described with a problem of factorizing natural numbers as an example. Here, the problem of factorizing natural numbers refers to a problem of finding, for a given natural number C, a set of natural numbers A and B that satisfies A×B=C. That is, for natural numbers A and B, the processing of calculating the product of A and B is a forward problem, and for the given natural number C, the problem of finding a set of natural numbers A and B that satisfies A×B=C is an inverse problem to the forward problem.
First, considering a solution to the forward problem, for simplicity, with assumption that A and B are natural numbers between equal to or greater than 1 and smaller than 16, and A and B are represented by binary representations, A=A3×23+A2×22+A1×2+A0×20, and B=B3×23+B2×22+B1×21+B0×20. Representing A×B with these binary representations and comparing the representations with binary representations of C=C7×27+C6×26+C5×23+C4×24+C3×23+C2×22+C1×21+C0×20, with taking into account carryovers and the like, enable implementation of a logic circuit that calculates the product of A and B for natural number A and natural number B.
An example of such a logic circuit is illustrated in
Here, a gate 20 and a gate 21 are AND logic gates. A circuit 22 and a circuit 23 are logic circuits known as Half-Adder and Full-Adder, respectively, which can be implemented in combination of predetermined logic gates. For example, the circuit 22 and the circuit 23 are circuits that can be implemented with a predetermined combination of the AND gates and the XOR gates. Therefore, as an example, an invertible Half-Adder circuit can be generated by the replacement of the AND gate with the invertible AND logic gate, and the replacement of the XOR gate with the invertible XOR logic gate in the circuit configuration of the circuit 22, which serves as the Half-Adder. In addition, as an example, an invertible Full-Adder circuit can be generated by the replacement of the AND gate with the invertible AND logic gate, and the replacement of the XOR gate with the invertible XOR logic gate in the circuit configuration of the circuit 23, which serves as the Full-Adder.
Therefore, in a multiplication circuit illustrated in
Returning to
Referring again to
First, at step S100, the processing circuit 150 inputs an initial value to the output nodes at time t=0 by the data input function 151. As an example, the processing circuit 150 inputs the binary representations of the natural number C to be factorized into the output nodes 13 of the invertible multiplication circuit 15 by the data input function 151.
The processing then proceeds to step S200, where the processing circuit 150 updates a signal value at each node at regular time intervals. Here, “each node” refers to each of the input nodes 11, the input nodes 12, and the intermediate nodes 14, which are nodes other than the output nodes 13. The processing circuit 150 probabilistically updates signal values of these nodes by the invertible logic gate processing function 160. The processing circuit 150 can fix the signal values of the output nodes 13 without updating the signal values.
Here, the processing circuit 150 updates the signal value at each node with equations (8) to (10), and in the evaluation of the right side of equation (8) for the signal value at each node in the circuit formed of the invertible logic gates in combination, the first term and the second term on the right side of equation (8) are evaluated by using the contribution of a portion of the Hamiltonian in the entire circuit, which is determined by the sum of the individual logic gates, the portion being related to each of the nodes.
That is, in the case in which the logic gates are combined to form a single circuit, the Hamiltonian H of the entire circuit can be represented by the following equation (11).
Here, k is the number assigned to each invertible logic gate and HGate_k is the Hamiltonian of the k-th invertible logic gate. The Hamiltonian of each invertible logic gate is in the form of equation (1). Thus, the Hamiltonian can be separated into node-specific components, as in equations (6) and (7). Therefore, the Hamiltonian of the entire circuit in equation (11) can also be separated into node-by-node components. The Hamiltonian component for each node is changed to the first term and the second term on the right side of equation (8), and substituted by using equations (9) and (10); thereby the processing circuit 150 updates the signal value at each node by the invertible logic gate processing function 160.
That is, at step S210, the processing circuit 150 calculates the first evaluation value, which is the contribution for each node in the Hamiltonian of the entire circuit, by the first evaluation value generation function 161.
Next, at step S220, the processing circuit 150 generates random number ri(t) represented in the third term on the right side of equation (8) by the random number generation function 162d. Next, the processing circuit 150 calculates the second evaluation value, which is the third term on the right side of equation (8), by multiplying the fixed random number coefficient nrnd in the third term on the right side of equation (8) by the random number ri(t), by the second evaluation value generation function 162.
Next, at step S230, the processing circuit 150 adds the first evaluation value and the second evaluation value by the evaluation value addition function 163 to generate a value of the function Ii(t+1). Next, the processing circuit 150 updates, based on the value of the function Ii(t+1) generated, the signal value mi in the i-th node according to equations (9) and (10) by the node data update function 164.
As described above, at step S200, the processing circuit 150 updates the signal value mi for each node by the node data update function 164.
Returning to
In a case in which the processing circuit 150 determines that the end determination condition has not been satisfied by the invertible logic gate processing function 160 (No at step S300), the processing returns to step S200, and the processing circuit 150 updates the signal value mi at each node. In contrast, in a case in which the processing circuit 150 determines that the end determination condition has been satisfied by the invertible logic gate processing function 160 (Yes at step S300), the processing proceeds to step S400.
Next, at step S400, the processing circuit 150 outputs signal values of the input nodes as calculation results by the data output function 155. As an example, the processing circuit 150 outputs the signal values of the input nodes 11 and the input nodes 12 as calculation results by the data output function 155.
Next, the background of the embodiment will be described.
In the calculation with the invertible logic gates, there is a problem that the calculation result is stuck in a local minimum energy state, and as a result, a global minimum energy state, which is the true calculation result, may not be reached. For example, it is assumed that a plurality of logic gates (second logic gates) are adjacent to a logic gate (hereinafter, referred to as a first logic gate) that does not satisfy the logical relationship to be satisfied by the original logic gate, and each node in these second logic gates satisfies the logical relationship to be satisfied by the original logic gate.
In this case, it is assumed that signal values of nodes in the first logic gate are changed in order for each node in the first logic gate to satisfy the relevant logical relationship. The second logic gates may no longer satisfy the logical relationship to be satisfied by the original logic gate as a result of a change in the signal values of the nodes in the first logic gate, and as a result, the energy of that state may be evaluated as a high energy state. Thus, even though a further change of the signal value at each node in the second logic gates results in a global low energy state, the probability of reaching such a state is low, and the true calculation results may not be obtained.
The above-described processing circuit 150 is based on this background. That is, the processing circuit 150 according to the embodiment is formed of the logic gates in combination each of which probabilistically determines, based on signal values of one or two or more input nodes and output nodes at a certain time, signal values at at least one of the input nodes and the output nodes at a subsequent time. Here, the processing circuit 150 can control the signal values based on the relationship to be satisfied between at least some nodes of the input nodes and the output nodes by the invertible logic gate processing function 160. The processing circuit 150 may also be formed in combination of the logic gates that probabilistically determine, based on signal values at the input nodes and the output nodes at a certain time, signal values at both the input nodes and the output nodes at a subsequent time. In a circuit with the logic gates gathered, as illustrated in
In addition, the logic gate according to the embodiment probabilistically determines, based on signal values of one or two or more input nodes and output nodes at a certain time, signal values at at least one of the input nodes and the output nodes at a subsequent time, and includes a control unit configured to control the signal values based on a relationship to be satisfied between at least some nodes of the input nodes and the output nodes.
Furthermore, an arithmetic processing method according to the embodiment includes performing arithmetic processing of probabilistically determining, based on signal values of one or two or more input nodes and output nodes at a certain time, a signal value at at least one of the input nodes and output nodes at a subsequent time, and controlling the signal values during the arithmetic processing based on a relationship to be satisfied between at least some nodes of the input nodes and the output nodes.
Furthermore, a computer program according to the embodiment causes a computer to execute arithmetic processing of probabilistically determining, based on signal values of one or two or more input nodes and output nodes at a certain time, signal values at at least one of the input nodes and the output node at a subsequent time, and causes the computer to execute processing of controlling the signal values during the arithmetic processing based on a relationship to be satisfied between at least some nodes of the input nodes and the output nodes.
That is, in the embodiment, the processing circuit 150 performs, at step S200 of
The term “some nodes of the input nodes and the output nodes” described herein means a node serving as the first input node 1a, the second input node 1b, or the output node 1c of any of the invertible logic gates 10 constituting the processing circuit 150. That is, for example, in the case of the invertible multiplication circuit 15 in
The processing circuit 150 according to the embodiment is formed of one or more invertible logic gates 10 in combination, and used in calculations to solve the inverse problem. That is, the processing circuit 150 according to the embodiment is formed of one or more the logic gates in combination each of which probabilistically determines, based on signal values of one or two or more input nodes and output nodes at a certain time t, signal values at at least one of the input nodes and the output nodes at a subsequent time t+1.
The basic flow from the input of the initial data to the output of the calculation results has already been illustrated in
Here, the processing circuit 150 according to the embodiment updates the signal values based on the following equations (12) and (13) instead of equation (8). In other words, the processing circuit 150 updates the signal values based on equations (12), (13), (9), and (10).
In equation (12), nrnd_i(t) is the magnitude of the random number, similar to nrnd in equation (8), but in the embodiment, is not a constant and has a different value for each node i, and depends on time t. The third term on the right side of equation (12) indicates that the evaluation value of the third term on the right side is added to the right side only in a case in which the node i is included in a predetermined gate. That is, equation (12) is similar to equation (8) in terms of the first term and the second term on the right side, but it is indicated that the magnitude of the random term given by the third term on the right side can employ a different value depending on the node i and time t, and such processing is performed only for a predetermined gate.
Equation (13) also indicates the magnitude of such a random term illustrated in the third term on the right side of equation (12). Here, TINTVL is a predetermined time interval, l is a constant, and nrnd is a fixed value of the random number. That is, equation (13) means that the magnitude of the given random term is a result value obtained by multiplying the fixed random number nrnd by the constant 1 only in a case in which a predetermined gate (Gate k) is invalid, and time t is a multiple of a predetermined time interval TINTVL, and in other cases, the magnitude of the random term is the fixed value nrnd. That is, equation (13) means that only in the case in which a state of the predetermined gate is invalid, and time t is a multiple of the predetermined time interval TINTVL, the magnitude of the given random term is made different with other cases. The constant 1 is usually selected to be a value greater than 1, that is, a large random term is given only in the case in which the state of the predetermined logic gate is invalid, and time t is a multiple of the predetermined time interval TINTVL.
In other words, the processing circuit 150 according to the embodiment gives the large random term to the nodes to increase the inversion probability only in the case in which the state of the predetermined logic gate is invalid, and time t is a multiple of the predetermined time interval TINTVL, thereby performing the processing that enables the quick escape of the state of the system from the local minimum energy state. In a case in which it is predetermined at what timing the large random term is given to the node to increase its inversion probability, the inversion probability of the node may be increased other than the case in which time t is a multiple of the predetermined time interval TINTVL. Thus, in the present embodiment, in a case in which the logic gate is “invalid” as compared to a case in which the state of the logic gate configured to include the input nodes and the output nodes is “valid”, the processing of adding a larger random value (in other words, a larger noise) to the nodes of the logic gate is performed to invert at least one of the input value and the output value with higher probability (for example, updating the value to −1 in a case in which the input value is 1).
Whether the predetermined logic gate is valid or invalid is determined depending on, for example, whether the logic gate satisfies the relationship to be satisfied or not. That is, in a case in which the relationship to be satisfied under the assumption that an invertible logic gate is the normal logic gate is satisfied, the invertible logic gate is in a valid state, and in a case in which the relationship to be satisfied under the assumption that an invertible logic gate is the normal logic gate is not satisfied, the invertible logic gate is in an invalid state. As an example, in an invertible AND gate, in a case in which input nodes are “1” and “1” and an output node is “1”, the invertible AND gate is in the valid state, and in a case in which the input nodes are “1” and “0” and the output node is “1”, the invertible AND gate is in the invalid state.
According to the above description, the flow of processing performed by the processing circuit 150 according to the embodiment will be described with reference to
As aforementioned, regarding the first term and the second term on the right side of equation (12), the same processing as in
Here, in the embodiment, as can be seen from the fact that in equation (13), a value of the left side of equation (13) is different from nrnd only in a case in which t is a multiple of TINTVL, the processing circuit 150 probabilistically updates, by the invertible logic gate processing function 160, the signal value mi while switching between a first operation mode and a second operation mode, in which in the first operation mode, the magnitude of random value nrnd given to at least one of the input nodes and the output nodes is fixed, and in the second operation mode, the magnitude of random value nrnd_i(t) given to at least one of the input nodes and the output nodes varies between some nodes of the input nodes and the output node (for example, between some nodes of the input nodes 11 and 12, the intermediate nodes 14, and the output nodes 13) based on the relationship to be satisfied.
As an example, the processing circuit 150 probabilistically updates, by the invertible logic gate processing function 160, the signal value mi in the second operation mode at a certain time period TINTVL, and probabilistically updates the signal value mi in the first operation mode at a time other than a time when operating in the second operation mode.
That is, while the second operation mode described herein has the advantage of preventing calculation results from being trapped in the local low-energy state, too-frequent activation of the second operation mode may cause a negative impact on the convergence of the calculation results. Thus, the processing circuit 150 according to the embodiment can also activate the second operation mode only at a certain time period TINTVL, instead of activating the second operation mode every time when the signal value is updated. Typically, a value of TINTVL=6 or TINTVL=10 is selected, for example.
That is, at step S215, the processing circuit 150 determines whether to activate the second operation mode that causes the magnitude of the random number to vary for each gate, by the invertible logic gate processing function 160. As an example, the processing circuit 150 activates the second operation mode only every certain time period TINTVL by the invertible logic gate processing function 160. As an example, in a case in which time t is an integer multiple of TINTVL (Yes at step S215), the processing circuit 150 causes, by the invertible logic gate processing function 160, the processing to proceed to step S500, and the processing circuit 150 performs the processing at steps S510 to S540 (second operation mode). On the other hand, in a case in which time t is other than an integer multiple of TINTVL (No at step S215), the processing circuit 150 causes, by the invertible logic gate processing function 160, the processing to proceed to step S216, and the processing circuit 150 performs the processing at step S220 (first operation mode). The redundant description will be omitted because the processing at step S220 is similar to the processing already described in
Next, the processing of the second operation mode will be described with appropriate reference to
Next, at step S520, the processing circuit 150 determines, by the valid state determination function 162b, whether the invertible logic gates extracted at step S510 satisfy the relationship to be satisfied between some nodes of the input nodes and the output nodes. As an example, the processing circuit 150 determines, by the valid state determination function 162b, whether the invertible logic gates extracted at step S510, that is, the logic gates in the assumption that the invertible logic gates are the normal logic gates satisfy the relationship to be satisfied between the nodes. That is, the relationship to be satisfied between some nodes of the input nodes and the output nodes is determined based on the relationship to be satisfied by the logic gates, for example. Instead of determining whether the invertible logic gates satisfy the relationship to be satisfied between some nodes of the input nodes and the output nodes, it may be determined whether the invertible logic gates satisfy the relationship to be satisfied between all of the input nodes and the output nodes that constitute the invertible logic gates.
As more specific processing, the processing circuit 150 performs the verification of the signal value of each node for the logic gates extracted at step S510 with the truth table by the valid state determination function 162b, and determines that the logic gates satisfy the relationship to be satisfied and the state thereof is valid in a case in which the signal values are matched with the truth table. In contrast, the processing circuit 150 performs the verification of the signal value of each node for the logic gates extracted at step S510 with the truth table by the valid state determination function 162b, and determines that the logic gates do not satisfy the relationship to be satisfied and the state thereof is invalid in a case in which the signal values are not matched with the truth table.
As an example, in
As described above, the term “some nodes of the input nodes and the output nodes” described herein means some nodes of the input nodes and the output nodes of any of the invertible logic gates 10 constituting the processing circuit 150. Thus, for example, in the case of the invertible multiplication circuit 15 in
Next, at step S530, the processing circuit 150 calculates the random number coefficient nrnd_i(t) with a different value according to the result determined at step S520 by the random number coefficient determination function 162c. As an example, the processing circuit 150 calculates the random number coefficient nrnd_i(t) with a different value based on the result of the verification of the signal value of each node with the truth table at step S520 by the random number coefficient determination function 162c.
Specifically, the processing circuit 150 applies the upper value of equation (13) to nodes pertaining to the logic gate determined to be invalid at step S520 by the random number coefficient determination function 162c, and calculates a value obtained by multiplying the fixed value nrnd by the constant 1 as the random number coefficient nrnd_t(t). In contrast, the processing circuit 150 applies the lower value of equation (13) to nodes pertaining to the logic gate determined to be valid at step S520 by the random number coefficient determination function 162c, and calculates the fixed value nrnd as the random number coefficient nrnd_i(t).
As the value of the constant 1, a value greater than 1 is usually used. In this case, by the random number coefficient determination function 162c, the processing circuit 150 gives at least one of the input nodes and the output nodes a larger random value in a case in which the signal values at the input nodes and the output nodes are not matched with the truth table to be satisfied by the logic gate as compared with a case in which the signal values are matched with the truth table.
Next, at step S540, the processing circuit 150 generates random number ri(t) represented in the third term on the right side of equation (12) by the random number generation function 162d. Next, the processing circuit 150 calculates the second evaluation value, which is the third term on the right side of equation (12), by multiplying the random number coefficient nrnd_i(t) given at step S530 by the random number ri(t), by the second evaluation value generation function 162.
Next, at step S230, the processing circuit 150 generates a value of function Ii(t+1) by adding the first evaluation value, which is the sum of the first term and the second term on the right side of equation (12), and the second evaluation value, which is the third term on the right side of equation (12), by the evaluation value addition function 163. Next, the processing circuit 150 updates, based on the value of the function Ii(t+1) generated, the signal value mi(t) in the i-th node according to equations (9) and (10) by the node data update function 164. Thus, as illustrated in
As described above, the processing circuit 150 controls the signal value mi(t) based on the relationship to be satisfied between some nodes of the input nodes and the output nodes by the invertible logic gate processing function 160. That is, the processing circuit 150 determines, by the invertible logic gate processing function 160, the magnitude of the random value nrnd_i(t) to be given to at least one of the input nodes and the output nodes based on the relationship to be satisfied between some nodes of the input nodes and the output nodes, thereby probabilistically updating the signal value mi(t). Specifically, the processing circuit 150 probabilistically updates the signal values at at least one of the input nodes and the output nodes based on the sum of the evaluation value determined based on the signal values mi(t) at the input nodes and the output nodes and the random number generated based on the magnitude of the random value nrnd_i(t).
The embodiment is not limited thereto. In the embodiment, in the case of performing the processing of determining whether the relationship to be satisfied between the nodes is satisfied at step S520, it will be described that the signal values of the nodes are determined in units of the logic gates. However, the embodiment is not limited thereto, and at step S520, the processing circuit 150 may determine whether or not the relationship to be satisfied between nodes is satisfied in units of blocks of the logic gates by the second evaluation value generation function 162.
In
Here, a graph 40 and a graph 41 represents comparative examples, while a graph 42 and a graph 43 represents the methods used in the embodiment.
The graph 40 is a result of calculation using the method illustrated in
It can be seen in
According to at least one embodiment described above, the performance can be improved in the circuits that can solve the inverse problems.
While certain embodiments have been described, these embodiments have been presented by way of example only, and are not intended to limit the scope of the inventions. Indeed, the novel embodiments described herein may be embodied in a variety of other forms; furthermore, various omissions, substitutions and changes in the form of the embodiments described herein may be made without departing from the spirit of the inventions. The accompanying claims and their equivalents are intended to cover such forms or modifications as would fall within the scope and spirit of the inventions.
Number | Date | Country | Kind |
---|---|---|---|
2022-099193 | Jun 2022 | JP | national |