A solid state density functional study of crystalline thiophene-based oligomers and polymers.