Experiemtal code using generators and namedtuples