User:RachelRooster/Use case diagram

A use case diagram (UCD) is a graphical depiction of a software system, use cases within this system, and the actors of the use cases. UCDs are used to model the behaviour of a system and to help capture the requirements of the system, without going into detail about technical aspects like data structures or  algorithms. The diagram is part of the Unified Modeling Language, or UML for short. Within UML, it is a subclass of behavioural diagrams.

A use case diagram consists of different elements, the most prominent elements being the Actor, Use Case, and System. A use case diagram can contain a box representing the system and its boundaries. Within the system, ellipses represent use cases. Outside of the system, actors are represented as stick figures. Actors can have a relation to one or more use cases that belong to the actor using simple lines. A use case can have a relation with one or more actors. Relations can also exist between actors themselves, or between use cases themselves, see Elements:Relations.

Use case diagrams can be used to answer the following questions:
 * What is being described? (the system)
 * Who interacts with the system? (the actors)
 * What actions can these actors perform? (the use cases)

Use case diagrams can be used throughout the entire software development process, and can provide value to anyone involved with the project, including the developers, testers, management, and stakeholders. IBM describes four situations in which use case diagrams can be helpful:
 * Before or while starting a project, UCDs can be used to model a process or system to make sure all participants have the same global understanding of the process or system.
 * While gathering requirements, UCDs can be created to show the system requirements to both the stakeholders, as well as the developers.
 * During analysis and design phases, the components of the UCD, mainly the actors and use cases, can be used to identify the classes that the system requires.
 * During the test phase, UCDs can be used to identify tests for the system.

Research History
The term use case diagram was first used in 1986 by the inventor of the use case Ivar Jacobson. The usage of use case diagrams in research however, be it in papers or in articles in journals, started at around 1996 according to Google Scholar. Until 2000, UCDs appeared sporadically in such publishments.

2001 - 2005
From 2001-2005, three publications express interesting aspects of UCDs. First, a paper published by Siau, K. and Lee, L. (2001) states that use case diagrams were “undoubtedly the most controversial diagramming technique in UML”. The study laid out an experiment to “better understand the informational value of UCDs in communicating and verifying requirements analysis”. The results of this study sadly have not been found anywhere online by the authors of this Wikipedia page.

A second paper highlights a different branch of research that would gain support in later years, being the automatic generation of UCDs, and generation of elements from UCDs. A bachelor’s thesis by Cayaba, C. and Rodil, J. (2005, though formally published in 2006) put the focus on a system that automatically generated UCDs from English requirements specification documents by a system they named “CAUse”.

A third publication shows research in the direction of formalization of UCDs, another branch of research that would continue to develop in years to come. This publication did research with the aim of formalizing, testing and executing a use case diagram in order to find errors in a requirements model during the early phase of software development.

2006 - 2010
Between 2006 and 2010, research on UCDs increased. Until 2005, research was mostly done on understanding UCDs and allowing generation of UCDs, with both branches of research consisting of a small number of published articles. From 2006 onwards however, two categories became more widely researched.

The generation of UCDs and generation of items (other diagrams, test cases, and more) from UCDs, a branch of research which was seen in the first half of the decade, continued to grow with several new publications. In this timeframe, multiple publications came out on using UCDs to generate test cases.

Second, the formalization of UCDs became a branch of research concerning UCDs. Multiple papers formalized UCDs using the Z notation, a formal specification language used for describing and modelling computing systems, making the UCDs structured and easier to employ automation-techniques on. A different publication focussed on developing well-formedness rules (WFR) for UCDs, where WFRs describe consistency rules between diagrams. A third paper proposed a formal model of use cases and presented methods of formal analysis and verification.

2011 - 2015
At the end of the previous decade, Ibrahim, N., Ibrahim, R. et al. (2010) stated that UCDs were “one of the most used diagram[s] among UML practitioners”. Looking at publications in the timespan of 2011 – 2015, this popularity of UCDs is well-visible.

