Function Modelling
A model is a function that describes a real situation well enough to answer questions about it: how low will the tire pressure be by tomorrow, when will the tea be cool enough to drink, how many people will live here in ten years? This lesson pulls together every function type in the course. You’ll choose a type that fits the data, build the equation from a few key points, check whether it’s reasonable, and use it to predict. Trig functions here use radians.
Key ideas
Section titled “Key ideas”The modelling cycle
Section titled “The modelling cycle”- Look at the data. Plot it, or study the table. Is it increasing, decreasing, or repeating? Does it level off?
- Choose a type. Use the fingerprints from comparing function types and what you know about the situation.
- Find the parameters from key points: the starting value, a maximum or minimum, a period, a ratio.
- Check the fit. Compare the model’s values with the data. The differences (data minus model) are called residuals; for a good model they’re small and don’t follow an obvious pattern.
- Use and interpret. Predict values, answer the question, and explain what each parameter means in context.
- Think about limits. Is the model reasonable for the inputs you’re using? Predictions far outside the data (extrapolation) are much riskier than predictions inside it (interpolation).
Choosing a type
Section titled “Choosing a type”| The situation or data shows… | Try… |
|---|---|
| a constant rate of change; constant first differences | linear: |
| constant second differences; one maximum or minimum (like a projectile) | quadratic: |
| constant ratios; growth or decay by a percentage | exponential: |
| levelling off toward a value other than (like cooling) | shifted exponential: |
| a repeating cycle (tides, seasons, rotation) | sinusoidal: with |
| constant third (or higher) differences; volumes and other products | polynomial of higher degree |
Context matters as much as the numbers. A slow leak loses a percentage of what’s left, so it’s exponential, not linear. A volume made by multiplying three lengths is a cubic.
Technology and regression
Section titled “Technology and regression”Graphing technology can fit a curve of any chosen type to all the data at once (this is called regression), and it can graph residuals. That’s how scientists usually do it. But choosing the type and judging whether the result makes sense is still your job. In the examples below, the models are built by hand from key points, which is often accurate enough and shows exactly where each number comes from.
Worked examples
Section titled “Worked examples”Example 1: A slow leak
Section titled “Example 1: A slow leak”A car tire has a slow leak. Its pressure is measured every hours.
| Time (h) | |||||
|---|---|---|---|---|---|
| Pressure (kPa) |
- (a) Decide whether a linear or an exponential model fits better, and build it.
- (b) Predict the pressure after hours.
- (c) The tire is unsafe below kPa. When does that happen?
Solution.
(a) The differences are : not constant, and shrinking. The ratios are
all very close to . So the tire loses about of its pressure every hours, and an exponential model fits. It makes physical sense too: the higher the pressure, the faster air is pushed out.
Start at and multiply by for every hours, which is two-hour periods:
Check the fit: the model gives , , and at . Every residual is less than kPa. ✓
(b) kPa.
(c) Solve with logarithms:
The tire becomes unsafe after about hours. (A linear model, losing about kPa per hour on average, would predict the pressure reaching after about a day, which isn’t how leaks behave.)
Example 2: Cooling tea
Section titled “Example 2: Cooling tea”A cup of tea is left in a room at .
| Time (min) | |||||
|---|---|---|---|---|---|
| Temperature (°C) |
- (a) Build a model for the temperature.
- (b) Predict the temperature after minutes, and say when the tea reaches .
Solution.
(a) The ratios of the temperatures aren’t constant ( but ). But the tea can’t cool below room temperature, so look at how far it is above :
| (min) | |||||
|---|---|---|---|---|---|
Now the ratios are constant: , and . The temperature difference shrinks by every minutes:
The is the room temperature (the horizontal asymptote), and the is the starting difference.
(b) .
For , solve :
The tea reaches after about minutes. A plain exponential would wrongly predict the tea cooling toward , colder than the room.
Example 3: Most economical speed
Section titled “Example 3: Most economical speed”A test driver measures a car’s fuel consumption at different speeds.
| Speed (km/h) | |||||
|---|---|---|---|---|---|
| Consumption (L/100 km) |
Build a model, and find the most economical speed.
Solution. The data falls and then rises, which suggests a quadratic. Check the differences (the speeds go up in equal steps of ):
- First differences:
- Second differences:
Constant second differences confirm a quadratic . For steps of size , the second difference is , so , giving and .
Now use two data points to find and :
Subtracting the first equation from the second: , so . Then .
Check: . ✓
The minimum is at the vertex:
The car is most economical at about km/h, using about L per km. The model only makes sense for realistic speeds: it would predict L/100 km at km/h, which is meaningless for a parked car.
Example 4: Monthly temperatures in radians
Section titled “Example 4: Monthly temperatures in radians”The average monthly temperatures for a Canadian city are shown (month is January).
| Month | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Temp. (°C) |
Build a sinusoidal model, check its fit, and use it to estimate the temperature in mid-April ().
Solution. Maximum (July), minimum (January), and the cycle repeats every months.
- Amplitude:
- Axis:
- The maximum is at , so use cosine with .
Check the fit for a few months (model values to 1 decimal place):
| Month | ||||||
|---|---|---|---|---|---|---|
| Data | ||||||
| Model | ||||||
| Residual |
The residuals are all under , so the model fits well.
Mid-April: .
Common mistakes
Section titled “Common mistakes”Choosing a type from one or two numbers. Check differences and ratios across the whole table, and think about the situation. A leak or a cooling drink is exponential even if the first few values look nearly linear.
Forgetting the shift in cooling and heating. Objects cool toward room temperature, not toward . Model the difference from room temperature exponentially, then add the room temperature back.
Using the wrong exponent for the time step. If the ratio is per hours, the exponent is , not . Check: after hours, . ✓
Trusting extrapolation. A model that fits data from to km/h says nothing reliable about or km/h. State the inputs for which the model is reasonable.
Using degrees in a radian model. With , your calculator must be in radian mode. (In degrees you’d use instead, as in Grade 11.)
Not checking the fit. Always compare the model with at least a couple of data points you didn’t use to build it. Large or patterned residuals mean you should rethink the type.
Practice
Section titled “Practice”1. (Warm-up) Which type of function would you choose to model each situation? Explain briefly.
- (a) The height of the tide over two days.
- (b) The number of bacteria in a culture that doubles every hour.
- (c) A taxi fare with a fixed charge plus a fee per kilometre.
- (d) The volume of a box whose length, width and height all depend on .
Solution
(a) Sinusoidal: tides repeat in a regular cycle.
(b) Exponential: doubling means a constant ratio.
(c) Linear: the fare increases at a constant rate per kilometre.
(d) Polynomial (cubic): volume is a product of three expressions in .
2. (Warm-up) Is each table best modelled by a linear, quadratic, or exponential function?
| A | |||||
| B | |||||
| C |
Solution
A: first differences ; second differences . Quadratic.
B: ratios all . Exponential.
C: first differences all . Linear.
3. (Warm-up) A town’s population is modelled by , where is in years. Interpret and , and predict the population after years.
Solution
is the population at . means the population grows by per year.
people.
4. (Core) A town’s population is recorded every years.
| Year | |||||
|---|---|---|---|---|---|
| Population |
- (a) Show that an exponential model fits, and build it.
- (b) A linear model through the first and last points is . Compare both models at with the data.
- (c) Use both models to predict the population at . Which prediction is more reasonable?
Solution
(a) Ratios: , , , . The population grows by about every years:
(b) At , the data is . , off by about . , off by about . The exponential model fits much better.
(c) and . The exponential prediction is more reasonable, because the data shows a constant growth rate (percentage), not a constant number of people per year. Either way, a prediction years past the data is an extrapolation and should be treated with caution.
5. (Core) At a harbour, high tide is m at 2:00 a.m., and the next low tide is m at 8:15 a.m. Build a sinusoidal model for the depth hours after midnight (in radians), and predict the depth at noon to 2 decimal places.
Solution
and . High to low takes h, which is half a period, so the period is h and . The maximum is at :
At noon, :
The depth at noon is about m.
6. (Core) An open box is made from a cm by cm sheet of cardboard by cutting a square of side cm from each corner and folding up the sides.
- (a) Write a model for the volume , and state a reasonable domain.
- (b) Make a table for , and confirm that the third differences are constant.
- (c) Estimate the value of that gives the largest volume.
Solution
(a) The base is by and the height is :
All lengths must be positive, so .
(b)
| (cm³) |
First differences: . Second: . Third: . Constant third differences confirm a cubic (and matches the leading coefficient of ).
(c) The volume is largest near cm (about cm³). Graphing technology puts the maximum at cm, with cm³.
7. (Core) The concentration of a medication in a patient’s blood is modelled by mg/L, where is in hours. Interpret the model, and find when the concentration drops below mg/L.
Solution
The starting concentration is mg/L, and of the medication is removed each hour (since ).
Solve :
The concentration drops below mg/L after about hours.
8. (Challenge) A leaking tire has a pressure of kPa at and kPa after hours.
- (a) Build a linear model and an exponential model through these two points.
- (b) Use both to predict the pressure after hours.
- (c) Which model is more reasonable, and why?
Solution
(a) Linear: the slope is kPa/h, so .
Exponential: the ratio over hours is , so .
(b) kPa. kPa.
(c) The exponential model. Air leaks faster when the pressure is higher and slower as it drops, so the tire loses a percentage of its pressure, not a fixed amount. The linear model also predicts a pressure of at h and negative pressures after that, which is impossible.
9. (Challenge) A ball is thrown upward. Its height is m at , m at s, and m at s.
- (a) Find a quadratic model .
- (b) Find the maximum height and when the ball lands, to 2 decimal places.
Solution
(a) . Then
Subtracting: , and then .
(The matches half the acceleration due to gravity, m/s², a good sign the model is reasonable.)
(b) The vertex is at s, and
The ball lands when . By the quadratic formula, taking the positive root:
The maximum height is about m, at about s, and the ball lands after about s.