Skip to content

Instantly share code, notes, and snippets.

# This script runs all possible turing machines on all possible (finite) inputs
# idea by Toby Ord: http://www.amirrorclear.net/academic/ideas/simulation/index.html
from itertools import product
tms = []
# https://stackoverflow.com/q/79023187/9779026
def binary_split(v):
# works for v > 0
/-
Written by user "-d" from the https://bbchallenge.org/ Discord (https://discord.gg/3uqtPJA9Uv)
https://wiki.bbchallenge.org/wiki/BB(6)
Hydra:
https://wiki.bbchallenge.org/wiki/Hydra
https://bbchallenge.org/1RB3RB---3LA1RA_2LA3RA4LB0LB0LA
Antihydra:
!ENTRY = 0 R main()[] 1 R main()[]
dec.check = 0 L dec.restore 1 R dec.scan_1
dec.init = 0 R dec.check 0 R dec.check
dec.restore = 1 L return.1 1 L return.1
dec.scan_0 = 0 L dec.scan_done 1 R dec.scan_1
dec.scan_1 = 0 R dec.scan_0 1 R dec.scan_1
dec.scan_done = 0 L dec.shift_0 1 L dec.shift_0
dec.shift_0 = 0 L return2.0 0 L dec.shift_1
dec.shift_1 = 1 L dec.shift_0 1 L dec.shift_1
dispatch.0.carry = 1 L dispatch.1 0 L dispatch.1.carry
0 0 0 R 476
0 1 1 R 476
1 0 0 L 3
1 1 1 R 5
2 0 0 R 1
2 1 0 R 1
3 0 1 L 518
3 1 1 L 518
4 0 0 L 6
4 1 1 R 5
0RSI1RSI_0LD1RF_0RB0RB_1LTY1LTY_0LG1RF_0RE1RF_0LH1LH_0LTZ0LI_1LH1LI_1LK0LL_0LM1LM_1LM0LN_0LO1LO_1LO0LP_0LQ1LQ_1LQ0LR_0LS1LS_1LS0LT_0LU1LU_1LU0LV_0LW1LW_1LW0LX_0LY1LY_1LY0LZ_0LBA1LBA_1LBA0LBB_0L1L_1L0L_0LTX0RBD_1RBC1RBD_0RBF1RBF_0RBG1RBG_1LTY1RBH_0RBG1RBH_0LBJ1LBJ_0LBK0LBK_1LBL1LBL_0LBM0LBM_1LBN1LBN_0LBO0LBO_1LV1LV_0LBQ1LBQ_0LBR0LBR_1LBS1LBS_0LBT0LBT_0LCI0LCI_0LBV1LBV_0LBW0LBW_0LBX0LBX_1LBY1LBY_0LBZ0LBZ_1LBO1LBO_0LCB1LCB_0LCC0LCC_0LCR0LCR_0LCE1LCE_1LCF1LCF_1LCG1LCG_0LCH0LCH_1LCI1LCI_1LCJ1LCJ_1LCK1LCK_1LCL1LCL_0LY0LY_0LCN1LCN_1LCC1LCC_0LCP1LCP_0LCQ0LCQ_1LCR1LCR_1LCS1LCS_1LCT1LCT_0LS0LS_0LCV1LCV_1LCW1LCW_0LCX0LCX_0LDJ0LDJ_0LCZ1LCZ_0LDH0LDH_0LDB1LDB_1LDC1LDC_0LDD0LDD_1LDE1LDE_0LR0LR_0LDG1LDG_1LDH1LDH_0LDI0LDI_1LDJ1LDJ_0LDK0LDK_1LDL1LDL_0LU0LU_0LDN1LDN_0LDO0LDO_0LDP0LDP_0LEC0LEC_0LDR1LDR_1LDO1LDO_0LDT1LDT_1LDU1LDU_0LDV0LDV_0LEH0LEH_0LDX1LDX_0LEF0LEF_0LDZ1LDZ_1LEA1LEA_0LEB0LEB_1LEC1LEC_1LR1LR_0LEE1LEE_1LEF1LEF_0LEG0LEG_1LEH1LEH_1LDK1LDK_0LEJ1LEJ_0LEK0LEK_1LEL1LEL_1LEM1LEM_0LEN0LEN_0LEO0LEO_1LEP1LEP_0LEQ0LEQ_0LFS0LF
!ENTRY = 0 R main()[] 1 R main()[]
dec.check = 0 L dec.restore 1 R dec.scan_1
dec.init = 0 R dec.check 0 R dec.check
dec.restore = 1 L return.1 1 L return.1
dec.scan_0 = 0 L dec.scan_done 1 R dec.scan_1
dec.scan_1 = 0 R dec.scan_0 1 R dec.scan_1
dec.scan_done = 0 L dec.shift_0 1 L dec.shift_0
dec.shift_0 = 0 L return2.0 0 L dec.shift_1
dec.shift_1 = 1 L dec.shift_0 1 L dec.shift_1
dispatch.0.carry = 1 L dispatch.1 0 L dispatch.1.carry
!ENTRY = 0 R main()[] 1 R main()[]
dec.check = 0 L dec.restore 1 R dec.scan_1
dec.init = 0 R dec.check 0 R dec.check
dec.restore = 1 L return.1 1 L return.1
dec.scan_0 = 0 L dec.scan_done 1 R dec.scan_1
dec.scan_1 = 0 R dec.scan_0 1 R dec.scan_1
dec.scan_done = 0 L dec.shift_0 1 L dec.shift_0
dec.shift_0 = 0 L return2.0 0 L dec.shift_1
dec.shift_1 = 1 L dec.shift_0 1 L dec.shift_1
dispatch.0.carry = 1 L dispatch.1 0 L dispatch.1.carry
0RQV1RQV_0LD1RF_0RB0RB_1LSI1LSI_0LG1RF_0RE1RF_0LH1LH_0LSJ0LI_1LH1LI_1LK0LL_0LM1LM_1LM0LN_0LO1LO_1LO0LP_0LQ1LQ_1LQ0LR_0LS1LS_1LS0LT_0LU1LU_1LU0LV_0LW1LW_1LW0LX_0LY1LY_1LY0LZ_0LBA1LBA_1LBA0LBB_0L1L_1L0L_0LSH0RBD_1RBC1RBD_0RBF1RBF_0RBG1RBG_1LSI1RBH_0RBG1RBH_0LBJ1LBJ_1LBK1LBK_0LBL0LBL_0LBM0LBM_0LBU0LBU_0LBO1LBO_0LBR0LBR_0LBQ1LBQ_1LBR1LBR_1LBS1LBS_0LBT0LBT_1LBU1LBU_0LS0LS_0LBW1LBW_0LCI0LCI_0LBY1LBY_0LBZ0LBZ_0LCA0LCA_1LCB1LCB_1LCC1LCC_1LCD1LCD_1LCE1LCE_1LCF1LCF_0LY0LY_0LCH1LCH_1LCI1LCI_0LCJ0LCJ_1LBT1LBT_0LCL1LCL_1LCM1LCM_0LCN0LCN_0LCX0LCX_0LCP1LCP_1LCQ1LCQ_0LCR0LCR_1LCS1LCS_0LR0LR_0LCU1LCU_1LCV1LCV_0LCW0LCW_1LCX1LCX_0LEP0LEP_0LCZ1LCZ_0LDA0LDA_1LCR1LCR_0LDC1LDC_0LDD0LDD_0LDE0LDE_0LEJ0LEJ_0LDG1LDG_1LDH1LDH_0LDI0LDI_0LEO0LEO_0LDK1LDK_0LDL0LDL_0LDM0LDM_1LDN1LDN_1LDO1LDO_1LDP1LDP_1LDQ1LDQ_1LDR1LDR_1LDS1LDS_0LBA0LBA_0LDU1LDU_0LDV0LDV_1LDI1LDI_0LDX1LDX_0LDY0LDY_1LDZ1LDZ_1LEA1LEA_0LEB0LEB_1LEC1LEC_0LED0LED_0LEE0LEE_0LFL0LFL_0LEG1LEG_1LEH1LEH_0LEI0LEI_1LEJ1LEJ_1LR1LR_0LEL1LEL_0LEM0LEM_1LEN1LEN_1LEO1LEO_1LEP1LEP_1LEQ1LEQ_0LU
# stolen from here: https://amor.cms.hu-berlin.de/~rodrigus/Jupyter%20Notebooks/Solar_System_N-Body_Simulation.html
import numpy as np
import scipy as sp
import time
import scipy.constants as cs
import matplotlib.pyplot as plt
from numba import jit
from numba import cuda
from mpl_toolkits.mplot3d import Axes3D
from astropy.time import Time
# Python 3.9+
# You need to get and put your API key here https://developers.google.com/youtube/v3/getting-started
APIKEY = "XYZYOURSECRETAPIKEYXYZ"
from time import sleep
import csv
import requests
f = open("subscriptions.csv")