Molly

mostly reorganizing existing code