Ancient Software Projects

[gadgetry]

No new code here

This page contains some ancient and tiny programming projects. There's a good chance these will have broken some time after posting due to bit rot (e.g. failure to update for more recent versions of their dependencies). I no longer post anything here, as I've switched to hosting my code on Github.

Programs

trg - Display the internal references of a LaTeX document graphically

This short python script parses a LaTeX source file and generates a postscript image showing the internal reference structure of the document. The output is a "semicircle plot" in which semicircular arrows connect pairs of points along a horizontal axis that represent the line numbers of corresponding \ref and \label commands.
[trg output example]
Download: trg.py (python script)

grlen - Compute length functions on a grafting ray

This program is related to my work with Young-Eun Choi, Michael Wolf, and Kasra Rafi on the hyperbolic geometry of grafting rays in Teichmüller space. Using David Wright's program "kleinian" and Donald Marshall's numerical conformal mapping package "zipper", this python script constructs a bending of a Fuchsian punctured torus group, draws the limit set, conformally maps one of the complementary domains to the disk, and then uses this conformal mapping to determine the lengths of a given collection of closed geodesics. Due to the relationship between bending a Fuchsian group and grafting a hyperbolic surface, this is equivalent to grafting a punctured torus, re-uniformizing it (finding the Poincare metric) and then computing geodesic lengths.

Note that this program can only explore a short initial segment on any grafting ray, because it is limited to projective graftings that have quasi-Fuchsian holonomy and injective developing maps.
[grlen output plot]
Download:

Also needed:

dfiler - Document Filer

At one time I used this python script to organize the mathematical papers that I download from the web. This program helps you to choose an appropriate location and filename for a document by displaying a short section of extracted text (which probably contains key metadata like the title and author). Uses the wxPython GUI toolkit, but is broken on recent versions of that package.
Changes in version 0.0.5: Display informative error messages when text extraction fails; removed database code that never worked and was never used; include ".desktop" file for use with window managers.
Changes in version 0.0.4: Better handling of missing 'wxversion' module and version detection in general. First version to be licensed under GPL3.
Changes in version 0.0.3: Better wxPython version detection and selection; now scrubs unicode strings if wxPython does not support unicode, resulting in lower-quality text extraction instead of an exception and exit.
[dfiler screenshot]
Download:

tex-monolith - Remove comments and expand includes/bibliography in TeX/LaTeX

I sometimes use this utility to prepare TeX/LaTeX source for submission to journals or the preprint arXiv. It strips all comments from the input file and replaces all "\include" commands with the contents of the files they reference. It also replaces the bibtex "\bibliography" command with the contents of the associated ".bbl" file. Download:

HDF-XSL - HTML Prettyprinter for HDF5 data files

I used this with Apache Ant to create my gallery of Bers Slice Images (a long time ago).
[hdf-xsl output screenshot]
Download: hdf-xsl-0.1.0.tar.gz

h5frames - Create image sequence from HDF5 data

This python script generates a series of images from datasets in a HDF5 data file using Steven Johnson's utility h5topng. It looks for datasets and groups within the data file whose names are part of a sequence (e.g. group01, group02, …) and converts them to similarly named PNG images. I used this script (and transcode) to create all of my Bers slice animations.

Download: h5frames (python script)

assembleppm - Assemble PPM chunks from POVRay distributed rendering

The ray-tracer POV-Ray supports partial rendering, where a horizontal slice of a scene is generated. However, the resulting PPM files are technically invalid because the header size information refers to the entire image, rather than the rendered section. This small C program assembles a bunch of such partial image files into a single valid PPM.

This utility is based on combineppm by Paul Bourke.

Download: assembleppm.c (C source)

Back to the home page of Emily Dumas