0% found this document useful (0 votes)
25 views

Modelling Guide

Modeling for Mathematics

Uploaded by

John
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views

Modelling Guide

Modeling for Mathematics

Uploaded by

John
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 50

1

Mathematical Modelling
Guide
A guide to help with the exploration:
Maths IB Standard Level and Higher Level
Applications and Interpretations
Analysis and Approaches

(For first examination in 2021).

Author: Andrew Chambers


All rights reserved. No part of this publication may be reproduced, distributed, or
transmitted in any form or by any means, including photocopying, recording, or other
electronic or mechanical methods, without the prior written permission of the
publisher, except in the case of brief quotations embodied in critical reviews and
certain other noncommercial uses permitted by copyright law.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
2

Table of Contents
Page 3: Introduction

Page 4: Desmos extended guide

Page 18: Tracker extended guide

Page 24: Linear regression.

Page 27: Quadratic regression

Page 30: Cubic regression

Page 34: Exponential regression

Page 37: Linearisation using log scales.

Page 40: Trigonometric regression

Page 43: Normal distribution regression

Page 47: Other useful graphs

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
3

Introduction

I’ve written this guide to supplement the main Exploration Guide I put together. You
should consult the main guide for guidance on choosing topics, an explanation of the
marking criteria, common student mistakes and technology advice. In this guide I
look at various modelling techniques. In many cases these are taught in textbooks
simply using technology, whereas it is often desirable to demonstrate a greater
understanding through non-calculator methods in your maths exploration. So, where
possible I’ve included non-calculator techniques.

It’s important to note that these methods are not intended to be exemplars - there
are many different ways of explaining the following techniques and ideas, these are
just my ideas! You should attempt to put your methods into your own words so that
you can demonstrate a good personal understanding. The students who do best in
their exploration consult from a variety of sources, collate the ideas and are therefore
able to show a deep understanding.

If you do use this guide then it is essential that you correctly cite this source in your
exploration - failure to cite sources correctly can lead to malpractice investigations by
the IB, so make sure everything is done correctly.

The exploration is a great opportunity to apply your maths knowledge to an area of


personal interest - so choose something you are passionate about, and enjoy it!

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
4
Desmos: Modelling

Desmos is a very powerful tool for modelling graphs. If you have a small number of
data points you can add them in a table by clicking on the plus symbol and then
selecting table.

If you have a large number of data points you can copy the relevant 2 columns from
a spreadsheet program such as Excel and then paste them straight into this space
and it will automatically convert this to a table.

We can see that our x values are denoted as x1 and our y values are denoted as
y 1 . This then allows us to specify a regression using values from this table. If we
create another table we will see that our x values in this new are denoted as x2 etc.

To create a quadratic regression line in Desmos I now can type the following general
form of a quadratic equation:

y 1 ~ ax1 2 + bx1 + c

This tells Desmos that I have 3 values to find: a, b, c, and to use the values from my
table for x1 and y 1 . You will be able to type an underscore y 1 by pressing y then
shift and the takeaway key (next to 0). You will be able to type the wiggly line by
pressing shift and the key to the left of 1.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
5
This then returns the following:

This tells me the values of a,b,c which best fit these points are:

a = 0.175
b = - 0.135
c = 0.615

Which creates the following equation:

y = 0.175x2 ­ 0.135x + 0.615


I can also see the R2 statistic which measures the goodness of fit. R2 close to 1
shows a very good fit - our R2 value of 0.9949 shows that this curve fits the data very
well.

Using the same idea I can then fit any curve using regression. For example an
exponential regression would look like this:

y 1 ~ aebx1 + c

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
6
Summary of some different regression models on Desmos:

Polynomial

Linear: y 1 ~ ax1 + b

Quadratic: y 1 ~ ax1 2 + bx1 + c

Cubic: y 1 ~ ax1 3 + bx1 2 + cx1 + d

(Consider a higher order polynomial if there are more than 2 turning points).

Trigonometric

Sine curve: y 1 ~ asin(b(x1 + c)) + d

