Software Engineering
Software Engineering
SOLUTION
PART — A (Answer should be given up to 25 words only)
Q. 1 Define system engineering?
Answer: System Engineering is the systematic approach to the development, operation and maintenance of
Computer System. System Engineering is concerned with development and maintenance of combination of
software and hardware products.
Answer: Design Documentation help ensure consent and expectations. It helps to tell the narrative for
decisions made, and how yourself or the client responded to different situations. In this same manor, it is
important to record information that can help support the proper treatment plan and the reasoning for such
services.
Procedures: procedures are the policies that govern the operation of a computer system. ―Procedures are to
people what software is to hardware‖ is a common analogy that is used to illustrate the role of procedures in a
CBIS.
People: Every CBIS needs people if it is to be useful. Often the most over-looked element of the CBIS is the
people: probably the components that most influence the success or failure of information system.
The major Information Systems are
1. Formal Information System
2. Informal Information System
3. Computer Based Information System
This is based on the organization represented by the Organization Chart. The Organization char clearly lays
down the position and the personnel associated to those positions and their authority relationship.
The Systems Development Life Cycle (SDLC) is a conceptual model used in project
management that describes the stages involved in an information system development project
from an initial feasibility study through maintenance of the completed application. Various
SDLC methodologies have been developed to guide the processes involved including the
waterfall model (the original SDLC method), rapid application development (RAD), joint
application development (JAD), the fountain model and the spiral model. Mostly, several
models are combined into some sort of hybrid methodology. Documentation is crucial
regardless of the type of model chosen or devised for any application, and is usually done in
parallel with the development process. Some methods work better for specific types of
projects, but in the final analysis, the most important factor for the success of a project may
be how closely particular plan was followed.
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
The image above is the classic Waterfall model methodology, which is the first SDLC
method and it describes the various phases involved in development.
Q.3 What do you understand by data dictionary where and how it is used?
The data dictionary has been proposed as a quasi-formal grammar for describing
the content of objects defined during structured analysis. This important modeling
― The data dictionary is an organized listing of all data elements that are pertinent to the
system, with precise, rigorous definitions so that both user and system analyst will have a
common understanding of inputs, outputs, components of stores and [even] intermediate
calculations ―.
Today, the data dictionary is always implemented as part of a CASE "structured analysis and
design tool." Although the format of dictionaries varies from tool to tool, most contain the
following information:
• Name—the primary name of the data or control item, the data store or an external entity.
• Where-used/how-used—a listing of the processes that use the data or controlitem and how it
is used (e.g., input to the process, output from the process, as a store, as an external entity.
• Supplementary information—other information about data types, preset values (if known),
restrictions or limitations, and so forth.
Once a data object or control item name and its aliases are entered into the data dictionary,
consistency in naming can be enforced. That is, if an analysis team member decides to name a
newly derived data item xyz, but xyz is already in the dictionary, the CASE tool supporting
the dictionary posts a warning to indicate duplicate names. This improves the consistency of
the analysis model and helps to reduce errors.
unimportant, it is actually one of the most important benefits of the dictionary. During
analysis there is an almost continuous stream of changes. For large projects, it is often quite
difficult to determine the impact of a change. Many a software engineer has asked, "Where is
this data object used? What else will have to change if we modify it? What will the overall
impact of the change be?" Because the data dictionary can be treated as a database, the
analyst can ask "where used/how used" questions, and get answers to these queries.
types. Depending upon how the service is invoked, the respective portion of the code
gets executed.
For example if you want to design an object- for the registry system of your school the
MIS Systems Development Life Cycle (SDLC): The system development life cycle refers to the processing of
planning, creating, testing, and deploying an information system. The main objective of system development life
cycle is to produce high-quality information systems that meet or exceed the expectations of the users within the
stipulated budget and time frame. SDLC uses a number of development methodologies to achieve this objective.
Schedule: Simply means the amount of time required for the completion of the job, which is, of
course, proportional to the effort put. It is measured in the units of time such as weeks, months.
Different models of COCOMO have been proposed to predict the cost estimation at different levels, based on
the amount of accuracy and correctness required. All of these models can be applied to a variety of projects,
whose characteristics determine the value of constant to be used in subsequent calculations. These
characteristics pertaining to different system types are mentioned below.
Boehm‘s definition of organic, semidetached, and embedded systems:
1. Organic – A software project is said to be an organic type if the team size required is adequately
small, the problem is well understood and has been solved in the past and also the team members
have a nominal experience regarding the problem.
2. Semi-detached – A software project is said to be a Semi-detached type if the vital characteristics
such as team-size, experience, knowledge of the various programming environment lie in between
that of organic and Embedded. The projects classified as Semi-Detached are comparatively less
familiar and difficult to develop compared to the organic ones and require more experience and
better guidance and creativity. Eg: Compilers or different Embedded Systems can be considered of
Semi-Detached type.
3. Embedded – A software project with requiring the highest level of complexity, creativity, and
experience requirement fall under this category. Such software requires a larger team size than the
other two models and also the developers need to be sufficiently experienced and creative to develop
such complex models.
All the above system types utilize different values of the constants used in Effort Calculations.
Types of Models: COCOMO consists of a hierarchy of three increasingly detailed and accurate forms. Any
of the three forms can be adopted according to our requirements. These are types of COCOMO model:
1. Basic COCOMO Model
2. Intermediate COCOMO Model
3. Detailed COCOMO Model
The first level, Basic COCOMO can be used for quick and slightly rough calculations of Software Costs. Its
accuracy is somewhat restricted due to the absence of sufficient factor considerations.
Intermediate COCOMO takes these Cost Drivers into account and Detailed COCOMO additionally
accounts for the influence of individual project phases, i.e in case of Detailed it accounts for both these cost
drivers and also calculations are performed phase wise henceforth producing a more accurate result. These
two models are further discussed below.
Estimation of Effort: Calculations –
1. Basic Model –
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
The above formula is used for the cost estimation of for the basic COCOMO model, and also is used in the
subsequent models. The constant values a,b,c and d for the Basic Model for the different categories of
system:
SOFTWARE PROJECTS a b c d
The effort is measured in Person-Months and as evident from the formula is dependent on Kilo-Lines of
code.
The development time is measured in Months.
These formulas are used as such in the Basic Model calculations, as not much consideration of different
factors such as reliability, expertise is taken into account, henceforth the estimate is rough.
Answer: UML was created by the Object Management Group (OMG) and UML 1.0
specification draft was proposed to the OMG in January 1997.
UML is different from the other common programming languages such as C++, Java,
COBOL, etc.
Although UML is generally used to model software systems, it is not limited within
this boundary. It is also used to model non-software systems as well. For example, the
process flow in a manufacturing unit, etc.
UML is not a programming language but tools can be used to generate code in various
languages using UML diagrams. UML has a direct relation with object oriented analysis and
design. After some standardization, UML has become an OMG standard.
Goals of UML
A picture is worth a thousand words, this idiom absolutely fits describing UML. Object-
oriented concepts were introduced much earlier than UML. At that point of time, there were
no standard methodologies to organize and consolidate the object-oriented development. It
was then that UML came into picture.
There are a number of goals for developing UML but the most important is to define some
general purpose modeling language, which all modelers can use and it also needs to be made
simple to understand and use.
UML diagrams are not only made for developers but also for business users, common people,
and anybody interested to understand the system. The system can be a software or non-
software system. Thus it must be clear that UML is not a development method rather it
accompanies with processes to make it a successful system.
In conclusion, the goal of UML can be defined as a simple modeling mechanism to model all
possible practical systems in today‘s complex environment.
UML includes the following nine diagrams, the details of which are described in the
subsequent chapters.
Class diagram
Object diagram
Sequence diagram
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
Collaboration diagram
Activity diagram
Statechart diagram
Deployment diagram
Component diagram
The power of FSM comes from the ability to clearly define different behaviors in different conditions. Usually FSM
is used with looping behavioral scripts which constantly evaluate the current situation in a loop or with events.
To help form an image of how this might be applied, a coffee machine will be used as an example of a finite state
machine. We will also cover a state diagram to visualise the FSM and provide coding examples.
State Diagram
This diagram shows the possible states for the coffee machine:
Open (BUSY)
ReadyToBuy(IDLE)
PoweredOff
The lines between these states show which transitions are possible between states and in which direction. These
transitions have conditions for when the FSM needs to change between states.
StartUpMachine From the PoweredOff state to the Open state the machine has to start up. This is done
manually in this case.
deposit >= cost of coffee The FSM evaluates the amount of deposited cash either in a loop or when the
amount changes (recommended in this case) If you deposit enough cash into the coffee machine, the FSM
will go from ‗Open‘ to ‗ReadyToBuy‘.
ShutdownMachine The machine will automatically go from Open to PoweredOff through the
ShutDownMachine method if the condition ‗no more coffees left‘ is met.
DispenseCoffee In the ReadyToBuy state the user can buy a coffee whereafter it will be brewed and
dispensed. The condition is when the BuyCoffee event (!Link to observer pattern!) fires. (not shown in
diagram)
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
CancelCoffee If the user opts to cancel, the machine will go from ReadyToBuy to Open.
ShutDownMachine The machine will go to PoweredOff state
States
In every state there is defined behavior which will only be executed when the object is in that state. For instance,
during PoweredOff the coffee machine won‘t brew coffee before it‘s powered on, during the Open state it will wait
either until there‘s enough cash inserted, until the power down command is given, or until it runs out of coffee. During
this Open state it can do routines such as cleaning which won‘t happen in other states.
Initial State
Every FSM has an initial state, this means which state it starts in when it is created and has to be defined when
constructed or instantiated. Of course it‘s possible to directly change state if conditions are met.
Transitions
Every state either constantly evaluates if it should transition to another state or will transition to another state based on a
triggered event.
StartUpMachine From the PoweredOff state to the Open state the machine has to start up. This is done manually in
this case.
deposit >= cost of coffee The FSM evaluates the amount of deposited cash either in a loop or when the amount
changes (recommended in this case) If you deposit enough cash into the coffee machine, the FSM will go from
‗Open‘ to ‗ReadyToBuy‘.
ShutdownMachine The machine will automatically go from Open to PoweredOff through the ShutDownMachine
method if the condition ‗no more coffees left‘ is met.
DispenseCoffee In the ReadyToBuy state the user can buy a coffee whereafter it will be brewed and dispensed. The
condition is when the BuyCoffee event (!Link to observer pattern!) fires. (not shown in diagram)
CancelCoffee If the user opts to cancel, the machine will go from ReadyToBuy to Open.
ShutDownMachine The machine will go to PoweredOff state
States
In every state there is defined behavior which will only be executed when the object is in that state. For instance,
during PoweredOff the coffee machine won‘t brew coffee before it‘s powered on, during the Open state it will wait
either until there‘s enough cash inserted, until the power down command is given, or until it runs out of coffee. During
this Open state it can do routines such as cleaning which won‘t happen in other states.
Initial State
Every FSM has an initial state, this means which state it starts in when it is created and has to be defined when
constructed or instantiated. Of course it‘s possible to directly change state if conditions are met.
Transitions
Every state either constantly evaluates if it should transition to another state or will transition to another state based on a
triggered event.
Q.3 Explain object - oriented analysis and its approach and explain classes and object relationship model.
Answer:
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
Data-flows: A data-flow represents a package of information flowing between two objects in the data-flow
diagram. Data-flows are used to model the flow of information into the system, out of the system, and
between elements within the system.
Occasionally, a data-flow is used to illustrate information flows between two external entities, which is,
strictly speaking, outside of the system boundaries. However, knowledge of the transfer of information
between external entities can sometimes aid understanding of the system under investigation, in which case it
should be depicted on the diagram.
Notation: A data-flow is depicted on the diagram as a directed line drawn between the source and recipient
of the data-flow, with the arrow depicting the direction of flow.
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
Data stores: A data store is a place where data is stored and retrieved within the system. This may be a
file, Customer Contracts file for example, a catalogue or reference list, Options Lists for example, a log book
such as the Job Book, and so on.
Notation: A data store is represented in the data-flow diagram by a long rectangle, containing two locations.
External entities: External entities are entities outside of the system boundary which interact with the
system, in that they send information into the system or receive information from it. External entities may be
external to the whole organisation — as in Customer and Supplier in our running example; or just external to
the application area where users' activities are not directly supported by the system under
investigation. Accounts and Engineering are shown as external entities as they are recipients of information
from the system. Sales also provide input to the system.
External entities are often referred to as sources and sinks. All information represented within the system is
sourced initially from an external entity. Data can leave the system only via an external entity.
Notation: External entities are represented on the diagram as ovals drawn outside of the system boundary,
containing the entity name and an identifier.
A control-flow diagram can consist of a subdivision to show sequential steps, with if-then-else conditions, repetition,
and/or case conditions. Suitably annotated geometrical figures are used to represent operations, data, or equipment,
and arrows are used to indicate the sequential flow from one to another.
There are several types of control-flow diagrams, for example:
Change-control-flow diagram, used in project management
Configuration-decision control-flow diagram, used in configuration management
Process-control-flow diagram, used in process management
Quality-control-flow diagram, used in quality control.
In software and systems development, control-flow diagrams can be used in control-flow analysis, data-flow analysis,
algorithm analysis, and simulation. Control and data are most applicable for real time and data-driven systems. These
flow analyses transform logic and data requirements text into graphic flows which are easier to analyze than the text.
PERT, state transition, and transaction diagrams are examples of control-flow diagrams.
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
1. The Oval
An End or a Beginning
The oval, or terminator, is used to represent the start and end of a process. Use the Gliffy flowchart tool to drag and
drop one of these bad boys and you've got yourself the beginning of a flowchart. Remember to use the same symbol
again to show that your flowchart is complete.
2. The Rectangle
A Step in the Flowcharting Process
The rectangle is your go-to symbol once you've started flowcharting. It represents any step in the process you‘re
diagramming and is the workhorse of the flowchart diagram. Use rectangles to capture process steps like basic tasks
or actions in your process.
3. The Arrow
Indicate Directional Flow
The arrow is used to guide the viewer along their flowcharting path. And while there are many different types of
arrow tips to choose from, we recommend sticking with one or two for your entire flowchart. This keeps your
diagram looking clean, but also allows you to emphasize certain steps in your process.
4. The Diamond
Indicate a Decision
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
The diamond symbolizes that a decision is required to move forward. This could be a binary, this-or-that choice or a
more complex decision with multiple choices. Make sure that you capture each possible choice within your diagram.
Q.5 Explain the use case diagram and state diagram in the context of UML.
Answer: UML Use Case Diagrams: Use case diagrams are usually referred to as behavior diagrams used to
describe a set of actions (use cases) that some system or systems (subject) should or can perform in
collaboration with one or more external users of the system (actors). Each use case should provide some
observable and valuable result to the actors or other stakeholders of the system.
UML specifications also described use case diagram as a specialization of a class diagram, and class diagram
is a structure diagram.
Use case diagrams are in fact twofold - they are both behavior diagrams, because they describe behavior of
the system, and they are also structure diagrams - as a special case of class diagrams where classifiers are
restricted to be either actors or use cases related to each other with associations.
Use case diagrams are considered for high level requirement analysis of a system. When the
requirements of a system are analyzed, the functionalities are captured in use cases.
We can say that use cases are nothing but the system functionalities written in an organized
manner. The second thing which is relevant to use cases are the actors. Actors can be defined
as something that interacts with the system.
Actors can be a human user, some internal applications, or may be some external
applications. When we are planning to draw a use case diagram, we should have the
following items identified.
Actors
Use case diagrams are drawn to capture the functional requirements of a system. After
identifying the above items, we have to use the following guidelines to draw an efficient use
case diagram
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
The name of a use case is very important. The name should be chosen in such a way
so that it can identify the functionalities performed.
Do not try to include all types of relationships, as the main purpose of the diagram is
to identify the requirements.
Following is a sample use case diagram representing the order management system. Hence, if
we look into the diagram then we will find three use cases (Order, SpecialOrder, and
NormalOrder) and one actor which is the customer.
The SpecialOrder and NormalOrder use cases are extended from Order use case. Hence, they
have extended relationship. Another important point is to identify the system boundary,
which is shown in the picture. The actor Customer lies outside the system as it is an external
user of the system.
A state diagram is used to represent the condition of the system or part of the system at finite instances of time. It‘s
a behavioral diagram and it represents the behavior using finite state transitions. State diagrams are also referred to
as State machines and State-chart Diagrams. These terms are often used interchangeably. So simply, a state
diagram is used to model the dynamic behavior of a class in response to time and changing external stimuli. We can
SOLUTION of RTU PAPER 3CS4-07 Software Engineering
say that each and every class has a state but we don‘t model every class using State diagrams. We prefer to model the
states with three or more states.
Uses of statechart diagram –
We use it to state the events responsible for change in state (we do not show what processes cause those
events).
We use it to model the dynamic behavior of the system .
To understand the reaction of objects/classes to internal or external stimuli.
Basic components of a statechart diagram –
1. Initial state – We use a black filled circle represent the initial state of a System or a class.
Figure – transition
3. State – We use a rounded rectangle to represent a state. A state represents the conditions or circumstances of
an object of a class at an instant of time.