Documentation

this is a first draft of code documentation

I will improve it as I use it