Started writing a memo that explains what the code does.