Newer
Older
\documentclass[12pt, titlepage]{article}
\usepackage{fullpage}
\usepackage[round]{natbib}
\usepackage{multirow}
\usepackage{booktabs}
\usepackage{tabularx}
\usepackage{graphicx}
\usepackage{float}
\usepackage{hyperref}
\hypersetup{
colorlinks,
citecolor=black,
filecolor=black,
linkcolor=red,
urlcolor=blue
}
\usepackage[round]{natbib}
\newcounter{acnum}
\newcommand{\actheacnum}{AC\theacnum}
\newcommand{\acref}[1]{AC\ref{#1}}
\newcounter{ucnum}
\newcommand{\uctheucnum}{UC\theucnum}
\newcommand{\uref}[1]{UC\ref{#1}}
\newcounter{mnum}
\newcommand{\mthemnum}{M\themnum}
\newcommand{\mref}[1]{M\ref{#1}}
\author{Andrew Hum \\ huma3 \\ 400138826 \and
William Lei \\ leim5 \\ 400125240 \and
Arshan Khan \\ khana172 \\ 400145605 \and
Jame Tran \\ tranj52 \\ 400144141
\begin{document}
\maketitle
\pagenumbering{roman}
\tableofcontents
\listoftables
\listoffigures
\begin{table}[bp]
\caption{\bf Revision History}
\begin{tabularx}{\textwidth}{p{3cm}p{2cm}X}
\toprule {\bf Date} & {\bf Version} & {\bf Notes}\\
\midrule
3/9/2020 & 1.0 & Arshan and Andrew created document\\
3/11/2020 & 1.1 & Andrew added modules to section 3 and 6\\
3/11/2020 & 1.2 & Arshan added modules to section 3 and 6\\
\bottomrule
\end{tabularx}
\end{table}
\newpage
\pagenumbering{arabic}
\section{Introduction}
Decomposing a system into modules is a commonly accepted approach to developing
software. A module is a work assignment for a programmer or programming
team. We advocate a decomposition based on the principle of information hiding. This
principle supports design for change, because the ``secrets'' that each module
hides represent likely future changes. Design for change is valuable in SC,
where modifications are frequent, especially during initial development as the
solution space is explored.
Our design follows the rules layed out, as follows:
\begin{itemize}
\item System details that are likely to change independently should be the
secrets of separate modules.
\item Each data structure is used in only one module.
\item Any other program that requires information stored in a module's data
structures must obtain it by calling access programs belonging to that module.
\end{itemize}
After completing the first stage of the design, the Software Requirements
Specification (SRS), the Module Guide (MG) is developed. The MG
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
specifies the modular structure of the system and is intended to allow both
designers and maintainers to easily identify the parts of the software. The
potential readers of this document are as follows:
\begin{itemize}
\item New project members: This document can be a guide for a new project member
to easily understand the overall structure and quickly find the
relevant modules they are searching for.
\item Maintainers: The hierarchical structure of the module guide improves the
maintainers' understanding when they need to make changes to the system. It is
important for a maintainer to update the relevant sections of the document
after changes have been made.
\item Designers: Once the module guide has been written, it can be used to
check for consistency, feasibility and flexibility. Designers can verify the
system in various ways, such as consistency among modules, feasibility of the
decomposition, and flexibility of the design.
\end{itemize}
The rest of the document is organized as follows. Section
\ref{SecChange} lists the anticipated and unlikely changes of the software
requirements. Section \ref{SecMH} summarizes the module decomposition that
was constructed according to the likely changes. Section \ref{SecConnection}
specifies the connections between the software requirements and the
modules. Section \ref{SecMD} gives a detailed description of the
modules. Section \ref{SecTM} includes two traceability matrices. One checks
the completeness of the design against the requirements provided in the SRS. The
other shows the relation between anticipated changes and the modules. Section
\ref{SecUse} describes the use relation between modules.
\section{Anticipated and Unlikely Changes} \label{SecChange}
This section lists possible changes to the system. According to the likeliness
of the change, the possible changes are classified into two
categories. Anticipated changes are listed in Section \ref{SecAchange}, and
unlikely changes are listed in Section \ref{SecUchange}.
\subsection{Anticipated Changes} \label{SecAchange}
Anticipated changes are the source of the information that is to be hidden
inside the modules. Ideally, changing one of the anticipated changes will only
require changing the one module that hides the associated decision. The approach
adapted here is called design for
change.
\begin{description}
\item[\refstepcounter{acnum} \actheacnum \label{acHardware}:]
The specific hardware on which the software is running.
\item[\refstepcounter{acnum} \actheacnum \label{acInput}:]
The format of the initial input data.
\item[\refstepcounter{acnum} \actheacnum \label{acSample}:]
...
\end{description}
\subsection{Unlikely Changes} \label{SecUchange}
The module design should be as general as possible. However, a general system is
more complex. Sometimes this complexity is not necessary. Fixing some design
decisions at the system architecture stage can simplify the software design. If
these decision should later need to be changed, then many parts of the design
will potentially need to be modified. Hence, it is not intended that these
decisions will be changed.
\begin{description}
\item[\refstepcounter{ucnum} \uctheucnum \label{ucIO}:]
Input/Output devices (Input: File and/or Keyboard, Output: File, Memory, and/or Screen).
\item[\refstepcounter{ucnum} \uctheucnum \label{ucInput}:]
There will always be a source of input data external to the software.
\item[\refstepcounter{ucnum} \uctheucnum \label{ucSample}:]
...
\end{description}
\section{Module Hierarchy} \label{SecMH}
\begin{description}
\item [\refstepcounter{mnum} \mthemnum \label{mHH}:] Hardware-Hiding Module
\item [\refstepcounter{mnum} \mthemnum \label{mLM}:] \textit{Launcher Modules}
\item [\refstepcounter{mnum} \mthemnum \label{mMGM}:] Maze Generator (Maze)
\item [\refstepcounter{mnum} \mthemnum \label{mSTM}:] Score Tracking (Maze)
\item [\refstepcounter{mnum} \mthemnum \label{mDGM}:] Draw Game (Maze)
\item [\refstepcounter{mnum} \mthemnum \label{mPMM}:] Player Movement (Maze)
\item [\refstepcounter{mnum} \mthemnum \label{mMSM}:] Menu and Settings (Maze)
\item [\refstepcounter{mnum} \mthemnum \label{mBTP}:] Ball Trajectory (Pong)
\item [\refstepcounter{mnum} \mthemnum \label{mSTP}:] Score Tracking (Pong)
\item [\refstepcounter{mnum} \mthemnum \label{mDGP}:] Draw Game (Pong)
\item [\refstepcounter{mnum} \mthemnum \label{mPMP}:] Player Movement (Pong)
\item [\refstepcounter{mnum} \mthemnum \label{mMSP}:] Menu and Settings (Pong)
\item [\refstepcounter{mnum} \mthemnum \label{mFM}:] \textit{Flappy Modules}
\end{description}
\begin{table}[h!]
\centering
\begin{tabular}{p{0.3\textwidth} p{0.6\textwidth}}
\toprule
\textbf{Level 1} & \textbf{Level 2}\\
\midrule
{Hardware-Hiding Module} & ~ \\
\midrule
\multirow{1}{0.3\textwidth}{Behaviour-Hiding Module} & ?\\
& \textit{Launcher Modules}\\
& Draw Game (Maze)\\
& Player Movement (Maze)\\
& Menu and Settings (Maze)\\
& Draw Game (Pong)\\
& Player Movement (Pong)\\
& Menu and Settings (Pong)\\
& \textit{Flappy Modules}\\
\multirow{1}{0.3\textwidth}{Software Decision Module} & {?}\\
& Ball Trajectory (Pong)\\
& Score Tracking (Pong) \\
\bottomrule
\end{tabular}
\caption{Module Hierarchy}
\label{TblMH}
\end{table}
\section{Connection Between Requirements and Design} \label{SecConnection}
The design of the system is intended to satisfy the requirements developed in
the SRS. In this stage, the system is decomposed into modules. The connection
between requirements and modules is listed in Table \ref{TblRT}.
\section{Module Decomposition} \label{SecMD}
Modules are decomposed according to the principle of ``information hiding''
proposed by . The \emph{Secrets} field in a module
decomposition is a brief statement of the design decision hidden by the
module. The \emph{Services} field specifies \emph{what} the module will do
without documenting \emph{how} to do it. For each module, a suggestion for the
implementing software is given under the \emph{Implemented By} title. If the
entry is \emph{OS}, this means that the module is provided by the operating
system or by standard programming language libraries. Also indicate if the
module will be implemented specifically for the software.
Only the leaf modules in the
hierarchy have to be implemented. If a dash (\emph{--}) is shown, this means
that the module is not a leaf and will not have to be implemented. Whether or
not this module is implemented depends on the programming language
selected.
\subsection{Hardware Hiding Modules (\mref{mHH})}
\begin{description}
\item[Secrets:]The data structure and algorithm used to implement the virtual
hardware.
\item[Services:]Serves as a virtual hardware used by the rest of the
system. This module provides the interface between the hardware and the
software. So, the system can use it to display outputs or to accept inputs.
\end{description}
\subsection{Behaviour-Hiding Module}
\begin{description}
\item[Secrets:]The contents of the required behaviours.
\item[Services:]Includes programs that provide externally visible behaviour of
the system as specified in the software requirements specification (SRS)
documents. This module serves as a communication layer between the
hardware-hiding module and the software decision module. The programs in this
module will need to change if there are changes in the SRS.
\subsubsection{Draw Game (Maze) Module (\mref{mDGM})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsubsection{Player Movement (Maze) Module (\mref{mPMM})}
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsubsection{Menu and Settings (Maze) Module (\mref{mMSM})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsubsection{Draw Game (Pong) Module (\mref{mDGP})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsubsection{Player Movement (Pong) Module (\mref{mPMP})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsubsection{Menu and Settings (Pong) Module (\mref{mMSP})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries, pygame
\end{description}
\subsection{Software Decision Module}
\begin{description}
\item[Secrets:] The design decision based on mathematical theorems, physical
facts, or programming considerations. The secrets of this module are
\emph{not} described in the SRS.
\item[Services:] Includes data structure and algorithms used in the system that
do not provide direct interaction with the user.
% Changes in these modules are more likely to be motivated by a desire to
% improve performance than by externally imposed changes.
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
\item[Implemented By:] N/A
\end{description}
\subsubsection{Maze Generator (Maze) Module (\mref{mMGM})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries
\end{description}
\subsubsection{Score Tracking (Maze) Module (\mref{mSTM})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries
\end{description}
\subsubsection{Ball Trajectory (Pong) Module (\mref{mBTP})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries
\end{description}
\subsubsection{Score Tracking (Pong) Module (\mref{mSTP})}
\begin{description}
\item[Secrets:]
\item[Services:]
\item[Implemented By:] Mini-Arcade, Python Libraries
\end{description}
\section{Traceability Matrix} \label{SecTM}
% the table should use mref, the requirements should be named, use something
% like fref
\begin{table}[H]
\centering
\begin{tabular}{p{0.2\textwidth} p{0.6\textwidth}}
\toprule
\textbf{Req.} & \textbf{Modules}\\
\midrule
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
\multicolumn{2}{c}{Functional Requirements} \\
\midrule
FR1 & \\
FR2 & \\
FR3 & \\
FR4 & \\
FR5 & \\
FR6 & \\
FR7 & \\
FR8 & \\
FR9 & \\
FR10 & \\
FR11 & \\
FR12 & \\
FR13 & \\
FR14 & \\
FR15 & \\
FR16 & \\
FR17 & \\
FR18 & \\
FR19 & \\
FR12 & \\
FR21 & \\
FR22 & \\
FR23 & \\
FR24 & \\
FR25 & \\
FR26 & \\
FR27 & \\
FR28 & \\
FR29 & \\
FR30 & \\
\midrule
\multicolumn{2}{c}{Non-Functional Requirements} \\
\midrule
NFR1 & \\
NFR2 & \\
NFR3 & \\
NFR4 & \\
NFR5 & \\
NFR6 & \\
NFR7 & \\
NFR8 & \\
NFR9 & \\
NFR10 & \\
NFR11 & \\
NFR12 & \\
\bottomrule
\end{tabular}
\caption{Trace Between Requirements and Modules}
\label{TblRT}
\end{table}
\begin{table}[H]
\centering
\begin{tabular}{p{0.2\textwidth} p{0.6\textwidth}}
\toprule
\textbf{AC} & \textbf{Modules}\\
\midrule
\acref{acHardware} & \mref{mHH}\\
\bottomrule
\end{tabular}
\caption{Trace Between Anticipated Changes and Modules}
\label{TblACT}
\end{table}
\section{Use Hierarchy Between Modules} \label{SecUse}
In this section, the uses hierarchy between modules is
provided. Parnas said of two programs A and B that A {\em uses} B if
correct execution of B may be necessary for A to complete the task described in
its specification. That is, A {\em uses} B if there exist situations in which
the correct functioning of A depends upon the availability of a correct
implementation of B. Figure \ref{FigUH} illustrates the use relation between
the modules. It can be seen that the graph is a directed acyclic graph
(DAG). Each level of the hierarchy offers a testable and usable subset of the
system, and modules in the higher level of the hierarchy are essentially simpler
because they use modules from the lower levels.
\begin{figure}[H]
\centering
%\includegraphics[width=0.7\textwidth]{UsesHierarchy.png}
\caption{Use hierarchy among modules}
\label{FigUH}
\end{figure}
\section{Gantt Schedule} \label{SeCSched}
See Gantt Chart at the following url: \\
%\url{../../ProjectSchedule/3XA3-ProjSched.pdf}\\
%\includegraphics[width=14cm]{TestPlan/GanttRev2.png}\\
\\
%\includegraphics[width=14cm]{TestPlan/GanttRevB2.png}
%\section*{References}
\bibliographystyle {plainnat}
\bibliography {MG}