In order to run growing string calculations, first you need the optimized geometry of the reactant and product. For surface reactions, we need to define the slab and adsorbate species. The atomic simulation environment (ASE) is the tool we are going to use. ASE is implemented in Python and automates the process to some extent (e.g, if you are using VASP as the calculator, it creates all the input files). The following script is the general form of a geometry optimization script.
There are comments added to the code explaining each part. If VASP is used as the calculator (which happens almost always), make sure to run each job in a separate directory. To run an optimization job, copy this script and a queue submission script (example given in general information section) in a directory. There are also a couple of settings needed in your bashrc file (check the general information section).
For simple diatomic molecules like CO, the position and bond length of adsorbate (CO) can be defined using the script (like the one below), but there are cases where you have a more complicated adsorbate (like propanoic acid) and you want to adjust the position of the molecule on surface. In this case, use ASE to create the slab and optimize it, then using Avogadro (check the general information section) add molecule to the surface. After this step, surface and adsorbate should be optimized together, so copy (see general information section on how to copy from/to the cluster) the structure created by Avogadro as input.xyz file to the same directory and add the molecule to the surface in the script (lines 18 & 23). The order of atoms in input.xyz file and on the script (line 18) should be conserved. To set up the surface with new coordinates read from input.xyz, the lines 30-32 should be in the script.
More examples of setting up metal and metal oxide surfaces are given in surface set up section.