JP2021174061A - Zsdd construction apparatus, zsdd construction method, and program - Google Patents

Zsdd construction apparatus, zsdd construction method, and program Download PDF

Info

Publication number
JP2021174061A
JP2021174061A JP2020074831A JP2020074831A JP2021174061A JP 2021174061 A JP2021174061 A JP 2021174061A JP 2020074831 A JP2020074831 A JP 2020074831A JP 2020074831 A JP2020074831 A JP 2020074831A JP 2021174061 A JP2021174061 A JP 2021174061A
Authority
JP
Japan
Prior art keywords
zsdd
node
vtree
construction
graph
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP2020074831A
Other languages
Japanese (ja)
Other versions
JP7377493B2 (en
Inventor
正彬 西野
Masaaki Nishino
真一 湊
Shinichi Minato
純 川原
Jun Kawahara
裕 中畑
Yu Nakahata
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Nippon Telegraph and Telephone Corp
Kyoto University NUC
Original Assignee
Nippon Telegraph and Telephone Corp
Kyoto University NUC
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Nippon Telegraph and Telephone Corp, Kyoto University NUC filed Critical Nippon Telegraph and Telephone Corp
Priority to JP2020074831A priority Critical patent/JP7377493B2/en
Publication of JP2021174061A publication Critical patent/JP2021174061A/en
Application granted granted Critical
Publication of JP7377493B2 publication Critical patent/JP7377493B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

To efficiently construct a ZSDD representing a family of edge collections that satisfies an order constraint on nodes of a graph.SOLUTION: A ZSDD construction apparatus according to one embodiment includes an input unit that inputs a graph G configured by a node collection V and an edge collection E, and an order constraint relating to the number of edges with the node as an end point, and a construction unit that constructs a ZSDD representing a family which is a subset of the collection E and is configured by a subset of the edges that satisfy an order constraint based on the graph G and a vtree corresponding the order constraint and the graph G.SELECTED DRAWING: Figure 7

Description

本発明は、ZSDD構築装置、ZSDD構築方法及びプログラムに関する。 The present invention relates to a ZSDD construction device, a ZSDD construction method and a program.

集合Sが与えられたとき、Sの部分集合を要素とするような集合は集合族と呼ばれる。様々な問題は、集合族を対象とした計算問題に帰着して解くことができる。例えば、ノードの集合をV、ノードの対からなるエッジの集合をEとしたグラフG=(V,E)が与えられたとき、グラフGのマッチングとは、Eの部分集合のうち、他のエッジとノードを共有しないエッジで構成される部分集合のことである。そのため、マッチングの集合は、Eを台集合とした集合族で表現することが可能である。マッチングのうち、エッジ数が最大のマッチングを選択する問題は最大マッチング問題と呼ばれ、多くの応用問題が最大マッチング問題に帰着して解かれている。最大マッチング問題は、グラフGの全てのマッチングの集合が集合族として表現されていれば、この集合族の中から、要素数が最大の集合を選択する問題として解くことができる。 Given a set S, a set whose elements are subsets of S is called a family of sets. Various problems can be solved by reducing them to computational problems for the family of sets. For example, when a graph G = (V, E) is given in which the set of nodes is V and the set of edges consisting of pairs of nodes is E, the matching of the graph G is the other subset of E. A subset of edges that do not share a node with an edge. Therefore, the matching set can be represented by a family of sets with E as a support set. Of the matching, the problem of selecting the matching with the largest number of edges is called the maximum matching problem, and many applied problems are solved as a result of the maximum matching problem. The maximum matching problem can be solved as a problem of selecting the set having the largest number of elements from the set family if all the matching sets of the graph G are expressed as a set family.

ところで、集合族を対象とした計算は、多くの場合、集合族の大きさに比例した時間を要する。このため、集合族の大きさが膨大になると、その計算に多くの時間を要し、効率的な処理が困難となる。例えば、前述のマッチングの個数は最悪でエッジの総数|E|の指数倍となる可能性があるため、マッチングの集合を明示的に求めて、それに対して処理を行うことは非効率的である。 By the way, in many cases, the calculation for the family of sets takes time proportional to the size of the family of sets. Therefore, when the size of the family of sets becomes enormous, it takes a lot of time to calculate it, and efficient processing becomes difficult. For example, since the number of matchings described above may be an exponential multiple of the total number of edges | E | in the worst case, it is inefficient to explicitly obtain a set of matchings and process it. ..

このような点に鑑みて、集合族を計算に適したデータ構造に変換して保持することによって、集合族を対象とした各種演算を高速に実行するアプローチが存在する。このようなアプローチの1つとして、ZSDD(Zero-suppressed Sentential Decision Diagram)を用いて集合族を表現する方法が挙げられる(非特許文献1)。ZSDDは集合族を有向非巡回グラフ(DAG:Directed acyclic graph)として表現し、集合族を対象とした様々な演算をZSDDのエッジ数に比例する時間で実行可能なデータ構造である。 In view of these points, there is an approach to execute various operations on the family of sets at high speed by converting the family of sets into a data structure suitable for calculation and holding it. As one of such approaches, there is a method of expressing a family of sets using ZSDD (Zero-suppressed Sentential Decision Diagram) (Non-Patent Document 1). ZSDD is a data structure that expresses a family of sets as a directed acyclic graph (DAG) and can perform various operations on the family of sets in a time proportional to the number of edges of ZSDD.

ZSDDを用いて計算を行う場合、集合族を表現するZSDDを効率的に構築することが重要となる。これに対して、(1)グラフのマッチングの集合を表す集合族(つまり、エッジの集合の部分集合のうち、他のエッジとノードを共有しないエッジで構成される部分集合をその要素とする集合族)、(2)台集合の部分集合のうち、要素数がKの部分集合からなる集合族、のいずれかの集合族を表現するZSDDを効率的に構築する方法が知られている(特許文献1)。 When performing calculations using ZSDD, it is important to efficiently construct ZSDD that represents the family of sets. On the other hand, (1) a set family representing a set of matching graphs (that is, a set whose elements are a subset of edges that do not share a node with other edges. A method is known for efficiently constructing a ZSDD that represents one of a set family consisting of a subset of K elements among a subset of a set (family) and (2) a set (patent). Document 1).

特開2018−041161号公報JP-A-2018-041161

Masaaki Nishino, Norihito Yasuda, Shin-ichi Minato and Masaaki Nagata, "Zero-suppressed Sentential Decision Diagrams", In Proceedings of the 30th AAAI Conference on Artificial Intelligence, pp 1058-1066, 2016.Masaaki Nishino, Norihito Yasuda, Shin-ichi Minato and Masaaki Nagata, "Zero-suppressed Sentential Decision Diagrams", In Proceedings of the 30th AAAI Conference on Artificial Intelligence, pp 1058-1066, 2016.

しかしながら、上記の特許文献1では、上記の(1)又は(2)の2種類の集合族以外の集合族を表現するZSDDは構築することができなかった。一方で、グラフのノードに対する次数制約を満たすエッジの集合の集合族を対象とした計算問題も多く存在する。このため、このような集合族を表現するZSDDを効率的に構築する方法が求められている。 However, in Patent Document 1 described above, ZSDD representing a family of sets other than the two types of family of sets (1) or (2) described above could not be constructed. On the other hand, there are many computational problems for the family of sets of edges that satisfy the degree constraint for the nodes of the graph. Therefore, there is a demand for a method for efficiently constructing a ZSDD that expresses such a family of sets.

本発明の一実施形態は、上記の点に鑑みてなされたもので、グラフのノードに対する次数制約を満たすエッジの集合の集合族を表現するZSDDを効率的に構築することを目的とする。 One embodiment of the present invention has been made in view of the above points, and an object of the present invention is to efficiently construct a ZSDD representing a family of sets of edges satisfying a degree constraint for a node of a graph.

上記目的を達成するため、一実施形態に係るZSDD構築装置は、ノードの集合Vとエッジの集合Eとで構成されるグラフGと、前記ノードを端点とするエッジ数に関する制約を表す次数制約とを入力する入力部と、前記グラフGと前記次数制約と前記グラフGに対応するvtreeとに基づいて、前記集合Eの部分集合であって、かつ、前記次数制約を満たすエッジの部分集合で構成される集合族を表すZSDDを構築する構築部と、を有することを特徴とする。 In order to achieve the above object, the ZSDD construction apparatus according to the embodiment includes a graph G composed of a set V of nodes and a set E of edges, and a degree constraint representing a constraint on the number of edges with the node as an end point. Based on the input unit for inputting, the graph G, the order constraint, and the vtree corresponding to the graph G, the set is a subset of the set E and is composed of a subset of edges satisfying the order constraint. It is characterized by having a construction unit for constructing a ZSDD representing a family of sets to be created.

グラフのノードに対する次数制約を満たすエッジの集合の集合族を表現するZSDDを効率的に構築することができる。 It is possible to efficiently construct a ZSDD that represents a family of sets of edges that satisfy the order constraint for the nodes of the graph.

vtreeの一例を示す図である。It is a figure which shows an example of vtree. ZSDDの一例を示す図である。It is a figure which shows an example of ZSDD. ZSDDの計算機上での表現の一例を示す図である。It is a figure which shows an example of the expression on the computer of ZSDD. 本実施形態に係るZSDD構築装置の機能構成の一例を示す図である。It is a figure which shows an example of the functional structure of the ZSDD construction apparatus which concerns on this embodiment. 本実施形態に係るZSDD構築装置のハードウェア構成の一例を示す図である。It is a figure which shows an example of the hardware composition of the ZSDD construction apparatus which concerns on this embodiment. 本実施形態に係るZSDD構築装置が実行する処理の一例を示すフローチャートである。It is a flowchart which shows an example of the process executed by the ZSDD construction apparatus which concerns on this embodiment. 本実施形態に係るZSDD構築処理の一例を示すフローチャートである。It is a flowchart which shows an example of the ZSDD construction process which concerns on this Embodiment. 本実施形態に係るconstruct(v, Z)の処理の一例を示すフローチャートである。It is a flowchart which shows an example of the process of construct (v, Z) which concerns on this embodiment. 本実施形態に係るterminal(v, m)の処理の一例を示すフローチャートである。It is a flowchart which shows an example of the processing of terminal (v, m) which concerns on this embodiment. 本実施形態に係るdecomp(v, z)の処理の一例を示すフローチャートである。It is a flowchart which shows an example of the process of decomp (v, z) which concerns on this embodiment.

以下、本発明の一実施形態について説明する。本実施形態では、グラフのノードに対する次数制約を満たすエッジの集合の集合族を表現するZSDDを効率的に構築することが可能なZSDD構築装置10について説明する。 Hereinafter, an embodiment of the present invention will be described. In the present embodiment, the ZSDD construction device 10 capable of efficiently constructing a ZSDD representing a family of sets of edges satisfying the order constraint for the nodes of the graph will be described.

<準備>
まず、本実施形態で用いる記号や概念、用語等について説明する。
<Preparation>
First, symbols, concepts, terms, and the like used in the present embodiment will be described.

Vをノードの集合、Eをエッジの集合として、G=(V,E)をグラフとする。エッジe∈Eはノードのペアu,v∈Vによってe=(u,v)と表される。また、グラフの頂点v∈Vに対して、vを端点として含むようなエッジの数をvの次数と呼ぶ。 Let V be a set of nodes, E be a set of edges, and G = (V, E) be a graph. The edge e ∈ E is expressed as e = (u, v) by the pair of nodes u, v ∈ V. Further, the number of edges including v as an end point with respect to the vertex v ∈ V of the graph is called the order of v.

集合族とは、ある台集合Z={A,B,C,・・・}に対して、その部分集合S⊆Zを要素とする集合のことである。例えば、Z={A,B,C,D}とすると、{{A,B},{B},{B,C},{C,D}}はZを台集合とする集合族(の1つ)である。また、φは空集合、2はZのべき集合(つまり、台集合Zの全ての部分集合から構成される集合族)、|Z|はZの要素数を表すものとする。なお、以降では、台集合の要素(例えば、Z={A,B,C,D}である場合のA,B,C及びD)をアイテムと表す。 The family of sets is a set whose elements are subsets S ⊆ Z for a certain support set Z = {A, B, C, ...}. For example, if Z = {A, B, C, D}, then {{A, B}, {B}, {B, C}, {C, D}} is a family of sets with Z as a support. One). Further, φ is an empty set, 2 Z is a power set of Z (that is, a family of sets composed of all subsets of the platform set Z), and | Z | is the number of elements of Z. In the following, the elements of the support set (for example, A, B, C and D when Z = {A, B, C, D}) are referred to as items.

