  We present a methodology based on deformations of the unit cell that allows
to compute the isotropic magnetoelastic constants, isotropic magnetostrictive
coefficients and spontaneous volume magnetostriction associated to the exchange
magnetostriction. This method is implemented in the python package MAELAS
(v3.0), so that it can be used to obtain these quantities by first-principles
calculations and classical spin-lattice models in an automated way. We show
that the required reference state to obtain the spontaneous volume
magnetostriction combines the equilibrium volume of the paramagnetic state and
magnetic order of the ground state. We identify an error in the theoretical
expression of the isotropic magnetostrictive coefficient $\lambda^{\alpha 1,0}$
for uniaxial crystals given in previous publications, which is corrected in
this work. The presented computational tool may be helpful to provide a better
understanding and characterization of the relationship between the exchange
interaction and magnetoelasticity.
