  We prove a pair of transformation formulas for multivariate elliptic
hypergeometric sum/integrals associated to the $A_n$ and $BC_n$ root systems,
generalising the formulas previously obtained by Rains. The sum/integrals are
expressed in terms of the lens elliptic gamma function, a generalisation of the
elliptic gamma function that depends on an additional integer variable, as well
as a complex variable and two elliptic nomes. As an application of our results,
we prove an equality between $S^1\times S^3/\mathbb{Z}_r$ supersymmetric
indices, for a pair of four-dimensional $\mathcal{N}=1$ supersymmetric gauge
theories related by Seiberg duality, with gauge groups $SU(n+1)$ and $Sp(2n)$.
This provides one of the most elaborate checks of the Seiberg duality known to
date. As another application of the $A_n$ integral, we prove a star-star
relation for a two-dimensional integrable lattice model of statistical
mechanics, previously given by the second author.
