Cub11k's BIU Notes
Cub11k's BIU Notes
Assignments
Discrete-math
Discrete-math 1
Discrete-math 10
Discrete-math 11
Discrete-math 12
Discrete-math 2
Discrete-math 3
Discrete-math 4
Discrete-math 5
Discrete-math 6
Discrete-math 7
Discrete-math 8
Discrete-math 9
Infi-1
Infi-1 10
Infi-1 11
Infi-1 2
Infi-1 3
Infi-1 4
Infi-1 5
Infi-1 6
Infi-1 7
Infi-1 8
Infi-1 9
Linear-1
Linear-1 1
Linear-1 10
Linear-1 11
Linear-1 12
Linear-1 2
Linear-1 3
Linear-1 4
Linear-1 5
Linear-1 6
Linear-1 7
Linear-1 8
Linear-1 9
Linear-2
Linear-2 1
Lectures
Data-structures
Data-structures 1
Data-structures 2
Data-structures 3
Discrete-math
Discrete-math 10
Discrete-math 11
Discrete-math 12
Discrete-math 13
Discrete-math 14
Discrete-math 15
Discrete-math 16
Discrete-math 18
Discrete-math 19
Discrete-math 20
Discrete-math 21
Discrete-math 22
Discrete-math 23
Discrete-math 24
Discrete-math 25
Discrete-math 26
Discrete-math 3
Discrete-math 4
Discrete-math 5
Discrete-math 6
Discrete-math 7
Discrete-math 8
Discrete-math 9
Exam 2023 (2A)
Exam 2023 (2B)
Exam 2023 (A)
Exam 2023 (B)
Exam 2023 (C)
Exam 2024 (A)
Exam 2024 (B)
Exam 2024 (C)
Midterm
Infi-1
Exam 2022B (A)
Exam 2022B (B)
Exam 2023B (A)
Exam 2023B (B)
Exam 2024 (A)
Exam 2024 (B)
Exam 2025 (A)
Infi-1 10
Infi-1 12
Infi-1 13
Infi-1 14
Infi-1 15
Infi-1 16
Infi-1 17
Infi-1 19
Infi-1 20
Infi-1 21
Infi-1 22
Infi-1 23
Infi-1 24
Infi-1 25
Infi-1 26
Infi-1 5
Infi-1 6
Infi-1 7
Infi-1 9
Midterm
Theorems and proofs
Infi-2
Infi-2 1
Infi-2 10
Infi-2 11
Infi-2 12
Infi-2 13
Infi-2 14
Infi-2 15
Infi-2 16
Infi-2 17
Infi-2 2-3
Infi-2 3-4
Infi-2 5
Infi-2 6
Infi-2 7
Infi-2 8
Infi-2 9
Linear-1
Exam 2023 (B)
Exam 2023 (C)
Exam 2024 (A)
Exam 2024 (B)
Exam 2024 (C)
Exam 2025 (A)
Linear-1 11
Linear-1 12
Linear-1 13
Linear-1 4
Linear-1 5
Linear-1 6
Linear-1 7
Linear-1 8
Linear-1 9
Midterm
Random exams
Theorems and proofs
Linear-2
Linear-2 1
Linear-2 2
Linear-2 3
Linear-2 4
Linear-2 5
Linear-2 6
Linear-2 7
Linear-2 8
Seminars
CSI
CSI 2
Data-structures
Data-structures 1
Data-structures 2
Data-structures 3
Discrete-math
Discrete-math 1
Discrete-math 10
Discrete-math 11
Discrete-math 12
Discrete-math 2
Discrete-math 3
Discrete-math 4
Discrete-math 5
Discrete-math 6
Discrete-math 7
Discrete-math 8
Discrete-math 9
Infi-1
Infi-1 10
Infi-1 11
Infi-1 12
Infi-1 13
Infi-1 3
Infi-1 4
Infi-1 5
Infi-1 6
Infi-1 8
Infi-2
Infi-2 1
Infi-2 2
Infi-2 3
Infi-2 4
Infi-2 6
Infi-2 7
Infi-2 8
Linear-1
Linear-1 10
Linear-1 11
Linear-1 12
Linear-1 3
Linear-1 5
Linear-1 6
Linear-1 7
Linear-1 8
Linear-1 9
Linear-2
Linear-2 1
Linear-2 2
Linear-2 3
Linear-2 4
Linear-2 5
Linear-2 6
Linear-2 7
Templates
Lecture Template
Seminar Template
Home
Discrete-math 6
1
∀
(
n
1
,
m
1
)
,
(
n
2
,
m
2
)
∈
N
×
N
(
n
1
,
m
1
)
R
(
n
2
,
m
2
)
⟺
n
1
≤
n
2
∧
m
1
≤
m
2
1a
Prove:
R
is an ordering relation
Proof:
Let
(
n
,
m
)
∈
N
×
N
n
=
n
∧
m
=
n
⟹
n
≤
n
∧
m
≤
m
⟹
(
n
,
m
)
R
(
n
,
m
)
⟹
R
is reflexive
Let
(
n
1
,
m
1
)
R
(
n
2
,
m
2
)
,
(
n
2
,
m
2
)
R
(
n
1
,
m
1
)
⟹
{
n
1
≤
n
2
m
1
≤
m
2
n
2
≤
n
1
m
2
≤
m
1
⟹
n
1
=
n
2
∧
m
1
=
m
2
⟺
(
n
1
,
m
1
)
=
(
n
2
,
m
2
)
⟹
R
is anti-symmetric
Let
(
n
1
,
m
1
)
R
(
n
2
,
m
2
)
,
(
n
2
,
m
2
)
R
(
n
3
,
m
3
)
⟹
{
n
1
≤
n
2
≤
n
3
m
1
≤
m
2
≤
m
3
⟹
n
1
≤
n
3
∧
m
1
≤
m
3
⟹
(
n
1
,
m
1
)
R
(
n
3
,
m
3
)
⟹
R
is transitive
⟹
R
is an ordering relation
1b
Prove or disprove:
(
N
×
N
,
R
)
is a total order (
R
is linear)
Disproof:
Let
x
=
(
1
,
3
)
∈
N
×
N
Let
y
=
(
5
,
2
)
∈
N
×
N
3
>
2
⟹
x
R̸
y
5
>
1
⟹
y
R̸
x
⟹
∃
(
n
1
,
m
1
)
,
(
n
2
,
m
2
)
:
¬
[
(
n
1
,
m
1
)
R
(
n
2
,
m
2
)
∧
(
n
2
,
m
2
)
R
(
n
1
,
m
1
)
]
⟹
(
N
×
N
,
R
)
is not a total order
1c
B
=
{
(
1
,
n
)
|
n
∈
N
}
Find
i
n
f
(
B
)
and
s
u
p
(
B
)
Solution:
Let
(
x
,
y
)
∈
N
×
N
∀
b
∈
B
:
(
x
,
y
)
R
b
⟺
∀
n
∈
N
:
x
≤
1
∧
y
≤
n
⟺
x
≤
1
∧
y
≤
1
⟹
L
B
=
{
(
x
,
y
)
∈
N
×
N
|
x
≤
1
∧
y
≤
1
}
⟹
m
a
x
(
L
B
)
=
(
1
,
1
)
⟹
i
n
f
(
B
)
=
(
1
,
1
)
∀
b
∈
B
:
b
R
(
x
,
y
)
⟺
∀
n
∈
N
:
1
≤
x
∧
n
≤
y
⟺
1
≤
x
∧
∃
s
u
p
(
N
)
⏟
False
⟹
U
B
=
∅
⟹
∄
s
u
p
(
B
)
1d
B
=
{
(
n
,
1
)
|
n
∈
N
}
Find
i
n
f
(
B
)
and
s
u
p
(
B
)
Solution:
Let
(
x
,
y
)
∈
N
×
N
∀
b
∈
B
:
(
x
,
y
)
R
(
n
,
1
)
⟺
∀
n
∈
N
:
x
≤
n
∧
y
≤
1
⟺
x
≤
1
∧
y
≤
1
⟹
L
B
=
{
(
x
,
y
)
∈
N
×
N
|
x
≤
1
∧
y
≤
1
}
⟹
m
a
x
(
L
B
)
=
(
1
,
1
)
⟹
i
n
f
(
B
)
=
(
1
,
1
)
∀
b
∈
B
:
b
R
(
x
,
y
)
⟺
∀
n
∈
N
:
n
≤
x
∧
1
≤
y
⟺
∃
s
u
p
(
N
)
⏟
False
∧
1
≤
y
⟹
U
B
=
∅
⟹
∄
s
u
p
(
B
)
2
Let
(
A
,
≼
)
be a poset
,
|
A
|
≥
2
(
a
1
,
b
1
)
R
(
a
2
,
b
2
)
⟺
a
1
≼
a
2
∧
b
1
≼
b
2
Prove:
R
is a non-linear relation on
A
×
A
Proof:
Let
a
1
≠
a
2
,
a
1
≼
a
2
∧
b
2
≼
b
1
,
b
1
≠
b
2
⟹
(
a
1
,
b
1
)
R̸
(
a
2
,
b
2
)
∧
(
a
2
,
b
2
)
R̸
(
a
1
,
b
1
)
⟹
∃
(
a
1
,
b
1
)
,
(
a
2
,
b
2
)
∈
A
×
A
:
¬
[
(
a
1
,
b
1
)
R
(
a
2
,
b
2
)
∨
(
a
2
,
b
2
)
R
(
a
1
,
b
1
)
]
⟹
R
is a non-linear relation
3
Let
(
A
,
≤
)
,
(
B
,
≼
)
be posets
,
A
,
B
≠
∅
Lexicographic order
L
on
A
×
B
:
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
⟺
(
a
1
<
a
2
∨
(
a
1
=
a
2
∧
b
1
≼
b
2
)
)
3a
Find posets
(
A
,
≤
)
,
(
B
,
≼
)
such that
L
is non-linear
Solution:
(
A
,
≤
)
=
(
{
2
,
3
}
,
∣
)
(
B
,
≼
)
=
(
{
5
,
7
}
,
∣
)
2
∤
3
∨
(
2
≠
3
∧
5
∤
7
)
≡
F
⟹
(
2
,
5
)
L̸
(
3
,
7
)
3
∤
2
∨
(
3
≠
2
∧
7
∤
5
)
≡
F
⟹
(
3
,
7
)
L̸
(
2
,
5
)
⟹
L
is non-linear
3b
Prove:
L
is linear
⟺
≤
,
≼
are linear
Proof:
Let
a
1
,
a
2
∈
A
,
b
1
,
b
2
∈
B
⟹
(
a
1
,
b
1
)
,
(
a
2
,
b
2
)
∈
A
×
B
Let
≤
,
≼
be linear
{
a
1
≤
a
2
∨
a
2
≤
a
1
b
1
≼
b
2
∨
b
2
≼
b
1
⟹
{
[
a
1
<
a
2
a
2
<
a
1
a
1
=
a
2
b
1
≼
b
2
∨
b
2
≼
b
1
⟹
{
[
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
(
a
2
,
b
2
)
L
(
a
1
,
b
1
)
a
1
=
a
2
b
1
≼
b
2
∨
b
2
≼
b
1
⟹
[
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
(
a
2
,
b
2
)
L
(
a
1
,
b
1
)
a
1
=
a
2
∧
(
b
1
≼
b
2
∨
b
2
≼
b
1
)
⟹
[
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
(
a
2
,
b
2
)
L
(
a
1
,
b
1
)
a
1
=
a
2
∧
b
1
≼
b
2
a
1
=
a
2
∧
b
2
≼
b
1
⟹
[
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
(
a
2
,
b
2
)
L
(
a
1
,
b
1
)
(
a
1
,
b
1
)
L
(
a
2
,
b
2
)
(
a
2
,
b
2
)
L
(
a
1
,
b
1
)
⟹
L
is linear
(
1
)
Let
L
be linear
[
(
a
1
,
b
1
)
L
(
a
2
,
b
1
)
(
a
2
,
b
1
)
L
(
a
1
,
b
1
)
⟹
[
a
1
<
a
2
∨
(
a
1
=
a
2
∧
b
1
≼
b
1
)
a
2
<
a
1
∨
(
a
2
=
a
1
∧
b
1
≼
b
1
)
⟹
a
1
≤
a
2
∨
a
2
≤
a
1
⟹
≤
is linear
(
2
)
[
(
a
1
,
b
1
)
L
(
a
1
,
b
2
)
(
a
1
,
b
2
)
L
(
a
1
,
b
1
)
⟹
[
a
1
<
a
1
∨
(
a
1
=
a
1
∧
b
1
≼
b
2
)
a
1
<
a
1
∨
(
a
1
=
a
1
∧
b
2
≼
b
1
)
⟹
b
1
≼
b
2
∨
b
2
≼
b
1
⟹
≼
is linear
(
3
)
(
1
)
∧
(
2
)
∧
(
3
)
⟹
L
is linear
⟺
≤
,
≼
are linear
4
Let
(
A
,
≼
)
be a poset, assume
∃
m
i
n
(
A
)
=
a
,
let
B
⊆
A
4a
Prove or disprove:
a
∈
B
⟸
i
n
f
(
B
)
=
a
Proof:
B
⊆
A
⟹
∀
b
∈
B
:
b
∈
A
⟹
∀
b
∈
B
:
a
≼
b
a
∈
B
⟹
a
=
m
i
n
(
B
)
∃
m
i
n
(
B
)
⟹
i
n
f
(
B
)
=
m
i
n
(
B
)
⟹
i
n
f
(
B
)
=
a
4b
Prove or disprove:
i
n
f
(
B
)
=
a
⟹
a
∈
B
Disproof:
Let
A
=
{
x
∈
R
|
x
≥
0
}
Let
a
1
≼
a
2
⟺
a
1
≤
a
2
⟹
m
i
n
(
A
)
=
0
Let
B
=
{
1
n
|
n
∈
N
}
i
n
f
(
B
)
=
0
∧
0
∉
B
Disproved
5a
Find a function
f
:
N
→
N
that is injective but not surjective
Solution:
f
(
n
)
=
n
+
1
∀
n
1
,
n
2
∈
N
:
f
(
n
1
)
=
f
(
n
2
)
⟹
n
1
+
1
=
n
2
+
1
⟹
n
1
=
n
2
⟹
f
is injective
∀
n
∈
N
:
f
(
n
)
≠
1
⟹
f
is not surjective
5b
Find a function
f
:
N
→
N
that is surjective but not injective
Solution:
f
(
n
)
=
{
n
n
=
1
n
−
1
otherwise
f
(
1
)
=
f
(
2
)
⟹
f
is not injective
∀
n
∈
N
:
∃
n
+
1
∈
N
:
f
(
n
+
1
)
=
n
+
1
−
1
=
n
⟹
f
is surjective
5c
Let
f
:
R
→
R
,
f
(
x
)
=
m
x
+
b
For which values of
m
,
b
∈
R
,
function
f
is bijective?
Solution:
∀
m
,
b
,
x
1
,
x
2
∈
R
:
f
(
x
1
)
=
f
(
x
2
)
⟹
m
x
1
+
b
=
m
x
2
+
b
⟹
[
m
=
0
x
1
=
x
2
⟹
m
≠
0
⟹
f
is injective
Let
y
∈
R
y
=
m
x
+
b
⟺
x
=
y
−
b
m
y
−
b
m
∈
R
⟺
m
≠
0
⟹
[
∀
y
∈
R
∃
x
∈
R
:
f
(
x
)
=
y
]
⟺
m
≠
0
⟹
f
is bijective
⟺
m
≠
0
6
Define and prove whether the functions are injective, surjective or bijective
6a
f
:
Z
→
Z
,
f
(
n
)
=
|
n
|
Also find
I
m
(
f
)
Solution:
f
(
1
)
=
f
(
−
1
)
=
1
⟹
f
is not injective
∀
n
∈
Z
:
f
(
n
)
≠
−
1
⟹
f
is not surjective
I
m
(
f
)
=
{
z
∈
Z
|
z
≥
0
}
6b
f
:
R
→
{
0
,
1
}
,
f
(
x
)
=
{
1
x
∈
Q
0
x
∉
Q
Solution:
f
(
1
)
=
f
(
2
)
=
1
⟹
f
is not injective
f
(
1
)
=
1
,
f
(
2
)
=
0
⟹
I
m
(
f
)
=
{
0
,
1
}
⟹
f
is surjective
6c
f
:
P
(
A
)
→
P
(
A
)
,
f
(
B
)
=
A
∖
B
Solution:
If there are no two different elements in
P
(
A
)
,
then
f
is obviously injective
Let
B
1
,
B
2
⊆
A
,
B
1
≠
B
2
⟹
b
can be in
B
1
or in
B
2
∃
b
∈
B
1
:
b
∉
B
2
b
∈
B
1
⟹
b
∈
A
⟹
b
∈
A
∖
B
2
b
∈
B
1
⟹
b
∉
A
∖
B
1
⟹
A
∖
B
1
≠
A
∖
B
2
⟹
[
B
1
≠
B
2
⟹
f
(
B
1
)
≠
f
(
B
2
)
]
⟹
∀
A
:
f
is injective
Let
C
⊆
A
∃
B
⊆
A
:
B
=
A
∖
C
f
(
B
)
=
A
∖
(
A
∖
C
)
=
C
⟹
∀
A
:
f
is surjective
6d
A
≠
∅
,
B
⊂
A
f
:
P
(
A
)
→
P
(
B
)
,
f
(
C
)
=
C
∩
B
Solution:
A
∩
B
=
B
=
B
∩
B
f
(
A
)
=
f
(
B
)
=
B
⟹
f
is not injective
Let
B
1
⊆
B
B
1
⊆
B
⊂
A
⟹
B
1
∈
P
(
A
)
f
(
B
1
)
=
B
1
∩
B
=
B
1
⟹
f
is surjective
6e
A
≠
∅
,
B
⊂
A
f
:
P
(
B
)
→
P
(
A
)
,
f
(
C
)
=
C
∪
(
A
∖
B
)
Solution:
Let
C
1
,
C
2
⊆
B
,
C
1
≠
C
2
⟹
c
can be in
C
1
or in
C
2
∃
c
∈
C
1
:
c
∉
C
2
c
∈
C
1
⟹
c
∈
B
⟹
c
∉
A
∖
B
c
∉
C
2
⟹
c
∉
C
2
∪
(
A
∖
B
)
c
∈
C
1
⟹
c
∈
C
1
∪
(
A
∖
B
)
⟹
C
1
∪
(
A
∖
B
)
≠
C
2
∪
(
A
∖
B
)
⟹
[
C
1
≠
C
2
⟹
f
(
C
1
)
≠
f
(
C
2
)
]
⟹
f
is injective
B
⊂
A
⟹
A
∖
B
≠
∅
⟹
∀
X
:
X
∪
(
A
∖
B
)
≠
∅
∅
⊆
A
∧
∀
C
⊆
B
:
f
(
C
)
≠
∅
⟹
f
is not surjective
7
Let
A
be a set
Let
f
:
A
→
N
Let
R
be a relation
on A
a
R
b
⟺
f
(
a
)
≤
f
(
b
)
Prove:
R
is an order relation
⟺
f
is injective
Proof:
Let
a
,
b
,
c
∈
A
R
is reflexive
:
a
R
a
⟺
f
(
a
)
≤
f
(
a
)
≡
T
R
is transitive
:
a
R
b
∧
b
R
c
⟺
f
(
a
)
≤
f
(
b
)
≤
f
(
c
)
⟹
f
(
a
)
≤
f
(
c
)
⟹
a
R
c
Let
a
≠
b
,
f
(
a
)
=
f
(
b
)
f
(
a
)
=
f
(
b
)
∧
a
≠
b
⟹
f
(
a
)
≤
f
(
b
)
∧
f
(
b
)
≤
f
(
a
)
∧
a
≠
b
⟹
a
R
b
∧
b
R
a
∧
a
≠
b
⟹
R
is not an order relation
⟹
[
f
is not injection
⟹
R
is not an order relation
]
⟹
R
is an order relation
⟹
f
is injective
(
1
)
Let
a
≠
b
,
a
R
b
,
b
R
a
a
R
b
∧
b
R
a
∧
a
≠
b
⟹
f
(
a
)
≤
f
(
b
)
∧
f
(
b
)
≤
f
(
a
)
∧
a
≠
b
⟹
f
(
a
)
=
f
(
b
)
∧
a
≠
b
⟹
f
is not injective
⟹
[
R
is not an order relation
⟹
f
is not injective
]
⟹
f
is injective
⟹
R
is an order relation
(
2
)
(
1
)
∧
(
2
)
⟹
R
is an order relation
⟺
f
is injective
8
Let
A
,
B
be finite sets
8a
Let
f
:
A
→
B
Prove:
|
A
|
=
|
B
|
⟹
[
f
is injective
⟺
f is surjective
]
Proof:
Let
|
A
|
=
|
B
|
=
n
Let
f
be injective
∀
a
1
,
a
2
∈
A
:
a
1
≠
a
2
⟹
f
(
a
1
)
≠
f
(
a
2
)
There are
n
unique sources in
A
⟹
there are
n
unique images in
B
⟹
|
I
m
(
f
)
|
=
|
A
|
=
n
I
m
(
f
)
⊆
B
∧
|
I
m
(
f
)
|
=
n
⟹
I
m
(
f
)
=
B
⟹
f
is surjective
(
1
)
Let
f
be surjective
∀
b
∈
B
:
∃
a
∈
A
:
f
(
a
)
=
b
Let
a
1
,
a
2
∈
A
:
a
1
≠
a
2
∧
f
(
a
1
)
=
f
(
a
2
)
Let
b
∈
B
:
b
=
f
(
a
1
)
=
f
(
a
2
)
|
A
∖
{
a
1
,
a
2
}
|
=
n
−
2
|
B
∖
{
b
}
|
=
n
−
1
∀
b
1
∈
B
∖
{
b
}
:
b
1
≠
b
⟹
f
(
a
1
)
≠
b
1
≠
f
(
a
2
)
⟹
There are
n
−
1
distinct images that have at least one source each,
however there are only
n
−
2
distinct sources
⟹
∃
a
∈
A
,
∃
b
1
,
b
2
∈
B
:
f
(
a
)
=
b
1
=
b
2
⟹
f
is not to one
−
Contradiction!
⟹
[
∀
a
1
,
a
2
∈
A
:
a
1
≠
a
2
⟹
f
(
a
1
)
≠
f
(
a
2
)
]
⟹
f
is injective
(
2
)
(
1
)
∧
(
2
)
⟹
f
is injective
⟺
f
is surjective
8b
Let
f
:
A
→
B
Prove:
[
∃
f
:
f
is injective
⟺
f
is surjective
]
⟺
|
A
|
=
|
B
|
Proof:
As proved in 8a,
∀
f
:
|
A
|
=
|
B
|
⟹
[
f
is injective
⟺
f
is surjective
]
⟹
|
A
|
=
|
B
|
⟹
[
∃
f
:
f
is injective
⟺
f
is surjective
]
(
1
)
Let
∃
f
:
f
is injective
⟺
f
is surjective
Let
|
A
|
>
|
B
|
=
n
A
=
{
a
1
,
a
2
,
…
,
a
n
,
a
n
+
1
,
…
}
,
B
=
{
b
1
,
b
2
,
…
,
b
n
}
Let
∀
i
∈
[
1
,
n
]
:
f
(
a
i
)
=
b
i
⟹
f
is surjective
By our assumption,
f
is also injective, but there is no
b
n
+
1
⟹
∃
i
∈
[
1
,
n
]
:
f
(
a
n
+
1
)
=
b
i
⟹
∃
i
∈
[
1
,
n
]
:
a
i
≠
a
n
+
1
∧
f
(
a
i
)
=
f
(
a
n
+
1
)
⟹
f
is not injective
−
Contradiction!
⟹
|
A
|
≯
|
B
|
Let
n
=
|
A
|
<
|
B
|
A
=
{
a
1
,
a
2
,
…
,
a
n
}
,
B
=
{
b
1
,
b
2
,
…
,
b
n
,
b
n
+
1
,
…
}
Let
∀
i
∈
[
1
,
n
]
:
f
(
a
i
)
=
b
i
⟹
f
is injective
By our assumption,
f
is also surjective, but there is no
a
n
+
1
⟹
∄
i
∈
[
1
,
n
]
:
f
(
a
i
)
=
b
n
+
1
⟹
f
is not surjective
−
Contradiction!
⟹
|
A
|
≮
|
B
|
|
A
|
≯
|
B
|
∧
|
A
|
≮
|
B
|
⟹
|
A
|
=
|
B
|
⟹
[
∃
f
:
f
is injective
⟺
f
is surjective
]
⟹
|
A
|
=
|
B
|
(
2
)
(
1
)
∧
(
2
)
⟹
[
∃
f
:
f
is injective
⟺
f
is surjective
]
⟺
|
A
|
=
|
B
|
9
Let
X
=
P
(
N
×
N
)
S
on
X
is defined as following:
R
1
S
R
2
⟺
R
1
∪
R
2
is an equivalence relation
9a
Is
S
an equivalence relation on
X
?
Solution:
Let
R
1
∈
X
R
1
S
R
1
⟺
R
1
∪
R
1
is an equivalence relation
R
1
∪
R
1
=
R
1
⟹
[
S
is reflexive
⟺
R
1
is an equivalence relation
]
X
is a set of all relations on
N
Let
R
=
{
(
n
,
m
)
∈
N
×
N
|
n
<
m
}
R
⊆
N
×
N
⟹
R
∈
P
(
N
×
N
)
R
is not reflexive
⟹
R
is not an equivalence relation
⟹
S
is not reflexive
⟹
S
is not an equivalence relation
9b
Prove:
(
S
∘
S
)
is an equivalence relation
Proof:
Let us define
(
S
∘
S
)
R
1
(
S
∘
S
)
R
2
⟺
∃
R
3
:
R
1
S
R
3
∧
R
3
S
R
2
⟺
∃
R
3
:
R
1
∪
R
3
is an equivalence relation
∧
R
3
∪
R
2
is an equivalence relation
∀
R
1
,
R
2
∈
P
(
N
×
N
)
:
R
1
∪
N
×
N
=
R
2
∪
N
×
N
=
N
×
N
−
an equivalence relation
⟹
∀
R
1
,
R
2
∈
P
(
N
×
N
)
:
R
1
(
S
∘
S
)
R
2
⟹
S
is full
⟹
(
S
∘
S
)
is an equivalence relation