add abgabe.lyx and fix some issues in code