While reading Sipser’s book on theory of computation, it relies heavily on the concept of formal language, and machines that merely accept or reject an input.
But most useful programs we deal with do more than merely verify an input. They compute something. We may compute a solution for an equation instead of merely verify it. We may sum a list of numbers, or calculate some function on it.
Maybe “most” is an exaggeration since I can’t prove it. But still, it begs the question. Why not deal with machines than do more than merely verify?
Language recognition is a useful framework for complexity theory. There are also “counting problems” and complexity classes for them, like #P:
https://en.m.wikipedia.org/wiki/♯P
If you’re looking at numerical calculations from a theoretical standpoint, there is a variant of Turing machines for that, with a lot of really nice results:
https://en.m.wikipedia.org/wiki/Blum–Shub–Smale_machine