How can I get the font to be Times New Roman when using maths typing in matplotlib. The default font is italic, and I'm trying to make it match the other axes titles.
I'm trying to use \mathrm{}:
plt.xlabel(r"$\frac{\mathrm{1}}{{\mathrm{Distance}}^2 \ (\mathrm{m}^2)}$")
as suggested on a matplotlib website (https://matplotlib.org/users/mathtext.html) but it still appears as a sans-serif font. Is there a way I can make this into Times new Roman? Thanks!