集合族に対する演算をいくつか定義する。f,gを集合族する。このとき、集合族に対する二項演算 Define some operations on the family of sets. Family of f and g. At this time, a binary operation on the family of sets

Figure 2021174061
をそれぞれ以下で定義する。
Figure 2021174061
Are defined below.

Figure 2021174061
次に、ZSDDについて説明する。ZSDDは集合族を再帰的な(X,Y)−分割によって分割し、その分割の様子をDAGとして表現したものになる。集合X,Yが台集合Zの分割、すなわち、X∪Y=ZかつX∩Y=φを満たすとすると、Zを台集合とする集合族f(Z)の(X,Y)−分割は、
Figure 2021174061
Next, ZSDD will be described. ZSDD divides the family of sets by recursive (X, Y) -division, and the state of the division is expressed as DAG. Assuming that the sets X and Y satisfy the division of the support set Z, that is, X∪Y = Z and X∩Y = φ, the (X, Y) -division of the family of sets f (Z) with Z as the support set is ,

Figure 2021174061
と表される。ここで、各i=1,・・・,nに対して、p(X)はXを台集合とする集合族、s(Y)はYを台集合とする集合族である。
Figure 2021174061
It is expressed as. Here, for each i = 1, ..., N, pi (X) is a family of sets with X as a support set, and s i (Y) is a family of sets with Y as a support set.

このとき、(X,Y)−分割では、全てのi,j(ただし、1≦i<j≦n)に対して、 At this time, in the (X, Y) -division, for all i, j (however, 1 ≦ i <j ≦ n),

Figure 2021174061
を満たすものとする。
Figure 2021174061
Satisfy.

例えば、Z={A,B,C,D}、X={A,B}、Y={C,D}である場合、集合族{{A,B},{B},{B,C},{C,D}}の(X,Y)−分割は、 For example, when Z = {A, B, C, D}, X = {A, B}, Y = {C, D}, the family of sets {{A, B}, {B}, {B, C }, {C, D}} (X, Y) -division is

Figure 2021174061
となる。なお、以降では、(X,Y)−分割を{(p,s),・・・,(p,s)}とも表す。また、pをプライム、sをサブと呼ぶ。
Figure 2021174061
Will be. Hereinafter, (X, Y) -division is also referred to as {(p 1 , s 1 ), ..., (P n , s n )}. In addition, the prime p i, a s i is referred to as a sub.

(X,Y)−分割は、集合族に対して再帰的に行うことができる。すなわち、例えば、上記の(X,Y)−分割におけるp={{A,B}}は、更に(B,A)−分割によって{({{B}},{{A}}),({φ},φ)}と分割することができる。 (X, Y) -Division can be done recursively for the family of sets. That is, for example, p 1 = {{A, B}} in the above (X, Y) -division is further {({{B}}, {{A}}) by (B, A) -division. It can be divided into ({φ}, φ)}.

続いて、vtreeを導入する。vtreeは台集合に含まれる各アイテムに対応するノードを葉とするような完全二分木のことである。vtreeの一例を図1に示す。図1では、4つのアイテムA,B,C,Dに対するvtreeの一例を示している。図1に示すvtreeは、ノードvが根ノード、ノードv,v,v及びvが葉ノード、ノードv及びvは根でも葉でもないノードである。なお、葉ノードでないノードを中間ノードともいう。 Then, vtree is introduced. vtree is a complete binary tree whose leaves are the nodes corresponding to each item included in the support set. An example of vtree is shown in FIG. FIG. 1 shows an example of vtree for four items A, B, C, and D. In the vtree shown in FIG. 1, node v 3 is a root node, nodes v 0 , v 2 , v 4 and v 6 are leaf nodes, and nodes v 1 and v 5 are nodes that are neither roots nor leaves. A node that is not a leaf node is also called an intermediate node.

vtreeの中間ノードvは、当該中間ノードvを根とする部分木の葉ノードからなる変数の集合の分割を表現している。すなわち、中間ノードvを根とする部分木の葉ノードに対応するアイテムの集合を、vの左側の子ノードを根とする部分木の葉ノードに対応するアイテムの集合と、vの右側の子ノードを根とする部分木の葉ノードに対応するアイテムの集合とに分割する。なお、ノードvの左側の子ノードをv、右側の子ノードをvとも表す。 The intermediate node v of the volt represents the division of a set of variables consisting of the leaf nodes of the subtree rooted at the intermediate node v. That is, the set of items corresponding to the subtree leaf node rooted at the intermediate node v, the set of items corresponding to the subtree leaf node rooted at the child node on the left side of v, and the child node on the right side of v as the root. Divide into a set of items corresponding to the Konoha node. The child node on the left side of the node v is also expressed as v k , and the child node on the right side is also expressed as v r.

