rough notes, need tidying