Dynamics of the Szekeres system