Skip to content
Snippets Groups Projects
Commit 880f9181 authored by W. Spencer Smith's avatar W. Spencer Smith
Browse files

Added repetition in Spec Quality (Line Formatter Example) to avoid unnec slide flipping

parent 99c57949
No related branches found
No related tags found
No related merge requests found
No preview for this file type
%\documentclass[t,12pt,numbers,fleqn,handout]{beamer} \documentclass[t,12pt,numbers,fleqn,handout]{beamer}
\documentclass[t,12pt,numbers,fleqn]{beamer} %\documentclass[t,12pt,numbers,fleqn]{beamer}
\usepackage{pgfpages} \usepackage{pgfpages}
\usepackage{hyperref} \usepackage{hyperref}
...@@ -107,6 +107,33 @@ TBD ...@@ -107,6 +107,33 @@ TBD
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}[plain,fragile]
%\frametitle{Line Formatter Example}
%With different versions of MAXPOS
\begin{verbatim}
Lorem BL ipsum BL NL dolor BLBLBL sit BL amet, BL
consectetur.ET
Lorem ipsum dolor sit
amet, consectetur.ET
Lorem ipsum
dolor sit
amet,
consectetur.ET
Lorem
ipsum
dolor
sit
amet,
consectetur.ET
\end{verbatim}
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame} \begin{frame}
\frametitle{Line Formatter} \frametitle{Line Formatter}
...@@ -162,15 +189,43 @@ successive NL characters) ...@@ -162,15 +189,43 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{Abstract?} \frametitle{Abstract?}
\uncover<2->{
\bi \bi
\item Not abstract! \item \structure{Input} stream signalled with ET
\item Exactly one ET character in each input stream
\item \structure{Character} classifications:
\bi
\item Break character - BL (blank) and NL (new line)
\item Non Break Character - all others except ET
\item End of text indicator ET
\ei
\item \structure{Word} is a non-empty sequence of non break characters
\item \structure{Break} is a sequence of one or more break characters
\item \structure{Output} same sequence of words, except if there is an oversize
word
\bi
\item Oversize means more than MAXPOS characters, where MAXPOS is a positive
integer
\item If there is an oversize word
\bi
\item Set Alarm to TRUE
\item Exit the program
\ei
\ei
\ei
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}
\frametitle{Not Abstract}
\bi
\item Specifies an implementation for error handling (variable named Alarm) \item Specifies an implementation for error handling (variable named Alarm)
\item Do not have to name the variable Alarm \item Do not have to name the variable Alarm
\item Could use exception handling (or another approach) instead \item Could use exception handling (or another approach) instead
\item ET is a machine dependent (program domain) concept \item ET is a machine dependent (program domain) concept - abstractly, the input
is simply a finite sequence of characters
\ei \ei
}
\end{frame} \end{frame}
...@@ -179,15 +234,34 @@ successive NL characters) ...@@ -179,15 +234,34 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{Correct?} \frametitle{Correct?}
\uncover<2->{
\bi \bi
\item The definition of line is incorrect! \item Up to the point of an error, the program's output should have the
following properties
\bi
\item A new line should start only between words and at the beginning of the
output text, if any
\item A break in the input is reduced to a single break character in the output
\item As many words as possible should be placed on each line (i.e.\ between
successive NL characters)
\item No line may contain more than MAXPOS characters (words and BLs)
\ei
\ei
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}
\frametitle{Incorrect!}
\bi
\item A line is defined as being between NLs, which ignores text before the \item A line is defined as being between NLs, which ignores text before the
first NL and after the last NL first NL and after the last NL
\item The output file does not contain ET, which is either a bug in the spec or \item The output file does not contain ET, which is either a bug in the spec or
a significant non-uniformity a significant non-uniformity
\ei \ei
}
\end{frame} \end{frame}
...@@ -196,12 +270,33 @@ successive NL characters) ...@@ -196,12 +270,33 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{Unambiguous?} \frametitle{Unambiguous?}
\uncover<2->{
\bi \bi
\item Ambiguous! \item Up to the point of an error, the program's output should have the
following properties
\bi
\item A new line should start only between words and at the beginning of the
output text, if any
\item A break in the input is reduced to a single break character in the output
\item As many words as possible should be placed on each line (i.e.\ between
successive NL characters)
\item No line may contain more than MAXPOS characters (words and BLs)
\ei
\ei
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}
\frametitle{Ambiguous!}
\bi
\item ``output text, if any''
\item ``point of error'' is not defined \item ``point of error'' is not defined
\item Output matches input to the last acceptable word, or the last acceptable character? \item Output matches input to the last acceptable word, or the last acceptable character?
\item ``trailing blanks ending with ET'' is ambiguous \item ``trailing blanks ending with ET'' is ambiguous (trailing means at the end!)
\item The program's output should be the same sequence of words as in the input \item The program's output should be the same sequence of words as in the input
\bi \bi
\item But the input is not a sequence of words \item But the input is not a sequence of words
...@@ -214,7 +309,6 @@ successive NL characters) ...@@ -214,7 +309,6 @@ successive NL characters)
\ei \ei
\ei \ei
\ei \ei
}
\end{frame} \end{frame}
...@@ -223,13 +317,41 @@ successive NL characters) ...@@ -223,13 +317,41 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{Complete?} \frametitle{Complete?}
\uncover<2->{
\bi \bi
\item Not complete! \item \structure{Input} stream signalled with ET
\item Meaning of NL and its relation to the concept of line is left implicit \item Exactly one ET character in each input stream
\item \structure{Character} classifications:
\bi
\item Break character - BL (blank) and NL (new line)
\item Non Break Character - all others except ET
\item End of text indicator ET
\ei
\item \structure{Word} is a non-empty sequence of non break characters
\item \structure{Break} is a sequence of one or more break characters
\item \structure{Output} same sequence of words, except if there is an oversize
word
\bi
\item Oversize means more than MAXPOS characters, where MAXPOS is a positive
integer
\item If there is an oversize word
\bi
\item Set Alarm to TRUE
\item Exit the program
\ei
\ei
\ei
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}
\frametitle{Not Complete}
\bi
\item Meaning of NL and its relation to the concept of line is left implicit -
seem to expect that NL means carriage return on output, but they do not say this
\item Alarm is not specified if MAXPOS is never exceeded \item Alarm is not specified if MAXPOS is never exceeded
\ei \ei
}
\end{frame} \end{frame}
...@@ -238,7 +360,36 @@ successive NL characters) ...@@ -238,7 +360,36 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{Consistent?} \frametitle{Consistent?}
\uncover<2->{ \bi
\item \structure{Input} stream signalled with ET
\item Exactly one ET character in each input stream
\item \structure{Character} classifications:
\bi
\item Break character - BL (blank) and NL (new line)
\item Non Break Character - all others except ET
\item End of text indicator ET
\ei
\item \structure{Word} is a non-empty sequence of non break characters
\item \structure{Break} is a sequence of one or more break characters
\item \structure{Output} same sequence of words, except if there is an oversize
word
\bi
\item Oversize means more than MAXPOS characters, where MAXPOS is a positive
integer
\item If there is an oversize word
\bi
\item Set Alarm to TRUE
\item Exit the program
\ei
\ei
\ei
\end{frame}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{frame}
\frametitle{Not Consistent}
\bi \bi
\item Not consistent! \item Not consistent!
\item ``non-empty'' and ``one or more'' (synonyms) \item ``non-empty'' and ``one or more'' (synonyms)
...@@ -246,7 +397,6 @@ successive NL characters) ...@@ -246,7 +397,6 @@ successive NL characters)
\item Is the input a ``stream of characters'' or a ``sequence of words separated \item Is the input a ``stream of characters'' or a ``sequence of words separated
by breaks''? -- sequence of T is not the same as sequence of sequence of T by breaks''? -- sequence of T is not the same as sequence of sequence of T
\ei \ei
}
\end{frame} \end{frame}
...@@ -269,7 +419,7 @@ successive NL characters) ...@@ -269,7 +419,7 @@ successive NL characters)
\frametitle{Advantages and Disadvantages?} \frametitle{Advantages and Disadvantages?}
\bi \bi
\item \structure{Advantages and disadvantages of maintaining both \item \structure<1>{Advantages and disadvantages of maintaining both
formal and a natural language spec?} formal and a natural language spec?}
\ei \ei
...@@ -300,9 +450,11 @@ successive NL characters) ...@@ -300,9 +450,11 @@ successive NL characters)
\begin{frame} \begin{frame}
\frametitle{English and Mathematics as Languages} \frametitle{English and Mathematics as Languages}
\begin{itemize} See
\href{https://gitlab.cas.mcmaster.ca/smiths/se2aa4_cs2me3/blob/master/ReferenceMaterial/Baber2002.pdf}
{Baber2002}\\
\item From Dr. Baber, add link \begin{itemize}
\item English is a language \item English is a language
\item So is Mathematics \item So is Mathematics
\item Both have \item Both have
...@@ -476,7 +628,8 @@ successive NL characters) ...@@ -476,7 +628,8 @@ successive NL characters)
\begin{itemize} \begin{itemize}
\item When writing in English or any other natural language, one pays careful attention to \item When writing in English, or any other natural language, one pays careful
attention to
\begin{itemize} \begin{itemize}
\item Organization of the essay, report, etc. \item Organization of the essay, report, etc.
\item Style of expression \item Style of expression
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment