How to count number of relations of a set?

5.6k Views Asked by At

I'm having problem wrapping my mind around something. Let's assume set A = {1,2}. How many relations are there in the group? I know there's a formula that goes $$2^{n^2}$$ where $n$ is the number of objects in a set. That gives us $$2^4$$ which is 16.

But when I count the relations manually:

{1,1} {2,2} {1,2} {2,1}

That gives me only 4. What am I missing here?

3

There are 3 best solutions below

3
On

Hint:

$R$ is a relation on set $A$ if and only if $R$ is a subset of $A\times A$.

0
On

This is set $A:=\{1, 2\}$.

This is an ordered pair: $(1,2)$

This is set $A\times A:=\{(1,1),\ (1,2),\ (2,1),\ (2,2)\}$.

A relation $R$ on $A$ is a subset of $A\times A$, or equivalently, $R$ is a member of the power set of $A\times A$.

For a set $S$ of size $n$, the set $S\times S$ has size $n^2$, and the power set of $S\times S$ has $2^{n^2}$ elements.

0
On

$$A=\{1,2\}$$

$$A\times A=\{(1,1),(2,2),(1,2),(2,1)\}$$

$A\times A$ has $4$ elements. So total number of subsets of $A\times A$ is $2^4=16$. Each of the subset of $A\times A$ is a relation. They are $$\emptyset, \{(1,1)\},\{(2,2)\},\{(1,2)\},\{(2,1)\},\{(1,1),(2,2)\}, \{(1,1),(1,2)\},\{(1,1),(2,1)\},\{(2,2),(1,2)\},\{(2,2),(2,1)\},\{(1,1),(2,2),(1,2)\},\{(1,1),(2,2),(2,1)\},\{(1,2),(2,1)\}\{(1,1),(2,1),(1,2)\},\{(2,2),(2,1),(1,2)\},A.$$