This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import defaultdict | |
from itertools import count | |
import numpy as np | |
__version__ = "2024.12.13" | |
def create_graph(a): | |
"""Returns a graph from a n x n array of bools |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# testing a formula for the k-th prime number | |
# https://math.stackexchange.com/questions/5019919/an-exact-formula-for-the-k-th-prime-number | |
from mpmath import ceil, ln, mp, mpf, zeta | |
mp.dps = 500 | |
mp.pretty = True | |
one = mpf("1") | |
two = mpf("2") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
# | |
# Investigate the use of the self-pipe trick from Python | |
# | |
import logging | |
import os | |
import selectors | |
import signal | |
import struct |
OlderNewer