Piecewise-defined function in AP Pre-Calculus

A piecewise-defined function is a single function built from different expressions on different intervals of its domain. In AP Precalculus (Topic 1.14), you construct one when a data set or contextual scenario follows different patterns in different regions, like a rate that changes after a cutoff.

Verified for the 2027 AP Pre-Calculus examLast updated June 2026

What is piecewise-defined function?

A piecewise-defined function is one function with multiple rules. Each rule applies only on its own piece of the domain, so the function might behave linearly for small inputs, quadratically for middle inputs, and constantly after some cutoff. The key idea is that the context tells you where one rule ends and the next begins.

In AP Precalculus, this shows up as a modeling move, not just a notation skill. The CED (1.14.B) says a piecewise-defined function model can be constructed through a combination of modeling techniques. Translation: you might use linear regression on one chunk of data, a quadratic model on another chunk, and stitch them together at the boundary values. You're choosing the function type for each region based on the pattern in the data, which is exactly what learning objective 1.14.A asks you to do.

Why piecewise-defined function matters in AP® Precalculus

Piecewise-defined functions live in Topic 1.14 (Function Model Construction and Application) in Unit 1: Polynomial and Rational Functions. They directly support learning objective 1.14.A (construct a linear, quadratic, cubic, quartic, polynomial, or related piecewise-defined function model) and 1.14.B (use a function model to answer questions about a contextual scenario). They matter because real situations rarely follow one clean rule the whole way through. A parking garage charges one rate for the first two hours and a different rate after that. A delivery fee is flat up to a weight limit, then increases per pound. When the pattern in the data changes at a specific input value, a single polynomial won't capture it, and a piecewise model will. That judgment call, picking the right model type for the context, is the core skill Topic 1.14 tests.

How piecewise-defined function connects across the course

Regression analysis (Unit 1)

Regression fits one function type to one data set. A piecewise model is what you build when no single regression fits everything, so you run separate regressions on separate regions and join them. Piecewise modeling is regression with a 'this pattern stops here' boundary.

Quadratic and cubic regression (Unit 1)

Each piece of a piecewise model can come from a different regression. Data might look linear at first and then curve, so you'd use a linear rule on one interval and a quadratic or cubic regression on the next. The pieces are the standard Unit 1 model types; piecewise is just the container.

Rational function models and inverse proportionality (Unit 1)

Topic 1.14 also covers rational models for inversely proportional quantities (LO 1.14.C), like gravitational force versus squared distance. On the exam, your first job in a modeling question is deciding which model type fits the context, and piecewise is the answer specifically when the pattern switches at a known input value.

Average rates of change in applied models (Unit 1)

LO 1.14.D asks you to pull predictions and rates of change out of a model, with correct units. With a piecewise model, the rate of change can be different on each piece, which is often the whole point. The parking garage costs $3 per hour on one interval and $2 per hour on another, and you need to read the right rate off the right piece.

Is piecewise-defined function on the AP® Precalculus exam?

Piecewise-defined functions show up in modeling questions where the scenario has a built-in cutoff. A classic stem describes a parking garage that charges $5 for the first 2 hours, $3 per hour for hours 3 through 6, and $2 per hour after 6 hours, then asks which function type best models total cost. The answer is piecewise, because the rate changes at specific input values. Multiple-choice questions also test whether you know what a piecewise function is (one function, multiple rules on non-overlapping domain pieces) and which techniques are used to build one (combining regressions and transformations of parent functions, per EK 1.14.B). On free-response modeling tasks, expect to construct the model from a context, evaluate it at a given input by choosing the correct piece, and interpret a value or rate of change with units. Picking the wrong piece for a boundary input is the most common point-loser, so check the inequality on each domain interval carefully.

Piecewise-defined function vs Composite function

A composite function chains two functions together, feeding the output of one into the input of the other, and the same chained rule applies to every input. A piecewise-defined function never chains anything. It assigns different standalone rules to different intervals of the domain, and which rule you use depends only on where your input value falls. If the question says 'first apply f, then apply g,' that's composition. If it says 'one rule before x = 2 and a different rule after,' that's piecewise.

Key things to remember about piecewise-defined function

  • A piecewise-defined function is one single function whose rule changes depending on which interval of the domain the input falls in.

  • In Topic 1.14, you build a piecewise model when data or a context shows different patterns in different regions, like a price rate that changes after a cutoff hour.

  • The CED says piecewise models are constructed through a combination of modeling techniques, so each piece can come from its own regression or its own transformed parent function.

  • To evaluate a piecewise function, first locate which interval your input belongs to, then use only that piece's expression.

  • Each piece can have its own rate of change, so when a question asks for a rate or average rate of change, make sure you're reading it from the correct interval and attaching correct units.

Frequently asked questions about piecewise-defined function

What is a piecewise-defined function in AP Precalculus?

It's a single function defined by different expressions on different intervals of its domain. In Topic 1.14, you use one to model a data set or scenario where the pattern changes at specific input values, like a parking garage with different hourly rates before and after hour 6.

Is a piecewise function actually more than one function?

No. It's exactly one function with one output per input. It just uses different rules on different, non-overlapping parts of the domain. The pieces together still pass the vertical line test.

How is a piecewise function different from a composite function?

A composite function applies two functions in sequence (g of f of x) to every input. A piecewise function applies different separate rules to different intervals of the domain, with no chaining. Composition is 'do this, then that'; piecewise is 'use this rule here, that rule there.'

How do I know when a context needs a piecewise model on the AP exam?

Look for a rate or rule that changes at a specific input value. Phrases like '$5 for the first 2 hours, then $3 per hour' signal that no single linear, quadratic, or rational function will work, so a piecewise-defined function is the best model type.

Do piecewise functions have to be discontinuous?

No. The pieces can meet perfectly at the boundary values, making the graph one connected curve. Many modeling contexts are designed so the pieces match up at the cutoffs, like a total cost that keeps accumulating smoothly even as the hourly rate changes.