Symplectic integration of hierarchical stellar systems