Susi is almost, but not quite, correct.
The C 0
line does indeed specify which atoms the following basis set definition applies to, but the zero actually specifies nothing at all (it's just a terminating character, indicating the end of that particular line).
The center identifier line specifies a list of centers on which to place the basis functions in the center definition block, terminated by a 0. It can contain one or more integers, which are used to indicate the corresponding atom(s) in the molecule specification; more commonly, it contains a list of atomic symbols to refer to all atoms of a specific type. Center numbers and atomic symbols may be freely intermixed within a single center identifier line.
From the Gaussian manual. Bolding my own.
So C 0
applies to all Carbon atoms. Additionally, if there are no carbons, the calculation will stop.
Gaussian also allows you to identify atoms by their index, so:
1 2 3 0
6-31G*
****
Would apply 6-31G* to the first 3 atoms.
These styles can also be combined, which is useful but slightly confusing at first:
C 1 2 3 0
6-31G*
****
Applies 6-31G* to all carbon atoms, and atoms 1, 2, and 3 (even if those atoms are not C).
Finally, you can use a third style to identify atoms by their elemental symbol, preceded by a minus sign (-
). This will allow the calculation to proceed even if those elements are not present:
-C
6-31G*
****
Would apply 6-31G* to any carbon atoms, and won't stop the calculation if there are none. Note (confusingly) that the terminating zero can be omitted in this case:
To help detect input mistakes, if a center definition block specifies an atom that is not present in the molecule, the run is aborted. If the center is preceded by a minus sign (e.g. -H), the basis set information is simply skipped if no atom of that type is present in the molecule specification (the terminal zero may also be omitted in this case).
The Gaussian manual doesn't make it clear if you can interchange the negative symbol form with the integer form (eg. -C 1 0
), or even if you can include multiple negative symbols (-C -H
or -C -H 0
?), but as the terminating character isn't used here I suspect that it is not allowed.
C 0
andCu 0
means these are the basis sets to be used for any C atom. If you instead put in a positive integer, likeC 2
, then the basis will be used for the second atom in the system, which should be carbon. YMMV $\endgroup$