IF YOU WANT TO SKIP TO THE IMAGE OF THE FRACTAL, CLICK THE LAST LINK IN THIS POST

I’ve been messing around with a fractal generating program I made a while ago, and when it comes to the subject of dragon curves, there are several famous ones (the Heighway Dragon and the Golden dragon are two of them). There’s not really a good strict definition of a “dragon curve” that I’ve found, but the Golden Dragon and Heighway Dragon have almost the same motif, one of them simply has a different angle and line proportions: https://i.imgur.com/m2uBwy9.png (Golden Dragon) https://i.imgur.com/J3pEsxD.png (Heighway Dragon)

Of the many similar fractals you can get by manipulating these angles and proportions, one particularly interested me: if you manipulate the proportions just right, you end up with a curve that almost perfectly overlaps itself https://i.imgur.com/A0DzjxO.png

Today I sat down and decided I was going to figure out the exact right proportions I need to get a perfect overlap. For that to happen, these two corners on iteration 5 need to be in the same place: https://i.imgur.com/VZY0tOl.png

To understand how I went about solving this problem, let’s start by labeling our triangle’s sides and angles:

https://i.imgur.com/2GmaAKp.png For the purpose of simplifying the math, we’re going to start with the assumption that side C is 1. Note that this triangle is NOT a right triangle.

Here is iteration 2: https://i.imgur.com/DxShJQD.png

This shows iteration 1 (outlined in red) morphing into iteration 2. note the proportions of iteration 1 are equal to those of the motif triangle. https://i.imgur.com/6HTTLl4.png

We know that this triangle is similar to our original: https://i.imgur.com/jhWqcVC.png because during the iteration, both sides A and B are multiplied in length by side B and offset by angle a to make the sides of that triangle.

Here’s where it gets interesting; I’m going to take iterations 2 through 5 and paste them on top of each other: https://i.imgur.com/1JgyU9z.png

Take a look at this: https://i.imgur.com/1YvUjrL.png On those 3 iterations, the red line iterates 3 times, each time being multiplied by the length of side A and being rotated by angle b. In the end, the endpoint of it is the point we want to match up with the end of the blue line. The blue line is side B of the original triangle! That means for the triangle we want, we need side A to be the length of side B when it is multiplied by side A 3 times, and to be lined up with side B when it is rotated by angle b 3 times. That gives us these equations:

A^{4} = B

b*3 = c

The first step to solving this is to take of our law of cosines:

A^{2} = B^{2} + C^{2} – 2*B*C*cos(a)

B^{2} = A^{2} + C^{2} – 2*A*C*cos(b)

C^{2} = A^{2} + B^{2} – 2*A*B*cos(b)

Using substitution for the latter two with C = 1, B = A^{4} and b = 3c, we get these two equations:

A^{8} = A^{2} + 1 – 2 * A * cos(c/3) 1 = A^{2} + A^{8} – 2 * A^{5} * cos(c)

Alright, we have 2 equations and 2 variables! We can solve it now! Unfortunately, this set of equations sort of explodes when you try to solve it by hand, so instead of spending all day doing that (assuming you can even figure out how) we’re going to plug it into Wolfram Alpha: http://www.wolframalpha.com/input/?i=0+%3C+c+%3C+pi,+1+%3D+A%5E2+%2B+A%5E8+-+2+*+A%5E5+*+cos(c),+A%5E8+%3D+A%5E2+%2B+1+-+2+*+A+*+cos(c%2F3),+solve+for+A,+c+is+real

This gives us 2 answers, obviously we want the set where A is positive:

A≈0.844772 c≈1.60217

All I have to do now is some simple math and get the point which to enter for the apex of our triangle, and we have a winner!

https://i.imgur.com/SoBHovc.png

Here’s a larger picture of what I call the “Perfectly Overlapping Dragon Curve”: https://i.imgur.com/8jEPyWF.png