Tableau

scalation.database.Tableau
class Tableau(r: Attrs, p: ArrayBuffer[Attrs])

The Tableau class support the creation is tableaux, i.e., abstract tables containing rows of symbols (distinguished and non-distinguished).

Value parameters

p

the set of sub-schemas defining the tables

r

the complete set of attributes

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def allDistinguished(): Boolean

Determine whether the final tableau contains a row of all distinguished symbols. Distinguished symbols "a" to "z". Non-distinguished symbols "a1" to "z25" where e.g. 25 is the number of rows in the tableau.

Determine whether the final tableau contains a row of all distinguished symbols. Distinguished symbols "a" to "z". Non-distinguished symbols "a1" to "z25" where e.g. 25 is the number of rows in the tableau.

Attributes

def equateRHS(y: Attrs, i: Int, j: Int): Boolean

Equate RHS symbols for attributes/columns in the tableau for rows i and j.

Equate RHS symbols for attributes/columns in the tableau for rows i and j.

Value parameters

i

index of i-th row

j

index of j-th row

y

the attributes to equate (make the same)

Attributes

def equateSymbols(f: FD): Boolean

For Functional Dependency (FD) f, try to equate symbols in the tableau by comparing each row with every other row. When two rows agree on their LHSs, make their RHSs the same. Return whether any symbols were changed.

For Functional Dependency (FD) f, try to equate symbols in the tableau by comparing each row with every other row. When two rows agree on their LHSs, make their RHSs the same. Return whether any symbols were changed.

Value parameters

f

the FD to use to try to equate symbols

Attributes

def genTuples(f: FD): Boolean

For Multi-Valued Dependency (MVD) f, try to generate and add new rows into the tableau by comparing each row with every other row. When two rows agree on their LHSs, make their RHSs the same. Return whether any symbols were changed.

For Multi-Valued Dependency (MVD) f, try to generate and add new rows into the tableau by comparing each row with every other row. When two rows agree on their LHSs, make their RHSs the same. Return whether any symbols were changed.

Value parameters

f

the MVD to use to try to equate symbols

Attributes

def makeRow(ri: Attrs, i: Int): Symbols

Make a row for Tableau tabl, the abstract table of strings, where for row i, element j is a distinguished (e.g., b) symbols when character j is in sub-relation p_i, and is otherwise a non-distinguished symbol (e.g., b3).

Make a row for Tableau tabl, the abstract table of strings, where for row i, element j is a distinguished (e.g., b) symbols when character j is in sub-relation p_i, and is otherwise a non-distinguished symbol (e.g., b3).

Value parameters

i

the i-th row

ri

the cuurent sub-schema

Attributes

def makeRow(x: Attrs, y: Attrs, i: Int, j: Int): Symbols

Make a new row for Tableau tabl by crossing row i with row j as follows: Given MVD x ->> y and two rows (x, y1, z1) and (x, y2, z2) add a new row (x, y2, z1).

Make a new row for Tableau tabl by crossing row i with row j as follows: Given MVD x ->> y and two rows (x, y1, z1) and (x, y2, z2) add a new row (x, y2, z1).

Value parameters

h

the second row

i

the first row

x

the LHS attributes of the MVD

y

the RHS attributes of the MVD

Attributes

def onto(x: Attrs, row: Symbols): Symbols

Project the given row in the tableau onto attributes x".

Project the given row in the tableau onto attributes x".

Value parameters

row

the given row in the tableau

x

the given attributes

Attributes

def printTableau(): Unit

Print the tableau.

Print the tableau.

Attributes