例えば、図1に示すvtreeは、根ノードvは{A,B}と{C,D}への分割に対応し、根ノードvの左側の子ノードvは{B}と{A}への分割に対応する。同様に、根ノードvの左側の子ノードvは{D}と{C}への分割に対応する。以降では、vtreeのノードのうち、左側の子ノードが葉ノードであるようなノードを決定vtreeノードと呼ぶ。また、決定vteeノードでないノードを分割vtreeノードと呼ぶ。図1に示す例では、ノードv及びvが決定vtreeノードである。 For example, in the vtree shown in FIG. 1, the root node v 3 corresponds to the division into {A, B} and {C, D}, and the child node v 1 on the left side of the root node v 3 corresponds to {B} and {A}. } Corresponds to the division into. Similarly, the child node v 5 on the left side of the root node v 3 corresponds to the division into {D} and {C}. Hereinafter, among the nodes of vtree, the node whose left child node is a leaf node is referred to as a determined vtree node. A node that is not a determined vtee node is called a split vtree node. In the example shown in FIG. 1, the node v 1 and v 5 are determined vtree node.

ZSDDは、あるvtreeが与えられたときに、そのvtreeに基づいて集合族を再帰的に分割することによってDAGとして表現することができる。αをZSDD、αが表す集合族を〈α〉とすると、ZSDDは、以下のように再帰的に定義される。 ZSDD can be expressed as a DAG by recursively dividing the family of sets based on a given vtree. Assuming that α is ZSDD and the family of sets represented by α is <α>, ZSDD is recursively defined as follows.

Figure 2021174061
ここで、⊥及びεを定数ZSDDと呼び、X及び±XをリテラルZSDDと呼ぶ。また、定数ZSDDとリテラルZSDDとをあわせて終端ZSDDと呼ぶ。一方、ある(X,Y)−分割に対応するZSDDは分解ZSDDと呼ぶ。
Figure 2021174061
Here, ⊥ and ε are called constant ZSDD, and X and ± X are called literal ZSDD. Further, the constant ZSDD and the literal ZSDD are collectively referred to as a terminal ZSDD. On the other hand, the ZSDD corresponding to a certain (X, Y) -division is called a decomposed ZSDD.

一例として、集合族{{A,B},{B},{B,C},{C,D}}を表すZSDDを図2に示す。図2中の丸で表されているノードは、そのノードを根とするDAGが表現する分解ZSDDを表している。このようなノードを決定ZSDDノードと呼ぶ。決定ZSDDノードを表す丸の中の数字は、vtreeのノードのうち、この決定ZSDDノードに対応するノードを表している。例えば、図2に示すZSDDにおいて、丸の中に数字「3」が記載された決定ZSDDノードは、図1に示すvtreeのノードvに対応していることを表している。同様に、丸の中に数字「1」が記載された決定ZSDDノードは、図1に示すvtreeのノードvに対応していることを表し、丸の中に数字「5」が記載された決定ZSDDノードは、図1に示すvtreeのノードvに対応していることを表している。なお、ZSDDには、同一の数字が丸の中に記載された複数の決定ZSDDノードが存在してもよい。 As an example, ZSDD representing the family of sets {{A, B}, {B}, {B, C}, {C, D}} is shown in FIG. The nodes represented by circles in FIG. 2 represent the decomposed ZSDD represented by the DAG rooted at that node. Such a node is called a decision ZSDD node. The number in the circle representing the decision ZSDD node represents the node corresponding to this decision ZSDD node among the nodes of vtree. For example, in ZSDD shown in FIG. 2, determined ZSDD node number "3" is written in the circle represents that correspond to the node v 3 of vtree shown in FIG. Similarly, decision ZSDD node number "1" is written in the circle, indicates that correspond to the node v 1 of vtree shown in FIG. 1, the number "5" is written in the circle determining ZSDD node represents that correspond to the node v 5 of vtree shown in FIG. In addition, ZSDD may have a plurality of determination ZSDD nodes in which the same number is described in a circle.

また、決定ZSDDノードを親ノードとするノードの対は要素ノード対と呼ばれ、図2中では四角の対で表されている。この要素ノード対は、(X,Y)−分割{(p,s),・・・,(p,s)}におけるあるプライムとサブのペア(p,s)を表している。要素ノード対のうち、左側の四角がプライムを、右側の四角がサブを表している。プライム及びサブのそれぞれは「終端ZSDD」又は「他の分解ZSDDへのポインタ」を表し、終端ZSDDを表す場合は四角中に該当の終端ZSDDを表す記号が記載されており、他の分解ZSDDへのポインタを表す場合は他の分割ZSDDにおける該当の決定ZSDDノードへの矢印が記載されている。これにより、決定ZSDDノードと、その子ノードである要素ノード対の集合とである(X,Y)−分割が表現される。すなわち、決定ZSDDノードの子ノードとなっている各要素ノード対のそれぞれがプライムとサブのペアに対応している。なお、ZSDDでは、サブが⊥となるようなペアは省略する。したがって、ZSDD中に、 Further, a pair of nodes having a determined ZSDD node as a parent node is called an element node pair, and is represented by a square pair in FIG. This element node pair represents a prime and sub pair ( pi , s i ) in the (X, Y) -division {(p 1 , s 1 ), ..., (P n , s n)}. ing. Of the element node pairs, the square on the left represents the prime and the square on the right represents the sub. Each of the prime and sub represents "termination ZSDD" or "pointer to another decomposition ZSDD", and when representing termination ZSDD, a symbol representing the corresponding termination ZSDD is described in the square, and to another decomposition ZSDD. When representing a pointer to, an arrow to the corresponding decision ZSDD node in another split ZSDD is provided. This represents a (X, Y) -division of the decision ZSDD node and its set of element node pairs that are its child nodes. That is, each element node pair that is a child node of the decision ZSDD node corresponds to a prime and sub pair. In ZSDD, pairs whose sub is ⊥ are omitted. Therefore, during ZSDD,

Figure 2021174061
に対応するような決定ZSDDノードが存在する場合(つまり、上記の3つのいずれかを表す要素ノード群を子ノードとして持つ決定ZSDDノードが存在する場合)、最初の2つはαに、残り1つは⊥に置き換える。
Figure 2021174061
If there is a decision ZSDD node that corresponds to (that is, if there is a decision ZSDD node that has a group of element nodes representing any of the above three as child nodes), the first two are in α and the remaining 1 Replace one with ⊥.

ここで、ZSDDは計算機上では配列を用いて実現することができる。例えば、図2に示すZSDDを計算機上で実現した場合を図3に示す。図3では、vtreeのノードvに対応する決定ZSDDノードは要素数3の配列で実現されており、vtreeのノードvに対応する決定ZSDDノードとvtreeのノードvに対応する決定ZSDDノードはそれぞれ要素数1の配列で実現されている。このとき、配列の各要素には、当該配列に対応する決定ZSDDノードの子ノードである要素ノード対がそれぞれ格納される。言い換えれば、1つの要素には、1つの要素ノード対が表すプライムとサブのペアが格納される。このとき、プライム又はサブが終端ZSDDを表す場合はその終端ZSDDを表す記号(X,⊥,ε等)が格納され、そうでない場合(つまり、他の分解ZSDDへのポインタを表す場合)は他の決定ZSDDノードへの計算機上でのアドレスを保持する。図3に示す例では、vtreeのノードを示すIDと、このIDに対応する決定ZSDDノードのインデックスとのペアで表されている。例えば、図3における「1:1」は、vtreeのノードvに対応する決定ZSDDノードのうち、インデックス「1」の決定ZSDDノードを実現する配列のアドレスを表す。同様に、例えば、「5:1」は、vtreeのノードvに対応する決定ZSDDノードのうち、インデックス「1」の決定ZSDDノードを実現する配列のアドレスを表す。なお、決定ZSDDノードのインデックスが必要な理由は、上述したように、vtreeの1つのノードに対して複数の決定ZSDDノードが対応することがあるためである。 Here, ZSDD can be realized by using an array on a computer. For example, FIG. 3 shows a case where the ZSDD shown in FIG. 2 is realized on a computer. In FIG. 3, the decision ZSDD node corresponding to the node v 3 of the vtree is realized by an array of 3 elements, and the decision ZSDD node corresponding to the node v 1 of the vtree and the decision ZSDD node corresponding to the node v 5 of the vtree are realized. Is realized by an array of 1 element each. At this time, each element of the array stores an element node pair that is a child node of the determination ZSDD node corresponding to the array. In other words, one element stores the prime and sub pairs represented by one element node pair. At this time, if the prime or sub represents the terminal ZSDD, the symbol (X, ⊥, ε, etc.) representing the terminal ZSDD is stored, otherwise (that is, if it represents a pointer to another decomposed ZSDD), the other Decision Holds the computer address to the ZSDD node. In the example shown in FIG. 3, it is represented by a pair of an ID indicating a node of vtree and an index of a determination ZSDD node corresponding to this ID. For example, in FIG. 3, "1: 1", among the decision ZSDD node corresponding to node v 1 of Vtree, representing the address of the array for implementing the decision ZSDD node of the index "1". Similarly, for example, "5: 1", among the decision ZSDD node corresponding to a node v 5 of Vtree, representing the address of the array for implementing the decision ZSDD node of the index "1". The reason why the index of the decision ZSDD node is necessary is that, as described above, a plurality of decision ZSDD nodes may correspond to one node of vtree.