Cosine curve: y 1 ~ acos(b(x1 + c)) + d

(You might need to fix b if you get a graph which is too frequent).

Exponential

y 1 ~ aebx1 + c

(will fit both exponential growth and decay models)

Logistic

y1 ~ a
1+be­r(x1 ­c)

(Will fit population growth models which start with high growth and gradually slow to
a limit).

Ellipse and circles

­
(x1 h)2
+
­
(y 1 k)2
=1
a2 b2

(The general equation of an ellipse - but will also fit circles).

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
7
Residuals (measuring error)

For a graphical representation of a goodness of fit we can click on the plot button by
the e1 (or e2 etc) residuals after we have plotted a regression curve.

This returns the following:

The residuals are plotted in blue. Here I clicked on the points to show the
coordinates. The y-coordinates of the residuals help to illustrate the perpendicular
distance between the actual points and the regression graph. If we have the actual
coordinate (xi , y i ) and our regression model predicts the point (xi , y j ) then our
residual ei is given by:

ei = y i ­y j

And Desmos will plot the residual coordinate:

(xi , ei )

When the regression graph overestimates the actual point we get a negative residual
and when the regression graph underestimates the actual point we get a positive
residual. So we can see that when x = 0 the regression graph overestimates the
real y value by 0.015, and so this gives a negative residual, i.e - 0.015.

By looking at our 4 residuals - all are very close to a y value of 0 which shows that
the residuals are small, and we can also see that 2 of our points have been
overestimated by the regression graph and 2 of our points have been
underestimated.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
8
Visualising how a single point changes your regression model:

Another trick allows you to see what happens if you vary a single point. Say for
example i want to see what effect changing the coordinate (1,0.7) has on my
regression graph, well I can click and hold down on the circle above the y 1 column,
then select drag as shown below.

This allows me to drag a chosen point either vertically or horizontally to explore what
happens to my regression line.

This allows you to see quickly the effect of changing one of your data points.
Because there were so few data points in this model, changing one has a big effect
on the output.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
9

Presentation of graphs

Restricting the domain:

I might then want to restrict my domain so that my regression graph starts when x =
0. To do this I can click to un-highlight the red regression line, and then type in a
new equation using the values of a,b,c generated.

I can then add the curly brackets {x ≥ 0} after the equation as shown above to make
sure that my graph starts where I want it to.

Changing the line style:

I might also want to change this line to a dotted line, or to change the colour. I can
do this by clicking and holding down whilst on the green circle. This brings up the
following:

I can now change the colour, style or width of the line.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
10

Labelling axes in Desmos:

The default labelling of axes in Desmos causes problems for students. Let’s see
what happens when we use the default method:

The labels do appear but are positioned such that we have to screen-capture to the
edge of the graph window. One way around this is to label 2 points like this:

This allows us to position exactly where our axes labels will appear:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
11
Getting the domain and range right.

Click on the spanner on the right hand side of the screen to change the domain and
range of your graph.

Let’s look at plotting the graph:


y = 100sin(2x)

We can start by making sure we are in radians or degrees as appropriate. I will


select radians. I can set the domain from 5π2
­
to 5π
2
simply by typing in “pi” for the
π symbol. I’ll set the range from -100 to 100.

I can then change the x axis step size - as the default will be to have the faint lines
representing integers. I would like them to be relevant for my trig graph so I change
the step size to π2 .

I then can restrict the domain of my graph by using the curly brackets after my
­
equation: { 2π ≤ x ≤ 2π}

This then allows me to show my graph with domain and range appropriately drawn.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
12

Polar grid

A polar grid is useful if you are working with complex numbers, or in polar
coordinates.

We click on the spanner on the right hand side of the page and select the green
highlighted grid above.

This then generates a grid of concentric circles, with labels to show the radius of the
circles and the angle of rotation from the x-axis.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
13

If I now plot the graph in polar coordinates:


r = θ

I will get the following spiral. The r value tells me the distance from the origin and
the θ value tells me the anticlockwise rotation from the x-axis. As my graph is
r = θ , this means that at every point the rotation from the x-axis is equal to the
distance from the origin. For example the red point marked above is a distance of π2
from the origin and a rotation of π2 radians from the x-axis.

