Brecon and Merthyr 0-6-2T locomotives were steam tank locomotives of the Brecon and Merthyr Railway including classes 36 and 45.
The Brecon and Merthyr 36 was a class of 0-6-2T steam locomotive introduced into traffic in 1909 from a design by the Rhymney Railway's engineer Hurry Riches. There were initially four locos in the class augmented to eight in 1914. They were built by Robert Stephenson and Company and were almost identical to the successful Rhymney Railway R class excepting a round-topped boiler. When rebuilt by the GWR they acquired GWR Belpaire boilers.
The B & M also borrowed from the Rhymney Railway P class for six more engines in two batches of three in 1915 and 1920 loosely known as the 45 class.
In similar vein, the Neath and Brecon Railway used the Rhymney Railway's Stephensons as a blueprint for three locomotives (known as the Neath and Brecon Stephensons) built in 1904 to the design of the Rhymney Railway M class.
The Rhymney Railway R class and related 1904-introduced Rhymney Railway M class and 1910 Rhymney Railway A class were successful designs ideally suited to hauling heavy coal trains a relatively short distance. In 1924, Nos 36 & 38 were reboilered by the GWR and in this form were visually almost indistinguishable from the GWR 5600 Class. All but two of the fourteen B & M Stephensons were eventually rebuilt, the last as late as 1947.
Thus the 36 (and larger wheeled 45 class) were designed for work on the Brecon and Merthyr, replacing smaller locomotives. When the smaller railway companies were forcibly merged into the GWR, these 0-6-2T's were in generally good order and had proved successful. Collectively the sixty-five various permutations of the Rhymney Stephensons became the blueprint for the 200 strong 56xx class.