This is an introduction to both graphical programming in Python and fractal geometry at an intermediate level.
We learn through coding examples in which you type along with me as we go through examples of fractals created with iteration, recursion, cellular automata, and chaos.
These concepts are implemented in Python using it's built-in Tkinter and turtle graphics libraries, so no special packages have to be brought in by the user, in fact by the time we are done you could write graphical packages on your own!
By the end of these lectures you will
I will introduce myself in this lecture and proceed to go through some of the goals of the course.
We will discuss the general idea of a fractal and talk about randomness in general.
At this point we will install Python on our computers and go through some simple coding structures in the language
We will look at the baseline graphics package in Python, the Tk interface and do a simple drawing.
For our first classical fractal we will create the Cantor set in Python's Tk interface.
At this point we will go through a few interesting facts about the Cantor set, in particular the concept of dimension in Fractal geometry as it is incongruent to normal geometry dimensionality.
The Turtle graphics system in Python is built on the Tk interface and is a great logical shortcut to drawing the kind of patterns we are going to create.
Today we will review a simple flow chart description of an L-System, a way to model natural growth, and then proceed to a live coding exercise in which we will use string manipulation to model algae growth.
In this lecture we will combine what we've learned in the prior L-System and turtle graphics lessons to create the Koch curve. This curve, published in 1904 by Helge Koch opens up the general possibility of creating fractals through simple L-System interpretation.
Some facts about the perimeter, area, and dimension of the Koch snowflake.
We will now use the L-System approach to construct a simple, non-intersecting dragon curve. This serves as an example of how extensive the replacement method can be and how easily the code we wrote in Koch.py can be recycled into other fractals.
In this lecture we are expanding on our prior code for the simple dragon fractal to create the Jurassic Park dragon curve, which is our first space-filling fractal. At the same time we are dividing the script into two sections
As a brief break from our L-System creation we create an iconic fractal using recursion in Turtle graphics. The Serpinski triangle can be created in a number of ways and we will see it again as we continue to look at L-Systems and later as we delve into Cellular Automata.
In this lecture we will learn how to stack turtle states, essentially adding a recursive element into our iterative L-System, and use it to create a simple fractal plant.
We will take the next step in our L-System approach to modeling growth by adding a recursive aspect to our system which allows for branching patterns to occur and is great for creating trees and bushes.
At this point we can show how these growth algorithms can be used to fill space and create Fractal patterns that are fully two-dimensional.
We will revisit the creation of the Seirpinski triangle using L-Systems, also called the Seirpinski's Arrow system.
In this lecture we understand the concept of a Cellular Automata and perform a simple print based automata operation.
At this point we get more sophisticated in our printout and implement Rule 30, a specific one-dimensional automata.
This is the first part of our creation of the Game of Life automata in which we use the Tk interface to create a grid for two-dimensional automata creation.
In this lecture we finish our creation of the Game of Life, applying the rules of the game on our grid and observing what happens as we run it.
Using the same grid from the Game of Life, we now implement a set of rules called Majority Rule and observe the output.
In this lecture we expand on the Feigenbaum plot just created to add some event driven process items to zoom on different values for the a parameter.
I've been performing mathematical programmer for 20 years across a variety of languages. After starting my career as a game programmer I moved on to become an actuary. Over the past ten years I have been coding actuarial based applications and making business decisions for a variety of insurance companies.