Step Function Intuition Examples: 45 Problems with Answers

Worked examples of Step Function Intuition to try before you open each solution, then practice problems with answers.

Worked Examples

Example 1

easy
Evaluate the floor function f(x)=⌊x⌋ at x=3.7, x=−2.1, and x=5. Then describe the graph on [0,4].
Show solution

Answer

⌊3.7⌋=3; ⌊−2.1⌋=−3; ⌊5⌋=5

First step

1.
⌊3.7⌋=3 (greatest integer ≤3.7).

Full solution

  1. 2.
    ⌊−2.1⌋=−3 (greatest integer ≤−2.1 is −3, not −2).
  2. 3.
    ⌊5⌋=5. Graph on [0,4]: horizontal steps at heights 0,1,2,3. Each step spans a half-open interval [n,n+1) with a closed left endpoint and open right endpoint.
The floor function always rounds down toward −∞. For negative numbers, this means ⌊−2.1⌋=−3, not −2, because −3≤−2.1<−2.

Example 2

medium
A parking garage charges $3 for the first hour (or part thereof) and $2 for each additional hour (or part). Write and evaluate the cost function for t=0.5, 1, 1.2, and 3.9 hours.

Example 3

medium
Let f(x)=⌊x/2⌋. Find all x∈[0,6) where f(x)=2.

Example 4

medium
A rideshare charges $2.50 for the first 5 minutes (or part) and $1 for each started 5-minute block after. Cost for a 13-minute trip?

Example 5

medium
A movie ticket service charges $10 for 0-1 ticket, $18 for 2 tickets, $24 for 3, then $5 per additional ticket. Cost for 5 tickets?

Example 6

hard
Find all integers n in [1,30] such that ⌊n/3⌋=⌊n/4⌋.

Practice Problems

Try each one, then open the solution to compare your method.

Example 1

easy
Evaluate: (a) ⌊7.9⌋, (b) ⌈4.1⌉, (c) ⌊−0.5⌋, (d) ⌈−3.2⌉.

Example 2

hard
Define f(x)=⌊2x⌋. Find all x in [0,2] where f(x)=3, and sketch f on [0,2].

Example 3

easy
Evaluate the floor function ⌊3.7⌋.

Example 4

easy
Evaluate ⌊5⌋.

Example 5

easy
A parking garage charges $4 for any time up to 1 hour, $8 up to 2 hours. Cost for 1.5 hours?

Example 6

easy
Does a step function's graph have sloped segments?

Example 7

easy
Is a step function continuous at its jump points?

Example 8

easy
Evaluate ⌊−1.2⌋.

Example 9

easy
Postage is $1 for up to 1 oz, $2 for up to 2 oz. Cost for exactly a 1 oz letter (boundary included in first tier)?

Example 10

easy
How many distinct values does a 3-step function take?

Example 11

medium
Define f(x)=⌊x⌋. Find f(2.9)+f(3.1).

Example 12

medium
A taxi charges $3 base plus $2 for each started mile (round up). Cost for 2.3 miles?

Example 13

medium
At a jump from value 2 to 5 at x=4, with the left piece including x=4, find f(4).

Example 14

medium
Grades: A for ≥90, B for ≥80. A score of 80 earns what?

Example 15

medium
How many jumps does f(x)=⌊x⌋ have on the interval [0,3)?

Example 16

medium
A step function is $5 for 0≤x<2 and $9 for 2≤x<4. Find the total jump size at x=2.

Example 17

medium
Why can't you draw a step function without lifting your pencil?

Example 18

medium
Evaluate ⌊2.5⌋+⌈2.5⌉.

Example 19

challenge
Shipping: $5 for the first pound, $3 for each additional started pound. Cost for a 3.2 lb package?

Example 20

challenge
For f(x)=⌊2x⌋, find all jump points in [0,2).

Example 21

challenge
A cell-phone plan: $30 for up to 2 GB, then $10 per started GB beyond. Cost for 4.5 GB?

Example 22

medium
How many $1 stamps does a 3.4 oz letter need if each oz (rounded up) needs one stamp?

Example 23

easy
Evaluate ⌊0⌋.

Example 24

easy
Evaluate ⌊−3.5⌋.

Example 25

easy
Evaluate ⌈−2.3⌉.

Example 26

easy
True or false: the graph of a step function consists of horizontal segments.

Example 27

easy
Evaluate ⌊9.9⌋−⌊9.1⌋.

Example 28

medium
How many jumps does f(x)=⌊3x⌋ have on [0,1)?

Example 29

medium
Evaluate ⌊π⌋+⌈π⌉.

Example 30

medium
For f(x)=⌊x⌋, sketch on [−2,2) and list the value on each step.

Example 31

medium
Income tax: 10% on income up to $10,000, 20% flat on the bracket $10,001-$30,000 (whole bracket, not marginal). What does this rate function look like at $15,000?

Example 32

medium
A boundary-included-on-left step function jumps from 5 to 9 at x=3. What is f(3)?

Example 33

medium
If f(x)=⌊x⌋, compute f(2.999)+f(3)+f(3.001).

Example 34

hard
Solve ⌊x⌋=x−0.4 for real x.

Example 35

hard
Define f(x)=⌈x2⌉. Find f(1.4) and f(5).

Example 36

hard
A parking meter charges $0.50 per started 15 minutes. Cost for a 52-minute park?

Example 37

hard
Is f(x)=⌊x⌋ left-continuous, right-continuous, or neither at each integer?

Example 38

hard
A photocopy shop charges $0.10 per page for the first 50 pages and $0.07 per page after. Cost for 80 pages?

Example 39

challenge
Find ∑k=1100⌊k⌋.

What to focus on

Core idea: A step function holds one constant value across a whole interval, then leaps to a new value at the boundary.

Common stuck point: The procedure for step function intuition is the easy part; the trap is interpolating between steps. Asking "Is the output constant within each interval and changing only by sudden jumps at boundaries?" first is what keeps a correct-looking calculation from being attached to the wrong concept.

Ask yourself: Is the output constant within each interval and changing only by sudden jumps at boundaries?

Concept recap

A step function is piecewise constant — it takes a fixed value on each of several intervals, jumping abruptly at the interval boundaries.

A staircase seen from the side: you stay at one height along the whole tread and rise all at once at the riser, so walking further along a tread never lifts you. Unlike a real staircase, a step function can also step down, and it takes no value partway up the riser.

Read the full lesson on Step Function Intuition

Related concepts

Background knowledge

These ideas may be useful before you work through the harder examples.

piecewise function