Text this: Templates for the solution of algebraic eingenvalue problems