Введение
Двойная задача — это переформулировка задачи об удовлетворении ограничениям, в которой каждое ограничение исходной задачи представляется переменной. Двойные задачи содержат только бинарные ограничения и, следовательно, могут быть решены алгоритмами, разработанными для решения таких задач. Объединительные графы и объединительные деревья задачи об удовлетворении ограничениям — это графы, представляющие двойную задачу или задачу, полученную из двойной задачи путём удаления некоторых избыточных ограничений.
Двойная проблема
Двойная задача задачи об удовлетворении ограничениями содержит переменную для каждого ограничения исходной задачи. Области определения и ограничения строятся таким образом, чтобы обеспечить своего рода эквивалентность исходной задаче. В частности, область определения переменной двойной задачи содержит один элемент для каждой кортежа, удовлетворяющей соответствующему исходному ограничению. Таким образом, двойная переменная может принимать значение тогда и только тогда, когда соответствующее исходное ограничение выполняется соответствующей кортежем. Ограничения двойной задачи запрещают двум двойным переменным принимать значения, соответствующие двум несовместимым кортежам. Без этих ограничений одна двойная переменная может принимать значение, соответствующее кортежу, в то время как другая двойная переменная принимает значение, соответствующее, что присваивает другое значение.
More generally, the constraints of the dual problem enforce the same values for all variables shared by two constraints. If two dual variables correspond to constraints sharing some variables, the dual problem contains a constraint between them, enforcing equality of all shared variables. The dual variables are the constraints of the original problem. The domain of each dual variable is the set of tuples of the corresponding original constraint. The dual constraints enforce the dual variables (original constraints) to have values (original tuples) that contain equal values of the original variables. In this example, the original constraints and share the variable In the dual problem, the variables and are allowed to have values and because these values agree on
In the dual problem, all constraints are binary. They all enforce two values, which are tuples, to agree on one or more original variables. The dual graph is a representation of how variables are constrained in the dual problem. More precisely, the dual graph contains a node for each dual variable and an edge for every constraint between them. In addition, the edge between two variables is labeled by the original variables that are enforced equal between these two dual variables. The dual graph can be built directly from the original problem: it contains a vertex for each constraint, and an edge between every two constraints sharing variables; such an edge is labeled by these shared variables. A dual graph. An edge between two constraints corresponds to a dual constraint enforcing equality of their shared variables. For example, the edge labeled between and indicates that the dual problem contains a constraint between and , and this constraint enforces values (tuples) that match on and .
В более общем случае ограничения двойной задачи обеспечивают одинаковые значения для всех переменных, общих для двух ограничений. Если две двойные переменные соответствуют ограничениям, имеющим общие переменные, двойная задача содержит ограничение между ними, обеспечивающее равенство всех общих переменных. Двойные переменные соответствуют ограничениям исходной задачи. Область определения каждой двойной переменной является множеством кортежей соответствующего исходного ограничения. Двойные ограничения заставляют двойные переменные (исходные ограничения) иметь значения (исходные кортежи), содержащие равные значения исходных переменных. В этом примере исходные ограничения и имеют общую переменную. В двойной задаче переменные и могут иметь значения и, поскольку эти значения согласованы на.
More generally, the constraints of the dual problem enforce the same values for all variables shared by two constraints. If two dual variables correspond to constraints sharing some variables, the dual problem contains a constraint between them, enforcing equality of all shared variables. The dual variables are the constraints of the original problem. The domain of each dual variable is the set of tuples of the corresponding original constraint. The dual constraints enforce the dual variables (original constraints) to have values (original tuples) that contain equal values of the original variables. In this example, the original constraints and share the variable In the dual problem, the variables and are allowed to have values and because these values agree on
In the dual problem, all constraints are binary. They all enforce two values, which are tuples, to agree on one or more original variables. The dual graph is a representation of how variables are constrained in the dual problem. More precisely, the dual graph contains a node for each dual variable and an edge for every constraint between them. In addition, the edge between two variables is labeled by the original variables that are enforced equal between these two dual variables. The dual graph can be built directly from the original problem: it contains a vertex for each constraint, and an edge between every two constraints sharing variables; such an edge is labeled by these shared variables. A dual graph. An edge between two constraints corresponds to a dual constraint enforcing equality of their shared variables. For example, the edge labeled between and indicates that the dual problem contains a constraint between and , and this constraint enforces values (tuples) that match on and .
В двойной задаче все ограничения бинарны. Все они обеспечивают согласованность двух значений, которые являются кортежами, по одной или нескольким исходным переменным. Двойной граф представляет собой представление того, как переменные ограничены в двойной задаче. Более точно, двойной граф содержит узел для каждой двойной переменной и ребро для каждого ограничения между ними. Кроме того, ребро между двумя переменными маркируется исходными переменными, которые должны быть равны между этими двумя двойными переменными. Двойной граф может быть построен непосредственно из исходной задачи: он содержит вершину для каждого ограничения и ребро между любыми двумя ограничениями, имеющими общие переменные; такое ребро маркируется этими общими переменными. Двойной граф. Ребро между двумя ограничениями соответствует двойному ограничению, обеспечивающему равенство их общих переменных. Например, ребро, помеченное, между и указывает, что двойная задача содержит ограничение между и, и это ограничение обеспечивает соответствие значений (кортежей) на и.
More generally, the constraints of the dual problem enforce the same values for all variables shared by two constraints. If two dual variables correspond to constraints sharing some variables, the dual problem contains a constraint between them, enforcing equality of all shared variables. The dual variables are the constraints of the original problem. The domain of each dual variable is the set of tuples of the corresponding original constraint. The dual constraints enforce the dual variables (original constraints) to have values (original tuples) that contain equal values of the original variables. In this example, the original constraints and share the variable In the dual problem, the variables and are allowed to have values and because these values agree on
In the dual problem, all constraints are binary. They all enforce two values, which are tuples, to agree on one or more original variables. The dual graph is a representation of how variables are constrained in the dual problem. More precisely, the dual graph contains a node for each dual variable and an edge for every constraint between them. In addition, the edge between two variables is labeled by the original variables that are enforced equal between these two dual variables. The dual graph can be built directly from the original problem: it contains a vertex for each constraint, and an edge between every two constraints sharing variables; such an edge is labeled by these shared variables. A dual graph. An edge between two constraints corresponds to a dual constraint enforcing equality of their shared variables. For example, the edge labeled between and indicates that the dual problem contains a constraint between and , and this constraint enforces values (tuples) that match on and .
Расширения
Не все задачи удовлетворения ограничений имеют дерево объединения. Однако задачи можно модифицировать для получения дерева объединения. Кластеризация деревьев объединения – это конкретный метод модификации задач таким образом, чтобы они приобрели дерево объединения. Это достигается путем объединения ограничений, что обычно увеличивает размер задачи; однако решение полученной задачи упрощается, как и для всех задач, имеющих дерево объединения. Методы декомпозиции обобщают кластеризацию деревьев объединения, группируя переменные таким образом, чтобы результирующая задача имела дерево объединения. Методы декомпозиции напрямую связывают дерево с задачей; узлы этого дерева соответствуют переменным и/или ограничениям исходной задачи. Объединяя ограничения на основе этого дерева, можно получить задачу, имеющую дерево объединения, которое легко вывести из дерева декомпозиции. Альтернативно, можно непосредственно из дерева декомпозиции построить бинарную ациклическую задачу.