What you see below is a cube in four dimensions.

Because humans can't see in more than 3D, it is challenging to make sense of it for the first time. However, there is a simple yet beautiful pattern behind.

This is how the magic is done!
What is a cube in one dimension?

It is simply two vertices connected with a line of unit length.
To move beyond and construct a cube in two dimensions, also known as a square, we simply copy a one-dimensional cube and connect each original vertex with its copy.

(These new edges are colored blue.)
You can probably guess the pattern by now.

Copying a cube's graph and connecting each of its vertices with its corresponding copy brings it to the next dimension.

This is how it looks in 3D.
Repeating this process one more time, we obtain a tesseract, that is, a cube in four dimensions.

(I stretched the new edges a bit to make it easier to see the pattern.)
All 8 of its faces are 3D cubes.
I have always found this pattern quite beautiful.

Geometry intrigued me since I was a child, and when I discovered how to draw a tesseract, I was over the moon.

Small things such as this ignited my desire to be a mathematician, and I still enjoy playing around with fun math.
I regularly post deep dive threads about mathematics and machine learning, explaining (seemingly) complex concepts in a simple way.

If you also love to look beyond the surface and understand how things work, consider giving me a follow!

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Tivadar Danka

Tivadar Danka Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @TivadarDanka

31 May
Last week, I lost my mother due to COVID.

Ever since then, I can't really focus on work. I keep thinking about life, death, and the meaning of it all.

I never post personal tweets/threads like this, but I have to write about this.
I am a man of science.

I don't believe in god, heaven, or any kind of afterlife.

I believe that if you die, you cease to exist. You fall into the void.
Everyone is fighting against the third law of thermodynamics.

Entropy increases. Knowledge decays. Your work dissipates.
Read 9 tweets
18 May
Reading research papers is a skill in itself.

I learned it the hard way. After reading hundreds of articles, I figured out the methods of learning and extracting information the simplest way.

Here is how.

🧵 👇🏽
Regardless of fields, most well-written papers have a similar structure:

What is the problem?
🠓
What are the previous works?
🠓
What did previous works miss?
🠓
What is the main result?
🠓
Why does it work?
🠓
How it compares to others?
🠓
What are its limitations?
However, research papers are not meant to be read linearly.

There are several levels of understanding:

knowing
1. how to use the result,
2. when to use it,
3. why and how does it work,
4. and how to improve it.

Depending on your goal, the reading paths might differ.
Read 9 tweets
12 May
What you see below is a 2D representation of the MNIST dataset.

It was produced by t-SNE, a completely unsupervised algorithm. The labels were unknown to it, yet it almost perfectly separates the classes. The result is amazing.

This is how the magic is done!

🧵 👇🏽
Even though real-life datasets can have several thousand features, often the data itself lies on a lower-dimensional manifold.

Dimensionality reduction aims to find these manifolds to simplify data processing down the line.
So, we have data points 𝑥ᵢ in a high-dimensional space, looking for lower dimensional representations 𝑦ᵢ.

We want the 𝑦ᵢ-s to preserve as many properties of the original as possible.

For instance, if 𝑥ᵢ is close to 𝑥ⱼ, we want 𝑦ᵢ to be close to 𝑦ⱼ as well.
Read 15 tweets
11 May
There is a mathematical formula so beautiful that it is almost unbelievable.

Euler's identity combines the famous numbers 𝑒, 𝑖, π, 0, and 1 in a single constellation. At first sight, most people doubt that it is true. Surprisingly, it is.

This is why.

🧵 👇🏽
Let's talk about the famous exponential function 𝑒ˣ first.

Have you ever thought about how is this calculated in practice? After all, raising an irrational number to any power is not trivial.

It turns out that the function can be written as an infinite sum!
In fact, this can be done with many other functions.

For those that are differentiable infinitely many times, there is a recipe to find the infinite sum form. This form is called the Taylor expansion.

It does not always yield the original function, but it works for 𝑒ˣ.
Read 9 tweets
10 May
Creative abuse of rules can lead to game-changing discoveries.

In high school, you learned that -1 has no square roots. Yet, by ignoring this, you'll soon discover something that changed mathematics forever: complex numbers.

Follow along, and you'll see how!

🧵 👇🏽 Image
Let's start with a very simple equation:

𝑥² + 1 = 0

Can we solve this? Not at first glance, since the left side of the equation is always larger than one. This is equivalent to solving

𝑥² = -1,

which is (apparently) not possible. Image
But let's disregard this and imagine a number whose square is -1.

Let's appropriately name it the 𝑖𝑚𝑎𝑔𝑖𝑛𝑎𝑟𝑦 𝑛𝑢𝑚𝑏𝑒𝑟 and denote it with 𝑖.

So, 𝑖² = -1.

Now that we have this strange entity, what can we do?
Read 12 tweets
7 May
One of the biggest misconceptions regarding education is that its main purpose is to give knowledge you can immediately use.

It is not.

The best thing education can give you is the mental agility to obtain knowledge at the speed of light.

Let's unpack this idea a bit!

1/7
Consider a course where you build a custom neural network framework with NumPy.

This is hardly usable in practice: working with a custom library is insane.

However, if you know how they are built, you only need to learn the interface to master an actual framework!

2/7
By understanding how the framework is built and how the underlying algorithms work, you'll be able to do much more: experiment with custom optimizers, implement your own layers, etc.

3/7
Read 7 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!

Follow Us on Twitter!

:(