<次数制約を満たすエッジの集合の集合族>
エッジの集合S⊆Eが与えられたときに、ノードv∈Vを端点として含むエッジe∈Sの数をdeg(S,v)と定義する。本実施形態では、各頂点v∈Vに対して0以上の整数を割り当てることで次数制約を表現する。頂点vに割り当てられた整数をδ*(v)とすれば、次数制約を満たすエッジの集合S⊆Eとは、全てのv∈Vに対してdeg(S,v)=δ*(v)を満たすようなSのことである。以降では、このようなSの集合を表す集合族を表現するZSDDを構築するZSDD構築装置10について説明する。
<Family of sets of edges that satisfy order constraints>
Given a set of edges S ⊆ E, we define the number of edges e ∈ S including the node v ∈ V as an endpoint as deg (S, v). In this embodiment, a degree constraint is expressed by assigning an integer of 0 or more to each vertex v ∈ V. Assuming that the integer assigned to the vertex v is δ * (v), the set S⊆E of edges that satisfies the degree constraint is deg (S, v) = δ * (v) for all v ∈ V. It is S that satisfies. Hereinafter, the ZSDD construction device 10 for constructing the ZSDD representing the family of sets representing such a set of S will be described.

<機能構成>
本実施形態に係るZSDD構築装置10の機能構成について、図4を参照しながら説明する。図4は、本実施形態に係るZSDD構築装置10の機能構成の一例を示す図である。
<Functional configuration>
The functional configuration of the ZSDD construction device 10 according to the present embodiment will be described with reference to FIG. FIG. 4 is a diagram showing an example of the functional configuration of the ZSDD construction device 10 according to the present embodiment.

図4に示すように、本実施形態に係るZSDD構築装置10は、入力部101と、vtree獲得部102と、ZSDD構築部103と、出力部104とを有する。 As shown in FIG. 4, the ZSDD construction device 10 according to the present embodiment includes an input unit 101, a vtree acquisition unit 102, a ZSDD construction unit 103, and an output unit 104.

入力部101は、グラフG=(V,E)と次数制約δ*(v)とを入力として受け付ける。なお、入力部101は、予め設定された任意の入力元からグラフG及び次数制約δ*(v)を入力すればよい。このような入力元としては、例えば、後述するメモリ装置206、後述する記録媒体203a、通信ネットワークを介して接続される他の装置又はシステム等が挙げられる。 The input unit 101 accepts the graph G = (V, E) and the order constraint δ * (v) as inputs. The input unit 101 may input the graph G and the order constraint δ * (v) from an arbitrary input source set in advance. Examples of such an input source include a memory device 206 described later, a recording medium 203a described later, another device or system connected via a communication network, and the like.

vtree獲得部102は、ZSDD構築の際に用いるvtreeを獲得する。なお、vtree獲得部102は、通信ネットワークを介して接続される他の装置又はシステムからvtreeを入力してもよいし、後述する記録媒体203a等からvtreeを入力してもよいし、グラフGからvteeを計算してもよい。 The vtree acquisition unit 102 acquires the vtree used when constructing the ZSDD. The vtree acquisition unit 102 may input the vtree from another device or system connected via the communication network, may input the vtree from the recording medium 203a or the like described later, or may input the vtree from the graph G. You may calculate the vtee.

ZSDD構築部103は、次数制約を満たすエッジの集合の集合族を表すZSDDを構築する。 The ZSDD construction unit 103 constructs a ZSDD that represents a family of sets of edges that satisfy the order constraint.

出力部104は、ZSDD構築部103により構築されたZSDDを出力する。なお、出力部104は、予め設定された任意の出力先にZSDDを出力すればよい。このような出力先としては、例えば、後述するメモリ装置206、後述する記録媒体203a、通信ネットワークを介して接続される他の装置又はシステム等が挙げられる。 The output unit 104 outputs the ZSDD constructed by the ZSDD construction unit 103. The output unit 104 may output ZSDD to an arbitrary output destination set in advance. Examples of such an output destination include a memory device 206 described later, a recording medium 203a described later, another device or system connected via a communication network, and the like.

<ハードウェア構成>
次に、本実施形態に係るZSDD構築装置10のハードウェア構成について、図5を参照しながら説明する。図5は、本実施形態に係るZSDD構築装置10のハードウェア構成の一例を示す図である。
<Hardware configuration>
Next, the hardware configuration of the ZSDD construction device 10 according to the present embodiment will be described with reference to FIG. FIG. 5 is a diagram showing an example of the hardware configuration of the ZSDD construction device 10 according to the present embodiment.

図5に示すように、本実施形態に係るZSDD構築装置10は一般的なコンピュータ又はコンピュータシステムで実現され、入力装置201と、表示装置202と、外部I/F203と、通信I/F204と、プロセッサ205と、メモリ装置206とを有する。これらの各ハードウェアは、それぞれがバス207を介して通信可能に接続されている。 As shown in FIG. 5, the ZSDD construction device 10 according to the present embodiment is realized by a general computer or a computer system, and includes an input device 201, a display device 202, an external I / F 203, and a communication I / F 204. It has a processor 205 and a memory device 206. Each of these hardware is communicably connected via bus 207.

入力装置201は、例えば、キーボードやマウス、タッチパネル等である。表示装置202は、例えば、ディスプレイ等である。なお、ZSDD構築装置10は、入力装置201及び表示装置202のうちの少なくとも一方を有していなくてもよい。 The input device 201 is, for example, a keyboard, a mouse, a touch panel, or the like. The display device 202 is, for example, a display or the like. The ZSDD construction device 10 does not have to have at least one of the input device 201 and the display device 202.

外部I/F203は、外部装置とのインタフェースである。外部装置には、記録媒体203a等がある。ZSDD構築装置10は、外部I/F203を介して、記録媒体203aの読み取りや書き込み等を行うことができる。記録媒体203aには、ZSDD構築装置10が有する各機能部(入力部101、vtree獲得部102、ZSDD構築部103及び出力部104)を実現する1以上のプログラムが格納されていてもよい。 The external I / F 203 is an interface with an external device. The external device includes a recording medium 203a and the like. The ZSDD construction device 10 can read or write the recording medium 203a via the external I / F 203. The recording medium 203a may store one or more programs that realize each functional unit (input unit 101, vtree acquisition unit 102, ZSDD construction unit 103, and output unit 104) of the ZSDD construction device 10.

なお、記録媒体203aには、例えば、CD(Compact Disc)、DVD(Digital Versatile Disk)、SDメモリカード(Secure Digital memory card)、USB(Universal Serial Bus)メモリカード等がある。 The recording medium 203a includes, for example, a CD (Compact Disc), a DVD (Digital Versatile Disk), an SD memory card (Secure Digital memory card), a USB (Universal Serial Bus) memory card, and the like.

通信I/F204は、ZSDD構築装置10を通信ネットワークに接続するためのインタフェースである。なお、ZSDD構築装置10が有する各機能部を実現する1以上のプログラムは、通信I/F204を介して、所定のサーバ装置等から取得(ダウンロード)されてもよい。 The communication I / F 204 is an interface for connecting the ZSDD construction device 10 to the communication network. One or more programs that realize each functional unit of the ZSDD construction device 10 may be acquired (downloaded) from a predetermined server device or the like via the communication I / F 204.

