Reflections on maths, learning and maths learning support, by David K Butler

Tag: visualisation

  • Zooming in to see the slope

    A lot of people introduce the derivative at a point as the slope of the tangent at that point, which to me is quite confusing. It seems to me that the reason we want the derivative is that it is a measure of the slope of our actual function at that point, not the slope of a completely different thing. To me, the thing is that the function itself is pretty much straight if we are close enough to it, so when we’re looking really close, saying it has a slope at this point is a meaningful thing to say.

    For years I got at this idea by drawing a little magnifying glass on my function, and a big version nearby to show what you could see through the magnifying glass. But last year I decided to get technology to help me do this dynamically and I made a Desmos graph with a zooming view window that will show you the view on a tiny circle around a point on a curve. (Some of the bells and whistles here were provided with a little help from Andrew Knauft .)

    Here’s what the graph looks like, and a link to the graph so you can play with it yourself: https://www.desmos.com/calculator/pa1cudpc07 

    A screenshot of a Desmos graph. There is a red curve which is the graph of a function, and a small circle centred at a point on the function. A dotted line joins this to a bigger circle showing a zoomed in version of what's in the small circle. There is a zoom factor slider.

    I’ve used this to help students see that the curve itself really does look straight when you’re very close, and so treating it like it is straight there and saying it has a slope is a reasonable thing to do. Students are usually most impressed and love to play with it. It’s also interesting to put in a function with a kink in it like  |x2-1| to show that the kink never goes away no matter how closely you view the function, so having a single slope there isn’t really reasonable.

    Every time I’ve had to search my own twitter account to find the tweet where I shared it , and I couldn’t keep doing that, so here it is in a quick blog post for posterity.

  • Flipping absolute values

    Every semester I talk to students about what the absolute value does to the graph of a function. Basically, the graph of y = |f(x)| is the same as the graph of y = f(x), but with all the bits below the x-axis flipped to be above the x-axis. I’ve always simply drawn some graphs and then drawn the flipped-over bits in a different colour. Like this:

    A pair of x-y axes with a blue graph crossing the x-axis multiple times. A green arrow points from this graph to a new graph. The new graph has the bottom parts of the original graph flipped upwards across the x-axis, to make a new graph drawn in red that bounces along the x-axis.

    But this morning I read a blog post from Shaun Carter (which unfortunately no longer exists) and I realised I had fallen down on my physical manipulatives game. Shaun created a paper-and-glue thingy to physically flip the graph over, which I was most impressed with.

    Thinking about it later, it occurred to me that it wasn’t the sort of thing I could do on the fly in the Maths Learning Centre. It involved tracing the graph multiple times and cutting and pasting, and basically would be way too fiddly for me to use on the fly when a student was confused about this idea. I wondered if there was a way to quickly construct such a thing in a few seconds.

    The other problem with it is that the original function is obscured in the foldy-thingy. The paper moving over makes it seem a bit like the old graph vanishes to be replaced by the new one, but really all the up-parts are still there the same as they were before.

    And then, while drawing on the glass in the shower (as I do), it came to me: I need something transparent! A plastic sleeve and a whiteboard marker later, and the function-flipper was born!

    Three stills from a video. In the first still, there is a function crossing the x-axis a few times. In the second still, the function is revealed to be drawn on a plastic sleeve, which is being folded by a pair of hands. In the third still, the hands are holding the plastic down, having folded it in half across the x-axis, and now the graph is entirely above the x-axis.

    I made a very quick-and-dirty video to show it to you in action.

    An unexpected discovery is that whiteboard markers rub off of plastic sleeves, so you can draw and redraw all sorts of functions without needing to get a new sleeve. This means you could probably give a plastic sleeve and a marker and a tissue to everyone in your class and have them investigate for themselves.

    Now all I need to do is make sure there’s a stock of plastic sleeves in the MLC…


    These comments were left on the original blog post:

    Daniel 29 September 2016

    And if you transpose the plastic you have a function inverter

    David Butler 5 October 2016

    Yes you do get the graph of the inverse function when you transpose the sheet! Great idea!

  • Obscuring the GST by making it simple

    I was helping out at Roseworthy Campus yesterday as the Vet Medicine students were learning about budgeting for a Vet Clinic as a business. One aspect of this was calculating the amount of the cost of goods and services that was GST (stands for “Goods and Services Tax” – in other countries it’s known as VAT or Sales Tax). The Excel sheet they were working in already had the formula worked in and it was this:

    GST = (Total Price)/11.

    This formula is completely correct for GST-applicable items in Australia. In fact, if you google “calculate GST from total in Australia”, the first seven links all show you this exact formula. The problem is, it’s not all that obvious how this formula is related to the GST rate of 10% that we currently have in Australia.

    Here is an explanation that worked today when the students asked me.

    First, let’s imagine that this rectangle is the original price before the GST was added.

    A pink rectangle much wider than it is high.

    Now let’s add on the GST to get the total amount. Our goal is to figure out what the little blue part is if all we know is the combined amount.

    A rectangle much wider than it is high divided into two parts. The much larger left-hand end is pink, and the much smaller right-hand end is blue.

    The blue part is 10% of the pink part, so let’s divide the pink part into 10 pieces.

    A rectangle divided into 11 equal smaller slices. The first ten small rectangles are pink, and the last small rectangle is blue.

    Now there are 11 parts in total and the blue part is one of these 11. That is, it’s an 11th of the combined amount. So if you divide the combined amount by 11 it will tell you the GST.

    This made sense to them, so all was well.

    Or was it?

    Earlier, the lecturer had warned the student that the formula would be different if the GST rate was different, such as if the law changed in Australia in the future or they were in a different country. And it suddenly occurred to me that my explanation wouldn’t be at all useful if the GST rate was something different. It hinges upon some coincidences of our rate of 10% that really just won’t apply to most other rates of GST.

    The first coincidence is that the 10% divides evenly into 100%. In the third picture I was able to divide up the pink part evenly into pieces the same size as the GST, and then was able to count the total number of pieces. If the rate was 20%, then I could still do this, and the formula would come out to

    GST = (Total Price)/6.

    But if the rate was 15%, then I’d have no hope of using this explanation. Sure, I could figure out how many times 15 goes into 100% (it’s 100/15 = 16⅔), but there’d be a little leftover bit that would throw out all my whole-number counting.

    The second coincidence is that it’s obvious that 10% divides evenly into 100% and it’s obvious how many times it goes. If the rate was 12.5%, then it would still go in evenly, but the majority of people wouldn’t know off the top of their heads that it goes 8 times.

    So what we really want is not an explanation of our current formula, but a whole new formula and an explanation that goes with it, that will apply to any rate of GST and make it obvious what calculation needs to be done.

    And here is the one I came up with in the classroom. First, let’s consider the original amount before GST was added on.

    A pink rectangle much wider than it is high.

    Now, let’s add on the GST.

    A rectangle much wider than it is high divided into two parts. The much larger left-hand end is pink, and the much smaller right-hand end is blue.

    The GST is 10% of the original amount, and the original amount is 100% of the original amount, so the combined amount is 110% of the original.

    A rectangle divided into two parts. The much larger left-hand end is pink, and the much smaller right-hand end is blue. A brace above the pink part says 100. A brace above the blue part says 10. A brace below the whole rectangle says 110.

    That means the GST as a fraction of the combined amount is 10 out of 110. So our formula becomes

    GST = 10/110*(Total cost).

    The formula that goes with this for any GST rate is the following. If the GST rate is r% and you have the total cost including GST, then the amount of the GST itself is

    GST = r/(100+r)*(Total cost)

    This explanation and its attendant formula is admittedly more complex than the original, but that complexity allows it to be easily transferred to other situations, which is much better than relying on a couple of coincidences to make it simpler, only to obscure the actual process involved.

  • A function is not a graph

    When students learn about functions at school, we spend a lot of time forging the connection between functions and graphs. We plot individual points, and we find x-intercepts and y-intercepts. We use graphing software to investigate what the coefficients do to the graph, and discuss shifting along the x-axis and y-axis. We make reference to the graph to define derivatives and integrals. Some teachers help students to recognise from the formula of a function what general shape its graph ought to have, such as recognising that a quadratic function must have a parabola-shaped graph. (I wish this last point was much more strongly pushed, actually.)

    However, there is a problem with all of this that students come to think that functions are graphs you can draw. Their idea of a function is a curve drawn on a piece of paper, or at least something that can be drawn as a curve. And this is can cause some serious issues later on.

    The first problem comes when they investigate certain pathological functions where the graph is not drawable, but they are still perfectly good functions. For example, consider the Dirchlet function which is 1 when the input is rational and 0 when it’s irrational. It’s a perfectly good function but good luck trying to draw it!

    This one’s not insurmountable – students can usually imagine a graph of two ghostly lines with the property that a vertical line which meets one of them in an actual point misses the other. They’re just extending their definition of what it is to “draw” when they draw a graph.

    The real problem comes when we move on to functions where the inputs and/or the outputs aren’t ordinary numbers. The simplest case is a function like f(x,y) = xy. This takes a point in R2 and produces a number. Many students struggle to understand these functions because they don’t have a way to draw them. “A function is a curve”, says their experience, but where is the curve here? We get around this by extending their picture of what it means to “draw” a graph: We locate the point (x,y) on a plane and then the output we draw as a vertical height or depth. What this produces is not a curve but a surface.

    This is a good start, but unfortunately at this point we also often tell them about level curves (or indifference curves if they’re in Economics). Many students at this time simply come to see a specific one of the level curves as the function itself, instead of all the level curves together as a description of the function, because their experience says that a function is a curve.

    And now the real trouble starts: what about a function which takes a vector of 3 or 4 or 7 variables and outputs a number, like they meet in microeconomics or statistics? We don’t have enough dimensions to “draw” the graph then. And what about a function that takes a vector in 3D and produces a vector in 2D, like they meet when doing linear transformations in Maths 1B? And what about a function that takes a real number and produces a point in 3D, like they meet in geophysics? And what about a function that takes a complex number and produces a complex number, like they meet in Engineering Maths? What hope do those students have of understanding functions like that when their only understanding of function has an x-axis, a y-axis and a curve?

    These functions are most emphatically not graphs, at least not in a way that you can draw. (I can hear pure mathematicians saying something about the definition of function being a subset of the cartesian product and hence essentially a graph, but you can’t draw it can you?) At the very least they are certainly not the curves students are familiar with!

    I believe we need ways to represent functions that don’t involve drawing a curve on two axes, even for functions that can be drawn this way. When we introduce non-curve functions we place a huge burden on the students’ imagination, which can prevent them from understanding what’s going on. My idea is that if they can be familiar with multiple ways of imagining an ordinary number-to-number function, then new types of function will be a little less alien to them, because they will have ready-made ways to imagine them.