A polynomial translation of S4 into T and contraction-free tableaux for S4