First more or less complete version