Formal method is to use discrete mathematics method to solve the problem in the field of software engineering, mainly including the establishment of accurate mathematical model and the analysis of the model activities. In the narrow sense, the formal method is to use formal language, formal specification description, model inference and verification method. The main purpose of the formal method in software engineering practice is to ensure the correctness. Software development is actually the mapping of real-world needs into software-based modeling processes. The process includes: Formal specification, form proof I and inspection, procedure refinement three aspects of activities.
It uses modal to describe and calculate the proposition in the possible world, divided into: Kripke structure. First-order linear temporal logic.: Compute tree logic. The three main components of the model are input, output, and state, and they all have corresponding mathematical concepts to describe. The language formal specification is composed of two parts: Mathematical language description and natural language annotation. The mathematical language description part is the core, it is accurate, concise description system nature and automatic inference guarantee. The Natural annotation section is used to explain the contents of the mathematical section.
Finally, Petri nets: Network structure model communication system, which is based on this model developed theory. Sometimes the petri nets are called net theory. Petri nets are divided into two categories: location/Migration Petri nets and advanced petri nets.
The formal method in software engineering