First, let me point out that Wikipedia has some EXCELLENT in-depth information on "Boiler Water Treatment", and those of you interested in the various chemical names should refer to that site.
Second, back in the "days of steam", each and every railroad had pretty large numbers of personnel working in the Water Service Department. The Water Service Department people were responsible for testing all make-up water (that is, water that would be used in the locomotives from all sorts of water tanks/towers) at each and every location on the railroad, plus water being drained from locomotive boilers at each and every roundhouse/shop that was performing scheduled boiler washes. The information and records collected & maintained by the Water Service Department, was the basis for treatment plans and chemical purchases for water treatment levels throughout their system. Thus, unlike today with the use of water hydrants, each and every water tank/tower/track pan, etc. that supplied water to steam locomotive tenders, supplied water that had been regular tested and treated by the Water Service Department personnel.
Many locomotive terminals also had supplies of large bags (50 pounds ?) of Nalco Chemical Co. "Tender Water Treatment Balls", that could be carried up on top of the tender, for the Fireman to use when taking particularly known "bad water" from outlying points. Per written instructions/bulletins, the Fireman would throw a predetermined number of "balls" into the water portion of the tender, when taking water. Some railroads, the Union Pacific and Santa Fe for examples, had such really bad water across the Nebraska plaines and desert southwest, respectively, that the performed boiler washes at 15 day intervals instead of the ICC mandated every 30 days. Generally, the whole purpose of treating boiler water was/is, to keep the dissolved minerals in the water from sticking to all the internal water portions of the boilers, thus the reasons for constant use of blowdowns entoute and periodic boiler washes at roundhouses and shops.
In today's modern excursion service, water must be taken on from hydrants, and there is no control over the quality of the water being taken. Thus, most excursion operators hav, and use, water test kits, in order to determine the "hardness" of the supplied water. At that point, known quantities of treatment chemicals (usually a caustic concentrate) are added to the tender/tenders in order to prevent the dissolved minerals from sticking to the inside steel portions of the boiler. Also, based on the water test, small quantities of Oxygen Scavenger and/or Anti-Foaming chemicals can be added. For what it's worth, the SP 4449 operation constantly tests the water directly from the boiler (twice a day, at least), and uses the Injector to add the necessary treatment chemicals DIRECTLY into the boiler. By doing so, there is far less chemicals used, since the treatments are ONLY going into the boiler, and not out on the ground whenever the tender/tenders are drained.