The greatest integer function, also called the floor function, takes a real number as input and
gives the greatest integer less than or equal to that number as output.
It is denoted by ⌊x⌋.
Here are examples, broken down by category.
---
1. Basic Examples with Positive Numbers
For positive numbers, the function essentially "chops off" the decimal part.
· ⌊3.7⌋ = 3 (The greatest integer ≤ 3.7 is 3)
· ⌊5.01⌋ = 5 (Even though it's very close to 5, it's still 5)
· ⌊8⌋ = 8 (If the input is already an integer, the output is itself)
· ⌊0.5⌋ = 0
· ⌊π⌋ = ⌊3.14159...⌋ = 3
2. Examples with Negative Numbers
This is where it gets tricky! Remember, it's the greatest integer less than or equal to the number,
not "just drop the decimal."
· ⌊-2.3⌋ = -3
· Why? Let's think about integers less than or equal to -2.3: ... -4, -3, -2.
· -2 is greater than -2.3, so it doesn't count.
· -3 is less than -2.3, and it's the greatest integer that is still less than -2.3.
· ⌊-5⌋ = -5 (It's an integer, so the output is itself)
· ⌊-1.99⌋ = -2
· The integers less than or equal to -1.99 are ... -3, -2, -1.
· -1 is greater than -1.99, so it doesn't count.
· -2 is less than -1.99, and it's the greatest such integer.
3. Applied Examples (Word Problems)
The greatest integer function is perfect for modeling real-world scenarios where things are
charged in whole units.
Example 1: Parking Garage Fees
A parking garage charges$5 for the first hour or any part thereof. This means if you park for 1.5
hours, you pay for 2 hours.
The cost fort hours can be modeled as: C(t) = 5 * ⌊t ⌋ if t is not an integer. But if you park for any
part of an hour, you pay for the whole hour. The correct function is:
C(t) = 5 * ⌊t + 1⌋for t > 0.
· Park for 0.5 hours: C(0.5) = 5 * ⌊1.5⌋ = 5 * 1 = $5
· Park for 2.1 hours: C(2.1) = 5 * ⌊3.1⌋ = 5 * 3 = $15
· Park for 3 hours: C(3) = 5 * ⌊4⌋ = 5 * 4 = $20
Example 2: Postage Stamps
Stamps are sold as whole items.If a letter requires 2.4 ounces of postage and the first ounce costs
$1 and each additional ounce (or part of an ounce) costs $0.50, the cost is:
Cost = 1 + 0.50 * ⌊weight - 1⌋for weight > 1.
· Weight = 2.4 oz: Cost = 1 + 0.50 * ⌊1.4⌋ = 1 + 0.50 * 1 = $1.50
· Weight = 3.1 oz: Cost = 1 + 0.50 * ⌊2.1⌋ = 1 + 0.50 * 2 = $2.00
4. Visualizing the Function (The Graph)
The graph of the greatest integer function, y = ⌊x⌋, looks like a series of steps. This is why it's
often called a step function.
· For all x values from [0, 1), the y value is 0.
· For all x values from [1, 2), the y value is 1.
· For all x values from [-1, 0), the y value is -1.
· And so on.
Each "step" is a horizontal segment that includes its left endpoint (shown with a closed dot) but
not its right endpoint (shown with an open dot).
Summary Table
Here is a table summarizing some key values:
Input x Output ⌊x⌋ Explanation
4.9 4 Greatest integer ≤ 4.9
3.0 3 Integer inputs give themselves
2.1 2 Drops the decimal
0.7 0
-0.5 -1 The greatest integer ≤ -0.5 is -1 (not 0!)
-1.2 -2 The greatest integer ≤ -1.2 is -2 (not -1!)
-3.0 -3 Integer inputs give themselves
Here are some of the most important and powerful equations and identities related to the
Greatest Integer (Floor) Function, ⌊x⌋.
1. The Foundational Definition
This is the most fundamental "strong equation," defining the function in terms of basic
inequalities.
Definition:
⌊x⌋is the unique integer n satisfying:
n≤x<n+1
This is the cornerstone for all proofs and properties of the floor function. For example, for x = 2.7,
n = 2 because 2 ≤ 2.7 < 3.
---
2. Powerful Identities and Properties
These are the workhorses for solving problems and simplifying expressions.
a) Relationship with the Fractional Part
The fractional part of a number is defined as {x} = x - ⌊x ⌋. This leads to the fundamental
decomposition:
x = ⌊x⌋ + {x}
where0 ≤ {x} < 1.
This identity is crucial for breaking any number into its integer and decimal components.
b) Property of Negation (Interaction with the Ceiling)
This one often surprises people. The ceiling function, denoted ⌈x ⌉, is the smallest integer greater
than or equal to x.
⌊-x⌋ = -⌈x⌉
and equivalently,
⌈-x⌉ = -⌊x⌋
Example: Let x = 2.3.
· ⌊-2.3⌋ = -3
· -⌈2.3⌉ = -(3) = -3
c) Division Property (Extremely Important in Number Theory)
For integers m and n with n > 0, the number of positive integers less than or equal to m that are
divisible by n is given by:
⌊m/n⌋
Example: How many numbers from 1 to 100 are divisible by 7?
· ⌊100 / 7⌋ = ⌊14.285...⌋ = 14
d) Hermite's Identity (A Classic "Strong" Identity)
This is a non-obvious and powerful identity:
⌊x⌋ + ⌊x + 1/n⌋ + ⌊x + 2/n⌋ + ... + ⌊x + (n-1)/n⌋ = ⌊nx⌋
For n=2, this becomes a very useful specific case:
⌊x⌋ + ⌊x + 1/2⌋ = ⌊2x⌋
Example: Let x = 1.3, n=2.
· ⌊1.3⌋ + ⌊1.3 + 0.5⌋ = 1 + ⌊1.8⌋ = 1 + 1 = 2
· ⌊2 * 1.3⌋ = ⌊2.6⌋ = 2
---
3. A "Strong" Functional Equation
This equation defines the step-like behavior of the floor function and can be used to characterize
it.
⌊x + m⌋ = ⌊x⌋ + m for all integers m.
This seems simple, but it's a key property. It states that if you shift the input by an integer m, the
output shifts by the same integer m. This is what creates the "step" pattern in its graph.
---
4. An Important Inequality
This is essential for bounding expressions involving the floor function.
x - 1 < ⌊x⌋ ≤ x
This follows directly from the definition n ≤ x < n+1 where n = ⌊x ⌋. It's incredibly useful in analysis
and limit proofs.
---
5. A Non-Trivial Application: Sum of Digits
A famous "strong" use of the floor function is in finding the sum of the digits of a number. For a
positive integer k written in base 10, the sum of its digits S(k) can be expressed as:
S(k) = k - 9 * Σᵢ [⌊k / 10ⁱ⌋]
where the sum is taken overi from 1 to the number of digits in k.
This formula works because ⌊k/10⌋ is the number of times the tens digit contributes, ⌊k/100 ⌋ is
the number of times the hundreds digit contributes, etc.
Example (Simplified): The number of times the digit '1' appears in the units place from 1 to n is
given by ⌊(n+9)/10⌋.
These equations and identities demonstrate the depth and utility of the seemingly simple
greatest integer function. They are the "strong" tools needed to work with it effectively in
mathematics, computer science, and number theory.
Example 1: Basic Function Evaluation
Problem: Evaluate the following:
1. ⌊4.7⌋
2. ⌊-3.2⌋
3. ⌊8⌋
4. ⌊-5.9⌋
Solution:
1. ⌊4.7⌋ = 4 (The greatest integer ≤ 4.7 is 4)
2. ⌊-3.2⌋ = -4 (The greatest integer ≤ -3.2 is -4, not -3)
3. ⌊8⌋ = 8 (Integer inputs give themselves)
4. ⌊-5.9⌋ = -6 (The greatest integer ≤ -5.9 is -6)
---
Example 2: Solving Equations
Problem: Solve for x: ⌊2x + 1⌋ = 5
Solution:
1. By definition: 5 ≤ 2x + 1 < 6
2. Subtract 1 from all parts: 4 ≤ 2x < 5
3. Divide by 2: 2 ≤ x < 2.5
4. Answer: x ∈ [2, 2.5)
Verification:
· When x = 2: ⌊2(2) + 1⌋ = ⌊5⌋ = 5 ✓
· When x = 2.4: ⌊2(2.4) + 1⌋ = ⌊5.8⌋ = 5 ✓
· When x = 2.5: ⌊2(2.5) + 1⌋ = ⌊6⌋ = 6 ✗
---
Example 3: Word Problem - Taxi Fare
Problem: A taxi charges $3 for the first kilometer and $2 for each additional kilometer or part
thereof. Write a function for the fare F(d) for d kilometers and calculate the fare for 4.3 km.
Solution:
1. Function: F(d) = 3 + 2 × ⌊d - 1⌋ for d > 1
· Actually, since we charge for "part thereof," we need: F(d) = 3 + 2 × ⌊d ⌋ for d ≤ 1? Let's think
carefully:
· For any distance > 1 km, we count the first km as $3, then each additional complete or partial
km as $2
· Better: F(d) = 3 + 2 × ⌊d - 1⌋ doesn't work for partial kms
· Correct: F(d) = 3 + 2 × (⌈d⌉ - 1) or using floor: F(d) = 3 + 2 × ⌊d - 1 + ε⌋ where ε is very small
· Actually simplest: F(d) = 3 + 2 × ⌊d - 1⌋ if we only charge for complete additional kms, but
problem says "or part thereof"
· Therefore: F(d) = 3 + 2 × (⌊d⌋ - 1) + {2 if d - ⌊d⌋ > 0 else 0}
· Even better: F(d) = 3 + 2 × (⌈d⌉ - 1)
2. For d = 4.3 km:
· First km: $3
· Remaining: 4.3 - 1 = 3.3 km → charge for 4 additional kms (since "part thereof")
· Additional charge: 4 × $2 = $8
· Total: F(4.3) = 3 + 8 = $11
---
Example 4: Graphing and Domain Analysis
Problem: Graph y = ⌊x⌋ and determine its domain and range.
Solution:
1. Graph: Step function with:
· Horizontal segments at y = n for x ∈ [n, n+1)
· Closed circles at left endpoints, open circles at right endpoints
2. Domain: All real numbers (-∞, ∞)
3. Range: All integers {..., -3, -2, -1, 0, 1, 2, 3, ...}
---
Example 5: Limit Problems
Problem: Evaluate:
1. limₓ→₃⁺ ⌊x⌋
2. limₓ→₃⁻ ⌊x⌋
3. limₓ→₃ ⌊x⌋
Solution:
1. Right-hand limit (x → 3⁺):
· For x just greater than 3 (e.g., 3.001), ⌊x⌋ = 3
· ∴ limₓ→₃⁺ ⌊x⌋ = 3
2. Left-hand limit (x → 3⁻):
· For x just less than 3 (e.g., 2.999), ⌊x⌋ = 2
· ∴ limₓ→₃⁻ ⌊x⌋ = 2
3. Two-sided limit:
· Since limₓ→₃⁺ ⌊x⌋ ≠ limₓ→₃⁻ ⌊x⌋
· ∴ limₓ→₃ ⌊x⌋ does not exist
---
Example 6: Property Verification
Problem: Verify that ⌊x + n⌋ = ⌊x⌋ + n for integer n, using x = 2.7 and n = 4.
Solution:
1. Left side: ⌊2.7 + 4⌋ = ⌊6.7⌋ = 6
2. Right side: ⌊2.7⌋ + 4 = 2 + 4 = 6
3. Verification: 6 = 6 ✓
---
Example 7: Complex Expression
Problem: Evaluate ⌊⌊x⌋ + 0.5⌋ for x = 3.2 and x = 3.8
Solution:
1. For x = 3.2:
· Inner: ⌊3.2⌋ = 3
· Outer: ⌊3 + 0.5⌋ = ⌊3.5⌋ = 3
2. For x = 3.8:
· Inner: ⌊3.8⌋ = 3
· Outer: ⌊3 + 0.5⌋ = ⌊3.5⌋ = 3
Note: This expression effectively rounds x to the nearest integer toward zero.
---
Example 8: Inequality Solving
Problem: Solve ⌊2x - 1⌋ ≥ 3
Solution:
1. The inequality means: ⌊2x - 1⌋ = n where n ≥ 3
2. For each n ≥ 3: n ≤ 2x - 1 < n + 1
3. Add 1: n + 1 ≤ 2x < n + 2
4. Divide by 2: (n + 1)/2 ≤ x < (n + 2)/2
5. Union of all intervals:
· For n = 3: 2 ≤ x < 2.5
· For n = 4: 2.5 ≤ x < 3
· For n = 5: 3 ≤ x < 3.5, etc.
6. Combined solution: x ∈ [2, ∞)
---
Example 9: Number Theory Application
Problem: How many multiples of 7 are between 1 and 100?
Solution:
· Multiples of 7: 7, 14, 21, ..., 98
· The count = ⌊100/7⌋ = ⌊14.285...⌋ = 14
Verification: 7 × 14 = 98 ≤ 100, 7 × 15 = 105 > 100 ✓
---
Example 10: Piecewise Function
Problem: Express f(x) = ⌊x⌋ + ⌊-x⌋ as a piecewise function.
Solution:
1. Case 1: x is an integer
· ⌊x⌋ = x, ⌊-x⌋ = -x
· f(x) = x + (-x) = 0
2. Case 2: x is not an integer
· Let x = n + f where n ∈ ℤ, 0 < f < 1
· ⌊x⌋ = n
· ⌊-x⌋ = ⌊-n - f⌋ = -n - 1
· f(x) = n + (-n - 1) = -1
3. Piecewise definition:
```
{ 0 if x ∈ ℤ
f(x) = {
{ -1 if x ∉ ℤ
`
Challenge 1: Nested Floor Function
Problem: Solve for x: ⌊2⌊x⌋⌋ = 3
Solution:
1. Let n = ⌊x⌋, so n is an integer and n ≤ x < n+1
2. The equation becomes: ⌊2n⌋ = 3
3. This means: 3 ≤ 2n < 4
4. Divide by 2: 1.5 ≤ n < 2
5. Since n must be an integer, the only possibility is n = 2
6. But 2 does NOT satisfy 1.5 ≤ n < 2
7. Conclusion: No solution exists
---
Challenge 2: Floor with Quadratic
Problem: Solve: ⌊x² - 4x + 3⌋ = 0
Solution:
1. By definition: 0 ≤ x² - 4x + 3 < 1
2. Solve the inequality: x² - 4x + 3 < 1
· x² - 4x + 2 < 0
· Using quadratic formula: x = 2 ± √2
· So: 2 - √2 < x < 2 + √2
3. Solve the inequality: x² - 4x + 3 ≥ 0
· (x - 1)(x - 3) ≥ 0
· x ≤ 1 or x ≥ 3
4. Find intersection of both conditions:
· From (2): 2 - √2 ≈ 0.586 < x < 2 + √2 ≈ 3.414
· From (3): x ≤ 1 or x ≥ 3
· Solution: (2 - √2, 1] ∪ [3, 2 + √2)
---
Challenge 3: Trigonometric Floor Function
Problem: Find all x in [0, 2π] such that: ⌊2sin x⌋ = 1
Solution:
1. The equation means: 1 ≤ 2sin x < 2
2. Divide by 2: 0.5 ≤ sin x < 1
3. In [0, 2π], sin x ≥ 0.5 when:
· π/6 ≤ x ≤ 5π/6 (from unit circle)
4. But we need sin x < 1, so exclude points where sin x = 1
· sin x = 1 at x = π/2
5. Solution: [π/6, π/2) ∪ (π/2, 5π/6]
---
Challenge 4: System of Floor Equations
Problem: Solve the system:
1. ⌊x⌋ + ⌊y⌋ = 5
2. x + y = 7.2
Solution:
1. Let m = ⌊x⌋ and n = ⌊y⌋, so m + n = 5
2. Write x = m + a, y = n + b, where 0 ≤ a, b < 1
3. Then: (m + a) + (n + b) = 7.2
4. But m + n = 5, so: 5 + a + b = 7.2 ⇒ a + b = 2.2
5. This is impossible since 0 ≤ a, b < 1 ⇒ 0 ≤ a + b < 2
6. Wait! Let's check: a + b = 2.2, but maximum a + b < 2
7. Conclusion: No solution exists
---
Challenge 5: Self-Referential Floor Equation
Problem: Solve: ⌊x⌊x⌋⌋ = 8
Solution:
1. Let n = ⌊x⌋, so n ≤ x < n+1
2. The equation becomes: ⌊n·x⌋ = 8
3. Since n ≤ x < n+1, then: n² ≤ n·x < n(n+1)
4. So: n² ≤ ⌊n·x⌋ < n(n+1)
5. But ⌊n·x⌋ = 8, so: n² ≤ 8 < n(n+1)
6. Test integer values:
· n = 2: 4 ≤ 8 < 6? No
· n = 3: 9 ≤ 8 < 12? No (9 ≤ 8 is false)
· n = -4: 16 ≤ 8 < 12? No
7. Let's solve systematically:
· n² ≤ 8 ⇒ n ≤ 2√2 ≈ 2.828 ⇒ n ≤ 2
· 8 < n(n+1)
· n = 2: 8 < 6? No
· n = 3: 8 < 12? Yes, but n ≤ 2
8. Wait, maybe n is negative?
· If n is negative, n² is positive, but n·x could be negative
· Let's consider negative cases:
· n = -3: n² = 9 ≤ 8? No
· n = -2: n² = 4 ≤ 8? Yes, and 8 < (-2)(-1) = 2? No
9. Conclusion: No integer n satisfies both inequalities
10. Therefore: No solution exists
---
Challenge 6: Floor with Logarithm
Problem: Find all real x satisfying: ⌊log₂(x)⌋ = 3
Solution:
1. The equation means: 3 ≤ log₂(x) < 4
2. Rewrite using exponential: 2³ ≤ x < 2⁴
3. Solution: 8 ≤ x < 16
The equation ⌊log₂(x)⌋ = 3 means that the floor of the logarithm base 2 of x is 3. By the definition
of the floor function, this implies:
3 \leq \log_2(x) < 4
To solve for x, we exponentiate all parts of the inequality using base 2. Since the exponential
function is increasing, the inequality direction remains unchanged:
2^3 \leq x < 2^4
Which simplifies to:
8 \leq x < 16
Thus, the solution set for x is the interval [8, 16). This means x includes 8 but excludes 16.
Verification:
· When x = 8, \log_2(8) = 3, so \lfloor 3 \rfloor = 3.
· When x = 15, \log_2(15) \approx 3.906, so \lfloor 3.906 \rfloor = 3.
· When x = 16, \log_2(16) = 4, so \lfloor 4 \rfloor = 4, which does not satisfy the equation.
Therefore, all real x in the interval [8, 16) satisfy the equation
Challenge 7: Double Inequality with Floor
Problem: Solve: 1 ≤ ⌊2x + 1⌋ < 4
Solution:
1. Break into two inequalities:
· ⌊2x + 1⌋ ≥ 1 ⇒ 1 ≤ 2x + 1 < 2? No, careful!
· Actually: ⌊y⌋ ≥ 1 means y ≥ 1 (since if y were between 1 and 2, floor could be 1)
· More precisely: ⌊y⌋ ≥ 1 ⇔ y ≥ 1 (because if y < 1, floor would be ≤ 0)
· Similarly: ⌊y⌋ < 4 ⇔ y < 4
2. So we have: 1 ≤ 2x + 1 < 4
3. Subtract 1: 0 ≤ 2x < 3
4. Divide by 2: 0 ≤ x < 1.5
5. Solution: [0, 1.5)
---
Challenge 8: Functional Equation
Problem: Find all functions f: ℝ → ℝ such that: f(x) = ⌊x + f(x)⌋ for all x
Solution:
1. Let f(x) = ⌊x + f(x)⌋ = n (an integer)
2. Then: n ≤ x + f(x) < n + 1
3. But f(x) = n, so: n ≤ x + n < n + 1
4. Simplify: 0 ≤ x < 1
5. This must hold for ALL x, which is impossible unless we reconsider
6. Alternate approach: The equation means f(x) is an integer and f(x) ≤ x + f(x) < f(x) + 1
7. Simplify: 0 ≤ x < 1 for ALL x, which is false
8. Conclusion: No such function exists (except possibly the zero function, but that doesn't work
either)
---
Challenge 9: Limit with Floor
Problem: Evaluate: limₓ→₂ (x² - ⌊x²⌋)/(x - 2)
Solution:
1. Need to consider left and right limits separately
2. Right limit (x → 2⁺):
· For x just greater than 2, x² just greater than 4
· So ⌊x²⌋ = 4
· Expression becomes: (x² - 4)/(x - 2) = (x - 2)(x + 2)/(x - 2) = x + 2
· Limit = 2 + 2 = 4
3. Left limit (x → 2⁻):
· For x just less than 2, x² just less than 4
· So ⌊x²⌋ = 3
· Expression becomes: (x² - 3)/(x - 2)
· As x → 2⁻, numerator → 1, denominator → 0⁻
· Limit = -∞
4. Conclusion: The limit does not exist (finite from right, infinite from left)
These challenging problems demonstrate the depth and subtlety of the greatest integer function,
requiring careful analysis of domains, inequalities, and edge cases.