anchor.diff:                  end if
               end do
   
  +            ! Can select from any of the nbasis functions.
  +            ! Convert number, x, in range [1,nbasis] to any number in range
  +            ! [1,nbasis] using simply x (for compatibility with spin=-2,2).
               fac = 1
               shift = 0
               na = nbasis
  
positive.code:                 end if
              end do
  
              fac = 2
              shift = 0
              na = nbasis/2
  
negative.code:                 end if
              end do
  
              ! nbasis/2 functions of this spin.
              ! all basis functions of this spin are odd.
              ! Convert number, x, in range [1,nbasis/2] to odd number in range
              ! [1,nbasis] using 2*x-1
              fac = 2
              shift = 1
              na = nbasis/2
  