MATH 1 • ALGEBRA & FUNCTIONS

Constructing Functions from Context — I can construct a function that models a relationship between two quantities in a context.

Learn to translate real-world situations into algebraic functions that predict, model, and explain quantitative relationships.

Historical Context & Motivation

Humans have been describing relationships between quantities for thousands of years, but the formal idea of a function — a rule that assigns exactly one output to every input — took centuries to develop. Ancient Babylonian scribes recorded tables showing how crop yields changed with the amount of land planted, and Greek astronomers tracked how the position of stars shifted with the time of year. These early thinkers recognized patterns between two changing quantities, even though they lacked modern notation to express them.

The journey from pattern-spotting to function-writing shaped the way we do science, economics, and engineering today. Each milestone below marks a moment when mathematicians found a better way to capture real-world relationships in symbolic form.

~1600 BCE
Babylonian Tables
Clay tablets recorded relationships between quantities such as area and side length, effectively creating early input-output tables for quadratic relationships.
1637
Descartes & Coordinate Geometry
René Descartes connected algebra and geometry by plotting equations on a coordinate plane, allowing relationships between two quantities to be visualized as curves.
1748
Euler Formalizes f(x)
Leonhard Euler introduced the notation f(x) in his textbook, giving mathematicians a compact way to express that a rule assigns an output to each input.
1830s
Dirichlet's Modern Definition
Peter Gustav Lejeune Dirichlet defined a function as any rule that pairs each element of one set with exactly one element of another, broadening the concept beyond simple formulas.
Today
Functions Everywhere
From smartphone pricing plans to climate models, functions are the universal language used to describe how one quantity depends on another in virtually every field.

The central question this lesson addresses is both timeless and practical: When you encounter a real-world situation involving two related quantities, how do you construct an algebraic function that accurately models that relationship? Mastering this skill turns you from someone who reads about math into someone who uses math to solve genuine problems.

Core Principles & Definitions

Before you can build a function from a real-world context, you need a clear understanding of what a function actually is and what ingredients go into constructing one. The following foundational ideas will guide every function you write in this course and beyond.

1

Identify the Quantities

Every function starts with two quantities. The independent variable (input) is the quantity you control or that changes naturally, while the dependent variable (output) is the quantity that responds.
2

Determine the Relationship Type

Ask: does the output change by a constant amount (linear), a constant ratio (exponential), or some other pattern? The type of change dictates the form of your function.
3

Extract Key Values

Look for initial values, rates of change, and any fixed constants. These numbers become the coefficients, slopes, intercepts, and bases in your equation.
4

Write the Function Rule

Assemble the algebraic expression using the correct model (e.g., f(x) = mx + b for linear). Define your variables clearly so the function communicates meaning.
5

Verify with Context

Substitute a known value back into your function. If the output matches the situation described, your model is valid. If not, revisit your assumptions.
KEY TAKEAWAY
Think of constructing a function like writing a recipe. The ingredients are the quantities and numbers you pull from the context, the cooking method is the type of function (linear, exponential, etc.), and the finished dish is an equation that lets you predict new outputs for any input. If you mix up the ingredients or choose the wrong method, the dish won't come out right — and the function won't model the situation accurately.

Visual Explanation — From Words to Functions

The diagram below illustrates the complete workflow for turning a word problem into a working function. Follow the flow from left to right: you begin with a real-world context, extract the mathematical ingredients, choose the correct function type, write the rule, and then verify your answer.

This flowchart shows the five-step process: read the context, define variables, identify the pattern of change, write the function rule, and verify by substituting a known value.

Notice that the process is not purely mechanical. Step 3, identifying the pattern, requires you to decide what type of function fits the situation. A constant rate of change signals a linear function, while a constant multiplier or percentage change signals an exponential function. As you gain experience, this pattern recognition becomes faster and more intuitive.

Mathematical Framework

Most real-world contexts you encounter in Math 1 can be modeled with one of two major function types. Understanding the structure of each model — what each symbol represents and how to find its value — is the key to writing correct functions from context.

LINEAR FUNCTION
f(x) = mx + b
Where m is the rate of change (slope) — the constant amount the output changes for each unit increase in x, and b is the initial value (y-intercept) — the output when x = 0.

