Fix a bug in generate_random_formula().

If the lower bound of n_atoms_range is 1, then n_possibles may end up being 0,
causing an empty list of atoms to be generated.