You can also use the polar grid to get a nice visual representation of complex
numbers. For example the complex number:

π
z = 2e 3 i = 2cis( π3 )

Can be entered into desmos as the coordinate:

(2cos( π3 ), 2sin( π3 ))

This plots the following point:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
14

Which we can see visually is a distance of 2 from the origin and an anti-clockwise
rotation of π3 from the x-axis.

These graphs allows us to see clearly the symmetry in graphs such as the solutions
to:
z 12 = 1

The 12 roots of unity are all arranged at a distance of 1 from the origin and are
π
equally spaced by rotations of angles 12 .

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
15

Parametric equations

Parametric equations can also be plotted in Desmos. Say for example I have the
following parametric equations:

x(t) = 2cos(t) + sin(5t)

y (t) = 2sin(t) + cos(5t)

I can plot them in Desmos as the coordinate (make sure to use t as the parameter):

(2cos(t) + sin(5t), 2sin(t) + cos(5t) )

I also need to tell Desmos the values t can take. For example:

0 ≤ t ≤ 10

This then generates the following graph:

We can see the power of parameterization to create mathematical art by looking at


the following general parametric equation:

x(t) = cos(at) ­ cos(bt) j

y (t) = sin(ct) ­ sin(dt)k

(Note that this is just (bt)j not (cos(bt))j ).

Then by varying a,b,c,d,j,k we can see all sorts of pattern sets.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
16

For j = 3, k =3 we get the following group for (a,b,c,d) specified in the images:

[image by Josep M Batlle i Ferrer on Wikipedia: Parametric Equations]

And some more for j = 3, k =3 with larger values of (a,b,c,d) we get some really
interesting spherical and cuboidal images:

[image by Josep M Batlle i Ferrer on Wikipedia: Parametric Equations]

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
17

Parametric equations are useful whenever we can resolve into an x and y


component (such as in projectile motion). For example the parametric equations for
projectile motion are:

x(t) = (vcosθ)t
­
y (t) = (vsinθ)t 0.5gt2

Where θ is the launch angle, g the force due to gravity and v the launch speed

I can type this into Desmos as follows:

((vcos(p))t, (vsin(p))t ­ 0.5gt )


2

(note that Desmos doesn’t like θ as a parameter so I changed this to p). Desmos
then allows me to add sliders for v, p, g.

I can then vary the velocity, launch angle (and even gravity!) to see what happens to
my projectile:

Above we can see the projectile motion for an object launched with speed 8 m/s,
with the force of gravity at 9.8 m/ s2 at an angle of 1 radian.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
18

Tracker: Modelling

Tracker is best for motion tracking investigation when you want to convert a video to
a graph of motion.

It’s a little bit difficult to get set up (but well worth it if this is the sort of investigation
you plan to do). I’d recommend this excellent tutorial video here and the very helpful
user guide here. The basic idea is that we can upload a video, then track a point that
moves frame by frame using the buttons shift-ctrl-click.

For example, say I am interested in the circular motion of the Ferris wheel above. I
can choose to track many things (such as vertical height, horizontal height, vertical
speed etc against time).

If I generate a graph of vertical height against time I can get the following graph:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
19
One problem you might notice with the graph above is that the scale is not correct -
this is because I didn’t tell Tracker the scale of the video that was uploaded. It
assumes that your time is in seconds, but has no way of knowing what your
distances are represented by.

Set your axes:

Make sure you set your axes such that the origin is where you want it to be. Here I
have added the pink axes by clicking on the perpendicular pink lines icon and
dragged it so that (0,0) is the start of my ride.

Use the calibration stick

It’s also essential to add a calibration stick - so that the scale of the graph will be
accurate. Here I used the fact that my Ferris wheel is 200m high to give Tracker the
correct scale.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
20

This then creates the following graph. We can see that this graph much better
represents the real life data - it doesn’t reach 200 because we are tracking a point in
the middle of the carriage. Our time unit is in seconds and will be appropriate as
long as the video is shot in real time.

