a formal context for closures of acyclic hypergraphs ...icfca2019/... · two views of rdbm...

Post on 30-Apr-2020

2 Views

Category:

Documents

0 Downloads

Preview:

Click to see full reader

TRANSCRIPT

A Formal Context for Closures of AcyclicHypergraphs

ICFCA’19

Jaume Baixeries

Departament de Ciencies de la Computacio.Universitat Politecnica de Catalunya.

26/06/2019

Layout

1 Two complementary views on RDBM dependencies.

2 Acyclic Hypergraphs (AHG).

3 Main Result: AHG’s and FCA.

Two Views of RDBM Dependencies

Dependencies are constraints that (must) apply on databases(ex: functional dependencies).

We can see dependencies from two different points of view:

Semantics and Syntax

Two Views of RDBM Dependencies: Semantics

Semantics explains a dependency w.r.t. a dataset:

Example

A functional dependency X → Y holds if and only if:

∀ti , tj : ti [X ] = tj [X ]⇒ ti [Y ] = tj [Y ]

Two Views of RDBM Dependencies: Semantics

According to its Semantics we have:

Implications.

Functional dependencies.

Multivalued dependencies.

Join dependencies.

Acyclic Join dependencies.

...

Two Views of RDBM Dependencies: Syntax

Syntax explains a dependency w.r.t. a set of dependencies (usuallyof the same kind).

Example: Transitivity

If two functional dependencies X → Y and Y → Z hold,then X → Z holds as well.

Two Views of RDBM Dependencies: Syntax

Syntax answers the following question:

Given a set of dependendencies Σ that hold in a dataset, whatother dependencies necessarily hold as well?

(regardless of the dataset)

This set is called Σ+.

Syntax induces a set of axioms for each kind of dependency.

Two Views of RDBM Dependencies: Syntax

According to its Syntax we have:

Armstrong dependencies.

Symmetric dependencies.

Join dependencies.

...

Two Views of RDBM Dependencies

Semantics Syntax

Horn Clauses / ImplicationsFunctional Dependencies Armstrong DependenciesSimilarity Dependencies

MVD ClausesDegenerated MVD Symmetric DependenciesMultivalued Dependencies

Acyclic Join Dependencies Acyclic Hypergraphs

Table: Table of references (non exhaustive) of FCA/lattice-basedcharacterization of database constraints.

Notation

What is an Acyclic Hypergraph?

Acyclic Hypergraphs

Let U be a set of attributes.

A Hypergraph is a set of subsets of U :

H = [A1,A2, . . . ,An ] Ai ⊆ U

All attributes in U need to be in one of those subsets.

Join Dependencies

With these conditions, we just have a Join Dependency.

Acyclic Hypergraphs

Let U be a set of attributes.

A Hypergraph is a set of subsets of U :

H = [A1,A2, . . . ,An ]

All attributes in U need to be in one of those subsets.

The hypergraphs is α-acyclic.

α-Acyclic Hypergraphs

With these conditions, we now have a Acyclic Hypergraph.

Acyclic Hypergraphs

Hypergraph

U = { a, b, c , d , e }

H = [ abc, bcd , cde, ae ]

α-Acyclic Hypergraph

U = { a, b, c , d , e }

H = [ abc, bcd , cde ]

Characterization of α-acyclicity

Every AHG has (at least) one join tree

bcd

abc

bc

cde

cd

Figure: Join tree for [ abc, bcd , cde ].

From the Semantical point of view

Reminder!!

This is the definition of a (Acyclic) Join Dependency.

[ ab, bc, cd ] holds in R because:

a b

1 2

3 4

×

b c

2 3

2 1

4 3

×

c d

3 5

1 2

1 5

=

R a b c d

t1 1 2 3 5

t2 1 2 1 2

t3 3 4 3 5

t4 1 2 1 5

Acyclic Hypergraphs

However, we said that we only focus on the syntax of AJD’s.

Acyclic Join Dependencies → Acyclic Hypergraphs

Join Dependencies → Hypergraphs

Acyclic Hypergraphs vs Symmetric Dependencies

A Symmetric Dependency (SD) is an AHG of size 2:

[ ab, bcd ] ≡ a⇒ b | cd

AHG’s and FCA

The closure of a set of Symmetric Dependencies has already beencharacterized in terms of FCA:

KSD = (SDU ,℘(U), I )

←− SOMETHING (with attributes) −→↑

DEPENDENCIES↓

Σ′′ = Σ+

Acyclic Hypergraphs

Symmetric Dependencies ⊂ Acyclic Hypergraphs ⊂ Hypergraphs

Acyclic Join Dependencies - Acyclic Hypergraphs

Join dependencies can’t be axiomatized.

Acyclic Join Dependencies can be axiomatized.

Acyclic Join Dependencies are equivalent to a set ofSymmetric dependencies.

Acyclic Join Dependencies - Acyclic Hypergraphs

Join dependencies can’t be axiomatized.

Acyclic Join Dependencies can be axiomatized.

Acyclic Join Dependencies are equivalent to a set ofSymmetric dependencies.

Symmetric Dependencies Axioms

(B1) Let [A,B] be a SD, X ⊆ U

[A,B]⇒ [A ∪ X ,B ∪ X ]

(B2) Let [A,E ] and [X ,Y ] be SD’s, such that Y = A ∩ E .

[A,E ], [X ,Y ]⇒ [A,E ∩ X ]

(Trivial axioms are ommited)

Acyclic Hypergraphs Axioms

(B1) Let [A,B] be an AHG, X ⊆ U

[A,B]⇒ [A ∪ X ,B ∪ X ]

(B2) Let [A,E ] and [X ,Y ] be AHG’s, such that Y = A ∩ E .

[A,E ], [X ,Y ]⇒ [A,E ∩ X ]

(A3) Let [E ,H1, . . . ,Hn] and [X ,Y ] be AHG such that X ∩ Y ⊆ Eand ∀Hi : Hi ∩ E ⊆ X Hi ∩ E ⊆ Y . LetH ′ = reduction([E ∩ X ,E ∩ Y ,H1, . . . ,Hn]).

[E ,H1, . . . ,Hn], [X ,Y ]⇒ [H ′]

(Trivial axioms are ommited)

AHG’s and FCA: Main Result

Key idea: An AHG is equivalent to a set of SD’s.

Therefore: we need to test all SD’s in the previously definedformal context.

AHG’s and FCA: Main Result

The main result in this paper is the corollary of two results:

1 The characterization of SD’s with a formal context.

2 The fact that an AHG is equivalent to a set of SD’s.

AHG’s and FCA: Main Result

Let ΣAHG be a set of AHG.

ΣAHG ⇒ ΣSD ⇒ Σ+SD ⇒ Σ+

AHGeq. SD-AHG (SDU ,℘(U), I ) eq. SD-AHG

Th. 1 & 2 Papers [*]Cor. 1 & Prop. 2

Papers [*]:

1 J. Baixeries. A Formal Context for Symmetric Dependencies,pages 90–105. Springer Berlin Heidelberg, Berlin, Heidelberg,2008.

2 J. Baixeries. A New Formal Context for SymmetricDependencies. Concept Lattices and Applications 2011.

Future Work

1 Can we (still) simplify this formal context?

2 Can we have a native formal context in terms of AHG?

3 FCA still has a long way to go...

Thanks

Vielen Dank!

Questions??

top related