Differential equations have been widely and successfully used to describe the macroscopic or global behaviour of systems in general. With inhomogeneous, time-varying, specific, and often non-linear interactions, the dynamics of complex systems is in contrast more efficiently described by local rules and thus in an algorithmic and local or microscopic manner. In order to create computer models of systems, particularly complex systems, we recently presented a so-called allagmatic method including a system metamodel with two concrete implementations of cellular automata and artificial neural networks. Guidance from philosophy and its general concepts were helpful in these first studies focusing on computer modelling and simulation as well as feasibility. A rigorous mathematical formalism of the system metamodel, however, is still missing. This would not only more precisely describe and define the system metamodel, it would also further generalise it and with that extend its reach to formal treatment in applied mathematics and computational mathematics as well as extend its applicability to other mathematical models such as agent-based models. In this study, a mathematical definition of the system metamodel and its model parameters is provided and the creation of concrete mathematical models, i.e. cellular automata and artificial neural networks, from it is proved.