All parasitics such as switch conduction voltages, conduction resistances, switching times, and ESRs of capacitors are counted in a proposed state-space modeling based method on nonideal switching functions. An equivalent simplified model is derived from the complex circuit with parasitics. The modeling procedure is shown for the buck-boost converter as the general converter among the buck, boost, and buck-boost converters. The pole frequency, DC voltage gain, and efficiency are analyzed and verified by experiments that show good agreement with theory. The procedures for determining the the gain margin of the controller, the turn-ratio of an isolation transformer, the optimum duty factor, and the switching frequency are given for an example fly-back converter.