Disclosure of Invention
The invention provides a component arrangement method and a component arrangement system of a biochemical reaction detection device on a microchip, which are used for reducing the time of the whole biochemical reaction detection process by reasonably designing the physical position of a component and a connection path thereof.
A first aspect of the present invention provides a method for arranging components of a biochemical reaction detecting apparatus on a microchip, comprising:
designing constraint conditions of integer linear programming ILP and setting a guess value recursion rule of reaction completion time, wherein the constraint conditions comprise the constraint conditions of the reaction completion time;
calculating according to the guess value recursion rule to obtain a kth guess value, substituting the kth guess value into the reaction completion time constraint condition to form a kth ILP constraint condition, and performing combined solution under the kth constraint condition to judge whether the ILP corresponding to the kth guess value is feasible or not;
if the value is feasible, updating the upper bound of the ILP solution to the k-th guess value, and if the value is not feasible, updating the lower bound of the ILP solution to the k-th guess value;
and iterating the calculation to obtain a k-th guess value, solving and judging whether the corresponding ILP is feasible and updating the ILP upper limit or lower limit until the final solution of the ILP is the component position layout.
In a second aspect of the present invention, there is provided a component arrangement system for a biochemical reaction detecting apparatus on a microchip, comprising:
a position layout module, configured to design constraint conditions of an integer linear programming ILP and set guess value recurrence rules of response completion time, where the constraint conditions include response completion time constraint conditions, calculate a kth guess value according to the guess value recurrence rules, substitute the kth guess value into the kth response completion time constraint conditions to form kth ILP constraint conditions, jointly solve and determine whether ILP corresponding to the kth guess value is feasible under the kth constraint conditions, update an upper bound of an ILP solution to the kth guess value when feasible, update a lower bound of the ILP solution to the kth guess value when infeasible, iterate the calculation to obtain the kth guess value, determine whether ILP is feasible and solve the process of updating the upper bound or the lower bound of the ILP until a final solution of the ILP is obtained, and output a component position layout and component routing composition component layout scheme;
and the routing layout module is used for calculating and obtaining the routing layout under the component position layout according to a maze algorithm.
The invention has the beneficial effects that:
the component arrangement method of the biochemical reaction detection device on the microchip designs the biochip by adopting an ILP (Integer Linear Programming) algorithm, namely, the limiting conditions of the component position and the limiting conditions of the biochemical reaction completion sequence are set as the constraint conditions of the ILP when the biochip is designed, the ILP containing unknown constraint of biochemical reaction completion time is solved by successive iteration to reduce the upper bound and the lower bound of the ILP solution, the final solution is obtained to give the component position layout, and the time of the whole biochemical reaction detection process is reduced by reasonably designing the physical position and the connection path of the component; particularly, in iteration, a geometric series updating method is used for replacing a dichotomy in the conventional ILP for a guessed value of the biochemical reaction completion time, so that the solving time is reduced, and the design speed for different detection process component arrangements is improved.
Detailed Description
FIG. 1 is a flowchart of a first embodiment of a method for arranging elements of a biochemical reaction detecting device on a microchip according to the present invention, as shown in FIG. 1, the method for arranging elements of the biochemical reaction detecting device on a microchip according to the present invention comprises:
s101, designing constraint conditions of integer linear programming ILP (integer Linear programming) and setting a guess value recursion rule of reaction completion time, wherein the constraint conditions comprise the constraint conditions of the reaction completion time;
preferably, the ILP constraints (1) to (4) include:
constraint (1) that a component corresponds to and only one physical location:
component non-overlapping constraint (2):
component resource constraint (3):
the constraint condition indicates that at a time node t, the sum of the demands of j-th resources corresponding to all biochemical reactions needing the j-th resources is not more than the total amount of the j-th resources;
biochemical reaction sequence constraint (4):
wherein, a x,y,t,i Representing the corresponding layout variable of the component, the layout variable a x,y,t,i X, y, t and i in the database respectively represent two physical position coordinates of the component, a time node of the component in the biochemical reaction process and a component identifier;representing the amount of j resources required by the i component, r j Represents the total amount of j-th resources; t represents the total time for completion of the biochemical reaction; i.e. the constraint (5) for solving ILP jointly:
preferably, the assembly comprises an input liquid storage tank, an output liquid storage tank and a dilution tank for detecting the biochemical reactant on the microchip;
preferably, the assembly further comprises an Optical Sensor (Optical Sensor) for detecting a biochemical reactant on the microchip;
preferably, the guessed value recurrence rule of the reaction completion time includes:
setting the first guess as the initial guess t 0 ;
Or,
updating the k-th guess value t according to the formula (6) k :
Wherein k is>1,U k-1 Represents the upper bound, L, of the ILP solution for the (k-1) th iteration k-1 Represents the lower bound of the ILP solution for the (k-1) th iteration;
correspondingly, the iterating the calculation to obtain the k-th guess, the solving to judge whether the corresponding ILP is feasible, and the updating the ILP upper bound or lower bound process until the final solution of the ILP is obtained include:
iterating the calculation to obtain a k-th guess value, solving and judging whether the corresponding ILP is feasible or not, and updating the ILP upper bound or lower bound process until the iteration number n meets the requirement (7):
n=loglog(U n-1 /L n-1 ) (7);
wherein, U n-1 Represents the upper bound, L, of the ILP solution for the (n-1) th iteration n-1 Represents the lower bound of the ILP solution for the (n-1) th iteration;
s102, calculating according to the guess value recursion rule to obtain a kth guess value, substituting the kth guess value into the reaction completion time constraint condition to form a kth ILP constraint condition, and jointly solving under the kth constraint condition and judging whether the ILP corresponding to the kth guess value is feasible or not;
s103, if the upper bound of the ILP solution is feasible, updating the upper bound of the ILP solution to the k-th guessed value, and if the lower bound of the ILP solution is not feasible, updating the lower bound of the ILP solution to the k-th guessed value, and keeping the upper bound of the ILP solution unchanged;
s104, iterating the calculation to obtain a k-th guess value, solving and judging whether the corresponding ILP is feasible or not and updating the ILP upper bound or lower bound process until the final ILP solution is obtained and is the component position layout;
preferably, after iterating the calculation to obtain the kth guess value, solving to determine whether the corresponding ILP is feasible, and updating the ILP upper bound or lower bound until the final ILP solution is determined as the component position layout, the method further includes:
and S105, calculating a route layout under the component position layout according to a maze algorithm, wherein the component position layout and the component route layout form an output scheme of the component layout.
In the first embodiment of the component arrangement method of the biochemical reaction detection device on the microchip of the present invention, the biochip is designed by using the ILP (Integer Linear programming), that is, the limiting conditions of the component arrangement and the limiting conditions of the biochemical reaction completion sequence are set as the constraint conditions of the ILP when the biochip is designed, and the ILP containing the unknown constraint of the biochemical reaction completion time is solved by successive iteration to reduce the upper bound and the lower bound of the solution of the ILP, so that the final solution is obtained to give the component position layout, thereby realizing the reduction of the time of the whole biochemical reaction detection process by reasonably designing the physical position of the component and the connection path thereof; particularly, in iteration, a geometric series updating method is used for replacing a dichotomy in the existing ILP for a guessed value of the biochemical reaction completion time, so that the solving time is reduced, and the design speed for different detection process component arrangements is improved.
FIG. 2 is a flow chart of a first embodiment of a component arrangement system of a biochemical reaction detecting apparatus on a microchip according to the present invention, as shown in FIG. 2, the component arrangement system of the biochemical reaction detecting apparatus on a microchip according to the present invention comprises:
a position layout module 21, configured to design constraint conditions of an integer linear programming ILP and set guess value recurrence rules of response completion time, where the constraint conditions include response completion time constraint conditions, calculate a kth guess value according to the guess value recurrence rules, substitute the kth guess value into the response completion time constraint conditions to form kth-time ILP constraint conditions, jointly solve and determine whether ILP corresponding to the kth guess value is feasible under the kth constraint conditions, update an upper bound of ILP solution to the kth guess value (and a lower bound of ILP solution is unchanged) when feasible, update a lower bound of ILP solution to the kth guess value (and an upper bound of ILP solution is unchanged) when infeasible, and iterate the calculation to obtain the kth guess value, determine whether ILP is feasible by the solution, and iterate a process of updating the upper bound or the lower bound of ILP until a final solution of ILP is obtained, and output a component layout scheme composed of component position and component routes;
and the routing layout module is used for calculating and obtaining the routing layout under the component position layout according to a maze algorithm.
Preferably, the ILP constraints (1) to (4) include:
constraint (1) that a component corresponds to and only one physical location:
component non-overlap constraint (2):
component resource constraint (3):
the constraint condition indicates that at a time node t, the sum of the demanded quantity of j-th resources corresponding to all biochemical reactions needing the j-th resources is not more than the total quantity of the j-th resources;
biochemical reaction sequence constraint (4):
i.e. the constraint (5) for jointly solving ILP:
wherein, a x,y,t,i Representing the corresponding layout variable of the component, the layout variable a x,y,t,i X, y, t and i in the database respectively represent two physical position coordinates of the component, a time node of the component in the biochemical reaction process and a component identifier;representing the amount of j resources required by the i component, r j Represents the total amount of j-th resources; t represents the total time for completion of the biochemical reaction.
Preferably, the guessed value recurrence rule of the reaction completion time includes:
setting a first guess value t 0 (i.e., the initial guess);
or,
updating the k-th guess value t according to the formula (6) k :
Wherein k is>1,U k-1 Represents the upper bound, L, of the ILP solution for the (k-1) th iteration k-1 Representing the lower bound of the ILP solution for the (k-1) th iteration.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and these modifications or substitutions do not depart from the spirit of the corresponding technical solutions of the embodiments of the present invention.