Regression:

Now Tracker will do some basic regression but is not especially powerful when
compared with Desmos. To access this we right click on the graph on the right, and
then select analyze. This brings up the following page:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
21
We can see Tracker’s regression limitations here! But what we can do is now copy
and paste the data on the right hand side (this data could also be copied from the
previous screen’s tables). In order to paste into Desmos we just need 2 columns -
time and y-values. An easy way to achieve this is to paste all your data into a
spreadsheet then copy and paste the relevant data from here into Desmos.

This then allows you to work with the data in Desmos and do regression analysis
using Desmos’ tools.

By clicking on the originally generated Tracker graph you can change that graph and
data of what you are measuring. So, for example if I want to measure how vertical
velocity changes over time I click on the y-axis label and select vy:

This then gives me the new graph:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
22
If all has gone well this should be the derivative of the previous graph - so let’s
check. I’ll do the same as before and copy the data into Desmos:

We can see the regression is not quite as good (probably due to measuring errors in
Tracker). The original graph of the vertical displacement was given by Desmos as:

y (t) = 83.5sin(0.67(t ­ 1.4)) + 94.8


And the graph of the vertical speed (which should be the differential of the previous
graph) was given by Desmos as:

v (t) = 55cos(0.67(t ­ 1.2)) + 1.5


Differentiating y (t) with respect to time gives us approximately:

y ′(t) = 56cos(0.67(t ­ 1.4))


So we can see that we are getting an appropriate graph that fits with known physics!
You can explore lots of relationships from the simple video - acceleration,
momentum, rotation angle, angular velocity and more.

Plotting y position against x position gives the expected circular graph:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
23
Plotting acceleration in the y-direction versus time should also give me a trig graph
(the differential of the velocity graph):

If I want to plot kinetic energy versus time I can do this - here I need to ensure that
the mass A is assigned the correct mass (see the box in the tool bar next to mass A).
Below I have assigned a mass of 100kg.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
24

Linear Regression

Method 1

If you are doing a correlation investigation then you should use the Pearson’s
Product formula first to check the strength of correlation. Once you have done this
you can then find the equation of the line of best fit.

Method 2

If you are simply trying to find a linear regression line and not measure correlation
then you can use the least squares regression formula.

The equation of the line of best fit is given by:

y = mx + c

Where:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
25
Say for example we have the following data points we want to fit a line through:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
26

Let’s see how accurate this line is:

It’s pretty good! If we use the linear regression tool on Desmos by typing:

y 1 ~ mx1 + c

We find we get exactly the same equation to 3 significant figures.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
27
Quadratic regression

Completing the square

If I have the following graph I would notice that it follows a general quadratic shape.
So, usually the easiest method to fit a quadratic curve is to use the form:

y = p(x ­ q) 2
+r

Because my graph uses time and height, I will rewrite this as:

h(t) = p(t ­ q) 2
+r

When written in this form, p represents the vertical stretch factor and will be negative
because the graph is concave down. (q,r) will be the coordinates of the vertex of the
graph.

Looking at the graph, I need to decide where a best-fit quadratic curve would have
its vertex. In this case it looks like the coordinate point (3, 6.5) is quite close.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
28
Therefore I have:

h(t) = p(t ­ 3) 2
+ 6.5

Next I just need to find p. To do this I can choose any point that I want my curve to
go through. If I decide that my curve must go through (0,0) so that my model has a
height of 0 metres after 0 seconds, then I can substitute these values to find p:

h(0) = 0 = p(0 ­ 3) 2
+ 6.5

p= ­6.5
9

p ≈­ 0.722
Therefore:

h(t) = ­ 0.722 (t ­ 3) 2
+ 6.5

This gives the following curve:

We can see that it goes through the point we chose as a vertex as well as the origin.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
29
Desmos regression

I can also see what regression line Desmos will draw for these points by typing in:

y 1 ~ p(x1 ­ q) 2
+r

This generates the following graph:

h(t) = ­ 0.727 (t ­ 3.06) 2


