In the recent work, the reaction mechanism between triphenylphosphine 1, dialkyl acetylenedicarboxylates 2 in the presence of NH-acid, such as 5-aminoindazole 3 were investigated theoretically. Quantum mechanical studies were performed for evaluation of potential energy surfaces of all structures participated in the reaction mechanism both in gas phase and in dichloromethane. The first step of all reactions was recognized as a rate-determining step in the reaction mechanism. All the possible structures partipated on the reaction coordinate were well predicted. Quantum mechanical calculations were clarified how the ylides exist in solution as a mixture of two geometrical isomers (Z- and E-) as a minor or major forms.