The Wiener index (W) is a graph invariant. Because of its importance, various methods – numerical approaches and analytical formulas – have been proposed to compute W. Earlier formulas of W were derived for homeomorphic structures, polymers, and stars. The formulas are polynomials. In this paper, a method is proposed that allows calculating the coefficients of the polynomials in sets of non-homeomorphic structures