The present code provides a power analysis of a class B power amplifier. The results of the analysis are:
1) Average power drawn from the power supply;
2) Average power delivered to the load;
3) Average power dissipated by the amplifier;
4) Amplifier efficiency;
5) The output locus of the amplifier in the SOA field.
The code is based on author Signal–Power Amplifier–Load Model (SiPoLo Model). The analysis is performed under condition of operation with complex load (loudspeaker or speaker cabinet) and random (stochastic) signal (music, human speech, etc.). The results of the analysis concern the operation of the real-world class B power amplifiers.
The code is based on the theory described in:
 Хр. Живомиров, Р. Василев. Енергийни параметри на усилвателите клас B, при работа с комплексен товар и случаен сигнал. UNITECH’2014, November 21 – November 22 2014, Gabrovo, Bulgaria. Conference Proceedings, ISSN: 1313-230X, Vol. II, pp. II-53-II-58, 2014.
 R. Bortoni, S. Filho, R. Seara. “On the Design and Efficiency of Class A, B, AB, G, and H Audio Power Amplifier Output Stages”. Journal of the Audio Engineering Society, Vol. 50, No. 7/8, pp. 547-563, Aug. 2002.
 E. Benjamin. “Audio Power Amplifiers for Loudspeaker Loads”. Journal of the Audio Engineering Society, Vol. 42, No. 9, pp. 670-683, Sept., 1994.
 A. Berkhoff. “Impedance Analysis of Subwoofer Systems”, Journal of the Audio Engineering Society, Vol. 42, No 1/2, pp. 4-14, 1994 Jan./Feb.
 A. Thiele. “Loudspeakers in Vented Boxes, Parts I and II”. Journal of the Audio Engineering Society, Vol. 19, No. 5, pp. 382÷392, May 1971; pp. 471-483, June 1971.
 R. Small. “Closed-Box Loudspeaker Systems Part I: Analysis”, Journal of the Audio Engineering Society, Vol. 20, Number 10, pp. 798-808, 1972 Dec.
 R. Small. “Vented-Box Loudspeaker Systems: Part I: Small-Signal Ana¬ly¬sis”, Journal of the Audio Engineering Society, Vol. 21, No. 5, pp 363-372, June 1973.
 Scan-Speak 18W/8424G00 Midwoofer.
A new version of the code has been uploaded.