Theorems of Floor Function

Definition: Let x be a real number. Let [x] be the integral part of x and {x} be the non-integral part of x. The notation [x] is often used to denote the floor function. For example, if x = 3.14159, then [x] = 3, {x} = .14159; if x = -2.71828, then [x] = -3, {x} = .28172.

Theorems for [x]

Theorem 1

[x±n] = [x]±n for all n is an integer

Theorem 2

n[x] = [nx] for 0<={x}<1/n
[nx]-1 for 1/n<={x}<2/n
[nx]-2 for 2/n<={x}<3/n
·············
·············
·············
[nx]-(n-1) for (n-1)/n<={x}<1
for all n is an integer>=1

Theorem 3

Conversely,
[nx] = n[x] for 0<={x}<1/n
n[x]+1 for 1/n<={x}<2/n
n[x]+2 for 2/n<={x}<3/n
·············
·············
·············
n[x]+(n-1) for (n-1)/n<={x}<1
for all n is an integer>=1

Theorems for {x}

Theorem 4

{x±n}={x} for all n is an integer

Theorem 5

n{x} = {nx} for 0<={x}<1/n
{nx}+1 for 1/n<={x}<2/n
{nx}+2 for 2/n<={x}<3/n
·············
·············
·············
{nx}-(n-1) for (n-1)/n<={x}<1
for all n is an integer>=1

Theorem 6

Conversely,
{nx} = n{x} for 0<={x}<1/n
n{x}-1 for 1/n<={x}<2/n
n{x}-2 for 2/n<={x}<3/n
·············
·············
·············
n{x}-(n-1) for (n-1)/n<={x}<1
for all n is an integer>=1

Application

Prove

[x] = [(x+1)/2] + [x/2]

Solution:

Change the expression to,
x - {x} = (x+1)/2-{(x+1)/2} + x/2 - {x/2}
then, we have,
{(x+1)/2} + {x/2} = {x} + 1/2

Double the both sides,
2{(x+1)/2} + 2{x/2} = 2{x}+1

Apply Theorem 5, this results in two cases

First case, for 0<={x/2}<1/2 and 1/2<={(x+1)/2}<1
==> {x+1} + 1 + {x} = 2{x} + 1
==> 2{x} + 1 == 2{x} + 1 By Theorem 4

Second case, for 1/2<={x/2}<1 and 0<={(x+1)/2}<1/2
==> {x+1} + {x} + 1 = 2{x} + 1
==> 2{x} + 1 == 2{x} + 1 By Theorem 4

As a result, the formula

[x] = [(x+1)/2] + [x/2]
is proved.

Back to my Front Page

Latest update: 3rd December, 1996