fixed docs
added what the functions throw
finished