In mathematics, a set is called finite if and only if there is a bijection between the set and some set of the form {1, 2,..., n} where n is a natural number.
It is a theorem (assuming the axiom of choice) that a set is finite if and only if there exists no bijection between the set and any of its proper subsets.
A finite state machine (FSM) or finite automaton is a model of behaviour composed of states, transitions and actions.
Finite state machines are one type of the automata studied in automata theory and the theory of computation.
In computer science, finite state machines are widely used in modelling of application behaviour, design of hardware digital systems, software engineering, compilers, study of computation and languages.