Skip to content

Instantly share code, notes, and snippets.

View christianp's full-sized avatar

Christian Lawson-Perfect christianp

View GitHub Profile
@christianp
christianp / placement.ipynb
Created September 14, 2019 13:33
Placement puzzle picture
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@christianp
christianp / README.md
Created March 27, 2019 09:07
MathJax for mastodon

These patches are based off Mastodon v2.7.1. They will probably need some work to apply to future releases.

mathjax.diff adds MathJax to render LaTeX. You need a copy of MathJax under the URL /MathJax. Write inline maths between \( and \), and display-mode maths between \[ and \].

autolatex.diff adds automatic replacement of some LaTeX with unicode equivalents in the toot compose box. It only applies to text not within LaTeX delimiters, so doesn't interfere with MathJax.

@christianp
christianp / bank-note-names.ipynb
Created November 27, 2018 16:12
Names of scientists nominated to appear on the new £50 note
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@christianp
christianp / mathsjam-2018-compo-compo-compo.ipynb
Created November 18, 2018 11:40
Working-out for the lowest-entry-not-in-an-arithmetic-sequence with other entries competition
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
from math import factorial, sqrt, floor
id = lambda x: x
commands = {
's': sqrt,
'f': floor,
'!': factorial,
}