Golden Ratio Numbers
Discovering Repeating Digit Patterns in the Golden Ratio
φ = 1.6180339887498948482045868343656381177203091798057...
Current Search Progress
Discovered Patterns
First occurrence of consecutive identical digits in φ:
| Run | Sequence | Decimal Place | Timing | Status |
|---|---|---|---|---|
| Loading experiment data... | ||||
Diagonal Patterns
Finding patterns where digit N repeats N times: 1, 22, 333, 4444, 55555, 666666, 7777777, 88888888, 999999999
| Pattern | Sequence | Decimal Place | Timing | Status |
|---|---|---|---|---|
| Loading diagonal pattern data... | ||||
Research Timeline
Programming a new Python script to compute and record 100 trillion digits of φ (approximately 100 terabytes of data). This will enable discovery of digit runs far beyond current known records.
Estimated launch date for the 100 trillion digit computation. Extended search results and potential discovery of run length 11+.
The Search Command
python goldenratiofinder.py --max-digits 1T --max-run 100 --save phi_runs.json ====================================================================== Golden Ratio (φ) Run Finder - mpmath Computation ====================================================================== Target: 1.00T digits Looking for: runs of 2 to 100 identical digits Backend: mpmath ======================================================================
About the Golden Ratio
The Golden Ratio (φ) is an irrational number approximately equal to 1.618033988749... Like pi, its decimal expansion goes on forever without repeating. This project searches for the first occurrence of each "run" - consecutive identical digits - within the decimal expansion of φ.
Interesting fact: The run of 8 identical 5's (55555555) starts at the same position as the run of 7 identical 5's - position 771,952. This means there's actually a run of at least 8 consecutive 5's at that location!
Try It Yourself - Interactive Terminal
Run the Golden Ratio pattern finder directly in your browser. Type help for commands.
Python Source Code
Copy this code to run the Golden Ratio pattern finder on your system.
#!/usr/bin/env python3
# golden_ratio_patterns.py - Interactive φ Run Finder with curses UI
# pip3 install mpmath --break-system-packages
# python3 golden_ratio_patterns.py
import curses
import sys
import time
from mpmath import mp
DIGITS = 333_333_333 # Calculate 333 million digits to find all 9 patterns
# digit '0'..'9' → curses color_pair index (for runs ≥ 2)
RUN_COLOR_MAP = {
'0': 2, '1': 2, '2': 3, '3': 3, '4': 4,
'5': 4, '6': 5, '7': 5, '8': 6, '9': 6,
}
# run-length n → highlight color_pair index
HIGHLIGHT_PAIR = {2:2, 3:4, 4:3, 5:7, 6:8, 7:9, 8:10, 9:11}
# Known patterns in φ
KNOWN_PATTERNS = {
2: ("33", 7),
3: ("222", 131),
4: ("4444", 1218),
5: ("99999", 6401),
6: ("555555", 99790),
7: ("5555555", 771952),
8: ("55555555", 771952),
9: ("333333333", 314529196),
}
def print_legend(header_win, width):
header_win.addstr(1, 2, "Len: ", curses.A_BOLD)
col = 7
for n in range(2, 10):
digit = KNOWN_PATTERNS[n][0][0]
label = f"{n}={digit}"
attr = curses.A_REVERSE | curses.color_pair(HIGHLIGHT_PAIR[n])
if col + len(label) + 2 < width - 2:
header_win.addstr(1, col, label, attr)
col += len(label) + 1
def curses_main(stdscr):
curses.curs_set(0)
curses.start_color()
curses.use_default_colors()
for i, c in enumerate([curses.COLOR_WHITE, curses.COLOR_RED, curses.COLOR_GREEN,
curses.COLOR_YELLOW, curses.COLOR_BLUE, curses.COLOR_MAGENTA, curses.COLOR_CYAN,
curses.COLOR_BLUE, curses.COLOR_MAGENTA, curses.COLOR_RED, curses.COLOR_YELLOW], 1):
curses.init_pair(i, c, -1)
h, w = stdscr.getmaxyx()
if h < 20 or w < 80:
stdscr.addstr(0, 0, "Terminal too small. Resize to at least 80×20.")
stdscr.getch()
return
header_win = curses.newwin(10, w, 0, 0)
digit_win = curses.newwin(h - 10, w, 10, 0)
digit_win.scrollok(True)
digit_win.idlok(True)
title = "★ φ-Run Finder (333M digits, lengths 2…9) ★"
header_win.addstr(0, max(0, (w // 2) - (len(title) // 2)), title, curses.A_BOLD)
print_legend(header_win, w)
for n in range(2, 10):
header_win.addstr(n, 2, f"Len {n}: searching...")
header_win.refresh()
digit_win.addstr("Computing φ to 333,333,333 digits...\n", curses.color_pair(4))
digit_win.refresh()
compute_start = time.time()
mp.dps = DIGITS + 100
phi_str = mp.nstr((1 + mp.sqrt(5)) / 2, DIGITS + 2, strip_zeros=False)
compute_time = time.time() - compute_start
digit_win.addstr(f"Computed {len(phi_str)-2:,} digits in {compute_time:.1f}s\n\n", curses.color_pair(3))
digit_win.refresh()
time.sleep(1)
total_pos, run_char, run_len = 0, None, 0
remaining, start_time = set(range(2, 10)), time.time()
for ch in phi_str:
total_pos += 1
if not ch.isdigit():
run_char, run_len = None, 0
continue
run_len = run_len + 1 if ch == run_char else 1
run_char = ch
if run_len in remaining:
n, start_pos = run_len, total_pos - run_len + 1
elapsed, seq = time.time() - start_time, run_char * n
if elapsed >= 3600:
time_str = f"{int(elapsed//3600)}h {int((elapsed%3600)//60)}m"
elif elapsed >= 60:
time_str = f"{int(elapsed//60)}m {elapsed%60:.1f}s"
else:
time_str = f"{elapsed:.3f}s"
info = f"Len {n}: {seq} @ {start_pos:,} [{time_str}]"
hl_attr = curses.A_REVERSE | curses.color_pair(HIGHLIGHT_PAIR[n])
header_win.move(n, 2)
header_win.clrtoeol()
header_win.addstr(n, 2, info[:w-4], hl_attr)
header_win.refresh()
curses.beep()
time.sleep(1)
remaining.remove(n)
pair = curses.color_pair(RUN_COLOR_MAP.get(run_char, 1)) if run_len >= 2 else curses.color_pair(1)
if run_len >= 2 and run_char in '13579': pair |= curses.A_BOLD
try:
digit_win.addstr(ch, pair)
except curses.error:
pass
digit_win.refresh()
total_time = time.time() - start_time
time_str = f"{int(total_time//3600)}h {int((total_time%3600)//60)}m" if total_time >= 3600 else f"{int(total_time//60)}m"
digit_win.addstr(f"\n\n═══ COMPLETE ═══ All 9 patterns found in {time_str}\n", curses.color_pair(3) | curses.A_BOLD)
digit_win.addstr("Press any key to exit.")
digit_win.refresh()
stdscr.nodelay(False)
stdscr.getch()
def main():
print("★ φ-Run Finder ★")
print(f"Target: {DIGITS:,} digits")
print("Starting curses interface...\n")
curses.wrapper(curses_main)
if __name__ == "__main__":
main()
Source Code
This project is open source. You can verify and review all the code used to find these patterns.
View the Python source code for goldenratiofinder.py and verify our methodology.