When you electromagnetize a nail with wire coiled around it, then connect it to a small battery, how come it works when the wire has been been insulated,..... and what if you were to use uninsulated wire.
The insulation around the wire prevents the flow of current between wires, (shorting out the coil). It has no effect on the magnetic field created by the flow of current in the wires. If you tried uninsulated wire, you wouldn't have much of a field, as the current path would be short, direct from one end of the coil to the other with no 'turns` at all.
If the wire were uninsulated, then the coils of wire would short circuit. This would bypass the current and no magnetising would occur. Although a wire with current passing through it has a magnetic field, coiling the wire concentrates the magnetic field. When you put the nail in the coil it couples this field and the random magnetic particles align forming a magnet.