ray tracing through a stack of flat plates

Say I want to trace rays in 3 dimensions through a stack of flat plates of various refractive indices. My rays have canonical coordinates {Q,P}. The plates are normal to the z axis, all the rays start together at z=0. When a ray moves through a spacing from one surface to the next, Qout = Qin + t Pin / Pin,z, where that Pin,z is the z component of Pin and t is some constant. I can take all the first derivatives of {Qout,Pout} versus {Qin,Pin} and check that this transformation is, in fact, symplectic.

At the interface between two materials, the rays follow Snell's Law, which is only a function of Pin. Q doesn't change at the interface. But a transformation of {Q,P} that changes P and only depends on P isn't symplectic. What am I miss missing?

• Please use MathJax to write formulas or formula-like objects. It really improves your question. – Victor Pira Nov 7 '15 at 0:13
• I understand nothing, surely due to your notations (and poor definitions). Please use latex math. – Fabrice NEYRET Nov 7 '15 at 10:29
• And what do you mean by "sympleptic transform" ? – Fabrice NEYRET Nov 7 '15 at 10:31
• A symplectic transform has a matrix of first derivatives that form a symplectic matrix link. The transform from inputs to outputs for a Hamiltonian system is always symplectic. – stackexchangesucksimleaving Nov 9 '15 at 23:33