You are currently browsing the tag archive for the ‘fractals’ tag.

**Sierpinski Triangle: A picture of infinity**

This pattern of a Sierpinski triangle pictured above was generated by a simple iterative program. I made it by modifying the code previously used to plot the Barnsley Fern. You can run the code I used on repl.it. What we are seeing is the result of 30,000 iterations of a simple algorithm. The algorithm is as follows:

**Transformation 1:**

x_{i+1} = 0.5x_{i}

y_{i+1}= 0.5y_{i}

**Transformation 2:**

x_{i+1} = 0.5x_{i} + 0.5

y_{i+1}= 0.5y_{i}+0.5

**Transformation 3:**

x_{i+1} = 0.5x_{i} +1

y_{i+1}= 0.5y_{i}

So, I start with (0,0) and then use a random number generator to decide which transformation to use. I can run a generator from 1-3 and assign 1 for transformation 1, 2 for transformation 2, and 3 for transformation 3. Say I generate the number 2 – therefore I will apply transformation 2.

x_{i+1} = 0.5(0) + 0.5

y_{i+1}= 0.5(0)+0.5

and my new coordinate is (0.5,0.5). I mark this on my graph.

I then repeat this process – say this time I generate the number 3. This tells me to do transformation 3. So:

x_{i+1} = 0.5(0.5) +1

y_{i+1}= 0.5(0.5)

and my new coordinate is (1.25, 0.25). I mark this on my graph and carry on again. The graph above was generated with 30,000 iterations.

**Altering the algorithm**

We can alter the algorithm so that we replace all the 0.5 coefficients of x and y with another number, *a*.

a = 0.3 has disconnected triangles:

When a = 0.7 we still have a triangle:

By a = 0.9 the triangle is starting to degenerate

By a = 0.99 we start to see the emergence of a line “tail”

By a = 0.999 we see the line dominate.

And when a = 1 we then get a straight line:

When a is greater than 1 the coordinates quickly become extremely large and so the scale required to plot points means the disconnected points are not visible.

If I alternatively alter transformations 2 and 3 so that I add b for transformation 2 and 2b for transformation 3 (rather than 0.5 and 1 respectively) then we can see we simply change the scale of the triangle.

When b = 10 we can see the triangle width is now 40 (we changed b from 0.5 to 10 and so made the triangle 20 times bigger in length):

**Fractal mathematics**

This triangle is an example of a self-similar pattern – i.e one which will look the same at different scales. You could zoom into a detailed picture and see the same patterns repeating. Amazingly fractal patterns don’t fit into our usual understanding of 1 dimensional, 2 dimensional, 3 dimensional space. Fractals can instead be thought of as having fractional dimensions.

The Hausdorff dimension is a measure of the “roughness” or “crinkley-ness” of a fractal. It’s given by the formula:

D = log(N)/log(S)

For the Sierpinski triangle, doubling the size (i.e S = 2), creates 3 copies of itself (i.e N =3)

This gives:

D = log(3)/log(2)

Which gives a fractal dimension of about 1.59. This means it has a higher dimension than a line, but a lower dimension than a 2 dimensional shape.

Essential resources for IB students:

**Essential Resources for IB Teachers**

**teacher** then please also visit my new site. This has been designed specifically for teachers of mathematics at international schools. The content now includes over **2000 pages of pdf content** for the entire SL and HL Analysis syllabus and also the SL Applications syllabus. Some of the content includes:

**Original pdf worksheets**(with full worked solutions) designed to cover all the syllabus topics. These make great homework sheets or in class worksheets – and are each designed to last between 40 minutes and 1 hour.**Original Paper 3 investigations**(with full worked solutions) to develop investigative techniques and support both the exploration and the Paper 3 examination.- Over 150 pages of
**Coursework Guides**to introduce students to the essentials behind getting an excellent mark on their exploration coursework. - A large number of
**enrichment activities**such as treasure hunts, quizzes, investigations, Desmos explorations, Python coding and more – to engage IB learners in the course.

**Essential Resources for both IB teachers and IB students**

1) Exploration Guides and Paper 3 Resources

**168 page** Super Exploration Guide to talk students and teachers through all aspects of producing an excellent coursework submission. Students always make the same mistakes when doing their coursework – get the inside track from an IB moderator! I have also made **Paper 3 packs** for HL Analysis and also Applications students to help prepare for their Paper 3 exams. The Exploration Guides can be downloaded here and the Paper 3 Questions can be downloaded here.

**The Coastline Paradox and Fractional Dimensions**

The coastline paradox arises from the difficulty of measuring shapes with complicated edges such as those of countries like the Britain. As we try and be ever more accurate in our measurement of the British coastline, we get an ever larger answer! We can see this demonstrated below:

This first map represents an approximation of the British coastline with each line representing 200km. With this scale we arrive at an estimation of around 2400km. Yet if we take each line with length 50km we get the following:

This map now has a length of around 3400km. Indeed by choosing ever smaller measuring lengths we can make it much larger still. Coastlines have similar attributes to fractals – which are shapes which exhibit self similarity on ever smaller scales.

We can attempt to classify the dimension of fractals by using decimals. Just as 1 dimension represents a straight line and 2 dimensions represents a surface, we can have a pattern with dimension (say) 1.32. These dimensions make sense in terms of classifying fractal. A fractal with dimension close to 1 will be close to a straight line, one with a dimension close to 2 will be very “crinkly” indeed.

