&GLOBAL
  EPS_CHECK_DIAG 1.0E-14
  PREFERRED_DIAG_LIBRARY ScaLAPACK
  PRINT_LEVEL low
  PROJECT " H2O geoopt "  # check digestion of spaces
  RUN_TYPE GEO_OPT
&END GLOBAL

&MOTION
  &GEO_OPT
    MAX_DR 0.001
    MAX_FORCE 0.00015
    MAX_ITER 3
    OPTIMIZER BFGS
    RMS_DR 0.0005
    RMS_FORCE 0.0001
  &END GEO_OPT
  &PRINT
    &STRESS
    &END STRESS
    &STRUCTURE_DATA
      ANGLE 2 1 3
      ANGLE 2 1 2  # as well as this
      DIHEDRAL 1 2 3 4  # this should result in a error message
      DIHEDRAL 1 2 3 1  # as well as this
      DISTANCE 1 2
      DISTANCE 2 3
      POSITION 1
      POSITION 2
      POSITION 3
    &END STRUCTURE_DATA
  &END PRINT
&END MOTION

&FORCE_EVAL
  METHOD Quickstep
  STRESS_TENSOR analytical
  &DFT
    BASIS_SET_FILE_NAME BASIS_SET
    POTENTIAL_FILE_NAME "GTH_SOC_POTENTIALS"  # quotes needed to allow for this comment
    &MGRID
      CUTOFF 200
    &END MGRID
    &PRINT
      &AO_MATRICES
        NDIGITS 12
        W_MATRIX
      &END AO_MATRICES
    &END PRINT
    &QS
      EPS_DEFAULT 1.0E-8
      EXTRAPOLATION use_prev_p
    &END QS
    &SCF
      EPS_SCF 1.0E-5
      SCF_GUESS ATOMIC
    &END SCF
    &XC
      &XC_FUNCTIONAL Pade
      &END XC_FUNCTIONAL
    &END XC
  &END DFT
  &PRINT
    &FORCES
      FORCE_UNIT eV/Angstrom
      NDIGITS 6
    &END FORCES
    &PROGRAM_RUN_INFO
      ENERGY_UNIT eV
    &END PROGRAM_RUN_INFO
    &STRESS_TENSOR
      STRESS_UNIT kbar
    &END STRESS_TENSOR
  &END PRINT
  &SUBSYS
    &CELL
      ABC 5.0 10.0/2.0 5.0
    &END CELL
    &COORD
      Unit Angstrom
      O   0.000000    0.000000   -0.065587
      H   0.000000   -0.757136    0.520545
      # H   0.000000    0.757136    0.520545 this line should be ignored
      H   0.000000    1.514272/2  0.520545
    &END COORD
    &KIND H
      BASIS_SET DZV-GTH-PADE
      POTENTIAL GTH-PADE-q1
    &END KIND
    &KIND O
      BASIS_SET DZVP-GTH-PADE
      POTENTIAL GTH-PADE-q6
    &END KIND
    &PRINT
      &STRUCTURE_DATA
        ANGLE 2 1 3
        ANGLE 2 1 2  # as well as this
        DIHEDRAL 1 2 3 4  # this should result in a error message
        DIHEDRAL 1 2 3 1  # as well as this
        DISTANCE 1 2
        DISTANCE 2 3
        POSITION 1
        POSITION 2
        POSITION 3
      &END STRUCTURE_DATA
    &END PRINT
  &END SUBSYS
&END FORCE_EVAL