プロセッサ205は、例えば、CPU(Central Processing Unit)やGPU(Graphics Processing Unit)等の各種演算装置である。ZSDD構築装置10が有する各機能部は、例えば、メモリ装置206に格納されている1以上のプログラムがプロセッサ205に実行させる処理により実現される。 The processor 205 is, for example, various arithmetic units such as a CPU (Central Processing Unit) and a GPU (Graphics Processing Unit). Each functional unit included in the ZSDD construction device 10 is realized, for example, by a process in which one or more programs stored in the memory device 206 are executed by the processor 205.

メモリ装置206は、例えば、HDD(Hard Disk Drive)やSSD(Solid State Drive)、RAM(Random Access Memory)、ROM(Read Only Memory)、フラッシュメモリ等の各種記憶装置である。 The memory device 206 is, for example, various storage devices such as an HDD (Hard Disk Drive), an SSD (Solid State Drive), a RAM (Random Access Memory), a ROM (Read Only Memory), and a flash memory.

本実施形態に係るZSDD構築装置10は、図5に示すハードウェア構成を有することにより、後述する各種処理を実現することができる。なお、図5に示すハードウェア構成は一例であって、ZSDD構築装置10は、他のハードウェア構成を有していてもよい。例えば、ZSDD構築装置10は、複数のプロセッサ205を有していてもよいし、複数のメモリ装置206を有していてもよい。 The ZSDD construction device 10 according to the present embodiment can realize various processes described later by having the hardware configuration shown in FIG. The hardware configuration shown in FIG. 5 is an example, and the ZSDD construction device 10 may have another hardware configuration. For example, the ZSDD construction device 10 may have a plurality of processors 205 or a plurality of memory devices 206.

<処理の詳細>
次に、本実施形態に係るZSDD構築装置10によって次数制約を満たすエッジの集合の集合族を表すZSDDを構築する処理について、図6を参照しながら説明する。図6は、本実施形態に係るZSDD構築装置10が実行する処理の一例を示すフローチャートである。
<Details of processing>
Next, the process of constructing the ZSDD representing the family of sets of edges satisfying the order constraint by the ZSDD construction apparatus 10 according to the present embodiment will be described with reference to FIG. FIG. 6 is a flowchart showing an example of processing executed by the ZSDD construction device 10 according to the present embodiment.

入力部101は、グラフG=(V,E)と次数制約δ*(v)とを入力として受け付ける(ステップS101)。 The input unit 101 accepts the graph G = (V, E) and the order constraint δ * (v) as inputs (step S101).

次に、vtree獲得部102は、上記のステップS101で入力されたグラフGのvtreeを獲得する(ステップS102)。なお、上述したように、vtree獲得部102は、通信ネットワークを介して接続される他の装置又はシステムからvtreeを入力してもよいし、記録媒体203a等からvtreeを入力してもよい、グラフGからvteeを計算してもよい。グラフGからvtreeを計算する場合、例えば、上記の特許文献1に記載されている方法によりグラフGからvtreeを計算(構築)すればよい。 Next, the vtree acquisition unit 102 acquires the vtree of the graph G input in step S101 above (step S102). As described above, the vtree acquisition unit 102 may input the vtree from another device or system connected via the communication network, or may input the vtree from the recording medium 203a or the like. You may calculate vtee from G. When calculating vtree from graph G, for example, vtree may be calculated (constructed) from graph G by the method described in Patent Document 1 above.

次に、ZSDD構築部103は、上記のステップS101で入力されたグラフG及び次数制約δ*(v)と、上記のステップS102で獲得されたvtreeとを用いて、次数制約を満たすエッジの集合の集合族を表すZSDD Zを構築する(ステップS103)。なお、本ステップ(ZSDD構築処理)の詳細については後述する。 Next, the ZSDD construction unit 103 uses the graph G and the order constraint δ * (v) input in step S101 above and the vtree acquired in step S102 above to set the edges satisfying the order constraint. ZSDD Z representing the family of sets of is constructed (step S103). The details of this step (ZSDD construction process) will be described later.

そして、出力部104は、上記のステップS103で構築されたZSDD Zを出力する(ステップS104)。 Then, the output unit 104 outputs the ZSDD Z constructed in the above step S103 (step S104).

≪ZSDD構築処理≫
次に、上記のステップS103のZSDD構築処理の詳細について、図7を参照しながら説明する。図7は、本実施形態に係るZSDD構築処理の一例を示すフローチャートである。なお、ZSDD構築処理は、上記のステップS102において、グラフGとvtreeの根ノードvと次数制約δ*(v)とを引数とする所定の関数が呼び出されることで実行が開始される。
≪ZSDD construction process≫
Next, the details of the ZSDD construction process in step S103 will be described with reference to FIG. 7. FIG. 7 is a flowchart showing an example of the ZSDD construction process according to the present embodiment. The execution of the ZSDD construction process is started by calling a predetermined function having the root node v of the graph G and the voltre and the order constraint δ * (v) as arguments in step S102.

ZSDD構築部103は、グラフGとvtreeの根ノードvと次数制約δ*(v)とを入力として受け付ける(ステップS201)。 The ZSDD construction unit 103 accepts the root node v of the graph G and the voltre and the order constraint δ * (v) as inputs (step S201).

次に、ZSDD構築部103は、配列Z[v]にrootState()の出力値を格納する(ステップS202)。ここで、Z[v]は、vtreeのノードvに対応する決定ZSDDノードとそのラベルとの組を格納する配列である。ラベルとは等価な決定ZSDDノードが存在しないかどうかを検査するための識別情報である。構築するZSDDの種類に応じてラベルは異なるが、次数制約を満たすエッジの集合の集合族を表すZSDDの場合は、ラベルとして|V|次元の整数値を格納した配列を用いる(つまり、ラベルは、|V|次元のベクトルで表される。)。この配列をδ()と表し、vtreeのノードuに対応する整数値(つまり、配列δ()の要素のうち、ノードuに対応する要素)をδ(u)で表す。また、rootState()は、ZSDDの根となる決定ZSDDノードのラベルとしてδ*を設定した上で、この決定ZSDDノードとラベルδ*との組を返す関数である。なお、δ*は、全てのu∈Vの次数制約δ*(u)を要素とする|V|次元の配列(ベクトル)又は当該配列と等価な関数である。また、ZSDDの根となる決定ZSDDノードは、例えば、上記の特許文献1に記載されているgetRoot()等と同様の処理により決定すればよい。ZSDDの根となる決定ZSDDノードは、vtreeの根ノードに対応するノードとなる。 Next, the ZSDD construction unit 103 stores the output value of rootState () in the array Z [v] (step S202). Here, Z [v] is an array that stores a set of the determination ZZDD node corresponding to the node v of the volt and its label. The label is identification information for checking whether or not an equivalent decision ZSDD node exists. The label differs depending on the type of ZSDD to be constructed, but in the case of ZSDD representing a family of sets of edges that satisfy the order constraint, an array containing an integer value of | V | dimension is used as the label (that is, the label is). , | V | Represented by a dimensional vector.) This array is represented by δ (), and the integer value corresponding to the node u of vtree (that is, the element corresponding to the node u among the elements of the array δ ()) is represented by δ (u). Further, rootState () is a function that returns a pair of the determination ZSDD node and the label δ * after setting δ * as the label of the determination ZSDD node that is the root of ZSDD. Note that δ * is an | V | dimensional array (vector) having all u ∈ V degree constraints δ * (u) as elements, or a function equivalent to the array. Further, the determination ZSDD node that is the root of ZSDD may be determined by, for example, the same process as getRoot () described in Patent Document 1 described above. The decision ZSDD that is the root of ZSDD is the node that corresponds to the root node of vtree.

次に、ZSDD構築部103は、construct(v, Z)を呼ぶ(ステップS203)。construct(v, Z)は、vtreeのノードv以下のノードに対応する決定ZSDDノードを根ノードとするZSDDを再帰的に構築する関数である。なお、construct(v, Z)の詳細については後述する。 Next, the ZSDD construction unit 103 calls construct (v, Z) (step S203). construct (v, Z) is a function that recursively constructs a ZSDD having a decision ZSDD node as a root node corresponding to a node v or less of the node v of vtree. The details of construct (v, Z) will be described later.