+ 6.39

We can see that this time Desmos fits the best possible quadratic for all the points -
and so it does not quite fit the maximum point or go through the origin.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
30
Cubic regression

Simultaneous equations

The general form of a cubic is:

y = ax3 + bx2 + cx + d

Because my graph uses time and height, I will rewrite this as:

h(t) = at3 + bt2 + ct + d

Here I have 4 unknowns and so need 4 equations. Luckily my graph goes through
(0,0) so I immediately know that d = 0. If your graph doesn’t pass through the origin
you can still use the same method but will use your GDC simultaneous equation
solver with 4 unknowns.

I will then choose the coordinate points which I want my graph to pass through. I’d
like it to pass through the origin (0, 0), the first maximum (1, 5.8), the first minimum
(3, 1.8) and the end point (4.5, 9).

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
31
This will therefore generate the following equations:

h(0) = 0 = a(0)3 + b(0)2 + c(0) + d

Therefore d = 0.

h(1) = 5.8 = a(1)3 + b(1)2 + c(1)

h(3) = 1.8 = a(3)3 + b(3)2 + c(3)

h(4.5) = 9 = a(4.5)3 + b(4.5)2 + c(4.5)

These simplify to give:

5.8 = a + b + c

1.8 = 27a + 9b + 3c

9 = 91.125a + 20.25b + 4.5c

Simultaneous equations can be solved using a GDC. For those doing HL maths you
might want to explore how to use the inverse of a 3x3 matrix to solve this. However
just using a Casio we could use the simultaneous equation solver:

This gives us: a = 1.00, b = -6.62, c = 11.4

Therefore we have the equation:

h(t) = 1.00t3 ­ 6.62t


2
+ 11.4t

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
32
If we plot this graph we get;

We can see that it passes through the points we specified and it is a very good fit.

Desmos regression

We can type the following in to see what regression line Desmos will create:

y 1 ~ ax1 3 + bx1 2 + cx1 + d

Desmos creates a very similar graph:

h(t) = 1.01t3 ­ 6.63t


2
+ 11.4t

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
33
Higher powers regression

You can use the same technique for cubic regression to find higher power
regression. For example a quartic curve has general equation:

y = ax4 + bx3 + cx2 + dx + e

Example of a quartic curve:

In order to fit a regression line to a quartic you will need to have 5 equations because
you have 5 unknowns. So, choose 5 points you want your graph to pass through.
You can then use your GDC simultaneous equation solver to solve.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
34
Exponential regression

Method 1: Simultaneous equations

The general equation for an exponential graph is:

y = AeBx + C

Because my graph plots infected (I) and time (t), I’ll rewrite it as:

I(t) = AeBt + C

This method needs your graph to have an asymptote y = 0 so that you can set C=0.
If your graph has an asymptote at (say) y = 3 then move all your points down by 3
(i.e take away 3 from each y coordinate). Then follow this method below to find A
and B. Finally you can set C = 3.

I(t) = AeBt

Next I need to choose 2 points that I want the exponential to pass through. I’m going
to choose coordinates one third and two thirds along so I can represent the curve in
the middle section. (5, 4.2) and (10, 14).

4.2 = AeB(5) (1)


B(10)
14 = Ae (2)

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
35
I can eliminate A by doing equation (2) divided by equation (1):

14 AeB(10)
4.2 = AeB(5)

10 e10B
3 = e5B

10
3 = e5B

10
ln( 3 ) = 5B

10
B = 0.2 ln( 3 )

I can then find A by substituting into one of the equations (e.g equation (1) ):

4.2 = AeB(5)

10
4.2 = Ae5(0.2ln( 3 ))

10
4.2 = Aeln( 3 )

4.2 = A( 10
3 )

A = 1.26.

And I can now round B to 3 sf to give:

B ≈ 0.241
So my equation is:
I(t) = 1.26e0.241t

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
36
This gives the following equation:

