Before revision:  We validate  our framework through rigorous proofs of correctness and efficiency .
After revision:  We validate our framework through runtime experiments. We find our algorithms are up to 15 and 9 times faster than previous algorithms for computing the Shannon entropy and the gradient of the generalized expectation objective, respectively .