Photoisomerizable bipyridine ligands and macroligands: absorption, photoisomerization properties and theoretical study.