Raw

1. Objective / Мета роботи

Implement checks for the fundamental properties of a binary relation on a set, recognise equivalence relations, and generate the inverse of a relation.

By the end of the work the student should be able to:

  • represent a binary relation on a set AA as a set of ordered pairs RA×AR \subseteq A \times A;
  • test the three core properties — reflexivity (a, (a,a)R\forall a,\ (a,a)\in R), symmetry ((a,b)R(b,a)R(a,b)\in R \Rightarrow (b,a)\in R), and transitivity ((a,b),(b,c)R(a,c)R(a,b),(b,c)\in R \Rightarrow (a,c)\in R);
  • combine them to decide whether RR is an equivalence relation, and explain how such a relation partitions AA into equivalence classes;
  • construct the inverse relation R1={(b,a):(a,b)R}R^{-1} = \{(b,a) : (a,b)\in R\};
  • test antisymmetry and decide whether RR is a partial order (reflexive, antisymmetric, and transitive);
  • reason about the time complexity of each check.

The work makes the abstract properties of relations concrete and prepares the ground for order relations, functions, and partitions studied later.

Laboratory/Laboratory3/1purpose.md · 1.1 KB · updated 2026-08-01 20:20