The coil–globule transition of polymers of long rigid monomers connected by flexible spacers