次に、ZSDD構築部103は、Zをreduce(Z)に更新する(ステップS204)。reduce(Z)は、Zを構成するZSDD決定ノードのうち冗長なものを削除して、ZSDDの大きさを削減する関数である。reduce(Z)の詳細については、例えば、上記の特許文献1を参照されたい。 Next, the ZSDD construction unit 103 updates Z to reduce (Z) (step S204). reduce (Z) is a function that reduces the size of ZSDD by deleting redundant ZZDD determination nodes that make up Z. For details of reduce (Z), refer to, for example, Patent Document 1 above.

そして、ZSDD構築部103は、ZSDD Zを呼び出し元に出力する(ステップS205)。 Then, the ZSDD construction unit 103 outputs the ZSDD Z to the caller (step S205).

≪construct(v, Z)≫
次に、construct(v, Z)が呼び出された場合の処理の詳細について、図8を参照しながら説明する。図8は、本実施形態に係るconstruct(v, Z)の処理の一例を示すフローチャートである。
≪construct (v, Z) ≫
Next, the details of the processing when construct (v, Z) is called will be described with reference to FIG. FIG. 8 is a flowchart showing an example of the process of construct (v, Z) according to the present embodiment.

ZSDD構築部103は、Z[v]に格納されている各決定ZSDDノードzの各々に対して、ステップS311〜ステップS314の処理を繰り返し実行する(ステップS301)。ステップS311では、ZSDD構築部103は、配列elemsをφに初期化する。ステップS312では、ZSDD構築部103は、decomp(v, z)の実行結果として得られたラベルの組(m,m)の各々に対して、ステップS321〜ステップS322の処理を繰り返し実行する。ここで、decomp(v, z)は、決定ZSDDノードzのラベルm(z)に基づいて、その子ノードとなるプライム及びサブそれぞれのラベルの組(m,m)のリストを返す関数である。なお、decomp(v, z)の詳細については後述する。 The ZSDD construction unit 103 repeatedly executes the processes of steps S311 to S314 for each of the determined ZSDD nodes z stored in Z [v] (step S301). In step S311 the ZSDD construction unit 103 initializes the array elems to φ. In step S312, the ZSDD construction unit 103 repeatedly executes the processes of steps S321 to S322 for each of the label sets (m k , m r ) obtained as the execution result of decomp (v, z). .. Here, decomp (v, z) is a function that returns a list of label sets (m k , m r ) of each of the prime and sub labels that are child nodes based on the label m (z) of the determined ZSDD node z. be. The details of decomp (v, z) will be described later.

ステップS321では、ZSDD構築部103は、m及びmのそれぞれを用いて、ステップS331〜ステップS333の処理を実行する。すなわち、ZSDD構築部103は、mを用いてステップS331〜ステップS333の処理を実行すると共に、mを用いてステップS331〜ステップS333の処理を実行する。以降では、k又はrのいずれか一方を〇で表し、mはm又はmのいずれか一方を表すものとする。 In step S321, ZSDD construction unit 103 uses each of m k and m r, performs the process of step S331~ step S333. That, ZSDD construction unit 103, and executes the processing of step S331~ step S333 by using the m k, executes the processing of step S331~ step S333 using the m r. In the following, one of k or r expressed in 〇, m denote the one of the m k or m r.

ステップS331では、ZSDD構築部103は、vtreeのノードvのうち、mに対応するノードvを選択し、選択したvがvtreeの葉ノードであるか否かを判定する。mに対応するノードvは、mがmである場合はvであり、mがmである場合はvである。 In step S331, ZSDD construction unit 103 of the node v of Vtree, select the node v corresponding to m 〇, is v selected determines whether a leaf node of Vtree. node v corresponding to m 〇, if m is m k is v k, if m is m r a v r.

上記のステップS331でvがvtreeの葉ノードであると判定された場合(ステップS331でYES)、ZSDD構築部103は、terminal(v, m)の実行結果として得られたノード(終端ZSDD)をzに代入する(ステップS332)。zは、mがmである場合はzであり、mがmである場合はzである。また、terminal(v, m)は、ノードvがvtreeの葉ノードであった場合に、ラベルmに対応する終端ZSDDを求める関数である。なお、terminal(v, m)の詳細については後述する。 When it is determined in step S331 above that v is a leaf node of vtree (YES in step S331), the ZSDD construction unit 103 is the node (termination) obtained as the execution result of terminal (v 〇 , m 〇). ZSDD) is substituted for z 〇 (step S332). z 〇, if m is a m k is z k, if m is a m r a z r. Further, terminal (v , m ) is a function for obtaining the terminal ZSDD corresponding to the label m 〇 when the node v is a leaf node of voltre. The details of terminal (v , m ) will be described later.

一方で、上記のステップS331でvがvtreeの葉ノードでないと判定された場合(ステップS331でNO)、ZSDD構築部103は、unique(v, m)の実行結果として得られたノードをzに代入する(ステップS333)。unique(v, m)は、ノードvに対応する決定ZSDDノードでラベルmを持つものがすでにZ[v]中に存在するか否かを判定し、存在する場合はその決定ZSDDノードを出力し、存在しない場合は新たにラベルmを持つ決定ZSDDノードを作成してZ[v]に格納した上でその決定ZSDDノードを出力する関数である。 On the other hand, when it is determined in step S331 above that v 〇 is not a leaf node of volt (NO in step S331), the ZSDD construction unit 103 is the node obtained as the execution result of unique (v 〇 , m 〇). Is assigned to z (step S333). unique (v 〇, m 〇), the decision case where those with a label m Among decision ZSDD node corresponding to the node v already determined whether present in Z [v 〇], there It is a function that outputs a ZSDD node, creates a new decision ZSDD node with a label m 〇 if it does not exist , stores it in Z [v 〇 ], and then outputs the decision ZSDD node.

ステップS322では、ZSDD構築部103は、上記のステップS321の繰り返しで得られたz及びzのペアをelemsに追加する。 In step S322, the ZSDD construction unit 103 adds the z k and z r pairs obtained by repeating step S321 above to elems.

ステップS313では、ZSDD構築部103は、上記のステップS312の繰り返しで得られたelemsを、決定ZSDDノードzの子ノードとして設定する。 In step S313, the ZSDD construction unit 103 sets the elems obtained by repeating the above step S312 as a child node of the determination ZSDD node z.

ステップS314では、ZSDD構築部103は、v及びvのそれぞれを用いて、ステップS341〜ステップS342の処理を実行する。すなわち、ZSDD構築部103は、vを用いてステップS341〜ステップS342の処理を実行すると共に、vを用いてステップS341〜ステップS342の処理を実行する。なお、以降では、上記と同様に、vはv又はvのいずれか一方を表すものとする。 In step S314, the ZSDD construction unit 103 executes the processes of steps S341 to S342 by using each of v k and v r. That is, the ZSDD construction unit 103 executes the processes of steps S341 to S342 using v k , and executes the processes of steps S341 to S342 using v r. In the following, as in the above, v represents either v k or v r.

ステップS341では、ZSDD構築部103は、vがvtreeの中間ノード(つまり、葉ノード以外のノード)であるか否かを判定する。そして、ステップS341でvがvtreeの中間ノードである判定された場合(ステップS341でYES)、ZSDD構築部103は、再帰的にconstruct(v, Z)を呼ぶ(ステップS342)。これにより、再帰的にZSDDが構築される。 In step S341, the ZSDD construction unit 103 determines whether or not v 〇 is an intermediate node of the volt (that is, a node other than the leaf node). Then, when it is determined in step S341 that v is an intermediate node of volt (YES in step S341), the ZSDD construction unit 103 recursively calls construct (v 〇 , Z) (step S342). As a result, ZSDD is recursively constructed.

≪terminal(v, m)≫
次に、terminal(v, m)が呼び出された場合の処理の詳細について、図9を参照しながら説明する。図9は、本実施形態に係るterminal(v, m)の処理の一例を示すフローチャートである。
≪terminal (v, m) ≫
Next, the details of the processing when terminal (v, m) is called will be described with reference to FIG. FIG. 9 is a flowchart showing an example of the processing of the terminal (v, m) according to the present embodiment.

ZSDD構築部103は、配列δ()に対してmを設定する(ステップS401)。すなわち、ZSDD構築部103は、配列δ()の各要素に対して、ラベルmの各要素をそれぞれ設定する。なお、δ()は配列であるが、vtreeの各ノードに対して整数値を返す関数とみなすことができる(つまり、この場合、当該配列と当該関数とは等価である。)。 The ZSDD construction unit 103 sets m for the array δ () (step S401). That is, the ZSDD construction unit 103 sets each element of the label m for each element of the array δ (). Although δ () is an array, it can be regarded as a function that returns an integer value for each node of vtree (that is, in this case, the array and the function are equivalent).

