First stage finished. Added documentation.