derived state and some more fixes #68
fixes #68 fixes #69 fixes #70