Minor refactorings; closes #15