Theory of Networking