The B method is a method of software development based on B, a tool-supported formal method based on an abstract machine notation, used in the development of computer software. It was originally developed in the 1980s by Jean-Raymond Abrial in France and the UK. B is related to the Z notation and supports development of programming language code from specifications. B has been used in major safety-critical system applications in Europe. It has robust, commercially available tool support for specification, design, proof and code generation. Compared to Z, B is slightly more low-level and more focused on refinement to code rather than just formal specification — hence it is easier to correctly implement a specification written in B than one in Z. In particular, there is good tool support for this. The same language is used in specification, design and programming. Mechanisms include encapsulation and data locality. Recently, another formal method called Event-B has been developed. Event-B is considered an evolution of B. It is a simpler notation, which is easier to learn and use. It comes with tool support in the form of the Rodin tool.
In the first and the most abstract version, which is called Abstract Machine, the designer should specify the goal of the design.
Refinement
Then, during a refinement step, he may pad the specification in order to clarify the goal or to turn the abstract machine more concrete by adding details about data structures and algorithms that define, how the goal is achieved.
The new version, which is called Refinement, should be proven to be coherent and including all the properties of the abstract machine.
The designer may make use of B libraries in order to model data structures or to include or import existing components.
Implementation
The refinement continues, until a deterministic version is achieved: the Implementation.
During all of the development steps the same notation is used and the last version may be translated to a programming language for compilation.
Software
B-Toolkit
The B-Toolkit, developed by Ib Holm Sørensenet al., is a collection of programming tools designed to support the use of the B-Tool, a set theory based mathematical interpreter, for the purposes of a formal software engineering methodology known as the B method. The toolkit uses a custom X WindowMotif Interface for GUI management and runs primarily on the Linux, Mac OS X and Solarisoperating systems. It has been developed by the UK based company B-Core Limited. The B-Toolkit source code is now available.
Atelier B
Developed by ClearSy, Atelier B is an industrial tool that allows for the operational use of the B Method to develop defect-free proven software. Two versions are available: Community Edition available to anyone without any restriction, Maintenance Edition for maintenance contract holders only. It is used to develop safety automatisms for the various subways installed throughout the world by Alstom and Siemens, and also for Common Criteria certification and the development of system models by ATMEL and STMicroelectronics.