The Car-Parrinello ab initio molecular dynamics scheme combines electr
onic structure calculations with complete geometry optimizations very
efficiently. For the first time we apply this method to organic semico
nducting polymers. Equilibrium geometries are calculated for a series
of polymers: polythiophene (PTh), polypyrrole (PPy), polyisothianaphte
ne (PITN), polyparaphenylene (PPP), polyaniline (PANI) and polyparaphe
nylenesulfide (PPS). The bandgaps of these polymers, calculated with t
he local density functional, are shown to correctly represent the tren
d in the experimental optical bandgap.