Brian C. Wells' Homepage –

Table of Contents

Last Updated
August 26, 2016

Hi. I am Brian C. Wells, and this is my personal website. I intend to publish software and articles about whatever interests me: mostly computer science, mathematics, and economics/politics.

I am an Associate Member of the Free Software Foundation, which simply means I donate $10/month to help them develop all their great software. I use 100% free software Operating Systems exclusively. My laptop computer runs Trisquel GNU/Linux — based on Ubuntu (and therefore also Debian), but with all non-free software removed. I buy most of my hardware from ThinkPenguin, which allows me to run a 100% free OS like Trisquel without significant compatibility problems. On my cell phone, I run Replicant, another fully free OS — based on Android, but again with all non-free software removed. Recently, I canceled my Netflix subscription because I am tired of financially supporting a service that I can only actually use on some device that I supposedly "own" and yet they have stolen my right to control.


August 26, 2016: Something Useful!

I finally have something to put on this website which I think is genuinely useful to someone besides me. I used Emacs Org mode to write an article on how to derive rotation matrices by purely algebraic methods, and I wanted to publish it in both HTML and PDF formats. But since it uses a lot of mathematical notation, I ran into a problem that both I and others have had with Org mode: the MathJax library (for LaTeX math in HTML) and real LaTeX (for PDF) have slightly different expectations for where and how LaTeX macros should be defined, and Org mode does not try to solve the problem.

Several people have provided work-arounds for the problem, but so far they all seem to require either

  1. installing a large Emacs Lisp (.el) file somewhere, and still quite clunky to use, such as manually updating a dynamic block; or
  2. using only a single very restricted method of defining macros, namely \global\def inside \(...\) in an Org mode drawer.

Inspired by another GitHub repository to take advantage of Org mode's (undocumented?) ability to evaluate Emacs Lisp code in its own native macro definitions (at least in the version I tested with), I managed to write an Org mode setup file which has neither of these problems. The source code is available as an Org mode literate program in this GitHub repository, the unannotated setup file is here, and rotation is the article I wrote it for.



A simple literate program that uses an (apparently) undocumented feature of Org mode to make all varieties of (La)TeX definitions work in both HTML and PDF output.



A purely algebraic derivation of the 2-D rotation matrix. First article that uses org-tex-define.


You can send email to my first name (Brian) at this domain.

Author: Brian C. Wells

Created: 2016-08-26 Fri 10:00

Emacs 24.5.1 (Org mode 8.2.10)