Optimal reaction conditions for the minimization of energy consumption and by-product formation in a poly(ethylene terephthalate) process