Coding, Computer Science, Engineering, Logic, Math and Computer Science Everywhere, Python

Simon’s Halting Problem Gist

You can easily turn every statement into a program. If the program stops, or “halts”, then the statement is true, and if it never stops, or “loops”, the statement is false.

Like, for example, the following program corresponds to the statement: “There’s at least one even number that cannot be expressed as the sum of two primes” (this is the negation of the so-called “Goldbach Conjecture”):

So, if we can figure out if any program will halt or not halt, we can prove everything! Can we do that, though?

Read more on Simon’s GitHub

Geometry Joys, Murderous Maths, Simon's sketch book

Our New Craze: Euclidea

Simon is obsessed with Euclidea https://www.euclidea.xyz/ — a learning environment for geometric constructions and proofs. He has also downloaded the Euclidea app (which has more features), so that he could continue engaging with it while at the beach.

Yesterday, he finished the whole first section (called Alpha), completing all of its 7 tasks in several ways, most of which he solved himself without using hints. The goal is to solve a problem using the minimum number of moves:

Each solution is scored in two types of moves: L (straight or curved lines) and E (elementary Euclidean constructions). Points are not taken into account.

L counts tool actions: constructing a line, a perpendicular, and so on.
E counts moves as if a construction was made with real compass and straightedge. (Each advanced tool has its own E cost).

Each level has L and E goals. They are independent. A lot of problems have universal solution that satisfies both goals. But some problems should be solved twice: one solution to reach L goal and another solution to reach E goal.

You can receive the following stars on each level:

* the challenge was solved
* the L goal was reached
* the E goal was reached
* all variants (V) of answer were found

If there are several objects satisfying the statement of a problem, you can get a hidden V-star by constructing all the answers (solutions) at the same drawing. Usually this implies some kind of symmetry. You need to guess on what levels it is possible because the presence of a V-star is not shown until you find it.

– Euclidea Manual

The five images below are an example of solving a Euclidea puzzle:

Simon solving the above puzzle using only his compasses and a ruler
measuring the angle he wants to duplicate
marking the same degree angle
Solved

Simon also loves recreating all the puzzles:

For the last puzzle, Simon couldn’t find the minimum number of moves independently and looked the solution up on stackexchange. “It would have taken me a year to figure this out”, he said:

screenshot solution, stackexchange

Coding, Contributing, JavaScript, Milestones, Server Side Programming, Simon's Own Code

Question Bot

Simon has built a question bot that will collect questions on The Coding Train Discord so that Daniel Shiffman can answer them during the following live session.

This is something Simon worked on for days and he was thrilled to be able to present a working bot to Daniel. The only issue that remains unresolved is whether the mods should control the bot via a secret password or should a more advanced security system be developed. Daniel has decided to take a long break from live streaming, so the whole project probably won’t be revived until the streams resume. In any case, as Simon has put it, “I know, it’s messy, but it works. And that’s what’s important to me”.

Simon has also created several other bots (and built a separate Discord playground where other people can test their bots as well). He has been doing quite a lot of server side programming lately.

The code is on GitHub: https://github.com/simon-tiger/Question-Bot

The website is on Heroku: http://questionbot-discord.herokuapp.com/

Simon’s “question-answering round” Discord bot is a clone of CJ (Coding Garden)’s VOX system.

Math Tricks, Murderous Maths, Simon's sketch book

Calculating √2

Mom, I’ve tried the ancient Babylonian method and got 0 digits of precision after four iterations. Then I tried the continued fraction method and got four digits of precision after 5 iterations!

Two days later:

9 digits of precision after 13 iterations!

Simon also tried calculating Pi using root 2, but didn’t succeed.
Crafty, Geometry Joys, Murderous Maths, Notes on everyday life, Simon teaching, Thoughts about the world, Together with sis

Doughnut Education

Pondering over the future, I told the kids the universal basic income and Doughnut Economics should be the next step. Simon game me an improvised lecture on doughnut topology. Well, what do you know? The very next day, Simon’s native city of Amsterdam announced it would be the first city in the world to embrace Kate Raworth’s doughnut model!

In the long run, this may even mean we’ll be able to return to our home in Amsterdam we left 4 yrs ago to be able to homeschool. Raworth’s model views the child as much more than simply future “workforce” and that could help personalise education and create legal bearing for Self-Directed Learning. Because let’s face it: Can Industrial-Age schooling really serve as a foundation for a new sustainable mindset?

Below are some impressions of Simon’s doughnut topology tutorial on April 7:

Doughnut is homeomorphic to a mug. ‘Homeomorphic’ is a fancy word for saying ‘topologically the same’.
How many cuts can you make in a hollow sphere to guarantee it isn’t broken into two parts? That maximum number is zero! In topology, we say “the sphere has genus zero”.
Are only shapes without a hole that way? No, this sheet of paper also has genus zero.
Only zero cuts can guarantee it’s not broken into two pieces.
No matter what cut I draw on this mug, it will stay in one piece. I need two cuts to break a mug or a doughnut into two pieces. On a regular doughnut, it corresponds to a ring on the inside and a ring on the outside. A doughnut and a mug both have genus one, one cut can still guarantee they stay in one piece.

Simon emphasised that this trick won’t work with a real doughnut, as Simon explains:

