Detailed ab-initio calculations of a number of pyrrole oligomers are carried out in order to find out relative stability of structures bonded through alpha and beta carbons. Energetics of dimers, trimers and tetramers with all possible linkage types and several pentamers are obtained from fully optimized geometry. The linear as well as the branched forms of tetramers and pentamers are compared so that probabilities of branching can be estimated. The energy differences of different types of structures suggest that a great deal of branching is probable. It is shown that relative energies of 65 oligomers can be fairly reproduced by a simple partitioning in terms of monomer types. The approximate probability function generated in this manner is used in the following paper in a statistical mechanical approach to estimate the extent of bonding involving beta carbons as well as branching in polypyrroles. (C) 1999 Elsevier Science S.A. All rights reserved.