Nanocables made of a transition metal wire and boron nitride sheath : Density functional calculations