Nematic phase transitions of flexible spherocylindrical molecules