This file contains hidden or 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
import numpy as np | |
n = 6 | |
m = 2*(n-1) | |
maximum = (m*(m+1))//2 | |
target = set(range(1,maximum)) | |
def explore(permutations): | |
sums = [ sum(p) for p in permutations ] |
This file contains hidden or 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
\documentclass{article} | |
\usepackage{pgf} | |
\begin{document} | |
\includegraphics{triangle.pdf} | |
\begin{pgfpicture}% | |
\pgfpathrectangle{\pgfpointorigin}{\pgfqpoint{5.433564in}{3.363289in}}% | |
\pgfusepath{use as bounding box, clip}% | |
\definecolor{currentfill}{rgb}{0.796078,0.294118,0.086275}% | |
\definecolor{currentstroke}{rgb}{0.000000,0.168627,0.211765}% |
This file contains hidden or 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
sha512sum | xxd -r -p | tr -cd "[:print:]" |
This file contains hidden or 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
import numpy as np | |
from numpy.random import choice, uniform | |
from time import process_time | |
from scipy.integrate import ode, solve_ivp, odeint | |
from scipy.integrate._ivp.ivp import METHODS | |
from jitcode import jitcode, y | |
from symengine import sin | |
solver_ode = "dopri5" | |
solver_ivp = "RK45" |
This file contains hidden or 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 scipy.integrate import solve_ivp | |
from scipy.integrate._ivp.ivp import METHODS | |
import numpy as np | |
method = "Radau" | |
times = np.linspace(0,500,1000) | |
atol = 1e-10 | |
rtol = 1e-5 |