  The Advanced Wakefield (AWAKE) Experiment is a proof-of-principle experiment
demonstrating the acceleration of electron beams via proton-driven plasma
wakefield acceleration. AWAKE Run 1 achieved acceleration of electron beams to
2 GeV and the intention for Run 2 is to build on these results by achieving
acceleration to ~10 GeV with a higher beam quality. As part of the upgrade to
Run 2, the existing proton and electron beamlines will be adapted and a second
plasma cell and new 150 MeV electron beamline will be added. This new beamline
will be required to inject electron bunches with micron-level beam size and
stability into the second plasma cell from within the 1 m gap between the two
plasma cells. In this paper we describe the techniques used (e.g. numerical
optimizers and genetic algorithms) to produce the design of the 150 MeV
electron line in order to meet the challenging experimental specifications.
Operational techniques are also studied for both electron transfer lines
including steering and alignment methods utilising numerical optimizers and
beam measurement techniques employing neural networks.
