( ( When ( brakes ( are applied ) ) ) ( , ( ( each ( of ( the motors ) ) ) ( ( is ( reversed ( into ( ( ( an ( electric generator ) ) , ) ( ( ( ( ( turning ( ( the ( kinetic energy ) ) ( of ( the trolley ) ) ) ) ( into ( ( electric energy ) ( that ( is ( ( fed back ) ( to ( the wires ) ) ) ) ) ) ) ) and ) ultimately ) ( to ( other vehicles ) ) ) ) ) ) ) . ) ) ) )
(ROOT (S (SBAR (WHADVP (WRB When)) (S (NP (NNS brakes)) (VP (VBP are) (VP (VBN applied))))) (, ,) (NP (NP (DT each)) (PP (IN of) (NP (DT the) (NNS motors)))) (VP (VBZ is) (VP (VBN reversed) (PP (IN into) (NP (NP (DT an) (JJ electric) (NN generator)) (, ,) (VP (VP (VBG turning) (NP (NP (DT the) (JJ kinetic) (NN energy)) (PP (IN of) (NP (DT the) (NN trolley)))) (PP (IN into) (NP (NP (JJ electric) (NN energy)) (SBAR (WHNP (WDT that)) (S (VP (VBZ is) (VP (VBN fed) (PRT (RP back)) (PP (TO to) (NP (DT the) (NNS wires)))))))))) (CC and) (ADVP (RB ultimately)) (VP (TO to) (NP (JJ other) (NNS vehicles)))))))) (. .)))
When brakes are applied, each of the motors is reversed into an electric generator, turning the kinetic energy of the trolley into electric energy that is fed back to the wires and ultimately to  other vehicles.
(ROOT (S (NP (NNP Electric) (NNS motors)) (VP (VB transform) (NP (JJ electrical) (NN energy)) (PP (IN into) (NP (JJ kinetic) (NN energy)))) (. .)))
Electric motors transform electrical energy into kinetic energy.