The Reconfiguration Matrix (or Internal Reconfiguration Matrix) is a device within Optimus Prime which allows him to transform his body into numerous entirely distinct robot and vehicle modes. It can also reconfigure the bodies of others and even produce new bodies for dissociated sparks.
Generation 2 manga
In an epic battle with Megatron, Optimus Prime's weaponry was disabled by Hooligan. He was then badly injured by an attack from Dreadwing and Smokescreen. Megatron finally administered the fatal blow and believed his enemy was finally finished. The sparks of past Autobot leaders within the Matrix of Leadership then activated the Reconfiguration Matrix, reviving Optimus Prime as Battle Convoy.
Timelines toy bios
e-Hobby toy bios
When Galvatron II threatened the galaxy with a mobile battle fortress, the deceased Matrix-bearer Ultra Magnus became aware of it from within the Matrix. He reached out to Optimus Prime and used the Autobot leader's Reconfiguration Matrix to resurrect himself in a new Laser Rod body. Magnus also gained the ability to convert into other forms (such as his original body).