次に、ZSDD構築部103は、δ(u)=δ(u)=0であるか否かを判定する(ステップS402)。ここで、u及びuは、vtreeのノードvに対応するエッジeの両端点のノードである。 Next, the ZSDD construction unit 103 determines whether or not δ (u 1 ) = δ (u 2 ) = 0 (step S402). Here, u 1 and u 2 are nodes at both ends of the edge e corresponding to the node v of the voltre.

上記のステップS402でδ(u)=δ(u)=0であると判定された場合(ステップS402でYES)、ZSDD構築部103は、終端ZSDDとしてεを呼び出し元に出力する(ステップS403)。 When it is determined in step S402 above that δ (u 1 ) = δ (u 2 ) = 0 (YES in step S402), the ZSDD construction unit 103 outputs ε as the terminal ZSDD to the caller (step). S403).

一方で、上記のステップS402でδ(u)=δ(u)=0でないと判定された場合(ステップS302でNO)、ZSDD構築部103は、δ(u)=δ(u)=1であるか否かを判定する(ステップS404)。 On the other hand, when it is determined in step S402 above that δ (u 1 ) = δ (u 2 ) = 0 (NO in step S302), the ZSDD construction unit 103 has δ (u 1 ) = δ (u 2). ) = 1 (step S404).

上記のステップS404でδ(u)=δ(u)=1であると判定された場合、ZSDD構築部103は、終端ZSDDとしてL(v)を呼び出し元に出力する(ステップS405)。L(v)は、vtreeノードvに対応するエッジeを表す。 When it is determined in step S404 above that δ (u 1 ) = δ (u 2 ) = 1, the ZSDD construction unit 103 outputs L (v) as the terminal ZSDD to the caller (step S405). L (v) represents the edge e corresponding to the volt node v.

一方で、上記のステップS404でδ(u)=δ(u)=1であると判定されなかった場合、ZSDD構築部103は、終端ZSDDとして⊥を呼び出し元に出力する(ステップS406)。 On the other hand, if it is not determined in step S404 above that δ (u 1 ) = δ (u 2 ) = 1, the ZSDD construction unit 103 outputs ⊥ as the terminal ZSDD to the caller (step S406). ..

≪decomp(v, z)≫
次に、decomp(v, z)が呼び出された場合の処理の詳細について、図10を参照しながら説明する。図10は、本実施形態に係るdecomp(v, z)の処理の一例を示すフローチャートである。
≪decomp (v, z) ≫
Next, the details of the processing when decomp (v, z) is called will be described with reference to FIG. FIG. 10 is a flowchart showing an example of the decomp (v, z) process according to the present embodiment.

ZSDD構築部103は、配列labelPairsをφに初期化する(ステップS501)。次に、ZSDD構築部103は、配列δ()に対してm(z)を設定する(ステップS502)。なお、上述したように、m(z)は、決定ZSDDノードzのラベルである。 The ZSDD construction unit 103 initializes the array labelPairs to φ (step S501). Next, the ZSDD construction unit 103 sets m (z) for the array δ () (step S502). As described above, m (z) is the label of the determined ZSDD node z.

次に、ZSDD構築部103は、enumBoundedArray(δ, v)の実行結果として得られたδの各々に対して、ステップS511〜ステップS512の処理を繰り返し実行する(ステップS503)。enumBoundedArray(δ, v)は、ラベルδを持つ決定ZSDDノードの子ノードのうち、vtreeのノードv(つまり、ノードvの左側の子ノード)に対応するノードが取りうるラベルδを全て列挙する関数である。具体的には、u∈V(v)∩(v)であるようなuに対しては0≦δ(u)≦δ(u)とし、 Next, ZSDD construction unit 103, enumBoundedArray (δ, v) for each of the [delta] k obtained as the execution result of repeats steps S511~ step S512 (step S503). The enumBoundedArray (δ, v) enumerates all the labels δ k that can be taken by the node corresponding to the node v k of vtree (that is, the child node on the left side of the node v) among the child nodes of the determined ZSDD node having the label δ. It is a function to do. Specifically, the u∈V (v k) ∩ For u as a (v r) 0 ≦ δ k (u) ≦ δ (u),

Figure 2021174061
であるようなuに対してはδ(u)=δ(u)とし、
Figure 2021174061
For u such as, δ k (u) = δ (u).

Figure 2021174061
であるようなuに対してはδ(u)=0として、δ(u)を要素とするラベルδを順に列挙する。ここで、V(v)は、vを根ノードとする部分vtree(つまり、vtreeの部分木)の葉ノードに対応するエッジの端点となる全てのノードの集合を表す。
Figure 2021174061
For u such as, δ k (u) = 0, and the labels δ k having δ k (u) as an element are listed in order. Here, V (v) represents a set of all nodes that are the end points of the edges corresponding to the leaf nodes of the partial vtree (that is, the subtree of vtree) having v as the root node.

ステップS511では、ZSDD構築部103は、calcSubArray(δ, δ, v)の実行結果をδとする。calcSubArray(δ, δ, v)は、各u∈Vに対してδ(u)=δ(u)−δ(u)を計算する関数である。したがって、δは、calcSubArray(δ, δ, v)の実行結果として得られた各δ(u)の要素とするベクトルである。 In step S511, the ZSDD construction unit 103 sets the execution result of calcSubArray (δ, δ k , v) to δ r . calcSubArray (δ, δ k , v) is a function that calculates δ r (u) = δ (u) −δ k (u) for each u ∈ V. Therefore, δ r is a vector that is an element of each δ r (u) obtained as a result of executing calcSubArray (δ, δ k, v).

ステップS512では、ZSDD構築部103は、ラベルの組(δ,δ)をlabelPairsに追加する。 In step S512, the ZSDD construction unit 103 adds a set of labels (δ k , δ r ) to label Pairs.

そして、ステップS504では、ZSDD構築部103は、labelPairsを呼び出し元に出力する。これにより、ラベルの組のリストが呼び出し元に出力される
<まとめ>
以上のように、本実施形態に係るZSDD構築装置10は、次数制約を満たすエッジの集合の集合族を表現するZSDDを効率的に構築することができる。したがって、本実施形態に係るZSDD構築装置10を用いることで、集合族演算のための索引として用いることができるZSDDを効率的に得ることができるため、ZSDD構築に関するボトルネックが解消される。また、本実施形態に係るZSDD構築装置10は、次数制約を満たすエッジの集合の集合族を表現するZSDDを構築することができるため、ZSDDを用いた処理の適用範囲の拡大に寄与することができる。
Then, in step S504, the ZSDD construction unit 103 outputs labelPairs to the caller. As a result, a list of label sets is output to the caller. <Summary>
As described above, the ZSDD construction device 10 according to the present embodiment can efficiently construct a ZSDD that represents a family of sets of edges that satisfy the order constraint. Therefore, by using the ZSDD construction device 10 according to the present embodiment, the ZSDD that can be used as an index for the family of sets operation can be efficiently obtained, and the bottleneck related to the ZSDD construction is eliminated. Further, since the ZSDD construction device 10 according to the present embodiment can construct a ZSDD representing a family of sets of edges satisfying the order constraint, it can contribute to the expansion of the applicable range of the processing using the ZSDD. can.

本発明は、具体的に開示された上記の実施形態に限定されるものではなく、特許請求の範囲から逸脱することなく、種々の変形や変更、既知の技術との組み合わせ等が可能である。 The present invention is not limited to the above-described embodiment disclosed in detail, and various modifications and modifications, combinations with known techniques, and the like are possible without departing from the scope of claims.

10 ZSDD構築装置
101 入力部
102 vtree獲得部
103 ZSDD構築部
104 出力部
201 入力装置
202 表示装置
203 外部I/F
203a 記録媒体
204 通信I/F
205 プロセッサ
206 メモリ装置
207 バス
10 ZSDD construction unit 101 Input unit 102 vtree acquisition unit 103 ZSDD construction unit 104 Output unit 201 Input device 202 Display device 203 External I / F
203a Recording medium 204 Communication I / F
205 Processor 206 Memory Device 207 Bus

Claims (6)

