Skip to content

Instantly share code, notes, and snippets.

Jeff Thompson jeffThompson

View GitHub Profile
View LargestNumberOfZerosICouldCount.py
'''
LARGEST NUMBER OF ZEROS I COULD COUNT
Jeff Thompson | 2018 | jeffreythompson.org
After a breakfast conversation with Angeles, this script calculates
a number with so many zeros you couldn't count them in your lifetime.
RESULTS
8 hrs/day: 1 with 300,318,091 zeros
@jeffThompson
jeffThompson / IsCountableNoun.py
Last active Jul 15, 2019
A Python function to test if a noun is countable. Too many requests will get you locked out, so use sparingly.
View IsCountableNoun.py
# -*- coding: utf-8 -*-
import re, urllib2, json
def countable_noun(thing):
'''
searches Google NGram to see if a word is a countable/mass noun
returns True if countable, False if not
@jeffThompson
jeffThompson / Words In The Periodic Table: Results
Created Dec 4, 2013
A (partial but pretty extensive) list of words that can be made from the elements in the periodic table.
View Words In The Periodic Table: Results
Ac
AcCePt
AcCePtS
AcCEsS
AcCEsSeS
AcCrUAl
AcCRuAl
AcCrUAlS
AcCRuAlS
AcCrUEs
View CrosshatchImage.pde
float gridSize = 20;
boolean crosshatch = true;
PImage img;
void setup() {
size(1400, 788);
pixelDensity(displayDensity());
@jeffThompson
jeffThompson / Every Word In The Periodic Table
Last active Mar 15, 2018
Python script to generate all the possible words that can be made from the periodic table.
View Every Word In The Periodic Table
'''
EVERY WORD IN THE PERIODIC TABLE
Jeff Thompson | 2013 | www.jeffreythompson.org
Takes as its input the abbreviations of the elements in the
periodic table and returns all possible words that can be
generated from that input*.
Idea occurred while sitting through a boring meeting in a
lecture hall, staring at a periodic table on the wall.
@jeffThompson
jeffThompson / JPEGCompression
Created Apr 10, 2016
A Processing sketch to save JPG images with variable compression
View JPEGCompression
/*
JPEG COMPRESSION
Jeff Thompson | 2016 | www.jeffreythompson.org
For web-based images, controlling the compression of a JPG
can optimize dimensions and file size. The built-in save()
command for Processing doesn't give us this control, but we
can use Java's ImageIO to add this functionality.
*/
View TrumpWikipediaEdits_Additions.txt
213077: trump
91662: donald
75669: 2016
74596: news
72122: http
69864: title
66856: date
66778: cite
64664: 2015
45687: accessdate
@jeffThompson
jeffThompson / GetPatentImages.py
Last active Jun 19, 2017
A little Python script that automatically downloads images associated with a patent listing
View GetPatentImages.py
'''
GET PATENT IMAGES
Jeff Thompson | 2017 | jeffreythompson.org
A little Python script that automatically downloads
images associated with a patent listing. Use Google's
Patent Search first, then the "Download (CSV)" button
to save a file with all the results.
View Si4703.cpp
/*
Si4703 LIBRARY FOR ATTINY CHIPS
Jeff Thompson | 2017 | jeffreythompson.org
See .h file for credit where credit is due.
*/
#include "Arduino.h"
#include "Si4703_ATtiny.h"
View Si4703.h
/*
Si4703 LIBRARY FOR ATTINY CHIPS
Jeff Thompson | 2017 | jeffreythompson.org
A library for the Si4703 FM radio breakout from Sparkfun
for ATtiny chips like the ATtiny85. Mostly a little work
porting to the TinyWireM library, plus a bit of general
cleanup and formatting.
You can’t perform that action at this time.