we know that p1 times v1 is equal to some constant, and since we have no aggregate change in energy-- i'm just telling you that the box is squeezed, i'm not telling you whether it did any work, or anything like that-- the same constant is going to be equal to the new pressure times the new volume, which is equal to p2 times v2.