Improve formatting of Mathematica notes