Nature of the band gap of silicon and germanium nanowires