OFFSET
1,5
LINKS
Code Golf Stack Exchange user Domenico Modica, Eye test - How many squares are in this picture?
Wikipedia, Dragon Curve
EXAMPLE
For n = 5, the fifth iteration of the Harter-Heighway dragon has a(5) = 4 squares, as illustrated below. All of the squares are 1 X 1.
*---*
| |
*---* *
|
*---*
|
*---*---* *---* *---*
| | | | | | |
*---* *---*---*---* *---*
| | |
*---*---* *---*
| |
*---*
For n = 7, the seventh iteration of the Harter-Heighway dragon has a(7) = 30 squares, as illustrated below. It contains A003230(7) = 28 1 X 1 squares and two 2 X 2 squares.
_ _
|_|_| |_
_ _| _|
|_|_|_
|_|_|
|_ _ _ _
_ _|_|_| _|_| _|_|
|_|_|_|_|_ _|_|_ _|_|_ _
|_| |_| |_|_|_|_|_| |_| |_|_|
|_|_|_|_ |_
_ _|_| |_| _|
|_|_|_|_ |_|
|_| |_|
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Peter Kagey, Jan 05 2021
EXTENSIONS
a(17)-a(26) from Bert Dobbelaere, Jun 15 2024
STATUS
approved