Pure subgroup implies direct factor in torsion-free abelian group that is finitely generated as a module over the ring of integers localized at a set of primes

Statement
Consider the following:


 * A group $$G$$ that is a torsion-free abelian group that is also an abelian group that is finitely generated as a module over the ring of integers localized at a set of primes. Explicitly, this means that $$G$$ is torsion-free and is finitely generated as a module over $$\mathbb{Z}[\pi^{-1}]$$ where $$\pi$$ is a set of prime numbers. By the structure theorem for finitely generated modules over principal ideal domains, $$G$$ is a finitely generated free module over $$\mathbb{Z}[\pi^{-1}]$$.
 * $$H$$ is a pure subgroup of $$G$$.

Then, $$H$$ must be a direct factor.

Related facts

 * Pure subgroup of torsion-free abelian group not implies direct factor

Facts used

 * 1) uses::Equivalence of definitions of pure subgroup of torsion-free abelian group
 * 2) uses::Structure theorem for finitely generated modules over principal ideal domains

Proof
By Fact (1), $$G/H$$ is also torsion-free. It is also finitely generated over $$\mathbb{Z}[\pi^{-1}]$$. Thus, by Fact (2), it is free as a $$\mathbb{Z}[\pi^{-1}$$-module, and we can thus find a complement to $$H$$ in $$G$$.