SMS: Mathematical theory of entropy