Notes on Theory of Distributed Systems