Well.. one thing for sure... when a it is a mag-cell mag.. it wont evolve to anything else unless another cell is used.
What I was saying about the ids is that...you get a mag to level 50 with group A, gain PB (if its not already there) and evolve... then at the same level you feed it with group B, it will change accordingly to the group B evolution this time wont change PB tho.
My main point was like... if you are going to limit each mag type to certain evolution by themselves... it can get ugly... for example a mag cell that works on any mag, will be on every mag type evo check you have.
You can just have a evolution check code for each evolution level (10 - 35 - 50 - 100) ... and check everything there