An electromechanical model for the electrochemical oxidation of conducting polymers