On the effects of the heat generated during an electric field-induced ferroelectric domain switching