Well you have two options:
Take a photo if your any good with the photo shop
I would draw the diameter of the pipe i.e the center of the end pipe right across. Then send it to whom ever you decide to buy from so there are no mistakes when they find the correct flexi pipe.
Failing that I just measure the diameter and email the info and length of pipe you need.
Don't forget you need to
measure BOTH ENDS OF the diameters' of the two pipes you need to marry up!
Second option: which I prefer is BEFORE you take out the magnex box,
mark and fit up where the hangers on your chassis tunnel is against the box ,then make sure
no sides are touching the heat shields when you eventually get hangers on to it. Then take it to a local welder and get him to weld two or three hooks on the box where they should be, rather than where they currently are.
That way you have a perfect fit from center box to back box!
Costs money, but nothing worst than having a system rattle on you at idle or high speed it will drive you crazy! One last thing if you see any
securing circular discs for heatshields missing, which they usualy are rusted to pieces. Go down VAG and buy some it helps with rattles once that box is tight against any heat shields.
Good luck matey!

Jay