Dividends

Beginning of divis also some bugfixes