in topology, we’re talking about 2-dimensional manifolds (which means that they are hollow or that they’re just a flat surface). It doesn’t really make sense (not like it doesn’t make sense mathematically, but it just isn’t as interesting) to talk about 3-dimensional manifolds (filled 3D objects, not hollow) unless we’re doing it in 4-dimensional space. In other words, it doesn’t make sense to talk about 3-dimensional manifolds unless they’re embedded in 4-dimensional space.

Biology, Coding, Contributing, Curent Events, Experiments, live stream, Math and Computer Science Everywhere, Milestones, Murderous Maths, Simon teaching, Simon's Own Code, Simon's sketch book

Simon’s Corona Epidemic Simulation Code Along Project

At the beginning of April, Simon started working on his COVID-19 epidemic simulation project, implementing a number of scenarios (like various degrees of hygiene, quarantine, social distancing), explaining his code live on camera so that anyone can code along and create their own simulations.

Simon first started creating this project in p5.js (JavaScript) but quickly switched to Processing (Java). His code is available for download on GitHub at: https://github.com/simon-tiger/Corona-Simulation

The programming language I used is Processing (Java), optimized for Creative Coding purposes. To run the code on your computer, you’ll need to install Processing https://processing.org (I provide more detailed instructions in my GitHub readme).

My basic coronavirus simulation in p5.js: https://editor.p5js.org/simontiger/sketches/lCLuPy0jN

the spread of the virus and recovery
increased hygiene and quarantine
two social distancing scenarios

The project is still in progress, as Simon plans to implement a few more realistic scenarios. He recorded Part III live on Discord (The Coding Train’s Discord channel) and will probably do the same for the upcoming parts, so stay tuned!

Simon sketching while thinking the simulation through. The green, pink and blue circles say: susceptible, infected, recovered.
During his initial attempts to create the simulation in JS from scratch, Simon turned to these wicked algorithms and applied them correctly (as his peers told him reviewing his code), but the code produced chaotic results. He later switched to Java as he remembered one of the build-in examples in Processing could serve as the basis for dots colliding.
Biology, Coding, Contributing, Crafty, Geometry Joys, JavaScript, Laws and cultural differences, Math and Computer Science Everywhere, Math Tricks, Milestones, Murderous Maths, Notes on everyday life, Simon teaching, Simon's Own Code, Simon's sketch book, Thoughts about the world

Corona Math

On March 17, Simon started a series of math and coding projects about COVID-19. The first projects he called Corona Math: Why Social Isolation? 

This is part I of my Corona Math series. In this video, I calculate how many people will be infected with the coronavirus after 10 spreads (I call them iterations). I also calculate how many days there are in each iteration.

Link to another video where I explain what a polynomial is: https://youtu.be/W1faBAn6t5A

In the second video Corona Math: Where is the Inflection Point? (recorded on March 19), I attempt to calculate the “inflection point” for COVID-19, and ultimately fail. I come to the conclusion that it’s too unpredictable, and we’re now only at the very beginning. I used the Wolfram Language for this video, so here’s a link: https://www.wolframcloud.com/obj/721d493e-156b-4131-818c-e59476d1d2aa

10 days later Simon recorded another Corona Math project. In Belgium, we’re having a #Covid_19 “light #lockdown“, which means we’re allowed to walk within a 2km radius from our home. Simon calculated how many people would fit into his designated walking area, considering #SocialDistancing:

Simon’s animation for this last project is online at: https://editor.p5js.org/simontiger/present/VuXRGMLPp (Press the space bar to get to the next slide). Source code: https://editor.p5js.org/simontiger/sketches/VuXRGMLPp

Simon calculating how many people one can infect by having had contact with just three people (nearly 90 thousand)
Simon explaining to me what an inflection point is
Logic, Machine Learning, Milestones, Murderous Maths, Notes on everyday life, Set the beautiful mind free, Simon's sketch book

Learning to See. On Machine Learning and learning in general.

December was all about computer science and machine learning. Simon endlessly watched Welch Labs fantastic but freakishly challenging series Learning to See and even showed me all the 15 episodes, patiently explaining every concept as we went along (like underfitting and overfitting, recall, precision and accuracy, bias and variance). Below is the table of contents he made of the series:

While watching the series, he also calculated the solutions to some of the problems that Welch Labs presented, like the question about the number of possible rules (= grains of sand) for a simple ML problem if memorisation is applied. His answer was that the grains of sand would cover all land on earth:

Simon loved the historical/philosophical part of the course, too. Especially the juxtaposition of memorising vs. learning, the importance of learning to make assumptions, futility of bias-free learning, and the beautiful quotes from Richard Feynman!

screenshot from Welch Labs Learning to See [Part 5: To Learn is to Generalize]

I have since then found another Feynman quote that fits Simon’s learning style perfectly (and I believe is the recipe to anyone’s successful learning as opposed to teaching to the test): “Study hard what interests you the most in the most undisciplined, irreverent and original manner possible.” We have discussed the possibilities of continuing at the university again. I have also asked Simon how he sees himself applying his knowledge down the road, trying to understand what academic or career goals he may have set for himself, if any. Does he have a picture of himself in five years from now, where does he want to be by then? He got very upset, just like when asked to sum himself up in one sentence for an interview last spring. “Mom, I’m just having fun!”

A beautiful humbling lesson for me.

Coding, Contributing, Group, JavaScript, live stream, Milestones, Notes on everyday life, Simon teaching

How Simon takes part in the Coding train live sessions

Every live session Daniel Shiffman mentions Simon several times, usually because Simon gives good feedback/ advice. On the other end, Simon is invigorated and jumping about the room. Sometimes resulting in serious bumps against the furniture.