We introduce a novel method to improve the computational efficiency for (S)TEM image simulation by employing matrix diagonalization of the mixed envelope function (MEF). The MEF is derived by taking the finite size and the energy spread of the effective electron source into account, and is a component of the transmission cross-coefficient that accounts for the correlation between partially coherent waves. Since the MEF is a four-dimensional array and its application in image calculations is time-consuming, we reduce the computation time by using its eigenvectors. By incorporating the aperture function into the matrix diagonalization, only a small number of eigenvectors are required to approximate the original matrix with high accuracy. The diagonalization enables for each eigenvector the calculation of the corresponding image by employing the coherent model. The individual images are weighted by the corresponding eigenvalues and then summed up, resulting in the total partially coherent image.