Linear functions describe situations where a quantity increases or decreases by the same amount over equal intervals. Context clues include phrases like "per hour," "each month," "for every additional," or "at a constant rate." When you see these phrases, the number that follows is typically the slope m, and any starting amount is the y-intercept b.

EXPONENTIAL FUNCTION
f(x) = a · bˣ
Where a is the initial amount (the output when x = 0), and b is the growth or decay factor. If b > 1 the function grows; if 0 < b < 1 the function decays.

Exponential functions describe situations where a quantity is multiplied by the same factor over equal intervals. Context clues include "doubles every," "decreases by 10% each year," or "triples." A percentage increase of r% means b = 1 + r/100, and a percentage decrease of r% means b = 1 − r/100.

SLOPE FROM TWO POINTS
m = (y₂ − y₁) / (x₂ − x₁)
Use this when the context gives you two data points instead of stating the rate directly. The points are (x₁, y₁) and (x₂, y₂).
⚠️ Common Pitfall
Don't confuse a constant amount of change (linear) with a constant percentage of change (exponential). "Increasing by $50 per month" is linear, but "increasing by 5% per month" is exponential, even though both use the word "per month."

Comparing Linear & Exponential Models

The diagram below plots a linear function and an exponential function side by side on the same coordinate plane. Both start at the same initial value, but their behaviors diverge dramatically. Understanding this visual difference helps you decide which model to use when constructing a function from context.

The solid blue line represents a linear function growing by 25 units per year. The dashed pink curve represents an exponential function growing by a factor of 1.3 each year. Both start at 50 when x = 0, but the exponential curve overtakes the linear function and accelerates away.
Side-by-side comparison of linear and exponential function features
FeatureLinear FunctionExponential Function
General Formf(x) = mx + bf(x) = a · bˣ
Type of ChangeConstant amount (add/subtract)Constant factor (multiply/divide)
Graph ShapeStraight lineCurve (concave up or down)
Context Clue Words"per," "each," "constant rate""doubles," "% increase," "half-life"
Initial Valueb (y-intercept)a (coefficient)

Worked Example — Building a Function Step by Step

A streaming music service charges a one-time sign-up fee of $12 plus $8 per month for a subscription. Write a function C(m) that gives the total cost in dollars after m months.

Streaming Service Cost Function
1
Step 1 — Identify the Two QuantitiesThe two quantities are the number of months (m) and the total cost C(m). The number of months is the independent variable because it is what changes over time. The total cost depends on how many months you subscribe.
2
Step 2 — Determine the Relationship TypeThe cost increases by a constant $8 every month. A constant amount of change means the relationship is linear. We will use the form C(m) = slope × m + initial value.
3
Step 3 — Extract Key ValuesThe rate of change (slope) is $8 per month. The initial value (y-intercept) is the $12 sign-up fee, which is the cost at m = 0.
m = 8, b = 12
4
Step 4 — Write the Function RuleSubstituting the slope and y-intercept into the linear form gives us:
C(m) = 8m + 12
5
Step 5 — Verify with ContextAfter 3 months, the total cost should be the $12 sign-up fee plus 3 × $8 = $24 in monthly fees, for a total of $36. Let's check: C(3) = 8(3) + 12 = 24 + 12 = 36. ✓ The function matches the situation.
C(3) = 36 ✓

Now let's try an exponential context. A biology student counts 200 bacteria in a petri dish. The population doubles every 3 hours. Write a function P(t) that gives the population after t three-hour periods.

Bacteria Growth Function
1
Step 1 — Identify the Two QuantitiesThe independent variable is the number of three-hour periods (t) and the dependent variable is the bacteria population P(t).
2
Step 2 — Determine the Relationship Type"Doubles every 3 hours" means the population is multiplied by the same factor (2) over equal intervals. This is exponential growth. The model is P(t) = a · bᵗ.
3
Step 3 — Extract Key ValuesThe initial population is a = 200, and the growth factor is b = 2 (doubling).
a = 200, b = 2
4
Step 4 — Write the Function RuleSubstituting into the exponential form:
P(t) = 200 · 2ᵗ
5
Step 5 — Verify with ContextAfter 2 three-hour periods (6 hours), the population should have doubled twice: 200 → 400 → 800. Check: P(2) = 200 · 2² = 200 · 4 = 800. ✓
P(2) = 800 ✓

