<s>
In	O
relational	B-Application
database	I-Application
theory	O
,	O
a	O
functional	B-Application
dependency	I-Application
is	O
a	O
constraint	O
between	O
two	O
sets	O
of	O
attributes	O
in	O
a	O
relation	B-Language
from	O
a	O
database	O
.	O
</s>
<s>
In	O
other	O
words	O
,	O
a	O
functional	B-Application
dependency	I-Application
is	O
a	O
constraint	O
between	O
two	O
attributes	O
in	O
a	O
relation	B-Language
.	O
</s>
<s>
Given	O
a	O
relation	B-Language
R	O
and	O
sets	O
of	O
attributes	O
,	O
X	O
is	O
said	O
to	O
functionally	O
determine	O
Y	O
(	O
written	O
X	O
→	O
Y	O
)	O
if	O
and	O
only	O
if	O
each	O
X	O
value	O
in	O
R	O
is	O
associated	O
with	O
precisely	O
one	O
Y	O
value	O
in	O
R	O
;	O
R	O
is	O
then	O
said	O
to	O
satisfy	O
the	O
functional	B-Application
dependency	I-Application
X	O
→	O
Y	O
.	O
Equivalently	O
,	O
the	O
projection	B-Algorithm
is	O
a	O
function	O
,	O
i.e.	O
</s>
<s>
A	O
functional	B-Application
dependency	I-Application
FD	O
:	O
X	O
→	O
Y	O
is	O
called	O
trivial	O
if	O
Y	O
is	O
a	O
subset	O
of	O
X	O
.	O
</s>
<s>
The	O
determination	O
of	O
functional	B-Application
dependencies	I-Application
is	O
an	O
important	O
part	O
of	O
designing	O
databases	O
in	O
the	O
relational	B-Architecture
model	I-Architecture
,	O
and	O
in	O
database	B-Application
normalization	I-Application
and	O
denormalization	O
.	O
</s>
<s>
A	O
simple	O
application	O
of	O
functional	B-Application
dependencies	I-Application
is	O
Heath	O
's	O
theorem	O
;	O
it	O
says	O
that	O
a	O
relation	B-Language
R	O
over	O
an	O
attribute	O
set	O
U	O
and	O
satisfying	O
a	O
functional	B-Application
dependency	I-Application
X	O
→	O
Y	O
can	O
be	O
safely	O
split	O
in	O
two	O
relations	O
having	O
the	O
lossless-join	B-Algorithm
decomposition	I-Algorithm
property	O
,	O
namely	O
into	O
where	O
Z	O
=	O
U	O
−	O
XY	O
are	O
the	O
rest	O
of	O
the	O
attributes	O
.	O
</s>
<s>
An	O
important	O
notion	O
in	O
this	O
context	O
is	O
a	O
candidate	B-Application
key	I-Application
,	O
defined	O
as	O
a	O
minimal	O
set	O
of	O
attributes	O
that	O
functionally	O
determine	O
all	O
of	O
the	O
attributes	O
in	O
a	O
relation	B-Language
.	O
</s>
<s>
The	O
functional	B-Application
dependencies	I-Application
,	O
along	O
with	O
the	O
attribute	O
domains	O
,	O
are	O
selected	O
so	O
as	O
to	O
generate	O
constraints	O
that	O
would	O
exclude	O
as	O
much	O
data	O
inappropriate	O
to	O
the	O
user	O
domain	O
from	O
the	O
system	O
as	O
possible	O
.	O
</s>
<s>
A	O
notion	O
of	O
logical	O
implication	O
is	O
defined	O
for	O
functional	B-Application
dependencies	I-Application
in	O
the	O
following	O
way	O
:	O
a	O
set	O
of	O
functional	B-Application
dependencies	I-Application
logically	O
implies	O
another	O
set	O
of	O
dependencies	O
,	O
if	O
any	O
relation	B-Language
R	O
satisfying	O
all	O
dependencies	O
from	O
also	O
satisfies	O
all	O
dependencies	O
from	O
;	O
this	O
is	O
usually	O
written	O
.	O
</s>
<s>
The	O
notion	O
of	O
logical	O
implication	O
for	O
functional	B-Application
dependencies	I-Application
admits	O
a	O
sound	O
and	O
complete	O
finite	O
axiomatization	O
,	O
known	O
as	O
Armstrong	B-Application
's	I-Application
axioms	I-Application
.	O
</s>
<s>
This	O
functional	B-Application
dependency	I-Application
may	O
suggest	O
that	O
the	O
attribute	O
EngineCapacity	O
be	O
placed	O
in	O
a	O
relation	B-Language
with	O
candidate	B-Application
key	I-Application
VIN	O
.	O
</s>
<s>
For	O
example	O
,	O
if	O
that	O
functional	B-Application
dependency	I-Application
occurs	O
as	O
a	O
result	O
of	O
the	O
transitive	O
functional	B-Application
dependencies	I-Application
VIN	O
→	O
VehicleModel	O
and	O
VehicleModel	O
→	O
EngineCapacity	O
then	O
that	O
would	O
not	O
result	O
in	O
a	O
normalized	O
relation	B-Language
.	O
</s>
<s>
This	O
example	O
illustrates	O
the	O
concept	O
of	O
functional	B-Application
dependency	I-Application
.	O
</s>
<s>
can	O
be	O
expressed	O
by	O
a	O
functional	B-Application
dependency	I-Application
:	O
</s>
<s>
Note	O
that	O
if	O
a	O
row	O
was	O
added	O
where	O
the	O
student	O
had	O
a	O
different	O
value	O
of	O
semester	O
,	O
then	O
the	O
functional	B-Application
dependency	I-Application
FD	O
would	O
no	O
longer	O
exist	O
.	O
</s>
<s>
Other	O
nontrivial	O
functional	B-Application
dependencies	I-Application
can	O
be	O
identified	O
,	O
for	O
example	O
:	O
</s>
<s>
The	O
latter	O
expresses	O
the	O
fact	O
that	O
the	O
set	O
{	O
StudentID	O
,	O
Lecture}	O
is	O
a	O
superkey	B-Application
of	O
the	O
relation	B-Language
.	O
</s>
<s>
A	O
classic	O
example	O
of	O
functional	B-Application
dependency	I-Application
is	O
the	O
employee	O
department	O
model	O
.	O
</s>
<s>
This	O
case	O
represents	O
an	O
example	O
where	O
multiple	O
functional	B-Application
dependencies	I-Application
are	O
embedded	O
in	O
a	O
single	O
representation	O
of	O
data	O
.	O
</s>
<s>
The	O
process	O
of	O
normalization	B-Application
of	O
the	O
data	O
would	O
recognize	O
all	O
FDs	O
and	O
allow	O
the	O
designer	O
to	O
construct	O
tables	O
and	O
relationships	O
that	O
are	O
more	O
logical	O
based	O
on	O
the	O
data	O
.	O
</s>
<s>
Given	O
that	O
X	O
,	O
Y	O
,	O
and	O
Z	O
are	O
sets	O
of	O
attributes	O
in	O
a	O
relation	B-Language
R	O
,	O
one	O
can	O
derive	O
several	O
properties	O
of	O
functional	B-Application
dependencies	I-Application
.	O
</s>
<s>
Among	O
the	O
most	O
important	O
are	O
the	O
following	O
,	O
usually	O
called	O
Armstrong	B-Application
's	I-Application
axioms	I-Application
:	O
</s>
<s>
it	O
is	O
an	O
actual	O
axiom	B-Algorithm
,	O
where	O
the	O
other	O
two	O
are	O
proper	O
inference	O
rules	O
,	O
more	O
precisely	O
giving	O
rise	O
to	O
the	O
following	O
rules	O
of	O
syntactic	O
consequence	O
:	O
</s>
<s>
These	O
three	O
rules	O
are	O
a	O
sound	O
and	O
complete	O
axiomatization	O
of	O
functional	B-Application
dependencies	I-Application
.	O
</s>
<s>
This	O
axiomatization	O
is	O
sometimes	O
described	O
as	O
finite	O
because	O
the	O
number	O
of	O
inference	O
rules	O
is	O
finite	O
,	O
with	O
the	O
caveat	O
that	O
the	O
axiom	B-Algorithm
and	O
rules	O
of	O
inference	O
are	O
all	O
schemata	O
,	O
meaning	O
that	O
the	O
X	O
,	O
Y	O
and	O
Z	O
range	O
over	O
all	O
ground	O
terms	O
(	O
attribute	O
sets	O
)	O
.	O
</s>
<s>
One	O
can	O
also	O
derive	O
the	O
union	O
and	O
decomposition	O
rules	O
from	O
Armstrong	B-Application
's	I-Application
axioms	I-Application
:	O
</s>
<s>
The	O
closure	O
is	O
essentially	O
the	O
full	O
set	O
of	O
values	O
that	O
can	O
be	O
determined	O
from	O
a	O
set	O
of	O
known	O
values	O
for	O
a	O
given	O
relationship	O
using	O
its	O
functional	B-Application
dependencies	I-Application
.	O
</s>
<s>
One	O
uses	O
Armstrong	B-Application
's	I-Application
axioms	I-Application
to	O
provide	O
a	O
proof	O
-	O
i.e.	O
</s>
<s>
By	O
calculating	O
the	O
closure	O
of	O
A	O
,	O
we	O
have	O
validated	O
that	O
A	O
is	O
also	O
a	O
good	O
candidate	B-Application
key	I-Application
as	O
its	O
closure	O
is	O
every	O
single	O
data	O
value	O
in	O
the	O
relationship	O
.	O
</s>
<s>
Every	O
set	O
of	O
functional	B-Application
dependencies	I-Application
has	O
a	O
canonical	O
cover	O
.	O
</s>
<s>
Two	O
sets	O
of	O
FDs	O
and	O
over	O
schema	B-Application
are	O
equivalent	O
,	O
written	O
,	O
if	O
+	O
=	O
+	O
.	O
</s>
<s>
In	O
other	O
words	O
,	O
equivalent	O
sets	O
of	O
functional	B-Application
dependencies	I-Application
are	O
called	O
covers	O
of	O
each	O
other	O
.	O
</s>
<s>
An	O
important	O
property	O
(	O
yielding	O
an	O
immediate	O
application	O
)	O
of	O
functional	B-Application
dependencies	I-Application
is	O
that	O
if	O
R	O
is	O
a	O
relation	B-Language
with	O
columns	O
named	O
from	O
some	O
set	O
of	O
attributes	O
U	O
and	O
R	O
satisfies	O
some	O
functional	B-Application
dependency	I-Application
X	O
→	O
Y	O
then	O
where	O
Z	O
=	O
U	O
−	O
XY	O
.	O
</s>
<s>
Intuitively	O
,	O
if	O
a	O
functional	B-Application
dependency	I-Application
X	O
→	O
Y	O
holds	O
in	O
R	O
,	O
then	O
the	O
relation	B-Language
can	O
be	O
safely	O
split	O
in	O
two	O
relations	O
alongside	O
the	O
column	O
X	O
(	O
which	O
is	O
a	O
key	O
for	O
)	O
ensuring	O
that	O
when	O
the	O
two	O
parts	O
are	O
joined	O
back	O
no	O
data	O
is	O
lost	O
,	O
i.e.	O
</s>
<s>
a	O
functional	B-Application
dependency	I-Application
provides	O
a	O
simple	O
way	O
to	O
construct	O
a	O
lossless	B-Algorithm
join	I-Algorithm
decomposition	I-Algorithm
of	O
R	O
in	O
two	O
smaller	O
relations	O
.	O
</s>
<s>
Heath	O
's	O
theorem	O
effectively	O
says	O
we	O
can	O
pull	O
out	O
the	O
values	O
of	O
Y	O
from	O
the	O
big	O
relation	B-Language
R	O
and	O
store	O
them	O
into	O
one	O
,	O
,	O
which	O
has	O
no	O
value	O
repetitions	O
in	O
the	O
row	O
for	O
X	O
and	O
is	O
effectively	O
a	O
lookup	B-Data_Structure
table	I-Data_Structure
for	O
Y	O
keyed	O
by	O
X	O
and	O
consequently	O
has	O
only	O
one	O
place	O
to	O
update	O
the	O
Y	O
corresponding	O
to	O
each	O
X	O
unlike	O
the	O
"	O
big	O
"	O
relation	B-Language
R	O
where	O
there	O
are	O
potentially	O
many	O
copies	O
of	O
each	O
X	O
,	O
each	O
one	O
with	O
its	O
copy	O
of	O
Y	O
which	O
need	O
to	O
be	O
kept	O
synchronized	O
on	O
updates	O
.	O
</s>
<s>
(	O
This	O
elimination	O
of	O
redundancy	O
is	O
an	O
advantage	O
in	O
OLTP	B-General_Concept
contexts	O
,	O
where	O
many	O
changes	O
are	O
expected	O
,	O
but	O
not	O
so	O
much	O
in	O
OLAP	B-Application
contexts	O
,	O
which	O
involve	O
mostly	O
queries	O
.	O
)	O
</s>
<s>
Heath	O
's	O
decomposition	O
leaves	O
only	O
X	O
to	O
act	O
as	O
a	O
foreign	B-Application
key	I-Application
in	O
the	O
remainder	O
of	O
the	O
big	O
table	O
.	O
</s>
<s>
Functional	B-Application
dependencies	I-Application
however	O
should	O
not	O
be	O
confused	O
with	O
inclusion	O
dependencies	O
,	O
which	O
are	O
the	O
formalism	O
for	O
foreign	B-Application
keys	I-Application
;	O
even	O
though	O
they	O
are	O
used	O
for	O
normalization	B-Application
,	O
functional	B-Application
dependencies	I-Application
express	O
constraints	O
over	O
one	O
relation	B-Language
(	O
schema	B-Application
)	O
,	O
whereas	O
inclusion	O
dependencies	O
express	O
constraints	O
between	O
relation	B-Language
schemas	I-Language
in	O
a	O
database	B-Application
schema	I-Application
.	O
</s>
<s>
Furthermore	O
,	O
the	O
two	O
notions	O
do	O
not	O
even	O
intersect	O
in	O
the	O
classification	O
of	O
dependencies	O
:	O
functional	B-Application
dependencies	I-Application
are	O
equality-generating	O
dependencies	O
whereas	O
inclusion	O
dependencies	O
are	O
tuple-generating	O
dependencies	O
.	O
</s>
<s>
Enforcing	O
referential	O
constraints	O
after	O
relation	B-Language
schema	I-Language
decomposition	O
(	O
normalization	B-Application
)	O
requires	O
a	O
new	O
formalism	O
,	O
i.e.	O
</s>
<s>
Normal	B-Application
forms	I-Application
are	O
database	B-Application
normalization	I-Application
levels	O
which	O
determine	O
the	O
"	O
goodness	O
"	O
of	O
a	O
table	O
.	O
</s>
<s>
Generally	O
,	O
the	O
third	O
normal	B-Application
form	I-Application
is	O
considered	O
to	O
be	O
a	O
"	O
good	O
"	O
standard	O
for	O
a	O
relational	B-Application
database	I-Application
.	O
</s>
<s>
Normalization	B-Application
aims	O
to	O
free	O
the	O
database	O
from	O
update	O
,	O
insertion	O
and	O
deletion	B-Application
anomalies	I-Application
.	O
</s>
<s>
It	O
also	O
ensures	O
that	O
when	O
a	O
new	O
value	O
is	O
introduced	O
into	O
the	O
relation	B-Language
,	O
it	O
has	O
minimal	O
effect	O
on	O
the	O
database	O
,	O
and	O
thus	O
minimal	O
effect	O
on	O
the	O
applications	O
using	O
the	O
database	O
.	O
</s>
<s>
A	O
set	O
S	O
of	O
functional	B-Application
dependencies	I-Application
is	O
irreducible	O
if	O
the	O
set	O
has	O
the	O
following	O
three	O
properties	O
:	O
</s>
<s>
Each	O
right	O
set	O
of	O
a	O
functional	B-Application
dependency	I-Application
of	O
S	O
contains	O
only	O
one	O
attribute	O
.	O
</s>
<s>
Each	O
left	O
set	O
of	O
a	O
functional	B-Application
dependency	I-Application
of	O
S	O
is	O
irreducible	O
.	O
</s>
<s>
Reducing	O
any	O
functional	B-Application
dependency	I-Application
will	O
change	O
the	O
content	O
of	O
S	O
.	O
</s>
<s>
Sets	O
of	O
functional	B-Application
dependencies	I-Application
with	O
these	O
properties	O
are	O
also	O
called	O
canonical	O
or	O
minimal	O
.	O
</s>
<s>
Finding	O
such	O
a	O
set	O
S	O
of	O
functional	B-Application
dependencies	I-Application
which	O
is	O
equivalent	O
to	O
some	O
input	O
set	O
S	O
 '	O
provided	O
as	O
input	O
is	O
called	O
finding	O
a	O
minimal	O
cover	O
of	O
S	O
 '	O
:	O
this	O
problem	O
can	O
be	O
solved	O
in	O
polynomial	O
time	O
.	O
</s>
