Skip to content

Instantly share code, notes, and snippets.

View duetosymmetry's full-sized avatar
✌️

Leo C. Stein duetosymmetry

✌️
View GitHub Profile
@duetosymmetry
duetosymmetry / Kartik's toy BVP example.ipynb
Created January 9, 2025 15:54
Kartik's toy BVP example
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@duetosymmetry
duetosymmetry / maybe_texkey_to_doi.py
Created April 10, 2024 16:20
Convert INSPIRE texkey to doi
import json
import urllib.request
def maybe_get_insp_data(url, max_retries=3, sleep_ms=500):
"""Try to query an INSPIRE URL, with retries, and sleeping
Parameters
----------
url: string
@duetosymmetry
duetosymmetry / charge_figure.tex
Created March 3, 2023 04:08
TikZ code for making my figure showing the geometry for discussing multipole expansion
\documentclass[crop,tikz]{standalone}
\usepackage{bbm,bm}
\usetikzlibrary{arrows.meta,bending,positioning,shapes.symbols}
\begin{document}
\begin{tikzpicture}[>=Stealth]
\node[cloud, draw,
fill = gray!10,
minimum width = 6cm,
minimum height = 4cm] (c) at (0.5,0.5) {};
@duetosymmetry
duetosymmetry / lettuce-transparent.png
Last active April 20, 2021 22:41
Lettuce lattice
lettuce-transparent.png
@duetosymmetry
duetosymmetry / rand_perm_lines.py
Created January 24, 2020 16:06
Random permutation of stdin lines
#!/usr/bin/env python3
import sys
import numpy
import argparse
import time
if __name__ == "__main__":
parser = argparse.ArgumentParser()
parser.add_argument('--seed', type=int,
@duetosymmetry
duetosymmetry / interduck.tex
Created September 26, 2018 12:32
🦆🦆➡🦆
\documentclass[preview=true, border=2mm]{standalone}
\usepackage{bm} % boldmath
\usepackage{mathrsfs}
\usepackage{tikz}
\usetikzlibrary{shapes}
\usepackage{tikzducks}
\usepackage{tikz-feynman}
\definecolor{beaublue}{rgb}{0.74, 0.83, 0.9}
\definecolor{amethyst}{rgb}{0.6, 0.4, 0.8}
@duetosymmetry
duetosymmetry / lrr-massage.patch
Last active March 23, 2018 17:44
Difference between INSPRIRE and massaged XML. This is the `diff -u` of the two XML files in this repo: https://github.com/duetosymmetry/lrr-index
--- lrr.xml 2018-03-22 17:09:55.000000000 -0700
+++ lrr-massaged.xml 2018-03-22 17:57:54.000000000 -0700
@@ -465,7 +465,7 @@
<dates>
<year>2010</year>
</dates>
- <abstract/>
+ <abstract>Lunar laser ranging (LLR) has been a workhorse for testing general relativity over the past four decades. The three retroreflector arrays put on the Moon by the Apollo astronauts and the French built arrays on the Soviet Lunokhod rovers continue to be useful targets, and have provided the most stringent tests of the Strong Equivalence Principle and the time variation of Newton’s gravitational constant. The relatively new ranging system at the Apache Point 3.5 meter telescope now routinely makes millimeter level range measurements. Incredibly, it has taken 40 years for ground station technology to advance to the point where characteristics of the lunar retroreflectors are limiting the precision of the range measurements. In this article, we review the gravitational science and technology of lunar laser ranging and
@duetosymmetry
duetosymmetry / graph paper.tex
Last active September 14, 2023 10:59
dot grid update to Bob's graph paper TeX
%%-----------------------------------------------------------------------
%% Make your own quadrille, graph, hex, etc paper!
%% Uses the pgf/TikZ package for LaTeX, which should be part of
%% any modern TeX installation.
%% Email: [email protected]
%% Twitter: @mcnees
%%-----------------------------------------------------------------------
\documentclass[11pt]{article}