Many fixes. Documentation.