We can see that it goes through the 2 points we specified. It is a reasonable fit over
the first 10 days - but then fits less well over the next 10 days. We could try again
choosing the end point coordinate to ensure the curve fits through this point, or we
could choose to plot a piecewise function (i.e represent this using 2 different
equations, one equation for the first 10 days and another equation for the next 10
days).

Regression using Desmos

Desmos manages to fit a much better exponential curve - which shows that we
should try our exponential model again choosing one of the end coordinates.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
37
Exponential regression

Method 2: Linearisation

Let’s take the same graph and the same starting point:

I(t) = AeBt

We now do the following:

ln(I(t)) = ln(AeBt )

ln(I(t)) = lnA + ln(eBt )

ln(I(t)) = lnA + (Bt)ln(e)

ln(I(t)) = lnA + B t

ln(I(t)) = B t + lnA

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
38
Therefore this is in the form of the equation of a straight line, when we plot ln(I(t)) on
the y axis against t. When we do this, the gradient will be B and the y-intercept will
be lnA .

For example with the coordinate (5, 4.2), I will plot (5, ln(4.2)) etc. This will give:

I now can draw a straight line of best fit to find the gradient.

This has a gradient of 0.260. This means B = 0.260.

The y-intercept is -0.1832. This means that

­
lnA = 0.1832

A = e­0.1832

A ≈ 0.833
So my equation is:

I(t) = 0.833e0.260t
Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
39
This gives the following graph:

Other uses of linearisation:

The idea of linearisation is to transform a graph into a straight line which we can then
find the gradient and y-intercept from easily.

We can also use linearisation to find the equation of graphs of the form:

y = AxB

lny = ln(AxB )

lny = lnA + ln(xB )

lny = lnA + Bln(x)

In this case we would plot lny against ln(x) and would have B as the gradient and
lnA as the y-intercept.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
40
Trigonometric regression

The general form for a sine regression is:

y = asin(b(x ­ c)) + d
Because I’m looking at months t and average hours of sunlight S(t) I’ll rewrite this as:

S (t) = asin(b(t ­ c)) + d


a represents the amplitude and can be thought of as a vertical stretch of S (t) = sin(t).

b is related to the period by the equation:


period = b

and we have a translation from the standard S (t) = sin(t) graph by the vector:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
41
Step 1 is to find the amplitude (a). We do this by finding the difference between the
maximum and minimum points then dividing by 2.

a = 16.93
2
­ 7.57
a ≈ 4.68
Step 2 is to find b. We note that the period of the graph is 12 therefore:


period = b


12 = b

π
b= 6

Step 3 is to look at the maximum point. This has a y coordinate of 16.93.

The graph of

S (t) = 4.68sin( π6 t)

would have a y-coordinate maximum of 4.68. Therefore the vertical translation must
be:

d = 16.93 ­ 4.68 = 12.25.


Step 4 is to plot the graph you have already drawn.

S (t) = 4.68sin( π6 t) + 12.25

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
42
Then we can see that the maximum point at (3, 16.93) should be at (7, 16.93).
Therefore we need a horizontal translation of 4. So c = 4.

So our final graph is:

S (t) = 4.68sin( π6 (t ­ 4)) + 12.25

Regression using Desmos

I can type the following into Desmos to see what regression line it will create:

y 1 ~ asin( π6 (x1 ­ c)) + d


Note I need to specify the value of b (see what happens if you don’t do this!)

S (t) = 4.57sin( π6 (t ­ 3.67)) + 12.3


We can see that our initial model is pretty close to Desmos’ model here.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
43
Normal distribution model

For this example I will generate 300 pieces of data that should fit a normal
distribution from here. I then have copied them into an online frequency table
creator here to create the following table:

Frequency Distribution Table

Class Count Percentage

94 - 94.99 2 0.7

95 - 95.99 5 1.7

96 - 96.99 13 4.3

97 - 97.99 28 9.3

98 - 98.99 44 14.7

99 - 99.99 67 22.3

100 - 100.99 57 19

101 - 101.99 37 12.3

102 - 102.99 26 8.7

103 - 103.99 11 3.7

104 - 104.99 7 2.3

105 - 105.99 2 0.7

