The top-order zonal polynomials Ck(A), and top-order invariant polynomials Ck1,…,kr (A1, …, Ar) in which each of the partitions of ki, i = 1, …, r, has only one part, occur frequently in multivariate distribution theory, and econometrics — see, for example, Phillips (1980, Econometrica 48, 861–878; 1984, Journal of Econometrics 26, 387–398; 1985, International Economic Review 26, 21–36; 1986, Econometrica 54, 881–896), Hillier (1985, Econometric Theory 1, 53–72; 2001, Econometric Theory 17, 1–28), Hillier and Satchell (1986, Econometric Theory 2, 66–74), and Smith (1989, Journal of Multivariate Analysis 31, 244–257; 1993, Australian Journal of Statistics 35, 271–282). However, even with the recursive algorithms of Ruben (1962, Annals of Mathematical Statistics 33, 542–570) and Chikuse (1987, Econometric Theory 3, 195–207), numerical evaluation of these invariant polynomials is extremely time consuming. As a result, the value of invariant polynomials has been largely confined to analytic work on distribution theory. In this paper we present new, very much more efficient, algorithms for computing both the top-order zonal and invariant polynomials. These results should make the theoretical results involving these functions much more valuable for direct practical study. We demonstrate the value of our results by providing fast and accurate algorithms for computing the moments of a ratio of quadratic forms in normal random variables.