diff --git a/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.pdf b/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.pdf index 0c4230da5871852ce809b5081d0d764f8873f2e1..7c21ed245076b8ddbf9dbff33149c77b9c739e99 100644 Binary files a/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.pdf and b/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.pdf differ diff --git a/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.tex b/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.tex index c529bd9a0be1134174abc1c1e0fbb721acde63a8..e64c3ba1cd6f036b28c9c8dced81abcbab3423e7 100755 --- a/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.tex +++ b/Lectures/L05_SoftEngPrinciples/SoftEngPrinciples.tex @@ -279,7 +279,7 @@ TBD \begin{frame} \frametitle{Formality versus Rigour} -What are the advantages of formality over rigour? What are the disadvantages? +\structure{What are the advantages of formality over rigour? What are the disadvantages?} % advantage - unambiguous, can check for consistency, basis of mechanization % disadvantages - understandability, cost \end{frame} @@ -300,6 +300,44 @@ statement True or False? %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\begin{frame} +\frametitle{Formality} + +The A1 assignment specification is formal. Is this statement True or False? +\begin{enumerate}[A.] +\item True +\item False %correct answer +\end{enumerate} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Formality} + +Your first year mathematics textbook is formal presentation of Calculus. Is this +statement True or False? +\begin{enumerate}[A.] +\item True +\item False %correct answer - rigorous, but not formal, could not teach it to a + %computer as given +\end{enumerate} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Formal Versus Rigorous} + +\href{https://shemesh.larc.nasa.gov/fm/papers/Butler-JFR-FV-Integ.pdf}{Formal + Version of Calculus ``Textbook''} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \begin{frame} \frametitle{Separation of Concerns} @@ -339,4 +377,124 @@ statement True or False? %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +\begin{frame} +\frametitle{Separation of Concerns} + +\structure{What are examples of separation of concerns in traditional engineering?}\\ +% consider a building, or automobile +~\newline +\structure{What are examples of separation of concerns in software engineering?}\\ + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Separation of Concerns: SE Examples} + +\begin{itemize} + +\item Separation of requirements from design +\item Separation of design from implementation +\item Decomposition of a system into a set of modules +\item The distinction between a module's interface and its implementation +\item The distinction between syntax and semantics + +\end{itemize} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Modularity} + +\begin{itemize} + +\item A \structure<0->{modular system} is a complex system that is divided into smaller parts called +\structure<0->{modules} +\item Modularity enables the principle of separation of concerns to be applied in two ways: +\begin{enumerate} +\item Different parts of the system are considered separately +\item The parts of the system are considered separately from their composition +\end{enumerate} +\item \structure<0->{Modular decomposition} is the \alert{top-down} process of + dividing a system into modules +\item Modular decomposition is a \alert{``divide and conquer''} approach +\item \structure<0->{Modular composition} is the \alert{bottom-up} process of + building a system out of modules +\item Modular composition is an \alert{``interchangeable parts''} approach + +\end{itemize} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Examples of Modularity} + +\structure{What are examples of modularity in traditional engineering?}\\ + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Properties of Good Modules} + +\begin{itemize} + +\item To achieve the benefits of modularity, a software engineer must design + modules with two properties +\begin{enumerate} +\item \structure<0->{High cohesion:} The components of the module are closely + related +\item \structure<0->{Low coupling:} The module does not strongly depend on other + modules +\end{enumerate} +\item This allows the modules to be treated in two ways: +\begin{enumerate} +\item As a set of interchangeable parts +\item As individuals +\end{enumerate} + +\end{itemize} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Zero Coupling?} + +Given that low coupling is desirable, the ideal modularization has zero coupling. Is this +statement True or False? +\begin{enumerate}[A.] +\item True +\item False %correct answer - without coupling, every module would have to + %provide all of its own services - need some communication, think of electrical power + %network in a home +\end{enumerate} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +\begin{frame} +\frametitle{Proposed Modularization for a Car} + +Suppose you decide to modularize the description of a car by considering the +car as comprising small cubes 15 inches on a side. +\begin{enumerate} +\item Is the cohesion high or low? +\item Is the coupling high or low? +\item Propose a better modularization +\item In general, how should you decompose a complex system into modules? +\end{enumerate} + +\end{frame} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + \end{document} \ No newline at end of file diff --git a/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.pdf b/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.pdf index 7f2cd982ca5cf24093c5dfd50fa766c8555b9423..72e2c75be85b55091935ea7be65a07908d7c295e 100644 Binary files a/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.pdf and b/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.pdf differ diff --git a/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.tex b/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.tex index b4d044dc612293c91f85b07fc48b1088e6ecb05f..fb9e71133caf60eb0b1b5285424e06d2028cc783 100755 --- a/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.tex +++ b/Lectures/L06_SoftEngPrinciplesContd/SoftEngPrinciplesContd.tex @@ -119,23 +119,13 @@ TBD %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\begin{frame} -\frametitle{Formal Versus Rigourous} - -\href{https://shemesh.larc.nasa.gov/fm/papers/Butler-JFR-FV-Integ.pdf}{Formal - Version of Calculus ``Textbook''} - -\end{frame} - -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% - \begin{frame} \frametitle{Separation of Concerns} -What are examples of separation of concerns in traditional engineering?\\ +\structure{What are examples of separation of concerns in traditional engineering?}\\ % consider a building, or automobile ~\newline -What are examples of separation of concerns in software engineering?\\ +\structure{What are examples of separation of concerns in software engineering?}\\ \end{frame} @@ -186,7 +176,7 @@ What are examples of separation of concerns in software engineering?\\ \begin{frame} \frametitle{Examples of Modularity} -What are examples of modularity in traditional engineering?\\ +\structure{What are examples of modularity in traditional engineering?}\\ \end{frame} @@ -278,7 +268,7 @@ car as comprising small cubes 15 inches on a side. \begin{frame} \frametitle{Abstract Data Type} -What makes an Abstract Data Type Abstract? +\structure{What makes an Abstract Data Type Abstract?} \end{frame} @@ -313,8 +303,8 @@ What makes an Abstract Data Type Abstract? \begin{frame} \frametitle{Anticipation of Change} -Change should be anticipated for the development process, as well as the -product. For instance, what can you do to anticipate changes in staffing? +\structure{Change should be anticipated for the development process, as well as the +product. For instance, what can you do to anticipate changes in staffing?} % important knowledge shouldn't be with just one person % documentation!