If it's exactly the same, and the transformer isn't knackered, you won't have to change it.
It'll either be the fan itself or transformer that is faulty.
Unless of course your random attempts at guessing the wiring have ensured both items are now damaged.
May pay to (get someone to) change both.
The old fan was working but making a high pitched noise, so as you say if we havn't knackered the transformer it should still work with exactly the same fan. I think we will put the old one back just to see if the transformer is still working ok, if so we will opt for exactly the same fan.
Thankyou
Looking inside the transformer should give you an idea which coloured wires connect to which terminals at the fan.