Electronic band structures and charge densities of NbC and NbN