moving code around to improve initialization in preparation to adding molecules.