ノードの集合Vとエッジの集合Eとで構成されるグラフGと、前記ノードを端点とするエッジ数に関する制約を表す次数制約とを入力する入力部と、
前記グラフGと前記次数制約と前記グラフGに対応するvtreeとに基づいて、前記集合Eの部分集合であって、かつ、前記次数制約を満たすエッジの部分集合で構成される集合族を表すZSDDを構築する構築部と、
を有することを特徴とするZSDD構築装置。
An input unit for inputting a graph G composed of a set V of nodes and a set E of edges, and a degree constraint representing a constraint on the number of edges with the node as an end point.
Based on the graph G, the order constraint, and the vtree corresponding to the graph G, ZSDD represents a family of sets that is a subset of the set E and is composed of a subset of edges that satisfy the order constraint. With the construction department to build
ZSDD construction device characterized by having.
前記構築部は、
前記ZSDDの根ノードとして、前記vtreeの根ノードに対応するノードを設定すると共に、前記ZSDDの根ノードに対して、前記グラフの各ノードの次数制約を要素とするベクトルをラベルとして設定し、
前記ZSDDの根ノードを決定ノードと設定した上で、前記vtreeのノードを表すvtreeのうち、前記決定ノードに対応するvtreeノードの子ノードが葉ノードとなるまで、前記決定ノードに対して前記ZSDDの子ノードを設定すると共に前記ZSDDの子ノードを決定ノードとすることを繰り返すことで、前記ZSDDを構築する、ことを特徴とする請求項1に記載のZSDD構築装置。
The construction unit
As the root node of the ZSDD, a node corresponding to the root node of the vtree is set, and for the root node of the ZSDD, a vector having the degree constraint of each node of the graph as an element is set as a label.
After setting the root node of the ZSDD as a decision node, the ZSDD with respect to the decision node until the child node of the vtree node corresponding to the decision node among the vtrees representing the node of the vtree becomes a leaf node. The ZSDD construction device according to claim 1, wherein the ZSDD is constructed by repeatedly setting the child node of the ZSDD and setting the child node of the ZSDD as a determination node.
前記ZSDDの子ノードには、前記決定ノードの左側の子ノードを表すプライムと、前記決定ノードの右側の子ノードを表すサブとが含まれ、
前記構築部は、
前記プライムが取りうるラベルと前記サブが取りうるラベルとの組のリストを用いて、前記決定ノードに対して設定される、前記ZSDDの子ノードを生成する、ことを特徴とする請求項2に記載のZSDD構築装置。
The child node of the ZSDD includes a prime representing a child node on the left side of the decision node and a sub representing a child node on the right side of the decision node.
The construction unit
2. The second aspect of the present invention is to generate a child node of the ZSDD set for the determination node by using a list of a set of a label that can be taken by the prime and a label that can be taken by the sub. The ZSDD construction device described.
前記構築部は、
前記決定ノードに対応するvtreeノードの子ノードが葉ノードとなった場合は、前記葉ノードと前記プライム又は前記サブが取りうるラベルとを用いて、前記ZSDDの終端ノートを、前記ZSDDの子ノードとして設定し、
前記決定ノードに対応するvtreeノードの子ノードが葉ノードでない場合は、前記vtreeノードの子ノードと前記プライム又は前記サブが取りうるラベルとを用いて、前記vtreeノードの子ノードに対応する決定ノードであって、かつ、前記プライム又は前記サブが取りうるラベルを持つ決定ノードを、前記ZSDDの子ノードとして設定する、ことを特徴とする請求項3に記載のZSDD構築装置。
The construction unit
When the child node of the vtree node corresponding to the decision node becomes a leaf node, the terminal note of the ZSDD is set as the child node of the ZSDD by using the leaf node and the label that the prime or the sub can take. Set as
If the child node of the vtree node corresponding to the decision node is not a leaf node, the decision node corresponding to the child node of the vtree node is used by using the child node of the vtree node and the label that the prime or sub can take. The ZSDD construction device according to claim 3, wherein a determination node having a label that can be taken by the prime or the sub is set as a child node of the ZSDD.
ノードの集合Vとエッジの集合Eとで構成されるグラフGと、前記ノードを端点とするエッジ数に関する制約を表す次数制約とを入力する入力手順と、
前記グラフGと前記次数制約と前記グラフGに対応するvtreeとに基づいて、前記集合Eの部分集合であって、かつ、前記次数制約を満たすエッジの部分集合で構成される集合族を表すZSDDを構築する構築手順と、
をコンピュータが実行することを特徴とするZSDD構築方法。
An input procedure for inputting a graph G composed of a set V of nodes and a set E of edges, and a degree constraint representing a constraint on the number of edges with the node as an end point.
Based on the graph G, the degree constraint, and the vtree corresponding to the graph G, ZSDD represents a family of sets that is a subset of the set E and is composed of a subset of edges that satisfy the order constraint. And the construction procedure to build
ZSDD construction method, characterized in that a computer executes.
コンピュータを、請求項1乃至4の何れか一項に記載のZSDD構築装置として機能させるためのプログラム。 A program for causing a computer to function as the ZSDD construction device according to any one of claims 1 to 4.
JP2020074831A 2020-04-20 2020-04-20 ZSDD construction device, ZSDD construction method and program Active JP7377493B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2020074831A JP7377493B2 (en) 2020-04-20 2020-04-20 ZSDD construction device, ZSDD construction method and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2020074831A JP7377493B2 (en) 2020-04-20 2020-04-20 ZSDD construction device, ZSDD construction method and program

Publications (2)

Publication Number Publication Date
JP2021174061A true JP2021174061A (en) 2021-11-01
JP7377493B2 JP7377493B2 (en) 2023-11-10

Family

ID=78281798

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2020074831A Active JP7377493B2 (en) 2020-04-20 2020-04-20 ZSDD construction device, ZSDD construction method and program

Country Status (1)

Country Link
JP (1) JP7377493B2 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017111622A (en) * 2015-12-16 2017-06-22 日本電信電話株式会社 Calculation executing device, method, and program
JP2018041161A (en) * 2016-09-05 2018-03-15 日本電信電話株式会社 Zsdd construction device, method, and program

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017111622A (en) * 2015-12-16 2017-06-22 日本電信電話株式会社 Calculation executing device, method, and program
JP2018041161A (en) * 2016-09-05 2018-03-15 日本電信電話株式会社 Zsdd construction device, method, and program

Also Published As

Publication number Publication date
JP7377493B2 (en) 2023-11-10

Similar Documents

Publication Publication Date Title
Minkin et al. TwoPaCo: an efficient algorithm to build the compacted de Bruijn graph from many complete genomes
Rautiainen et al. Bit-parallel sequence-to-graph alignment
Huson et al. Application of phylogenetic networks in evolutionary studies
Simpson et al. Efficient construction of an assembly string graph using the FM-index
Higham et al. Fitting a geometric graph to a protein–protein interaction network
Stenz et al. Exploring tree-like and non-tree-like patterns using genome sequences: an example using the inbreeding plant species Arabidopsis thaliana (L.) Heynh
Kamal et al. De-Bruijn graph with MapReduce framework towards metagenomic data classification
Kim et al. Network motif detection: Algorithms, parallel and cloud computing, and related tools
Cherry A practical exact maximum compatibility algorithm for reconstruction of recent evolutionary history
Iverson et al. Evaluation of connected-component labeling algorithms for distributed-memory systems
Molloy et al. TreeMerge: a new method for improving the scalability of species tree estimation methods
Fountoulakis On a geometrization of the Chung–Lu model for complex networks
Hendricks et al. High-speed detection of emergent market clustering via an unsupervised parallel genetic algorithm
Djukanovic et al. An A⁎ search algorithm for the constrained longest common subsequence problem
Jacox et al. Resolution and reconciliation of non-binary gene trees with transfers, duplications and losses
CN111274455A (en) Graph data processing method and device, electronic equipment and computer readable medium
KR102227912B1 (en) Optimized data condenser and method
JP7377493B2 (en) ZSDD construction device, ZSDD construction method and program
EP3196780A1 (en) Information processing device, information processing method, and computer-readable storage medium
Büchler et al. An improved encoding of genetic variation in a Burrows–Wheeler transform
Barrett et al. Self-similarity of Communities of the ABCD Model
Van Iersel et al. Binets: fundamental building blocks for phylogenetic networks
JPWO2011016281A1 (en) Information processing apparatus and program for Bayesian network structure learning
Ashraf et al. RPPMD (Randomly projected possible motif discovery): An efficient bucketing method for finding DNA planted Motif
Molloy et al. FastMulRFS: Statistically consistent polynomial time species tree estimation under gene duplication

Legal Events

Date Code Title Description
RD01 Notification of change of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7426

Effective date: 20200423

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A821

Effective date: 20200423

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20220802

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20230718

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20230719

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20230915

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20231010

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20231020

R150 Certificate of patent or registration of utility model

Ref document number: 7377493

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150