They grab yeast from the bottom of the fermenters, toss it under a microscope to look at cell count as well as the health of the yeast - then do the math from that and calculate how much to pitch. If it looks unhealthy or has cells going wrong then they order more.

Not always, There is a brewery here in Cork, that use the same yeast over and over. The last time i asked it was on 184th generation.
I don't remember the details on how they keep it fresh. I'll ask the brewmaster next time I pop in for a beer.

That is the way we do it in bread baking. Freeze cultures that have the characteristics we want and if the current mother picks up characteristics we don't want we toss it and revive from the frozen line. A yeast culture will change over time but if you use it for the same purpose, using the same ingredients every time, it shouldn't change much past a certain point unless it gets infected with something.

If you want to keep a yeast strain at a relatively stable state, you need to feed it regularly and watch its activity cycles. The moment fermentation slows (not stops) you need to add more food, because at that point the other things in the culture start to gain ground. If you want to slow the growth of other things you have to refrigerate it.

There's also yeast washing, which seems like a more complicated and probably more certain way to maintain the exact strain you want.

Not always, There is a brewery here in Cork, that use the same yeast over and over. The last time i asked it was on 184th generation.
I don't remember the details on how they keep it fresh. I'll ask the brewmaster next time I pop in for a beer.

Cork? as in across the pond Cork? Man!... what I wouldn't do to join you...

I have been to over three hundred (300) breweries in the US and not one in an other Englinsh speaking country...

A brewpub I frequent reuses their yeast for one to two years. They have a brewing cycle where they reuse yeast from yeast propagator batches, generally lower alcohol beers. They do not reuse the yeast from the stronger beers.