They are mainly used to dissipate regenerated electrical energy from the motor and go into the electronic drive inverter during braking. If possible, this regenerated energy will be used to charge the battery. However, there are conditions when the battery cannot take (all) the energy, e.g., when it is cold or when the battery is fully charged.