Solution system, solution method, and solution program
Provided is a solution system capable of obtaining the optimal state of individual spins with a small amount of memory. The matrix simplification means 93 changes a matrix used in an energy function in a model representing states of individual spins by a first value or a second value into simplified form. In this case, the matrix simplification means 93 deletes elements that have a value of “0” from the matrix, and also deletes some elements that do not have the value of “0” from the matrix, thereby to change the matrix into the simplified form. The spin state derivation means 94 derives the optimal state of each spin based on the matrix changed into the simplified form.
1 . A solution system comprising:
a memory configured to store instructions; and
a processor configured to execute the instructions to:
change a matrix used in an energy function in a model representing states of individual spins by a first value or a second value into simplified form;
derive a state of each spin in a case where energy represented by the energy function is as small as possible or a state of each spin in a case where energy represented by the energy function is as large as possible, based on the matrix changed into the simplified form;
delete elements that have a value of “0” from the matrix, and also delete some elements that do not have the value of “0” from the matrix, to thereby change the matrix into the simplified form; and
control storage, in the memory, of the matrix which has been changed into the simplified form,
wherein whether the processor derives the state of each spin in a case where energy represented by the energy function is as small as possible or the state of each spin in a case where energy represented by the energy function is as large as possible, is specified from outside.
2 . The solution system according to claim 1 , wherein the processor is configured to execute the instructions to:
in a case where a set of spins is defined and a constraint is defined for the set, exclude elements representing connection between spins belonging to the set for which the constraint is defined from deletion targets.
3 . The solution system according to claim 1 , wherein the processor is configured to execute the instructions to:
delete elements whose absolute value is equal to or less than a threshold value among the elements that do not have the value of “0”, from the matrix.
4 . The solution system according to claim 1 , wherein the processor is configured to execute the instructions to:
delete the elements that do not have the value of “0” in ascending order of absolute value from the matrix, so that capacity of the matrix changed into the simplified form equals a predetermined memory capacity.
5 . The solution system according to claim 1 , wherein the processor is configured to execute the instructions to:
execute an operation in which the processor deletes elements that have a value of “0” from the matrix, and also deletes elements that do not have the value of “0” randomly, and the processor derives the state of each spin in a case where energy represented by the energy function is as small as possible or the state of each spin in a case where energy represented by the energy function is as large as possible, based on the matrix changed into the simplified form, and derives energy of derived state is repeated multiple times; and
select an optimal state from among multiple states obtained as states of each spin, based on the energy derived with the state of each spin.
6 . A solution method comprising:
executing a matrix simplification process comprising changing a matrix used in an energy function in a model representing states of individual spins by a first value or a second value into simplified form;
executing a spin state derivation process comprising deriving state of each spin in a case where energy represented by the energy function is as small as possible or a state of each spin in a case where energy represented by the energy function is as large as possible, based on the matrix changed into the simplified form,
deleting elements that have a value of “0” from the matrix, and also deleting some elements that do not have the value of “0” from the matrix, to thereby change the matrix into the simplified form; and
controlling storage, in memory, of the matrix which has been changed into the simplified form,
wherein whether to derive, in the spin state derivation process, the state of each spin in a case where energy represented by the energy function is as small as possible or the state of each spin in a case where energy represented by the energy function is as large as possible, is specified from outside.
7 . The solution method according to claim 6 , wherein the matrix simplification process comprises:
in a case where a set of spins is defined and a constraint is defined for the set, excluding elements representing connection between spins belonging to the set for which the constraint is defined from deletion targets.
8 . A non-transitory computer-readable recording medium in on which a solution program is recorded, wherein the solution program causes a computer to execute:
a matrix simplification process comprising changing a matrix used in an energy function in a model representing states of individual spins by a first value or a second value into simplified form;
a spin state derivation process comprising deriving state of each spin in a case where energy represented by the energy function is as small as possible or a state of each spin in a case where energy represented by the energy function is as large as possible, based on the matrix changed into the simplified form; and
control storage, in a memory, of the matrix which has been changed into the simplified form,
wherein the matrix simplification process comprises deleting elements that have a value of “0” from the matrix, and also deleting some elements that do not have the value of “0” from the matrix, thereby to change the matrix into the simplified form, and
wherein whether to cause the computer to derive, in the spin state derivation process, the state of each spin in a case where energy represented by the energy function is as small as possible or the state of each spin in a case where energy represented by the energy function is as large as possible is specified from outside.
9 . The non-transitory computer-readable recording medium on which the solution program is recorded according to claim 8 , wherein the matrix simplification process comprises, in a case where a set of spins is defined and a constraint is defined for the set, excluding elements representing connection between spins belonging to the set for which the constraint is defined from deletion targets.