Several new pieces of research were published in the period from 2011 to 2015. A paper was published concerning automized-UCD generation, this time from use case descriptions written in the Portuguese language, keeping the topic of automatization alive. A different paper was published concerning the role of the UCD in software development, concluding that “the significance of [the] use case diagram is increasing as the size of the project increases”. Lastly, a book was published in a book series “Undergraduate Topics in Computer Science” called “UML @ Classroom” explaining the history of UML, as well as several diagrams within UML including the UCD. Publications like these prove the significance of the UCD within software development.

2016 - Present
From 2016 onwards, research on UCDs has been more popular than ever, with research on UCD in this period being present in several research branches.

As per usual, automation was one of the biggest branches within UCD-related research. Within this branch, research has been done on automated UCD semantic assessment, support for automating transformations from SBVR to UCDs , automated UCD generation from textual user requirement documents , and plenty more.

The research branch of formalisation also sees multiple publications. Some publications focus on formalizing UCDs with Z notation, as well as other research on using Event-B (a method related to Z notation).

Actors
Actors are roles that can be played by persons, groups of people, organizations, or external systems that interact with the system. They are outside the system and are depicted as human figure icons. An object may have one or more roles in interacting with the system, but an object can play only one role at a time.

Use cases
Actors interact with use cases which are represented by horizontal ellipse. Use cases are things that the system performs for its actors. They are functionalities of the system which provide measurable value to the users.

System boundary
Uses cases are placed within the system boundary, which is shaped as a rectangle. Anything inside this boundary is a functionality in the scope of the system. If a system is large and complex, each module could be a separate system boundary.

Relations
Actors and use cases are connected with lines that symbolize the relationship between them. An association can have an optional arrowhead. This represents which element indicated the action. The actor or use case which started the interaction will in that case be at the blunt end of the line. There are three special types of relations:


 * 1) Use case diagram - include.pngde (or Use): This adds functionality to a main use case with another use case. It indicates that the main use case will include the behaviour of another use case. This type of relationship is shown by a directed arrow having a dotted line with “< >” written next to it. It points from the main use case to the child use case.
 * 2) Use case diagram - extend.pngd: This relationship represents optional functionality. It is also shown by a directed arrow having a dotted line, but with “< >” written next to it. It points from the optional use case to the main use case.
 * 3) Use case diagram - generalization actor.pngUse case diagram - generalization use case.pngalization: A generalization can be used between different actors or between different use cases. The child actor or use case inherits the behaviour of the parent actor or use case. This relationship is shown with a directed arrow with a triangle arrowhead. The child needs to be at the base of the arrow, and the tip is connected to the parent.

Application
While technical specifications can contain a lot of in-depth information about the workings of a system, a use case diagram can help provide a higher-level overview of the system. This is caused by the use case diagram providing a black-box view of the system. This higher-level overview has several benefits, the first being that this high-level overview takes a lot of (technical) detail away. This abstraction makes it easier for all users to understand the diagram better. For instance, it allows users to see if their needs are satisfied at the very beginning of the development process. A second reason the black-box high-level overview benefits the use case diagram is the function of a use case diagram as a blueprint for the software development process.

Due to their simplistic nature explained above, use case diagrams can be a good communication tool for stakeholders. The drawings attempt to mimic the real world and provide a view for the stakeholder to understand how the system is going to be designed. Siau, K., Lee, L. (2004) conducted research to determine if there was a valid situation for use case diagrams at all or if they were unnecessary. What was found was that the use case diagrams conveyed the intent of the system in a more simplified manner to stakeholders and that they were "interpreted more completely than class diagrams".

Limitations
It is not possible to model everything in a use case diagram. A few important limitations to consider are:
 * It is not possible to show or specify execution constrains between use cases.
 * A use case diagram does not show in which order, how often and at what time interval use cases occur.
 * You can only model the system and its immediate environment. If, for example, two actors share information related to the system, outside of the system, this communication can not be shown in the use case diagram.
 * Likewise, it is also not possible to show how multiple systems relate to eachother.
 * One of the goal of a use case diagram is to also be able reach a wide nontechnical audience. When qualifying elements are added and the complexity increases, this could overwhelm some of the intended stakeholders.