Strengths & Limitations of Function Models

Constructing a function from context is a powerful skill, but every model is a simplification of reality. Recognizing the strengths and limitations of your function helps you use it wisely and understand when it might break down.

Strengths and limitations of constructing functions from context
StrengthsLimitations
Functions let you predict outputs for inputs you haven't observed yet.Predictions may be inaccurate outside the range of data that inspired the model (extrapolation risk).
A single equation summarizes an entire pattern concisely.Real-world situations may switch behaviors (e.g., linear for a while, then leveling off), so one function may not fit forever.
Functions can be graphed, giving a visual picture of how quantities relate.Context assumptions (like constant rate of change) may only be approximately true.
Function notation f(x) clearly communicates what depends on what.Choosing the wrong function type (linear vs. exponential) can give wildly wrong predictions.
KEY TAKEAWAY
A function model is like a weather forecast: it uses patterns from known data to make useful predictions, but it isn't perfect. The further you predict into the future (or outside your data), the less reliable the forecast becomes. Always ask yourself, "Does this prediction still make sense in the real-world context?"

Connection to Advanced Topics

The function-building skills you learn in this lesson are the foundation for nearly every future math and science course. As you progress, the types of functions you construct will become more complex, but the core process — identify quantities, determine the pattern, write the rule, and verify — remains the same.

How today's skills connect to future coursework
What You Learn NowWhere It Leads
Linear functions f(x) = mx + bSystems of linear equations, linear regression, and lines of best fit in statistics
Exponential functions f(x) = a · bˣLogarithmic functions, compound interest formulas, and differential equations in calculus
Identifying independent and dependent variablesMultivariable functions and scientific experimental design
Verifying a function with known valuesResidual analysis and model evaluation in data science

In Algebra 2 and Precalculus, you will encounter quadratic, polynomial, rational, and trigonometric functions. Each follows a different pattern of change, but you will always use the same five-step approach to construct them from context. Mastering this process now builds a framework you will rely on for years to come.

Practice Problems

PROBLEM 1CONCEPTUAL
A student says, "My savings account earns $15 every month, so the relationship is exponential because my money keeps growing." Explain why the student's reasoning is incorrect and identify the correct function type.
PROBLEM 2BASIC CALCULATION
A taxi company charges a flat fee of $3.50 plus $2.25 per mile driven. Write a function C(d) that represents the total cost in dollars for a ride of d miles. Then calculate the cost of a 7-mile ride.
PROBLEM 3INTERMEDIATE
A car is purchased for $22,000 and loses 15% of its value each year due to depreciation. Write a function V(t) for the car's value after t years. What is the car worth after 4 years? Round to the nearest dollar.
PROBLEM 4APPLIED
A local gym offers two membership plans. Plan A charges $40 per month with no sign-up fee. Plan B charges $25 per month with a one-time sign-up fee of $120. Write a function for each plan giving the total cost after m months, then determine after how many months Plan B becomes the cheaper option.
PROBLEM 5CRITICAL THINKING
A town's population was 8,000 in 2010 and 9,200 in 2015. A student models the population with a linear function, and another student uses an exponential function. Write both models (let t = years since 2010). Then explain which model would likely give a more realistic prediction for the year 2050 and why.

Lesson Summary

Constructing a function from context is a five-step process. You begin by identifying the independent and dependent variables — the input you control and the output that responds. Next, you determine whether the relationship is linear or exponential by asking whether the output changes by a constant amount (linear: f(x) = mx + b) or a constant factor (exponential: f(x) = a · bˣ). You then extract key values such as rates of change, initial amounts, and growth factors from the context's language and data.

Once you assemble the equation, always verify your function by substituting a known value to confirm the output matches the scenario. Remember that every function model is an approximation — it works well within the context's conditions but may become unreliable for extreme inputs. The context clue words ("per," "each," "doubles," "% change") are your best friends for choosing the correct function type. Master these steps now, and you will have a framework that extends to every type of function you encounter in future mathematics courses.

Varsity Tutors • Math 1 • Constructing Functions from Context