fix references (although not until group1.tex is inputted)