106 - 106.99 1 0.3

107 - 107.99 0 0

108 - 108.99 0 0

Total 300 100

(Note this is not great notation for the class interval make sure to use inequalities for
any IA done like this).

With this table I now enter table values into Desmos, plotting the midpoint on the x
axis and the decimal equivalent of my percentages on my y axis.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
44
Now I can use the normal distribution regression model on Desmos:

Where a is the standard deviation and b is the mean of the normal distribution. This
generated the following model:

We can see that this normal distribution model very closely fits our data. Desmos
gives our a value is 2 and our b value is 100 which matches the standard deviation
and mean I used to generate the data in the first place.

So far so good - but there is a potential problem if your class widths in your
frequency table aren’t 1. To understand why we can consider the area under a
frequency histogram - this is going to be class width multiplied by our probabilities.
When the class widths are 1 then the total area under the frequency histogram will
be 1. This is good because the area under our normal distribution curve also has to
be one. However if our class width is (say) 5 then our total area ends up being 5 as
well. Therefore we can amend for this by taking the average probability over the
class width (similar to how we work out frequency density).

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
45
Let’s see this in action. I generate some data as before - but sorted into class-widths
of 2:
Class Count Percentage

94 - 95.99 7 2.3

96 - 97.99 41 13.7

98 - 99.99 111 37

100 - 101.99 94 31.3

102 - 103.99 37 12.3

104 - 105.99 9 3

106 - 107.99 1 0.3

108 - 109.99 0 0

Total 300 99.9

Therefore I will plot the mid point of the class width on the x axis and the decimal
equivalent of my percentages divided by my class width of 2 on my y axis.

x value y value

95 0.0115

97 0.0685

99 0.185

101 0.1565

103 0.0615

105 0.015

107 0.0015

109 0

I can now do a regression to try and fit the normal distribution curve to this data:

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
46

This fits the following curve:

This also gives a (standard deviation) as 2 and b (mean) as 100 - which is again the
original values I used to generate this data.

So this is a very useful technique to see how closely data fits a normal distribution
curve using technology.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
47
Other useful graphs

1. Logistic regression model:

a
y = 1+be­r(x­c)

The logistic model can be very useful for modelling population growth - and will
appear when you use the SIR model for infections. The value a is the carrying
capacity and is the maximum that the population can reach.

2. Damped harmonic motion

y = ef (x­g) sin(b(x ­ c)) + d

Sometimes when modelling harmonic motion you will notice that the amplitude
changes - eg. the height of tides or the vertical height of a pendulum. In this case we
can plot a damped graph by multiplying the trig function by an exponential term.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
48
3. Circles

(x ­ h) 2
+ (y ­ k) 2
= r2

This generates a circle with radius r centred at (h,k). For example:

(x ­ 2) 2
+ (y ­ 3) 2
= 22

4. Ellipses

­
(x h)
2
+
­
(y k)
2
=1
a2 b2

This generates an ellipse with distance from the centre to the edges of a horizontally
and b vertically, centred at (h,k). For example:

­
(x 2)
2
+
­
(y 3)
2
=1
12 22

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
49

5. Piecewise functions

Sometimes you’ll not be able to represent your graph using just one function - so you
can instead use a piecewise function like this:

This tells me that the function behaves like a linear function for all x values up to and
including 2, then behaves like a quadratic function for x values greater than 2. Note
here that you should usually aim to have a continuous function (i.e the value when x
= 2 is the same for both equations) when using this for modelling.

This gives the following graph:

6. Modulus functions

If you are dealing with graphs with sharp points then a modulus function may be
useful. The general form can be written as:

f (x) = a |b(x ­ c)| + d

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.
50
If we plot the graph of modulus x we get the following:

f = |x|

And more generally if we plot

f (x) = 2 |(x ­ 3)| + 4

We will have a graph that has been vertically stretched by a factor of 2 and then
translated by 3 units to the right and 4 units up.

Copyright © 2020 Andrew Chambers. All rights reserved. 300 IA ideas: https://ibmathsresources.com.

You might also like