Студопедия

Главная страница Случайная страница

КАТЕГОРИИ:

АвтомобилиАстрономияБиологияГеографияДом и садДругие языкиДругоеИнформатикаИсторияКультураЛитератураЛогикаМатематикаМедицинаМеталлургияМеханикаОбразованиеОхрана трудаПедагогикаПолитикаПравоПсихологияРелигияРиторикаСоциологияСпортСтроительствоТехнологияТуризмФизикаФилософияФинансыХимияЧерчениеЭкологияЭкономикаЭлектроника






Methods of relation specification.






1. A relation can be specified by enumeration of all arrangements of elements that satisfy the relation (as in the above given example).

2. A binary relation can be specified by means of a matrix.

 

For example, β ⊆ A ´ B, where A = {a1, a2, a3}, B = {b1, b2, b3, b4}.

β b1 b2 b3
The relation ai β bj is true for 6 ordered pairs: (a1 , b1), (a1 , b3), (a2 , b2), (a2 , b3), (a2 , b4), (a3 , b1).
b4

a1    
a2  
a3      

 

3. Relations can be specified, presented by means of directed graphs ( by figures cоnsisting оf points and arrows).

For the previous example we obtain such a graph:

The points of the graph correspond to the elements of the sets A and B, arrows directed from ai to bj denote that ai β bj is true.

If a binary relation a is specified on one set A: that is a ⊆ A ´ A, then the graph may have such a shape (form):

 

 

If a relation a contains all possible pairs, that is a = A ´ A, then the graph оf the relation has such a shape (form):

Each nondirected line (edge) substitutes two arrows, pointed in both directions.

Now we will consider binary relations. All binary relations are subsets of a set A ´ B. That is why it is possible to define operations of union, intersection, difference and compliment on relations (in order to define new relations).

1) a(a U β ) b ⇔ a a b or a β b (or is nonexclusive);

2) a(a ∩ β ) b ⇔ a a b and a β b;

3) a(a - β ) b ⇔ a a b is true and a β b is false.

In other terms a(a - β ) b = {(a, b) | (a, b) ∈ a and (a, b) ∉ β }.

4. If a is a universal relation, that is a = A x B, then a(a-β )b is denoted by a b. This new relation is called the compliment of β.

Formally:

a b = {(a, b)|(a, b)Ï β, (a, b) ∈ a}

Examples:

( ) = (a ≠ b);

(a = b) È (a < b) = (a ≤ b);

(a ≥ b)∩ (a < b) - this relation is always false.

(a ≥ b) È (a < b) - this relation is always true.

(a ≤ b) - (a = b) = (a < b)

(A x B) - (a < b) = = (a ≥ b);

In order to meet the requirements of practical applications, some other relational operations may be defined.