That's symbolic algebra, which Excel doesn't do. You could write code to do so in VBA (or any other language), but it would be reinventing the wheel; dozens exist.

https://en.wikipedia.org/wiki/List_o...lgebra_systems