The influence of lipid molecules on the aggregation of a highly amyloidogenic segment of human islet amyloid polypeptide, hIAPP20-29, and the corresponding sequence from rat has been studied by all-atom replica exchange molecular dynamics (REMD) simulations with explicit solvent model. hIAPP20-29 fragments aggregate into partially ordered beta-sheet oligomers and then undergo large conformational reorganization and convert into parallel/antiparallel beta-sheet oligomers in mixed in-register and out-of-register patterns. The hydrophobic interaction between lipid tails and residues at positions 23-25 is found to stabilize the ordered beta-sheet structure, indicating a catalysis role of lipid molecules in hIAPP20-29 self-assembly. The rat IAPP variants with three proline residues maintain unstructured micelle-like oligomers, which is consistent with non-amyloidogenic behavior observed in experimental studies. Our study provides the atomic resolution descriptions of the catalytic function of lipid molecules on the aggregation of IAPP peptides.