First complete version

Tests to be completed
Docs to be completed