We can use the graph above, which was used by one of the founding fathers of fractal mathematics – Mandelbrot – to help expand his early ideas on the subject. The x axis is a log base 10 scale of the length chosen to measure the coastline in. The y axis is a log base 10 scale of the subsequent coastline length. So for example if we take our first estimate of the British coastline, i.e measurements of 200km, which achieved an estimate of 2400km – then we would plot the coordinate ( log(200), log(2400) ) For our second estimate this achieves the point (log(50), log(3400) ).

We can see that countries with steeper slopes (i.e those whose coastline greatly increases with ever smaller measuring scales) will have a more jagged coastline and so can be regarded as having a higher dimension. Mandelbrot assigned the coastline dimension as related to the gradient of the slope.

**Finding the gradient of a log-log graph**

However to find the gradient of the lines above is slightly complicated by the fact that we have a log-log plot. There is a formula we should use:

In the formula above, m is the gradient and F_{1} and F_{2} are the corresponding y values to x_{1} and x_{2}. So using our coordinate values ( log(200), log(2400) ) and (log(50), log(3400) ) we would get a slope of:

log(2400/3400)/log(200/50) = -0.251

We then take the absolute value of this and add 1 – which gives a coastline dimension of 1.251 for Britain’s West coast.

We can also read off the approximate values from the graph. If we take the points (1.5, 3.3) and (2.7, 3) then we have a slope of:

log(3/3.3)/log(2.7/1.5) = -0.162 which gives a coastline dimension of 1.162.

Actually, with a more accurate reading of this scale Mandelbrot arrived at a coastline dimension of 1.25 for Britain – agreeing with our previous working out.

**The coastline dimensions of other countries**

The coastline of the German land frontier was assigned a dimension of 1.15 – i.e it is not as jagged as that of Britain. Meanwhile below we can see the South African coast:

This has a very smooth coastline – and as such the log-log graph looks to have an almost flat gradient. As such it has a dimension of 1.02.

If you liked this post you might also like:

Mandelbrot and the Koch Snowflake: An exploration of fractal patterns

Julia and Mandelbrot sets: How to use complex numbers to generate pictures of infinity.

**IB Revision**

If you’re already thinking about your coursework then it’s probably also time to start planning some revision, either for the end of Year 12 school exams or Year 13 final exams. There’s a really great website that I would strongly recommend students use – you choose your subject (HL/SL/Studies if your exam is in 2020 or Applications/Analysis if your exam is in 2021), and then have the following resources:

The Questionbank takes you to a breakdown of each main subject area (e.g. Algebra, Calculus etc) and each area then has a number of graded questions. What I like about this is that you are given a difficulty rating, as well as a mark scheme and also a worked video tutorial. Really useful!

The Practice Exams section takes you to ready made exams on each topic – again with worked solutions. This also has some harder exams for those students aiming for 6s and 7s and the Past IB Exams section takes you to full video worked solutions to every question on every past paper – and you can also get a prediction exam for the upcoming year.

I would really recommend everyone making use of this – there is a mixture of a lot of free content as well as premium content so have a look and see what you think.

Fractals aren’t actually on the syllabus – but they do offer quite a good opportunity to look at limits, infinite sequences, complex numbers (eg Julia sets etc), the relationship between maths and art and so on.

This video is a fantastic introduction to fractals – looking at how the Koch snowflake has simultaneously a finite area and an infinite perimeter (interesting to link this to Gabriel’s Horn which has finite volume and infinite surface area – though this is not related to fractals):

Even more amazing, the Koch snowflake has a fractional dimension – more than 1 but less than 2.

PBS Nova have created a really detailed and interesting look at fractals and how they occur in real life:

To introduce students to fractals, you can also use the Sierpinski Triangle – which can be generated quite easily (instructions here)

and while you at it, the video of an ultra-detailed Mandelbrot zoom in is pretty impressive – a form of pictorial infinity:

There’s also the Dragon Curve – which is explained in a Youtube video. This allows students to see the beginnings of a fractal design from simply repeatedly folding a strip of paper.

From this you can start to look at both Julia and Mandelbrot sets. Dan Pearcy has posted a fantastic blogpost on the topic – which explains how the amazing fractal nature of these shapes are generated. There are also some amazing Julia Set generators and Mandelbrot generators on Geogebra.

All of this can lead onto the coastline paradox (or indeed, it might be a good place to start a lesson) – which asks can we ever actually measure the length of a coastline – because the more detail we go into, the longer the perimeter becomes. A good link to ToK knowledge.

Essential resources for IB students:

Each course also has a dedicated video tutorial section which provides 5-15 minute tutorial videos on every single syllabus part – handily sorted into topic categories.

2) Exploration Guides and Paper 3 Resources

I’ve put together four comprehensive pdf guides to help students prepare for their exploration coursework and Paper 3 investigations. The exploration guides talk through the marking criteria, common student mistakes, excellent ideas for explorations, technology advice, modeling methods and a variety of statistical techniques with detailed explanations. I’ve also made 17 full investigation questions which are also excellent starting points for explorations. The Exploration Guides can be downloaded here and the Paper 3 Questions can be downloaded here.