Set Operators
25.2.2 Set Operators
A specialized set of symbology is used to represent set and logic operations. These symbols must be understood by the software engineer who intends to apply formal methods.
Knowledge of set The operator is used to indicate membership of a set. For example, the expression operations is
indispensible when x
formal specifications has the value true if x is a member of the set X and the value false otherwise. For are developed. Spend
the time to familiarize example, the predicate yourself with each, if
you intend to apply formal methods.
has the value true since 12 is a member of the set. The opposite of the
operator. The expression x
operator is the
X has the value true if x is not a member of the set X and false otherwise. For example,
the predicate
13 {13, 1, 124, 22} has the value false.
has the value true if the members of the set A are contained in the set B and has the value false otherwise. Thus, the predicate
has the value true. However, the predicate
has a value of false because the element RC5 is not contained in the set to the right of the operator.
CHAPTER 25
FORMAL METHODS
true. Thus, the value of the predicate
is false, and the predicate
is true. The empty set has the property that it is a subset of every other set. Two useful iden-
tities involving the empty set are
is the intersection operator, sometimes known as cap. The union operator takes two sets and forms a set that contains all the elements in the set with duplicates eliminated. Thus, the result of the expression
“Mathematical structures are among the most beautiful discoveries made by
is the set the human mind.”
{Filel, File2, Tax, Compiler, NewTax, D2, D3}
Douglas Hofstadter
The intersection operator takes two sets and forms a set consisting of the common elements in each set. Thus, the expression
results in the set {12, 1}. The set difference operator, \, as the name suggests, forms a set by removing the elements of its second operand from the elements of its first operand. Thus, the value of the expression
{New, Old, TaxFile, Sysparam} \ {Old, SysParam} results in the set {New, TaxFile}.
The value of the expression
there are no common elements between its operands so the resulting set will have no elements.
uct. This has two operands which are sets of pairs. The result is a set of pairs where each pair consists of an element taken from the first operand combined with an uct. This has two operands which are sets of pairs. The result is a set of pairs where each pair consists of an element taken from the first operand combined with an
The result of this expression is {(1, 4), (1, 5), (1, 6), (2, 4), (2, 5), (2, 6)} Notice that every element of the first operand is combined with every element of the
second operand.
A concept that is important for formal methods is that of a powerset. A powerset of a set is the collection of subsets of that set. The symbol used for the powerset oper-
set of subsets of its operand. For example,
since all the sets are subsets of {1, 2, 3}.
Parts
» The Concurrent Development Model
» SUMMARY Software engineering is a discipline that integrates process, methods, and tools for
» PEOPLE In a study published by the IEEE [CUR88], the engineering vice presidents of three
» THE PROCESS The generic phases that characterize the software process—definition, development,
» THE PROJECT In order to manage a successful software project, we must understand what can go
» METRICS IN THE PROCESS AND PROJECT DOMAINS
» Extended Function Point Metrics
» METRICS FOR SOFTWARE QUALITY
» INTEGRATING METRICS WITHIN THE SOFTWARE PROCESS
» METRICS FOR SMALL ORGANIZATIONS
» ESTABLISHING A SOFTWARE METRICS PROGRAM
» Obtaining Information Necessary for Scope
» An Example of LOC-Based Estimation
» QUALITY CONCEPTS 1 It has been said that no two snowflakes are alike. Certainly when we watch snow
» SUMMARY Software quality assurance is an umbrella activity that is applied at each step in the
» R diagram 1.4 <part-of> data model; data model <part-of> design specification;
» SYSTEM MODELING Every computer-based system can be modeled as an information transform using an
» Facilitated Application Specification Techniques
» Data Objects, Attributes, and Relationships
» Entity/Relationship Diagrams
» Hatley and Pirbhai Extensions
» Creating an Entity/Relationship Diagram
» SUMMARY Design is the technical kernel of software engineering. During design, progressive
» Data Modeling, Data Structures, Databases, and the Data Warehouse
» Data Design at the Component Level
» A Brief Taxonomy of Styles and Patterns
» Quantitative Guidance for Architectural Design
» Isolate the transform center by specifying incoming and outgoing
» SUMMARY Software architecture provides a holistic view of the system to be built. It depicts the
» The User Interface Design Process
» Defining Interface Objects and Actions
» D E S I G N E VA L U AT I O N
» Testing for Real-Time Systems
» Organizing for Software Testing
» Criteria for Completion of Testing
» The Transition to a Quantitative View
» The Attributes of Effective Software Metrics
» Architectural Design Metrics
» Component-Level Design Metrics
» SUMMARY Software metrics provide a quantitative way to assess the quality of internal product
» Encapsulation, Inheritance, and Polymorphism
» Identifying Classes and Objects
» The Common Process Framework for OO
» OO Project Metrics and Estimation
» Event Identification with Use-Cases
» SUMMARY Object-oriented analysis methods enable a software engineer to model a problem by
» Partitioning the Analysis Model
» Designing Algorithms and Data Structures
» Program Components and Interfaces
» SUMMARY Object-oriented design translates the OOA model of the real world into an
» Testing Surface Structure and Deep Structure
» Deficiencies of Less Formal Approaches 1
» What Makes Cleanroom Different?
» Design Refinement and Verification
» SUMMARY Cleanroom software engineering is a formal approach to software development that
» Structural Modeling and Structure Points
» Describing Reusable Components
» SUMMARY Component-based software engineering offers inherent benefits in software quality,
» Guidelines for Distributing Application Subsystems
» Middleware and Object Request Broker Architectures
» An Overview of a Design Approach
» Consider expert Web developer will create a complete design, but time and cost can be appropriate
» A Software Reengineering Process Model
» Reverse Engineering to Understand Data
» Forward Engineering for Client/Server Architectures
» SUMMARY Reengineering occurs at two different levels of abstraction. At the business level,
Show more