diff options
Diffstat (limited to 'macros')
24 files changed, 4240 insertions, 102 deletions
diff --git a/macros/latex/contrib/biblatex/CHANGES.md b/macros/latex/contrib/biblatex/CHANGES.md index d6fc6c23b9..c4db07a41c 100644 --- a/macros/latex/contrib/biblatex/CHANGES.md +++ b/macros/latex/contrib/biblatex/CHANGES.md @@ -1,6 +1,10 @@ +# RELEASE NOTES FOR VERSION 3.18b +- Reenable `\MakeUppercase`/`\MakeLowercase` "patches" for `\bibstring` + based on `\CaseSwitch`. + # RELEASE NOTES FOR VERSION 3.18a - Disable `\MakeUppercase`/`\MakeLowercase` patches as emergency fix - for LaTeX 2022-06-01-PL compatibility. + for LaTeX 2022-06-01-PL4 compatibility. # RELEASE NOTES FOR VERSION 3.18 - New sorting name key generation macro `\visibility` which allows diff --git a/macros/latex/contrib/biblatex/doc/biblatex.pdf b/macros/latex/contrib/biblatex/doc/biblatex.pdf Binary files differindex e9264025b9..a1f4b3d3c1 100644 --- a/macros/latex/contrib/biblatex/doc/biblatex.pdf +++ b/macros/latex/contrib/biblatex/doc/biblatex.pdf diff --git a/macros/latex/contrib/biblatex/doc/biblatex.tex b/macros/latex/contrib/biblatex/doc/biblatex.tex index 7cf466cc6e..67d334accd 100644 --- a/macros/latex/contrib/biblatex/doc/biblatex.tex +++ b/macros/latex/contrib/biblatex/doc/biblatex.tex @@ -68,7 +68,7 @@ url={\biblatexhome}, author={Philip Kime, Moritz Wemheuer, Philipp Lehman}, email={}, - revision={3.18a}, + revision={3.18b}, date={\today}} \hypersetup{% @@ -8545,7 +8545,7 @@ For any entry with an \bibfield{author} field, try to set } \end{ltxexample} % -Here, we use multiple match/replace for the same field to regularise some inconstant name variants. Bear in mind that \cmd{step} processing within a \opt{map} element is sequential and so the changes from a previous \cmd{step}s are already committed. Note that we don't need the \cmd{regexp} macro to protect the regular expressions in this example as they contain no characters which need special escaping. Please note that due to the difficulty of protecting regular expressions in \LaTeX, there should be no literal spaces in the argument to \cmd{regexp}. Please use escape code equivalents if spaces are needed. For example, this example, if using \cmd{regexp}, should be: +Here, we use multiple match/replace for the same field to regularise some inconstant name variants. Bear in mind that \cmd{step} processing within a \opt{map} element is sequential and so the changes from a previous \cmd{step}s are already committed. Note that we don't need the \cmd{regexp} macro to protect the regular expressions in this example as they contain no characters which need special escaping. Please note that due to the difficulty of protecting regular expressions in \latex, there should be no literal spaces in the argument to \cmd{regexp}. Please use escape code equivalents if spaces are needed. For example, this example, if using \cmd{regexp}, should be: % \begin{ltxexample} \DeclareSourcemap{ @@ -14858,9 +14858,13 @@ use$<$name$>$ &\+&\+&\_&\+&\+&\_&\_\\ This revision history is a list of changes relevant to users of this package. Changes of a more technical nature which do not affect the user interface or the behavior of the package are not included in the list. More technical details are to be found in the \file{CHANGES.md} file. The numbers on the right indicate the relevant section of this manual. \begin{changelog} +\begin{release}{3.18b}{2022-07-12} +\item Reenable \cmd{MakeUppercase}/\cmd{MakeLowercase} <patches> + based on \cmd{CaseSwitch} +\end{release} \begin{release}{3.18a}{2022-07-02} \item Disable \cmd{MakeUppercase}/\cmd{MakeLowercase} patches as emergency - fix for LaTeX 2022-06-01-PL compatibility. + fix for \latex 2022-06-01-PL4 compatibility. \end{release} \begin{release}{3.18}{2022-06-22} \item Added sorting option \cmd{intciteorder}\see{aut:ctm:srt} diff --git a/macros/latex/contrib/biblatex/latex/biblatex.sty b/macros/latex/contrib/biblatex/latex/biblatex.sty index 9fce90b22f..8b33c5d021 100644 --- a/macros/latex/contrib/biblatex/latex/biblatex.sty +++ b/macros/latex/contrib/biblatex/latex/biblatex.sty @@ -12,8 +12,8 @@ % particular purpose. % Set up the version strings here -\def\abx@date{2022/07/02} -\def\abx@version{3.18a} +\def\abx@date{2022/07/12} +\def\abx@version{3.18b} \def\abx@bbxid{\abx@date\space v\abx@version\space biblatex bibliography style (PK/MW)} \def\abx@cbxid{\abx@date\space v\abx@version\space biblatex citation style (PK/MW)} \def\abx@lbxid{\abx@date\space v\abx@version\space biblatex localization (PK/MW)} @@ -5052,73 +5052,147 @@ \ifbibstring \ifbibxstring \iffieldbibstring \iffieldplusstringbibstring} -\let\blx@hook@uc\relax -\let\blx@hook@lc\relax - -\iffalse -% disable this as emergency "fix" -% for LaTeX 2022-06-01-PL4 -\AtEndPreamble{% - \toggletrue{blx@tempa}% - \toggletrue{blx@tempb}% - \expandafter\patchcmd\csname MakeUppercase \endcsname - {\protected@edef} - {\blx@hook@uc\protected@edef} - {\togglefalse{blx@tempa}} - {}% - \expandafter\patchcmd\csname MakeLowercase \endcsname - {\protected@edef} - {\blx@hook@lc\protected@edef} - {\togglefalse{blx@tempb}} - {}% - \@ifpackageloaded{textcase} - {\expandafter\patchcmd\csname MakeUppercase \endcsname - {\def\i} - {\blx@hook@uc\def\i} +% \DeclareCaseChangeEquivalent is available in +% LaTeX 2022-06-01-PL5 +% the older code works-ish for LaTeX before 2022-06-01 +% it errors with 2022-06-01-PL4 +% but we'll not guard against this specific PL +\ifundef\DeclareCaseChangeEquivalent + {\let\blx@hook@uc\relax + \let\blx@hook@lc\relax + % + \AtEndPreamble{% + \toggletrue{blx@tempa}% + \toggletrue{blx@tempb}% + \expandafter\patchcmd\csname MakeUppercase \endcsname + {\protected@edef} + {\blx@hook@uc\protected@edef} {\togglefalse{blx@tempa}} {}% \expandafter\patchcmd\csname MakeLowercase \endcsname - {\@uclcnotmath{}} - {\@uclcnotmath{\blx@hook@lc}} + {\protected@edef} + {\blx@hook@lc\protected@edef} {\togglefalse{blx@tempb}} {}% - \expandafter\patchcmd\csname MakeTextUppercase \endcsname - {\def\i} - {\blx@hook@uc\def\i} - {} + \@ifpackageloaded{textcase} + {\expandafter\patchcmd\csname MakeUppercase \endcsname + {\def\i} + {\blx@hook@uc\def\i} + {\togglefalse{blx@tempa}} + {}% + \expandafter\patchcmd\csname MakeLowercase \endcsname + {\@uclcnotmath{}} + {\@uclcnotmath{\blx@hook@lc}} + {\togglefalse{blx@tempb}} + {}% + \expandafter\patchcmd\csname MakeTextUppercase \endcsname + {\def\i} + {\blx@hook@uc\def\i} + {} + {}% + \expandafter\patchcmd\csname MakeTextLowercase \endcsname + {\@uclcnotmath{}} + {\@uclcnotmath{\blx@hook@lc}} + {} + {}} {}% - \expandafter\patchcmd\csname MakeTextLowercase \endcsname - {\@uclcnotmath{}} - {\@uclcnotmath{\blx@hook@lc}} - {} - {}} - {}% - \iftoggle{blx@tempa}{\blx@err@patch{\string\MakeUppercase}}{}% - \iftoggle{blx@tempb}{\blx@err@patch{\string\MakeLowercase}}{}% -} -\fi - -\appto\blx@blxinit{% - \def\blx@hook@uc{% - \def\bibstring{\blx@imc@bibucstring}% - \def\biblstring{\blx@imc@bibuclstring}% - \def\bibsstring{\blx@imc@bibucsstring}% - \def\biblcstring{\blx@imc@bibucstring}% - \def\biblclstring{\blx@imc@bibuclstring}% - \def\biblcsstring{\blx@imc@bibucsstring}% - \def\bibcpstring{\blx@imc@bibucstring}% - \def\bibcplstring{\blx@imc@bibuclstring}% - \def\bibcpsstring{\blx@imc@bibucsstring}}% - \def\blx@hook@lc{% - \def\bibstring{\blx@imc@biblcstring}% - \def\biblstring{\blx@imc@biblclstring}% - \def\bibsstring{\blx@imc@biblcsstring}% - \def\bibucstring{\blx@imc@biblcstring}% - \def\bibuclstring{\blx@imc@biblclstring}% - \def\bibucsstring{\blx@imc@biblcsstring}% - \def\bibcpstring{\blx@imc@biblcstring}% - \def\bibcplstring{\blx@imc@biblclstring}% - \def\bibcpsstring{\blx@imc@biblcsstring}}} + \iftoggle{blx@tempa}{\blx@err@patch{\string\MakeUppercase}}{}% + \iftoggle{blx@tempb}{\blx@err@patch{\string\MakeLowercase}}{}% + } + % + \appto\blx@blxinit{% + \def\blx@hook@uc{% + \def\bibstring{\blx@imc@bibucstring}% + \def\biblstring{\blx@imc@bibuclstring}% + \def\bibsstring{\blx@imc@bibucsstring}% + \def\biblcstring{\blx@imc@bibucstring}% + \def\biblclstring{\blx@imc@bibuclstring}% + \def\biblcsstring{\blx@imc@bibucsstring}% + \def\bibcpstring{\blx@imc@bibucstring}% + \def\bibcplstring{\blx@imc@bibuclstring}% + \def\bibcpsstring{\blx@imc@bibucsstring}}% + \def\blx@hook@lc{% + \def\bibstring{\blx@imc@biblcstring}% + \def\biblstring{\blx@imc@biblclstring}% + \def\bibsstring{\blx@imc@biblcsstring}% + \def\bibucstring{\blx@imc@biblcstring}% + \def\bibuclstring{\blx@imc@biblclstring}% + \def\bibucsstring{\blx@imc@biblcsstring}% + \def\bibcpstring{\blx@imc@biblcstring}% + \def\bibcplstring{\blx@imc@biblclstring}% + \def\bibcpsstring{\blx@imc@biblcsstring}}}} + {\DeclareCaseChangeEquivalent{\bibstring}{% + \CaseSwitch + {\blx@imc@bibstring} + {\blx@imc@bibucstring} + {\blx@imc@biblcstring} + {\blx@imc@bibcpstring}} + \DeclareCaseChangeEquivalent{\biblstring}{% + \CaseSwitch + {\blx@imc@biblstring} + {\blx@imc@bibuclstring} + {\blx@imc@biblclstring} + {\blx@imc@bibcplstring}} + \DeclareCaseChangeEquivalent{\bibsstring}{% + \CaseSwitch + {\blx@imc@bibsstring} + {\blx@imc@bibucsstring} + {\blx@imc@biblcsstring} + {\blx@imc@bibcpsstring}} + \DeclareCaseChangeEquivalent{\biblcstring}{% + \CaseSwitch + {\blx@imc@bibstring} + {\blx@imc@bibucstring} + {\blx@imc@biblcstring} + {\blx@imc@bibcpstring}} + \DeclareCaseChangeEquivalent{\biblclstring}{% + \CaseSwitch + {\blx@imc@biblstring} + {\blx@imc@bibuclstring} + {\blx@imc@biblclstring} + {\blx@imc@bibcplstring}} + \DeclareCaseChangeEquivalent{\biblcsstring}{% + \CaseSwitch + {\blx@imc@bibsstring} + {\blx@imc@bibucsstring} + {\blx@imc@biblcsstring} + {\blx@imc@bibcpsstring}} + \DeclareCaseChangeEquivalent{\bibucstring}{% + \CaseSwitch + {\blx@imc@bibstring} + {\blx@imc@bibucstring} + {\blx@imc@biblcstring} + {\blx@imc@bibcpstring}} + \DeclareCaseChangeEquivalent{\bibuclstring}{% + \CaseSwitch + {\blx@imc@biblstring} + {\blx@imc@bibuclstring} + {\blx@imc@biblclstring} + {\blx@imc@bibcplstring}} + \DeclareCaseChangeEquivalent{\bibucsstring}{% + \CaseSwitch + {\blx@imc@bibsstring} + {\blx@imc@bibucsstring} + {\blx@imc@biblcsstring} + {\blx@imc@bibcpsstring}} + \DeclareCaseChangeEquivalent{\bibcpstring}{% + \CaseSwitch + {\blx@imc@bibstring} + {\blx@imc@bibucstring} + {\blx@imc@biblcstring} + {\blx@imc@bibcpstring}} + \DeclareCaseChangeEquivalent{\bibcplstring}{% + \CaseSwitch + {\blx@imc@biblstring} + {\blx@imc@bibuclstring} + {\blx@imc@biblclstring} + {\blx@imc@bibcplstring}} + \DeclareCaseChangeEquivalent{\bibcpsstring}{% + \CaseSwitch + {\blx@imc@bibsstring} + {\blx@imc@bibucsstring} + {\blx@imc@biblcsstring} + {\blx@imc@bibcpsstring}}} \def\abx@dostrings{% \do{bibliography}% diff --git a/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.pdf b/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.pdf Binary files differnew file mode 100644 index 0000000000..fb59bfb9e7 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.tex b/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.tex new file mode 100644 index 0000000000..cf200e8c0e --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/NDSU-Thesis-Extended.tex @@ -0,0 +1,1800 @@ +\documentclass[phd]{ndsu-thesis-2022} + +%------------------------------------------------------------------------------ +%-------------[Options]-applicable in this class---------------------- +% Degree options (any of these): phd, ms-thesis, ms-paper, ma-thesis, ma-paper, default is phd; +% Whole document font size (any of these): 10pt, 11pt, 12pt, default = 12pt; +% nonumber = document without chapter/section numbering - one of the NDSU template style, default = numbered, tables and figures are serially numbered; +% chapternumber = document with only chapter numbering and no number of other sections, tables and figures are numbered with chapter numbers; +% nojustify = ragged-right (non-hyphenated whole words) passages, default = justified (hyphenated words) with straight right margin; +% draft = no figures but box frames, default = final; +% showframe = frame around the text area to check how text fills in the margins - this with draft option shows the items crossing the frame, default = noshowframe; +% fonts (any of these): bookman, charter, gentium, kpfonts, libertine, mathdesign, mathptmx, newcent, palatino, tgtermes, times, tgbonum, tgpagella, tgschola, utopia, zlmtt, default = LaTeX computer modern. +%------------------------------------------------------------------------------ + +%--------------------------------------------------------------------------------------------------- +% --------------Other useful commands or shortcuts available are:----------------- +% \listofabbreviations = A 2-col tabular environment; Usage: {SI & System International}\\ +% \listofsymbols = A 2-col tabular environment; Usage: {$A$ & Area (\si{\m\squared})}\\ +% \tempend{*.sty}{*.bib} = temporarily ending the document with reference listing +% \myspacing = defined to give the correct spacing of about 23 lines per page +% \myheading = proper numbering and format +% \si{} and \SI{}{} = SI units from siunitx package that gives proper spacing between numbers and units +% \citep and \citet = natbib package commands application with options +% \myfig{5 items} = shortcut for regular figures {placement}{size}{file}{caption}{label} +% \myfigls {5 items} = shortcut for landscape figures {placement}{size}{file}{caption}{label} +% \cref and \Cref = use of cleveref package based reference +% \tabcolsep = to stretch the tables to fill the entire width +% \resizebox = to adjust the size of tables to fit the margins (font size will change) +% \toprule, \midrule, \cmidrule, \bottomrule = booktabs package commands for tables +% tablenotes env. = threeparttable package commands for tables with footnotes +% longtable env. = for longer tables that spans several pages from longtable package - can be combined with threeparttable t +% \abovedisplayskip = to adjust the space above the displayed items +% \hl, \nt, \dt, \rt, \notes = annotation commands: highlight, new text, delete text, replace text, and todo notes +% \url = URLs break well as expected at the right margin (necessary code added in class) +% \namedappendices{A}{Name ... } = multiple appendices - correctly producing all elements +% \myfigap, \myfigapls = appendix regular figure and appendix landscape figure {5 items as before} +% \citestyle{} = predefined natbib styles (options: plain, agu, egu, agms, dcu, kluwer, cospar, nature) use this after \usepackage[sort&compress]{natbib} +% \lstset{e.g. language, font, style, color} options and {lstlisting} environment of listings package for programs and algorithms source code listing +% \closeappendices = produces all elements (loat, loaf) when the last appendix does not have at least a figure and a table. If present, no need to use +%--------------------------------------------------------------------------------------------------- + +%----------------------------------------------------------------------------- +%--------------------Load specific packages-------------------------- +\usepackage[sort&compress]{natbib} +\citestyle{arms} % plain, agu, egu, agms, dcu, kluwer, cospar, nature +\newtheorem{theorem}{Theorem}[section] +\newtheorem{corollary}{Corollary}[theorem] +\newtheorem{lemma}{Lemma}[corollary] +%----------------------------------------------------------------------------- + +%----------------------------------------------------------------------------- +%\AtBeginDocument{\raggedright} % No justification - NDSU template; justification also okay +\newcommand\myspacing{1.9} % 23 lines/page needs 1.9 for thesis; 1.5 for proposal +\newcommand\italk[1]{\textcolor{blue}{#1}} % for my texts +\newcommand\cmd[1]{\textbackslash\texttt{#1}} % for commands +\newcommand\tend{\tempend{apalike}{my-bib-file}} % shortcut for tempend{bst}{bib} +%\captionsetup[figure]{labelformat=simple, labelsep=colon, labelfont=it,textfont={bf,it}} +%\captionsetup[table]{labelformat=simple, labelsep=colon, labelfont=it,textfont={bf,it}} + +\newcommand\lx{\LaTeX\xspace} +\newcommand\tx{\TeX\xspace} +\newcommand\bx{Bib\!\TeX\xspace} +\newcommand\rr{$\Rightarrow$\xspace} +\newcommand\vb[1]{\textcolor{blue}{\texttt{#1}}}%verb for text - Green3 of x11names is good +\newcommand\vbc[1]{\textcolor{blue}{\textbackslash\,\texttt{#1}}}%verb for commands + +% listing package options loaded to produce the listing () +\definecolor{pblue}{rgb}{0.13,0.13,1} +\definecolor{pgreen}{rgb}{0,0.5,0} +\definecolor{pred}{rgb}{0.9,0,0.3} +\definecolor{pgrey}{rgb}{0.46,0.45,0.48} + +\lstset{language=Java, + showspaces=false, + showtabs=false, + breaklines=true, + showstringspaces=false, + breakatwhitespace=true, + commentstyle=\color{pgreen}, + keywordstyle=\color{pblue}, + stringstyle=\color{pred}, + basicstyle={\ttfamily, \footnotesize}, + moredelim=[il][\textcolor{pgrey}]{$$}, + moredelim=[is][\textcolor{pgrey}]{\%\%}{\%\%} +} + +\newcommand\tabletopinfo{ +\toprule +Area (ha) & Number & Methods & Aggregation & Transport & Total & MD$^\dag$ & TSP$^\ddag$ \\ +$[$ac$]$ & of baless & & (km) & (km) & (km) & (km) & (km) \\ + \midrule +} + +%----------------------------------------------------------------------------- +\title{An M.S. Thesis or Ph.D. Dissertation Extended Illustration Sample Generated - Using the new ``NDSU-Thesis-2022'' \LaTeX\ Class and Template} +\author{Samuel Quincy Student} +\date{September 2022} +\progdeptchoice{Department} % Use Department (or) Program +\department{Mathematics} + +\cchair{Prof. John Adams} % Use actual committee members names +\cmembera{Prof. Abraham Lincoln} +\cmemberb{Prof. George Washington} +\cmemberc{Prof. Theodore Roosevelt} % If 3rd not required - delete this line +\approvaldate{2 September 2022} +\approver{Prof. James Garfield} + +\abstract{ +\hl{\emph{Note}: All the sample text from the example thesis and dummy text are in black and other instructions by the author are shown in color to draw users' attention. It should be noted that for the NDSU actual thesis/dissertation only black text should be used in general!} + +This is the abstract for my thesis. + +\italk{This document uses the new: \textbf{ndsu-thesis-2022.cls} class and \textbf{my-bib-file.bib} file storing the bibliography database.} \italk{NDSU has word count limitations and that should be adhered to. URL:} \textcolor{magenta}{\url{https://www.ndsu.edu/gradschool/current_students/graduation/theses_dissertations_papers/disquisition_formatting}}: \italk{``Margins must be at least \SI{1}{in} on each side of the page. Page number margins must be at least \SI{0.75}{in} from the bottom of the page. Abstracts appear after the Disquisition Approval page and begin on page iii of the disquisition. Abstracts for dissertations may not exceed 350 words. Abstracts for thesis and papers may not exceed 150 words.''} + +\italk{One the useful resources to learn \LaTeX\ is: } \textcolor{magenta}{\url{https://www.overleaf.com/learn/latex/Learn_LaTeX_in_30_minutes?utm_source=overleaf&utm_medium=email&utm_campaign=onboarding}} \italk{And others include (details in REFERENCES):} \textcolor{magenta}{(1) The Not So Short Introduction to \LaTeXe\/, (2) A Guide to \LaTeX\ and Electronic Publishing, and (3) \LaTeX\ -- A Document Preparation System.} + +\italk{Several features such as \textcolor{magenta}{newcommand - shortcuts, longtable - spanning more pages, threeparttable - table notes, tables spanning the entire width (tabu), subfigures - side-by-side figures, tikz - code-generated vector figures, itemize - bullet list, enumerate - number list, matrix, advanced math, various symbols, etc.,} can be inserted into the thesis following standard resource materials. All the general \LaTeX\ based commands and features will work in the NDSU \LaTeX\ thesis class.} + +\vspace{-1ex} +\italk{\hfill --- C. Igathinathane\\} +\italk{\hfill \scriptsize Ag \& Bio Sys Eng, NDSU} +} + +\acknowledgements{I acknowledge people here.} +\dedication{This thesis is dedicated to my cat, Mr. Fluffles.} +\preface{You can put a preface here.} + +\listofabbreviations{ % A 2-col tabular environment and may use titlecase; ;Usage: SI & System International\\ +AC & Alternating Current \\ +AGL & Above Ground Level \\ +API & Application Programming Interface \\ +NDSU & North Dakota State University \\ +ZL & Zeta Level +} + +\listofsymbols{ % A 2-col tabular environment and may use sentencecase; Usage: $A$ & Area (\si{\m\squared})\\ +$A$ & Area (\si{\m\squared})\\ +$e$ & Euler's constant (\num{2.718281828}) \\ +$R^2$ & Coefficient of determination\\ +$T$ & Time (s)\\ +$v$ & Velocity (\si{\m\per\second})\\ +$x$ & $x$-coordinate of image pixel \\ +$y$ & $y$-coordinate of image pixel \\ +$\sigma$ & Standard deviation\\ +$\gamma$ & Hyperparameter in SVM +} + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\begin{document} + +%----------------------------------------------------------------------------- +%\setlength{\parindent}{0.5in} % Automatic indenting - NDSU +\begin{spacing}{\myspacing} % New line spacing - 23 lines per page +%\linenumbers % When required during review +%------------------------------------------- + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\mypaperheading{General aspects --- Paper-Styled Chapter --- some study titles are long, and we are making it long enough so that it flow more than two line - oops it went to the fourth}{*}{This paper is planned to be submitted as a review article in the \emph{Advanced Technical Research Collection} journal. All the co-authors have assisted in the research direction and review of the manuscript.} + +%----------------------------------------------------------------------------- +%\vspace{-1ex} % adjusting the space when needed +\section{Abstract} +\italk{Welcome to the \LaTeX\ ``ndsu-thesis-2022'' document class (NDSU class hereafter) and this document serve as an \textcolor{magenta}{\emph{extended example}} of a template. The users are urged to first get familiarized with the \textcolor{magenta}{\emph{NDSU class documentation}}, where most of the instructions for developing the thesis/dissertation using the NDSU class are clearly outlined. The NDSU class tries to address several dissertation requirements that graduate students come to expect from a template. While \LaTeX\ provides several tools to create a professional-looking document, it requires some learning --- a new set of skills is always a desirable thing to have, especially for students. Several leading universities have their \emph{thesis} class and template to help their students, and NDSU is no different (we do have our thesis class, and being used by several students!). The NDSU \LaTeX\ class (previous and updated) even features in the CTAN (Comprehensive \TeX\ Archive Network) repository of \LaTeX. CTAN is the central archive location that currently (July 2022) has 6249 packages from 2869 contributors and most of the packages are free to download and use immediately. A search on ``thesis'' returns 114 hits in CTAN showing the popularity of universities developing their \LaTeX\ class to help their grad students with dissertations. Given the quality of output, no wonder that several publishing houses (peer-reviewed journals and books) use \LaTeX\ as their system and provide authors with templates and reference styles. In this document/chapter, we outline and provide illustrations of using the updated NDSU class for developing thesis/dissertations, and users should have noted that this document itself uses the updated NDSU class.\\ +} + +%----------------------------------------------------------------------------- +\vspace{-5ex} +\section{Introduction --- Second Section After Abstract --- \LaTeX\ as a Tool for Students/Researchers} +\italk{Students having some exposure to computer programming, which is quite common nowadays, find their way easily with \LaTeX\ as it follows structure principles (e.g., HTML, program codes requiring open and end braces/brackets, etc.,). It is interesting to hear what the creator of \LaTeX\ says on this:} +\textcolor{magenta}{ +\begin{quote} +\singlespacing +\raggedright +\textit{ +\LaTeX\ is easy to use --- if you're one of the \pr{2} of the population who thinks logically and can read an instruction manual. The other \pt{98} of the population would find it very hard or impossible to use.} +\hfill --- Leslie Lamport (2001) +\end{quote} +} + +\italk{As mentioned in the class documentation, it is safe to assume that students of higher education that came this far should have ``cared enough'' to improve the quality of their thesis/dissertation. On the other hand, some who may think they fall in the 98\,\% might discover that they have better logical skills than they originally believed. Based on our personal experience, \LaTeX\ is not as difficult as it was portrayed, and the benefits outweigh the effort (which also is a great skill to be acquired). Furthermore, using \LaTeX\ for the documentation needs (e.g., thesis/dissertation, paper, report, book, letter, CV, and so on) should be considered a useful skill in itself that students can pick up and use throughout their carrier. +} + +%------------------------------------------- +\subsection{Using and Installing \LaTeX\ --- Online and Desktop Environments} \index{online editor} \index{standalone editor} +\italk{\emph{This text was reproduced from the NDSU class documentation (Sec. 2) for ready reference.} Several online (e.g., Overleaf, Kile LaTex Editor, Authorea, Papeeria, and so on) and standalone desktop versions (e.g., TeXMaker, TeXWorks, TexShop, TeXStudio, and so on) of \LaTeX\ editors are available. Online editors are ``ready-to-go,'' with several templates, tutorials, and help documentation, where the user need not install the software but require an internet connection. The desktop version requires software installation and updating (not very frequent). Resources (text and video instructions) are available on both how to use the online editor and install the \LaTeX\ desktop version of users' choice. As \LaTeX\ is open source, most of these editors are free.} + +%----------------------------------------------------------------------------- +\section{Merits and Issues of Using \lx} +\italk{The advantages and the possible issues of using \lx as the system especially for preparing articles, thesis, and books from the viewpoint of ABE students and professionals, both beginners and advanced users, are listed and discussed.} + +%------------------------------------------- +\subsection{Advantages} +\begin{itemize}[leftmargin=*, itemsep=0pt, parsep=3pt] + +\item \italk{\lx is a open source, free yet advanced, software that can be readily downloaded and installed easily in every type of computing system (Windows, Linux, Unix, DOS, and Mac OS). \lx is also a system that grows benefiting from the user-developed codes (classes, packages, and templates), and all these updates are again open source and free to use.} + +\item \italk{\lx allows the user to concentrate on the content while \lx performs the consistent formatting. In other words, the author does the ``writing'' and the \lx compiler performs the consistent ``formatting.'' --- In text processing systems (TPS), without a template different users will produce different outputs that lack consistency, but using a \lx class file, an essential argument of `\vb{documentclass},' ensures consistency across users.} + +\item \italk{\lx packs in the sound principles of professional typesetting while formatting the documents. This introduces the concept of ``readability'' of documents that takes care of features like the number of words per line, their spacing, hyphenation, spacing of elements with reference to font size, ligature, etc. --- Authors, in general, may not be aware of these principles of typesetting, and they go by ``visual formatting'' to their personal preference, sometimes violating the principles of typesetting, resulting in documents that lack consistency across authors, while \lx does the ``logical formatting'' that is well suited for technical documents.} + +\item \italk{\lx automates and updates several aspects of the document such as, table of contents (short and extended), list of tables, list of figures, index (multi-level), bibliography, nomenclature, glossary, among several other features. As \lx forces the users to follow the ``structural'' principles, automation of these features was possible and fully realized. --- Although such automation was possible with other TPS, the users are mostly unaware or rarely use them. Hence, this opportunity is usually \emph{missed} with TPS, but the benefits come naturally with \lx as it is a ``structural'' language.} + +\item \italk{\lx is an excellent choice of a document preparation system for technical theses, reports, and books. For thesis, some of the universities have developed their \lx document class and template files, and when utilized will create a uniform feel for all the thesis prepared. --- This uniform style among thesis is possible with other TPS as well through templates, yet the other automation benefits are not quite common with TPS.} + +\item \italk{Moving document elements while revising the document that calls for updating the numbers of the cited elements (headings, equations, floats, table of contents, index, etc.) will be handled automatically. --- This in the traditional manual way will be tedious and highly error-prone.} + +\item \italk{The user can have all the references in one place as a \bx ($\ast$.\vb{bib}) flat-file that can have several hundred entries, yet being ASCII the size will be quite small. For example, for a 100 article entry, with 1757 lines of data, the size of the bib file is 68 KB, as opposed to the same content in the TPS doc file is 192 KB. Such master bib file will serve as ``Once Write and Read Many'' mode of operation and can be subjected to several style formats directly. --- Usually, such automation with TPS may require additional commercial software (e.g., EndNote).} + +\item \italk{The references will be automatically generated with proper format when appropriate style files were used. This avoids the classical error of \emph{uncited references} and \emph{unlisted references}, which eliminates the need for the reviewer to check for this unproductive and easily avoidable mistake from the authors. With some styles (e.g., \vb{chicagoa.bst}) the reference items get sorted alphabetically. --- This is a clear advantage over other manual document preparation systems.} + +\item \italk{\lx measurements are very accurate and the smallest dimension it can recognize is `\vb{sp}' (scaled point) and 65536 sp make 1 \vb{pt} that in turn $\approx$ 0.351366666666667 mm \citep{Wikibook2016}. Therefore the smallest dimension that is available in \lx for manipulating elements (e.g., moving and sizing) is approximately $\frac{1}{186517}$ mm = 0.00536 $\mu$m. --- Such fine tuning of elements is unheard of with TPS in general.} + +\item \italk{Users can generate the submission-ready double-spaced ``review'' as well as two-column, double-sided, single-spaced ``final'' formats of the paper from the same source by utilizing appropriate options in the document class (e.g., \vb{elsarticle.cls}). --- Usually, with TPS the user has to create two different versions manually.} + +\item \italk{It is possible to submit the rendered pdf version of the paper ($\ast$\vb{.pdf}) directly to the publishers (e.g., Elsevier Editorial System - EES) and after acceptance, the source code files ($\ast$\vb{.tex}) can be uploaded. This method subsequently allows for direct usage of the codes by the publishers during proofs production, without having to re-key or convert articles submitted using other TPS. --- Hence the usage of \lx results in quicker production and fewer errors in typesetting.} + +\item \italk{Journal articles that are camera-ready, professionally typeset, journal-feel, compact (usually $\le$12 pages), offprint like, easy to maintain, having better readability can be prepared using \lx document classes ($\ast$\vb{.cls}) and templates furnished by several journals. --- However, with TPS the users usually end up with only the double-spaced version of the pre-submitted article (editable, very long, $\approx$ 20--40 pages), and the official generated version of the submitted article (pdf non-editable). The TPS tools are either not capable or do not encourage the authors to make outputs that resemble the final offprint, and they usually wait (sometimes for years) for the article to be finally published to see the paper in journal format.} + +\item \italk{Several journals due to copyright restrictions will not allow posting the published versions of the articles on the websites of the authors; however, the journals allow posting the preprint version prepared by the author. --- With \lx as the system of document preparation, the user can produce an output that has the journal-feel and almost matches the published article, which enhances the authors' visibility and possible future citations from other readers.} + +\item \italk{Advanced conditional formatting and handling of other features can be performed in \lx using the `\vb{ifthen}' package. For instance, the command} \ifthenelse{\boolean{@twocolumn}}{}{\\}\vbc{ifthenelse +\{\textbackslash boolean\{$@$twocolumn\}\}\{\}\{\textbackslash linenumbers\}\}} \italk{produces line numbers only when the document mode is single column format (e.g., review format). --- This is similar to using the ``If-Then-Else'' statement frequently used in programming languages for conditional controls.} + +\item \italk{Document annotation features such as strikeout (\dt{``deleted text''}), inserted (\nt{``newly added''}), and highlighted (\hl{``deserves attention''}) text materials are incorporated using \vbc{sout\{text\}}, \vbc{textcolor\{color\}\{text\}}, and \vbc{hl\{text\}} commands. --- To use these features, `\vb{ulem}', `\vb{color}', and `\vb{soul}' packages should be included.} + +\item \italk{Footnotes (see below; the command is \cmd{footnote\{text\}})\footnote{This is the footnote text and the footnote mark was automatically generated!}, margin notes {\marginpar{\scriptsize\textcolor{red}{This is margin note shown in color.}}} (shown in red), and end notes were also used to annotate the manuscript. It is equally possible to have these features in black \& white and with shades of grey. --- These commands can be simplified by defining shortcuts.} + +\item \italk{Using advanced conditional formatting, a single source code could produce the ``Annotated'' (color-coded revised version showing inserted and deleted text) and ``Revised'' (updated final) versions of the journals articles. --- It is a common practice in the peer-reviewed article publication process during revision to create such versions. This usually takes the preparation of two different versions with the usual TPS.} + +\item \italk{With \lx book document class such as `\vb{memoir.cls},' high-quality books with several professional layouts can be prepared. --- For very large books \lx is the non-crashing reliable system available and offers several tasks automation.} + +\item \italk{Advanced use of \lx allows for drawing figures through `\vb{pstricks}' or `\vb{eepic}' packages that offer extended capabilities and produces good quality vectorized ($\ast$.\vb{eps} files) mathematical, graphical, flowchart, and geometrical figures \citep{Goossens2008g}. The method involves only codes prepared in ASCII text. --- This drawing capability is available through specific drawing tools in other TPS. Shown here is a generated picture using simple codes in `\vb{picture}' environment using \vbc{line}, and \vbc{multiput} commands among others \citep{Kern2007a, Kern2007, Mittelbach2004}:} + +\newcount\WL \unitlength.91pt + +\begin{center} +\begin{picture}(460,60)(355,-10) +\sffamily \tiny \linethickness{1.25\unitlength} \WL=360 +\multiput(360,0)(1,0){456}% +{{\color[wave]{\the\WL}\line(0,1){50}}\global\advance\WL1} +\linethickness{0.25\unitlength}\WL=360 +\multiput(360,0)(20,0){23}% +{\picture(0,0) +\line(0,-1){5} \multiput(5,0)(5,0){3}{\line(0,-1){2.5}} +\put(0,-10){\makebox(0,0){\the\WL}}\global\advance\WL20 +\endpicture} +\end{picture} +\end{center} + +\italk{However, it is also possible to draw some simple pictures using `\vb{picture}' environment directly in \lx, but they were restricted in their range. Shown below are simple drawings that used \vbc{circle}, \vbc{vector}, and \vbc{framebox} commands among others.} + +\setlength{\unitlength}{0.25mm} +\begin{picture}(320,140)(-315,0) +\put(-260,50){{\thicklines \circle{90}}} +\put(-260,50){\vector(3,1){26}} +\put(-260,50){\vector(-3,-1){26}} +\put(-260,50){\vector(-1,3){9}} +\put(-265,34){\scriptsize $d$} +\put(-263,69){\scriptsize $r$} +\put(-200,50){\small $\textrm{Area}= +\frac{\pi d^2}{4}$ or \;{\small $\pi r^2$};} +\put(0,0){\thicklines \framebox(100,100){}} +\put(-1.5,105) {\line(0,1){16}} +\put(101.2,105){\line(0,1){16}} +\put(105,101.2){\line(1,0){16}} +\put(105,-1.5) {\line(1,0){16}} +\put(50,113) {\vector(1,0){50}} +\put(50,113){\vector(-1,0){50}} +\put(113,50) {\vector(0,1){50}} +\put(113,50){\vector(0,-1){50}} +\put(50,126){\scriptsize \makebox(0,0){$x$}} +\put(126,50){\scriptsize \makebox(0,0){$x$}} +\put(150,50){\small $\textrm{Area}= x^2$} +\end{picture} + +\noindent \italk{The above drawings are vector-based and will retain their quality at any level of magnification.} + +\item \italk{\lx can also be used to create conference posters (e.g., \vb{a0poster.cls} and \vb{sciposter.cls}) and presentation slides (eg. \vb{beamer.cls} and \vb{prosper.cls}) using appropriate classes and packages.} + +\item \italk{Students could able to convert their thesis into a journal article with a few easy modifications, as the basic \lx code is the same irrespective of the documentclass or template.} + +\item \italk{A knowledge of \lx forms a useful skill set for the students for pursuing an academic, research, or educational career. One can take advantage of the available various journal, books, curriculum vitae, reports, and thesis styles provided by the publishers and other online sources.} + +\end{itemize} + +%------------------------------------------- +\subsection{Possible Issues --- And Our Takes} +\begin{itemize}[leftmargin=*, itemsep=0pt, parsep=3pt] +\item \italk{People hold the idea that ``a steep learning curve is involved with \lx.'' However, users with programming knowledge (graduate students and researchers) will find it easy to switch from any TPS. Our experience says that it is quite logical to approach and fun to learn this excellent documentation tool. It should be seen as an opportunity to learn an important tool rather than looking at it as a steep learning exercise. One of the ready-to-work online platforms is \href{https://www.overleaf.com/login}{\textcolor{magenta}{\underline{Overleaf}}} where students can readily dive in and easily work with \lx and obtain various templates and helpful documentation all in one place. Steep learning curves are always associated with any new programming language or software. Mastering and exploring several aspects of \lx definitely requires involvement from the users but a lot of help is also readily available in the internet domain.} + +\item \italk{Since \lx is an open source free software that is not a product of any commercial firm, there will not be official support, but \lx purchased through commercial sources will. However, using books, websites, cheatsheets, mailing lists, and forums could solve most of the issues.} + +\item \italk{Developing user-defined classes, templates, and packages will be quite complicated, as it requires knowledge of plain \tx and \lx codes. Although, it should be understood that with thorough knowledge and understanding of the existing codes, it is possible to develop them as they were added on regular basis by developers throughout the world enriching the system. However, there is no need for a general user to venture into those areas, as most of the document preparation requirements could be addressed by employing the available sources.} + +\item \italk{Debugging the codes needs some practice. As with any computer language, missing a symbol will stop the compilation with error messages or produce several errors. With experience, the users can able to decipher the error messages better and fix the codes easily.} + +\item \italk{A reviewer or collaborating authors should know \lx in order to incorporate the suggestions and modify the document at the source level. The student \& advisor should be ``\lx aware'' or at least ``support'' the rendered output for the collaboration to work well. The ``Track-changes'' feature available with TPS is not directly available with \lx but available through specific packages. However, this is not an issue for one with a working knowledge in \lx; as one can readily make annotations such as insert, delete, highlight, and comment the document with color codes and special notes (e.g., footnotes, margin notes, endnotes) as indicated earlier.} + +\item \italk{Although the ``spelling check'' facility is available with several \lx front-end editors, the ``grammar checking'' facility that is usually available with TPS is not available at present in \lx editors. However, other free tools (e.g., Grammarly and several others) can be used.} + +\item \italk{Sometimes, especially when relying solely on online resources, there will be a lot of searching to find the right information to perform a particular task. Is it not a common feature of any good research (where we search for the information)?} + +\end{itemize} + +%------------------------------------------- +\subsection{Useful \LaTeX\ Resources --- Subsection (titlecase)} + +\italk{There are some of the popular resources (they are \textcolor{magenta}{clickable} hyperlinks):} + +\begin{itemize} +\setlength\itemindent{0.25in} +\item \citet{notso2021}: \textcolor{magenta}{\href{http://tug.ctan.org/info/lshort/english/lshort.pdf} +{The Not So Short Introduction to \LaTeXe\ }} + +\item \citet{kopka2004guide}: \textcolor{magenta}{\href{https://www.math.ucdavis.edu/~tracy/courses/math129/Guide_To_LaTeX.pdf} +{A Guide to \LaTeX\ and Electronic Publishing}} + +\item \citet{lamport94}: \textcolor{magenta}{\href{https://www.pearson.com/us/higher-education/program/Lamport-La-Te-X-A-Document-Preparation-System-2nd-Edition/PGM159713.html} +{\LaTeX\ -- A Document Preparation System}} + +\item \citet{Wikibook2016}: \textcolor{magenta}{\href{http://upload.wikimedia.org/wikipedia/commons/2/2d/LaTeX.pdf} +{LaTeX}} + +\item \citet{latxprojteam20}: \textcolor{magenta}{\href{https://www.latex-project.org/help/documentation/usrguide.pdf} +{\LaTeXe\ for authors}} + +\item \citet{latxprojteam22}: \textcolor{magenta}{\href{https://www.latex-project.org/help/documentation/usrguide3.pdf} +{New \LaTeX\ methods for authors (starting 2020)}} + +\item \citet{Chang2014cheat}: \textcolor{magenta}{\href{https://wch.github.io/latexsheet/latexsheet.pdf} +{\LaTeXe\ Cheat Sheet}} + +\item \citet{pakin2021comp}: \textcolor{magenta}{\href{https://tug.ctan.org/info/symbols/comprehensive/symbols-a4.pdf} +{The Comprehensive \LaTeX\ Symbol List}} +\end{itemize} + +\italk{References listing of these are shown in the combined reference chapter before the appendices (See page: \pageref{biblio})} + +%------------------------------------------- +\subsection{Modern \LaTeX\ Commands - Calculations} +\italk{The modern \LaTeX\ has several new functionalities \citep{latxprojteam22}. Several new document commands and environments were now available for use. For example, simple calculations can be produced using \cmd{fpeval\{expression\}} the floating point evaluation command as:} + +\verb|\fpeval{2*3*100+6}| = \fpeval{2*3*100+6}; \hspace{0.15in} Follows the standard PEMDAS rule + +\verb|\fpeval{2*(10+6)}| = \fpeval{2*(10+6)} + +\verb|\fpeval{22/7}| = \fpeval{22/7} + +\verb|\fpeval{pi}| = \fpeval{pi}; \hspace{0.15in} So, $\pi$ is $\neq$ 22/7 (one good to 3 digits) + +\verb|\fpeval{round(pi, 3)}| = \fpeval{round(pi, 3)}; \hspace{0.15in} Rounded to 3 decimals + +\verb+\fpeval{deg}+ = \fpeval{deg}; \hspace{0.15in} 1 degree in radian + +\verb|\LaTeX\ can now compute: $\frac{\sin(3.5)}{2} + 2 \cdot 10^{-3}| + +\verb| = \fpeval{sin(3.5)/2 + 2e-3}$| + +\lx can now compute: $\frac{\sin(3.5)}{2} + 2 \cdot 10^{-3} = \fpeval{sin(3.5)/2 + 2e-3}$ + +\italk{These mathematical functions finds use in calculations and technical document preparation.} + +%----------------------------------------------------------------------------- +\section{Some New Helpful Commands and Options Available in NDSU Thesis~Class} + +\begin{lstlisting}[basicstyle=\ttfamily\footnotesize\color{blue}] %or \small or \footnotesize etc. + +--------------------------------------------------------------------- +-------------[Options]-applicable in this class---------------------- + Document options (any of these): phd, ms-thesis, ms-paper, ma-thesis, + ma-paper, default is phd; + + Whole document font size (any of these): 10pt, 11pt, 12pt, + default = 12pt; + + nonumber = document without chapter/section numbering - one of the + NDSU template style, default = numbered; + + nojustify = ragged-right (non-hyphenated whole words) passages, + default = justified (hyphenated words) with straight right margin; + + draft = no figures but box frames, default = final; + + showframe = frame around the text area to check how text fills in the + margins - this with draft option shows the items crossing the frame, + default = noshowframe; + + fonts (any of these): bookman, charter, gentium, kpfonts, libertine, + mathdesign, mathptmx, newcent, palatino, tgtermes, times, tgbonum, + tgpagella, tgschola, utopia, zlmtt, default = LaTeX computer modern. +--------------------------------------------------------------------- +---------Other useful commands or shortcuts available are:----------- + \listofabbreviations{} = A 2-col tabular environment; use titlecase + Usage: {SI & System International}\\ + \listofsymbols{} = A 2-col tabular environment; use sentence case + Usage: {$A$ & Area (\si{\m\squared})}\\ + \tempend{*.sty}{*.bib} = temporarily ending the document with + reference listing + \myspacing = defined to give the correct spacing of about + 23 lines per page + \myheading{} = regular-styled chapter with proper numbering and format + Usage: \myheading{title} + \mypaperheading{3 args} = paper-styled chapter + Usage: \mypaperheading{title}{*}{footnote text} + \si{} and \SI{}{} = SI units from siunitx package that gives proper + spacing between numbers and units + \citep{} and \citet{} = natbib package commands for parenthetical and + textual citation while writing + \cref{} and \Cref{} = use of cleveref package based smart references + that understands figures, tables, sections, etc. + \tabcolsep = to stretch the tables to fill the entire width - need + to use trial-and-error to get correct output + \resizebox{} = to adjust the size of tables or figures to fit the margins + (font size will change) + \toprule, \midrule, \cmidrule, \bottomrule = booktabs package + commands for tables + \abovedisplayskip = to adjust the space above the displayed items, + especially equations + \hl{}, \nt{}, \dt{}, \rt{}{}, \notes{} = annotation commands: highlight, + new text, delete text, replace text, and todo notes (Sec. 2.4) + \url{} = URLs break well as expected at the right margin (necessary + code added in class) +\citestyle{} = predefined natbib styles (options: plain, agu, egu, + agms, dcu, kluwer, cospar, nature) + use this after \usepackage[sort&compress]{natbib} + \myfig[1 optional]{5 items} = shortcut for regular figures + [caption vertical placement]{placement}{size}{file}{caption}{label} + \myfigls[1 optional]{5 items} = shortcut for landscape figures + [caption vertical placement]{placement}{size}{file}{caption}{label} +--------------------------------------------------------------------- + tabu env. = automatic full-width table generation using tabu package. + Replaces tabular environment and can be used with booktabs package + tablenotes env. = threeparttable package commands for tables + with footnotes + longtable env. = for longer tables that span several pages from + longtable package - can be combined with threeparttable +--------------------------------------------------------------------- + \namedappendices{A}{Name ... } = multiple appendices with names + \myfigap, \myfigapls = appendix regular figure and appendix landscape + figure {1 optional + 5 items as before with figures} + \closeappendices = produces all elements (LOAT, LOAF) when the last + appendix does not have at least a figure and a table. + If present, no need to use it. +--------------------------------------------------------------------- +\end{lstlisting} + +%------------------------------------------- +\subsection{Introduction Subsection} +\kant[4] + +%------------------------------------------- +\subsubsection{Introduction Subsubsection} +\kant[6] + +%------------------------------------------- +\paragraph{Introduction paragraph} +\kant[8] + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Tables in thesis/dissertation --- Regular-Styled Chapter} + +%----------------------------------------------------------------------------- +\section{Simple Tables} + +\italk{Users are encouraged to refer to the Sec. 8.1 of the NDSU Class Documentation before seeing some of the examples presented in this chapter. Shown below is the most basic table using \lx \texttt{tabular} environment. Vertical lines (created by ``pipe'' character |), which are not generally used in professional tables, are shown to illustrate the column widths. However, | can be used for visualization during table development.} + +\begin{table}[h!] +\centering +\caption{Simple fixed-width table with left-justified top caption.} +\begin{tabular}{| l |c| r |} +\hline +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\hline +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\hline +\end{tabular} +\label{tab21} +\end{table} + +\italk{The code generated this table (\cref{tab21}) in single-spacing is shown below:} + +{\singlespacing +\begin{verbatim} +\begin{table}[h!] +\centering +\caption{Simple fixed-width table with left-justified top caption.} +\begin{tabular}{| l |c| r |} +\hline +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\hline +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\hline +\end{tabular} +\label{tab21a} +\end{table} +\end{verbatim} +} + +\italk{The same table (\cref{tab21}) will be made as a professional table, as seen in published articles (\cref{tab22}), using \texttt{booktabs} package. The only change is removing | and replacing the generic \cmd{hline} by appropriate commands such as \cmd{toprule}, \cmd{midrule} (less thick), and \cmd{bottomrule} that produce different line thicknesses. +} + +{\singlespacing +\begin{verbatim} +\begin{table}[h!] +\centering +\caption{Professional fixed-width table with left-justified top caption + using \texttt{booktabs} package.} +\begin{tabular}{ l c r } +\toprule +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\midrule +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\bottomrule +\end{tabular} +\label{tab22} +\end{table} +\end{verbatim} +}\label{tabcode22} + +\begin{table}[h!] +\centering +\caption{Professional looking fixed-width table with left-justified top caption using \texttt{booktabs} package.} +\begin{tabular}{ l c r } +\toprule +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\midrule +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\bottomrule +\end{tabular} +\label{tab22} +\end{table} + +%----------------------------------------------------------------------------- +\section{Help with \LaTeX\ Tables} +\italk{The code for the \Cref{tab22} may be a bit intimidating (really?), but it is just two nested environments (\vb{table} and \vb{tabular}). The layout is: \vb{table\{} -- \vb{caption} -- \vb{tabular\{} -- data rows -- \vb{tablular\}} -- \vb{label} -- \vb{table\}}. This layout when looked at in an overall manner is simple and all tables follows the same pattern.} + +\italk{\LaTeX installations will have some tools (e.g., IntelliSense code completion) that allow to develop table codes from scratch or paste the copied table data from spreadsheets (e.g., ``Paste Spreadsheet Cells -- booktabs'' in Mac) make table creation easy. Also, there are several online tools \href{https://www.tablesgenerator.com}{\textcolor{magenta}{Table Generator}} and \href{https://www.latex-tables.com}{\textcolor{magenta}{LaTeX Tables Editor}} among others will help generate table codes from typed data, and imported files (*.csv, *.xls, etc.,). Also Excel Add Ins such as \href{https://ctan.org/tex-archive/support/excel2latex?lang=en}{\textcolor{magenta}{Excel2\LaTeX}} will generate and export the table codes. +} + +%----------------------------------------------------------------------------- +\section{Full-width Tables} +\italk{Even though these tables (\cref{tab21,tab22}) were compact, they are not supported by NDSU guidelines. Therefore, these tables should be made to full-width. We have two methods of achieving this.} + +%------------------------------------------- +\subsection{Manual Method --- Using Table Column Width} +\italk{One simple method is trial-and-error (manual) is to increase the tabular column separation width so that the table width fits the text width. The two commands \cmd{setlength\{}\cmd{tabcolsep\}} \vb{\{0.75in\}} (value of 0.75in obtained by trial-and-error) and \vbc{begin\{tabular\}\{ l |c| r \}} (rest of the code remains the same as in \cref{tab22}) created the table below (\cref{tab23}). It is possible to calculate the \vb{tabcolsep} based on the width of text elements and the number of gaps (2 * number of columns) with the use of \cmd{settowidth\{\ldots\}} and \cmd{fpeval\{\ldots\}} commands. Note the use of | was used for visualization.} + +\begin{table}[h!] +\centering +\caption{Professional looking full-width table using \cmd{tabcolsep} and \texttt{booktabs} package.} +\setlength{\tabcolsep}{0.75in} +\begin{tabular}{ l |c| r } +\toprule +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\midrule +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\bottomrule +\end{tabular} +\label{tab23} +\end{table} + +\italk{It can be seen that the table column separation (\vb{tabcolsep}) value of 0.75in was applied on both sides of the text in each column. The vertical spaces at the start (left) and end (right) are not working well with the \vb{l} and \vb{r} specifications for the 1st and 3rd columns set in the \vb{tabular} environment. Had all columns been centered then this would have worked.} + +\italk{To address and suppress these spaces, the control sequence \vb{@\{\ldots\}} can be used. When the spaces were removed, the table width will reduce and should be increased (1.1in used) accordingly. Thus, with the following code, the table (\cref{tab24}) was created where columns align per our expectation. +} + +{\singlespacing +\begin{verbatim} +\setlength{\tabcolsep}{1.1in} +\begin{tabular}{ @{ }l |c| r@{ } } +\end{verbatim} +} + +\begin{table}[h!] +\centering +\caption{Professional looking full-width table using \cmd{tabcolsep}, \texttt{@\{\ldots\}}, and \texttt{booktabs} package.} +\setlength{\tabcolsep}{1.1in} +\begin{tabular}{ @{ }l |c| r@{ } } +\toprule +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\midrule +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\bottomrule +\end{tabular} +\label{tab24} +\end{table} + +\italk{This table (\cref{tab24}), of course without the vertical lines (|), can be used in NDSU disquisition. The issue of such vertical space management will be prevalent only with fewer columns.} + +%------------------------------------------- +\subsection{Automatic Method --- Using \texttt{tabu} Environment --- Equal Widths} +\italk{The automatic method using the \vb{tabu} environment replacing the \vb{tabular} makes it simple and avoids the guess work in fixing the table width. The following code (rest of the code is same as Table~2.2, page: \pageref{tabcode22}) that reproduces the \cref{tab24} and the generated output (\cref{tab25}) are:} + +{\singlespacing +\begin{verbatim} +. . . . +\begin{tabu}{X | X[c] | X[r]} % tabular replaced by tabu +. . . . +\end{tabu} % tabular replaced by tabu +. . . . +\end{verbatim} +} + +\begin{table}[h!] +\centering +\caption{Professional looking automatic full-width table using \texttt{tabu} environment and \texttt{booktabs} package.} +\begin{tabu}{X | X[c] | X[r]} +\toprule +Number & Our rating & Month \\ +(left) & (center) & (right)\\ +\midrule +1 & Colder & January \\ +2 & Okay & February \\ +3 & Good & March\\ +\bottomrule +\end{tabu} +\label{tab25} +\end{table} + +\italk{From the code it can be seen that the full-width table can be easily made using the \vb{tabu} environment. The \vb{X} column specifier allots column widths automatically so that the table spans the full-width. The other parameter enclosed by square brackets extends the functionality of the \vb{X} column. Thus, \vb{X[c]} and \vb{X[r]} specifies centering and right-justification of the column content, while left-justification is default.} + +%------------------------------------------- +\subsection{Automatic Method --- Using \texttt{tabu} Environment --- Unequal Widths} + +\italk{Shown below is an advanced table (\cref{tab26}) with variable column widths and overall math-column specification. Variable widths can be specified using coefficients to \vb{X} columns. +} +\vspace{-4ex} +\begin{table}[ht] +\caption{Full-width table using the \texttt{tabu} environment showing some vegetative indices formulas demonstrating the use of \texttt{X} column code with variable column widths and math column specifications (\texttt{X[0.8, \$]}).} +\setlength{\tabulinesep}{0.85ex} % constant vertical spacing between rows +\begin{tabu}{X[2] X[0.8, $]} +\toprule +Segmentation method & \text{Formula} \\ +\midrule +Excess green segmentation (ExG) & 2G - R - B\\ +Visible atmospherically resistant index (VARI) & \dfrac{{G - R}}{(G + R - B)} \\ +Red green ratio index (RGRI) & \dfrac{R}{G}\\ +Excess red index (ExR) & 1.3R - G \\ +Excess green minus excess red (ExGR) & \text{ExG} - \text{ExR}\\ +Normalized green - red difference index (NGRDI) & \dfrac{(G - R)}{(G + R)}\\ +Vegetative index (VI) & \dfrac{G}{R^a B^{(1-a)}}\\ +Modified excess green index (MExG) & 1.262G - 0.884R - 0.311B\\ +Green chromatic coordinate (GCC) & \dfrac{G}{(R + G + B)}\\ +Color index vegetation extraction (CIVE) & 0.441R - 0.811G + 0.385B\\ +Simple text in math column right (See $\Rightarrow$) & \text{NDSU thesis class}\\ +\bottomrule +\end{tabu} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: $R$, $G$, $B$ stands for red, green, blue pixel values from the RGB color image. +\label{tab26} +\end{tablenotes} +\end{table} +%------------------ + +\italk{The code that created this \vb{tabu} environment is given below. For full code the users are encouraged to refer the source \vb{*.tex} file of this document.} + +\vspace{-1ex} +{\singlespacing +\begin{verbatim} +. . . . +\setlength{\tabulinesep}{0.85ex} % constant vertical spacing between rows +\begin{tabu}{X[2] X[0.8, $]} +. . . . +\end{verbatim} +} + +\vspace{-2ex} +\italk{The environment specifies 2 columns with the first having a proportional 2 as width (\vb{coef}) and the second having 0.8 as width. Stated otherwise, the first column is \fpeval{2/0.8} (2/0.8) times the width of the second (2~:~0.8 = 2.5~:~1). The second column type was also specified using \$, which makes the entire column as math and the column code can be input without enclosing items between \$\ldots\$, as usually done in math mode. This math column specification will be convenient when the column predominantly contains math entries. Of course regular entries can be input as \cmd{text\{\ldots\}}, as done in the last row of the \cref{tab26}. +} + +\italk{Of course the manual method can also produce the \cref{tab26} and the output is presented in \cref{tab27}. While the full code can be seen in the source code the important code segments and two rows entries are shown as follows: +} + +{\singlespacing +\begin{verbatim} +. . . . +\setlength{\tabcolsep}{7ex} +\begin{tabular}{@{\:}l l@{\:}} +. . . . +Visible atmospherically resistant index (VARI) & $\dfrac{{G - R}} +{(G + R - B)}$ \\[2ex] +Red green ratio index (RGRI) & $\dfrac{R}{G}$\\[2ex] +. . . . +\end{verbatim} +} + +\vspace{-2ex} +\italk{In the code \vb{tabcolsep} command was used (\cref{tab27}). The formula column uses the math mode \$\ldots\$ for all the rows. Also, for increasing the row vertical spacing because of the a/b format of the formula the code of \textbackslash\textbackslash[2ex] was used.} + +\begin{table}[ht] +\caption{Full-width table using the manual method showing some vegetative indices formulas --- Reproduction of \cref{tab26}.} +\setlength{\tabcolsep}{7ex} +\begin{tabular}{@{\:}l l@{\:}} +\toprule +Segmentation method & Formula \\ +\midrule +Excess green segmentation (ExG) & $2G - R - B$\\[1ex] +Visible atmospherically resistant index (VARI) & $\dfrac{{G - R}} +{(G + R - B)}$ \\[2ex] +Red green ratio index (RGRI) & $\dfrac{R}{G}$\\[2ex] +Excess red index (ExR) & $1.3R - G$\\[2ex] +Excess green minus excess red (ExGR) & \text ExG $-$ ExR\\[2ex] +Normalized green - red difference index (NGRDI) & $\dfrac{(G - R)}{(G + R)}$\\[2ex] +Vegetative index (VI) & $\dfrac{G}{R^a B^{(1-a)}}$\\[3ex] +Modified excess green index (MExG) & $ 1.262G - 0.884R - 0.311B$\\[2ex] +Green chromatic coordinate (GCC) & $\dfrac{G}{(R + G + B)}$\\[2ex] +Color index vegetation extraction (CIVE) & $0.441R - 0.811G + 0.385B$\\[2ex] +Simple text in regular column right (See $\Rightarrow$) & NDSU thesis class\\ +\bottomrule +\end{tabular} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: $R$, $G$, $B$ stands for red, green, blue pixel values from the RGB color image. +\label{tab27} +\end{tablenotes} +\end{table} +%------------------ + +\italk{When compared, the automatic method (\cref{tab26}) is simpler than the manual method (\cref{tab27}); however, both produce similar output visually.} + +%------------------------------------------- +\subsection{Another Example with Multicolumn and Cmidrule} +\italk{Usage of \vb{multicolumn} and \vb{cmidrule} in full-width tables using manual and automatic are presented (\cref{tab28,tab29}) in this example.} + +\begin{table}[ht] +\centering +\caption{Manual method full-length table showing multicolumn and rule.} +\setlength{\tabcolsep}{0.675in} +\begin{tabular}{|@{\:}l |c|l| l@{\:}|} +\toprule +Number & Month & Same & Same\\ +\midrule +1 & January & January & January\\ +1 & January & January & January\\ +\cmidrule(lr){3-4} +2 & February & \multicolumn{2}{c}{\hspace{5ex}Combined February}\\ +\cmidrule(lr){3-4} +3 & March & March & March \\ +3 & March & March & March \\ +\bottomrule +\end{tabular} +\label{tab28} +\end{table} + +\begin{table}[ht] +\centering +\caption{Automatic method full-length table showing multicolumn and rule.} +\begin{tabu}{| X[0.25] | X[0.95,c] | X[0.6] | X[0.2, l] |} +\toprule +Number & Month & Same & Same\\ +\midrule +1 & January & January & January\\ +1 & January & January & January\\ +\cmidrule(lr){3-4} +2 & February & \multicolumn{2}{c}{Combined February}\\ +\cmidrule(lr){3-4} +3 & March & March & March\\ +3 & March & March & March\\ +\bottomrule +\end{tabu} +\label{tab29} +\end{table} + +\italk{Both tables are visually the same barring the different column widths visualized using |, but their mechanisms are different. Only the significant code lines that produced these tables are given below. Based on the requirements, the users can use any of these methodologies. } + +{\singlespacing +\begin{verbatim} +. . . . %Table 2.8 +\setlength{\tabcolsep}{0.675in} +\begin{tabular}{|@{\:}l |c|l| l@{\:}|} . . . . +\cmidrule(lr){3-4} +2 & February & \multicolumn{2}{c}{\hspace{5ex}Combined February}\\ +\cmidrule(lr){3-4} + +. . . . %Table 2.9 +\begin{tabu}{| X[0.25] | X[0.95,c] | X[0.6] | X[0.2, l] |} +\cmidrule(lr){3-4} +2 & February & \multicolumn{2}{c}{Combined February}\\ +\cmidrule(lr){3-4} +\end{verbatim} +} + +%----------------------------------------------------------------------------- +\section{Landscape Tables} + +\italk{When more columns need to be accommodated in tables that cannot be handled in the regular orientation, with available text width of about \SI{6.5}{in}, the landscape that can utilize the text height of \SI{8.75}{in} for the table contents. If even more columns have to be packed then the use of \cmd{resizebox} command can scale-down the table to the required size, and this can be used in regular and landscape modes.} + +\italk{Landscape tables were usually set on a separate page using \vb{[p]} placement specifier. With the \vb{pdflscape} package that provides the \vb{landscape} environment for the table creation, the page is also rotated for direct viewing of the table, but prints correctly. An example of landscape table is shown in \Cref{tab210}. More information about this table is available in the table caption and footnote. The source code of this table can be referred to for details. +} + +% Use [p] use to adjust the centering of the whole table +% * version of vspace works - but manually adjusted: \vspace*{1.3in} +\begin{landscape} +\begin{table}[p] +\centering +\caption{Landscape table uses \vb{landscape} environment from \vb{pdflscape} package (loaded in the class). Landscape tables are set in a separate page using \vb{[p]} and usually don't have surrounding text, which makes sense. With the \vb{p} specifier the table is also centered vertically, otherwise with \vb{h} and \vb{t} will start from the top, and \vbc{vspace*} command need to be used to bring it down. The \vbc{columnwidth} in the landscape mode is = \fpeval{round(\columnwidth*0.013837, 8)}~in. +Note this table was resized using \vbc{resizebox} command --- Check the source code for details.} +\resizebox{\columnwidth}{!}{% +\begin{tabular}{l rrrr cccc llll rr} +\toprule +Row-of-values & \multicolumn{4}{c}{Block1} &\multicolumn{4}{c}{Block2} & \multicolumn{4}{c}{Block3} & Value A & Value B \\ +\cmidrule(lr){2-5} \cmidrule(lr){6-9} \cmidrule(lr){10-13} + & Value A & Value B & Value C & Value D & Value A & Value B & Value C & Value D & Value A & Value B & Value C & Value D \\ +\midrule +1 & 0.6010 & 0.9534 & 0.0230 & 0.2792 & 0.6536 & 0.6743 & 0.6670 & 0.7151 & 0.9233 & 0.0136 & 0.7240 & 0.7884 & 0.6380 & 0.4722 \\ +2 & 0.0879 & 0.5224 & 0.5080 & 0.8831 & 0.4167 & 0.9331 & 0.2338 & 0.4526 & 0.6214 & 0.1434 & 0.9304 & 0.5150 & 0.3284 & 0.2733 \\ +3 & 0.5354 & 0.5622 & 0.9666 & 0.3658 & 0.2022 & 0.7481 & 0.0094 & 0.3730 & 0.6100 & 0.4873 & 0.3478 & 0.3655 & 0.2236 & 0.3613 \\ +\cmidrule(lr){2-9} +4 & 0.5149 & 0.7877 & 0.7046 & 0.7844 & 0.8712 & 0.1463 & 0.6431 & 0.0756 & 0.2670 & 0.2400 & 0.8599 & 0.5413 & 0.3102 & 0.3564 \\ +5 & 0.2776 & 0.8775 & 0.0204 & 0.3931 & 0.1757 & 0.7755 & 0.7601 & 0.6077 & 0.1814 & 0.1600 & 0.3897 & 0.9181 & 0.5436 & 0.7620 \\ +\midrule +6 & 0.4873 & 0.1049 & 0.7446 & 0.3470 & 0.1444 & 0.0765 & 0.6868 & 0.7974 & 0.6107 & 0.4752 & 0.3983 & 0.3813 & 0.4250 & 0.7448 \\ +7 & 0.4924 & 0.2721 & 0.6291 & 0.4191 & 0.9174 & 0.2786 & 0.3453 & 0.6789 & 0.2796 & 0.2995 & 0.0936 & 0.5531 & 0.6751 & 0.8136 \\ +8 & 0.1246 & 0.5249 & 0.9767 & 0.1850 & 0.0554 & 0.7529 & 0.8975 & 0.6367 & 0.1115 & 0.1917 & 0.7160 & 0.8446 & 0.4325 & 0.0693 \\ +\cmidrule(lr){10-15} +9 & 0.8376 & 0.3821 & 0.4961 & 0.6293 & 0.5149 & 0.4190 & 0.6207 & 0.2706 & 0.6919 & 0.7676 & 0.0739 & 0.8534 & 0.1713 & 0.8018 \\ +10 & 0.2861 & 0.3240 & 0.9193 & 0.6021 & 0.2301 & 0.9783 & 0.1213 & 0.5350 & 0.4845 & 0.5200 & 0.0642 & 0.2804 & 0.7556 & 0.0147 \\ +\bottomrule +\end{tabular} +} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: \italk{The \cmd{cmidrule(lr)\{2-9\}} and \cmd{cmidrule(lr)\{10-15\}} commands issued after 3rd and 7th rows produced the horizontal lines separating the rows 3 and 4, and 8 and 9, respectively. This command can be used to mark grouped columns as well. The grouped (merged) column headings (Block1, Block2, and Block3) were created, for example, by \cmd{multicolumn\{4\}\{c\}\{Block1\}} command. Check the code how other groups and lines were made. +\item \vspace{4ex} +\italk{\hl{Important note:}} \textcolor{magenta}{\bfseries While printing the landscape pages (containing tables and figures) the settings should be double-checked. Adobe reader was known to print the landscape pages in the correct format. Mac Preview was observed not to give the correct output (distortion observed) at the time of this writing.} +} +\end{tablenotes} +\label{tab210} +\end{table} +\end{landscape} + +%----------------------------------------------------------------------------- +\section{Long Tables} +\italk{In the disquisition sometimes it is necessary to present data and results that go more than a single page. In such situations, long tables should be used and the package developed for this purpose and included in the class was +\vb{longtable} and it works well with \vb{threeparttable} package as well. The \vb{longtable} environment is used.} + +\italk{The long tables have more components than regular tables. Long tables contain, in general, main title, running title, running table head, running footnote, and table final footnote. Users are urged to refer to the documentation of \vb{longtable} and the source code for more details, as there are several aspects involved in long table creation.} + +%----------------------- +\vspace{2ex} +\setlength\LTleft{0pt} +\setlength\LTright{0pt} +{\small +{\renewcommand{\arraystretch}{0.6} +\begin{ThreePartTable} + \begin{TableNotes} + \baselineskip=0.5\baselineskip + \item[] $\dag$ MD - Methods distance i.e. total polygonal distance of all methods taken in the selected order + \item[] $\ddag$ TSP - Traveling salesperson distance i.e. total polygonal distance of all methods following traveling sales man technique; Origin was the outlet location where bales were finally transported; and medoid was the aggregation method where it coincided on one of the field stacks but other methods may not. + \end{TableNotes} + \begin{longtable}{lll lll ll} + \caption{\normalsize A long table - spanning 3 pages - an example taken from our research group work on ``Methods of optimum bale stack locations and their logistics distances and methods combined distances.''}\label{tab1}\\[-2ex] + \tabletopinfo + \endfirsthead + + \multicolumn{8}{l}% +{{\normalsize\tablename\ \thetable{} Methods of optimum bale stack locations and their logistics distances and}} \\ + \multicolumn{8}{l}% +{{\normalsize methods combined distances -- \emph{(continued).}}} \\[2ex] + \tabletopinfo + \endhead + + \cmidrule{7-8} + \multicolumn{8}{r}{\textit{continued \ldots}} + \endfoot + \bottomrule + \insertTableNotes + \endlastfoot + +% the contents of the table +0.41 & 3 & Origin & 0.196 & 0 & 0.196 & 0.070 & 0.045 \\ +$[1]$ & & Field middle & 0.085 & 0.045 & 0.130 \\ + & & Middle data range & 0.070 & 0.061 & 0.131 \\ + & & Centroid & 0.068 & 0.062 & 0.130 \\ + & & Geometric median & 0.065 & 0.064 & 0.129 \\ + & & Medoid & 0.068 & 0.075 & 0.143 \\ +\midrule +0.51 & 4 & Origin & 0.240 & 0 & 0.240 & 0.054 & 0.048 \\ +$[1.25]$ & & Field middle & 0.107 & 0.050 & 0.158 \\ + & & Middle data range & 0.108 & 0.052 & 0.160 \\ + & & Centroid & 0.102 & 0.057 & 0.159 \\ + & & Geometric median & 0.099 & 0.067 & 0.166 \\ + & & Medoid & 0.101 & 0.072 & 0.172 \\ +\midrule +1.01 & 8 & Origin & 0.462 & 0 & 0.462 & 0.095 & 0.051 \\ +$[2.5]$ & & Field middle & 0.404 & 0.142 & 0.546 \\ + & & Middle data range & 0.205 & 0.109 & 0.315 \\ + & & Centroid & 0.206 & 0.114 & 0.320 \\ + & & Geometric median & 0.205 & 0.109 & 0.314 \\ + & & Medoid & 0.206 & 0.103 & 0.308 \\ +\midrule +2.02 & 18 & Origin & 1.80 & 0 & 1.80 & 0.054 & 0.034 \\ +$[5]$ & & Field middle & 0.87 & 0.30 & 1.17 \\ + & & Middle data range & 0.87 & 0.30 & 1.17 \\ + & & Centroid & 0.86 & 0.31 & 1.17 \\ + & & Geometric median & 0.86 & 0.31 & 1.18 \\ + & & Medoid & 0.89 & 0.35 & 1.24 \\ +\midrule +4.05 & 33 & Origin & 5.26 & 0 & 5.26 & 0.144 & 0.100 \\ +$[10]$ & & Field middle & 3.11 & 0.85 & 3.96 \\ + & & Middle data range & 3.11 & 0.86 & 3.97 \\ + & & Centroid & 3.11 & 0.86 & 3.97 \\ + & & Geometric median & 3.11 & 0.88 & 3.99 \\ + & & Medoid & 3.45 & 1.09 & 4.53 \\ +\midrule +8.09 & 67 & Origin & 14.63 & 0 & 14.63 & 0.024 & 0.021 \\ +$[20]$ & & Field middle & 7.29 & 2.41 & 9.71 \\ + & & Middle data range & 7.29 & 2.43 & 9.72 \\ + & & Centroid & 7.29 & 2.43 & 9.72 \\ + & & Geometric median & 7.28 & 2.45 & 9.73 \\ + & & Medoid & 7.29 & 2.41 & 9.70 \\ +\midrule +16.19 & 133 & Origin & 40.67 & 0 & 40.67 & 0.074 & 0.072 \\ +$[40]$ & & Field middle & 20.28 & 6.54 & 26.82 \\ + & & Middle data range & 20.29 & 6.61 & 26.89 \\ + & & Centroid & 20.28 & 6.51 & 26.79 \\ + & & Geometric median & 20.28 & 6.58 & 26.86 \\ + & & Medoid & 20.52 & 6.88 & 27.39 \\ +\midrule +32.38 & 270 & Origin & 117.89 & 0 & 117.89 & 0.060 & 0.052 \\ +$[80]$ & & Field middle & 58.92 & 18.11 & 77.03 \\ + & & Middle data range & 58.92 & 18.22 & 77.14 \\ + & & Centroid & 58.92 & 18.16 & 77.08 \\ + & & Geometric median & 58.92 & 18.19 & 77.11 \\ + & & Medoid & 59.18 & 18.11 & 77.29 \\ +\midrule +64.75 & 540 & Origin & 333.12 & 0 & 333.12 & 0.049 & 0.043 \\ +$[160]$ & & Field middle & 166.52 & 51.21 & 217.73 \\ + & & Middle data range & 166.53 & 51.41 & 217.93 \\ + & & Centroid & 166.52 & 51.26 & 217.78 \\ + & & Geometric median & 166.52 & 51.30 & 217.82 \\ + & & Medoid & 166.81 & 51.23 & 218.05 \\ +\midrule +129.5 & 1082 & Origin & 943.38 & 0 & 943.38 & 0.051 & 0.029 \\ +$[320]$ & & Field middle & 470.83 & 145.65 & 616.48 \\ + & & Middle data range & 470.83 & 145.79 & 616.62 \\ + & & Centroid & 470.83 & 145.91 & 616.74 \\ + & & Geometric median & 470.83 & 145.83 & 616.66 \\ + & & Medoid & 471.26 & 148.53 & 619.79 \\ +\midrule +259 & 2163 & Origin & 2665.34 & 0 & 2665.34 & 0.028 & 0.027 \\ +$[640]$ & & Field middle & 1331.20 & 410.81 & 1742.01 \\ + & & Middle data range & 1331.21 & 411.45 & 1742.66 \\ + & & Centroid & 1331.19 & 411.07 & 1742.27 \\ + & & Geometric median & 1331.19 & 411.25 & 1742.44 \\ + & & Medoid & 1331.32 & 407.51 & 1738.83 \\ +\midrule +517 & 4324 & Origin & 7531.35 & 0 & 7531.35 & 0.022 & 0.020 \\ +$[1280]$ & & Field middle & 3765.75 & 1160.34 & 4926.09 \\ + & & Middle data range & 3765.77 & 1160.95 & 4926.72 \\ + & & Centroid & 3765.75 & 1160.51 & 4926.26 \\ + & & Geometric median & 3765.75 & 1160.39 & 4926.15 \\ + & & Medoid & 3765.86 & 1159.71 & 4925.57 \\ + \end{longtable} +\end{ThreePartTable} +} +} +\setlength{\parindent}{0.5in} +\vspace{-2ex} +%----------------------- + +\kant[3] + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Figures in thesis/dissertation} + +%----------------------------------------------------------------------------- +\section{Figures in the Chapters} +\italk{As before the class documentation should be read first (Sec. 9.2). Let us have some figures. Refer to our first figure (\cref{fig1}) and second (\cref{fig2}). This figure file (``\texttt{frog.jpg}'') is also included in the class folder, and if necessary can be replaced by any other dummy figures from the \texttt{mwe} package (Documentation Sec. 7). The following figure was coded using the regular figure environment and other commands.} + +\begin{figure}[H] +\centering +\includegraphics[width=0.4\textwidth]{frog.jpg} +\caption{\label{fig:frog}This frog figure short caption is centered - NDSU.} +\label{fig1} +\end{figure} + +%----------------------------------------------------------------------------- +\section{Shortcut Commands for Figures in Class} + +%------------------------------------------- +\subsection{Figure Shortcut Command --- 5 Arguments} +\italk{The same image using the \texttt{myfig} command (which is a shortcut defined to easily input the [caption alignment], figure placement, size, figure, caption, and label in one command). The following code shows how this is used and the figure displayed:} + +{\singlespacing +\begin{verbatim} +\myfig{H}{0.4}{frog.jpg}{Figure short caption is centered. +Use of myfig command.}{fig2} +\end{verbatim} +} + +\myfig{H}{0.4}{frog.jpg}{Figure short caption is centered. +Use of \cmd{myfig\{\}} command.}{fig2} + +\italk{When required, by issuing the command \cmd{captionsetup\{singlelinecheck=true\}} before the figure or inside the figure environment will center the shorter caption (as did with \cref{fig1}), and left-justify the longer captions. This was the default behavior of the class and reset by making the \texttt{singlelinecheck=false}, where the caption will be always left-justified, irrespective of the length.} + +%------------------------------------------- +\subsection{Figure Shortcut Command --- 1 Optional + 5 Arguments} + +\myfig{H}{0.4}{frog.jpg}{Figure with a long caption where it is left-justified. More text text text text text text text text used to make the title long.}{fig3} + +\italk{\Cref{fig3} with long title makes the caption left-justified automatically. It can be seen that the caption is too close to the bottom of the image, which may be good in some cases where already some white space/margin was present in the original figure. To address this the optional vertical caption placement should be used. In \Cref{fig4} the caption was given a +ve vertical space [2ex] to move the caption down, and can be moved up using -ve values. The code which developed this figure (\cref{fig4}) with the optional argument is shown below. +} + +{\singlespacing +\begin{verbatim} +\myfig[2ex]{H}{0.4}{frog.jpg}{Figure with long caption where it is +left-justified. More text text text text text text text text used to +make the title long. Also the 6th optional caption placement +was used in the \cmd{myfig[optional]\{\}} command.}{fig4} +\end{verbatim} +} + +\myfig[2ex]{H}{0.4}{frog.jpg}{Caption this frog was uploaded via the file-tree menu - a long title long title long title long title long title long title long title long title long title long title.}{fig4} + +%----------------------------------------------------------------------------- +\section{Landscape Figures} + +\italk{Landscape figures can be handled using the \cmd{myfigls\{\}} command (which is a shortcut for landscape figure similar to regular figures (1+5 arguments)). Usually, placement specifier `p' is used to vertically center the figure and caption. The following code that produced \Cref{fig5} shows how this is used:} + +\vspace{-4ex} +{\singlespace +\begin{verbatim} +\myfigls[5mm]{p}{0.6}{frog.jpg}{Landscape figure with long long long long long +long long long long long long long long long long caption and vertical caption +placement using 5mm.}{fig5} +\end{verbatim} +} + +\italk{\hl{Important note:}} \textcolor{magenta}{\bfseries While printing the landscape pages (containing tables and figures) the settings should be double-checked. Adobe reader was known to print the landscape pages in the correct format. Mac Preview was observed not to give the correct output (distortion observed) at the time of this writing.} + +% Option p vertically centers figure & 5mm +ve space added above caption +\myfigls[5mm]{p}{0.9}{frog.jpg}{Landscape figure with long long long long long long long long long long long long long long long caption and vertical caption placement using 5mm.}{fig5} + +%----------------------------------------------------------------------------- +\section{Subfigures with Automated Numbering} + \italk{This multiple subfigures uses \texttt{subfig} package. The main figure caption can be referenced as \Cref{fig6} and in parenthesis (\cref{fig6}). Also, the subfigures can be referenced (\cref{fig6:1a,fig6:1c,fig6:1d,fig6:1f}). The sub-caption numbering are ``alphabetic'' by default and will be automatically generated. Sizes of the sub-figures can be individually altered. Also, the number of images that occupy a single row can be readily coded with commands (refer source code), such as \cmd{subfloat\{\ldots\}}, \cmd{hspace\{\ldots\}}, and newline (\textbackslash\textbackslash).} + +\begin{figure}[H] +\captionsetup{singlelinecheck=true} % can be given in figure env. +\centering +\subfloat[frog1.\label{fig6:1a}]{\includegraphics[width=0.1\textwidth]{frog.jpg}}\hspace{1in} +\subfloat[frog2.\label{fig6:1b}] {\includegraphics[width=0.1\textwidth]{frog.jpg}}\\ +\subfloat[frog3.\label{fig6:1c}]{\includegraphics[width=0.3\textwidth]{frog.jpg}}\hspace{0.5in}\\ + +\subfloat[frog4\label{fig6:1d}]{\includegraphics[width=0.145\textwidth]{frog.jpg}}\hspace{1.2in} +\subfloat[Frog caption.\label{fig6:1e}]{\includegraphics[width=0.2\textwidth]{frog.jpg}} +\hspace{1.2in} +\subfloat[frog6.\label{fig6:1f}] {\includegraphics[width=0.145\textwidth]{frog.jpg}} + +\captionsetup{singlelinecheck=false} % can be given again +\caption{General caption of the subfigure - all the captions and sub-labels were created through \cmd{subfloat[\ldots]\{\ldots\}} command of \texttt{subfig} package.} \label{fig6} +\end{figure} +\clearpage + +%----------------------------------------------------------------------------- +\section{Subfigures Spanning Multiple Pages} +\italk{Sometimes several subfigures running through multiple pages need to be coded. These are similar to long tables that span several pages. The caption will be repeated with ``contd\ldots'' note. The \cmd{ContinuedFloat} with another \texttt{figure} environment will carry the numbering forward. When the number of subfigures exceeds the number of alphabets (26), the numbering system should be switched to numeric, using the commands (preferably inside the figure environment; refer source code): } + +\begin{verbatim} +\renewcommand*{\thesubfigure}{\arabic{subfigure}} % numeric +\renewcommand*{\thesubfigure}{\thefigure.\arabic{subfigure}} % with fig.number +\end{verbatim} + +\begin{figure}[H] +\captionsetup{singlelinecheck=true} % can be given in figure env. +\renewcommand*{\thesubfigure}{\arabic{subfigure}} % numeric +\centering +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\captionsetup{singlelinecheck=false} % can be given again +\caption{Multiple page sub-figures --- General caption of the subfigure - all the captions and sub-labels were created through \cmd{subfloat[\ldots]\{\ldots\}} command of \texttt{subfig} package.} \label{fig:1gen} +\end{figure} +\clearpage + +\begin{figure}[p]\ContinuedFloat +\captionsetup{singlelinecheck=true} % can be given in figure env. +\renewcommand*{\thesubfigure}{\thefigure.\arabic{subfigure}} +\centering +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.15\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.2\textwidth]{frog.jpg}}\\ +\captionsetup{singlelinecheck=false} % can be given again +\caption[]{Multiple page sub-figures --- General caption of the subfigure - all the captions and sub-labels were created through \cmd{subfloat[\ldots]\{\ldots\}} command of \texttt{subfig} package (\emph{contd\ldots}). \textcolor{magenta}{Notice the figure number included in the numbering}.} +\end{figure} +\clearpage + +\begin{figure}[t]\ContinuedFloat +\captionsetup{singlelinecheck=true} % can be given in figure env. +\renewcommand*{\thesubfigure}{\arabic{subfigure}} % numeric +\centering +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.2\textwidth]{frog.jpg}}\\ +\subfloat[SubCap]{\includegraphics[width=0.2\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap]{\includegraphics[width=0.15\textwidth]{frog.jpg}}\hspace{0.5in} +\subfloat[SubCap] {\includegraphics[width=0.2\textwidth]{frog.jpg}}\\ +\captionsetup{singlelinecheck=false} % can be given again +\caption[]{Multiple page sub-figures --- General caption of the subfigure - all the captions and sub-labels were created through \cmd{subfloat[\ldots]\{\ldots\}} command of \texttt{subfig} package (\emph{contd\ldots}) \textcolor{magenta}{Notice figure number was dropped in the numbering}.} +\end{figure} + +\italk{The \cmd{clearpage} command, which typesets all unprocessed floats, is necessary after every block of \texttt{figure} environments (3 used in this \Cref{fig:1gen}). For suppressing the TOC entries of the subsequent captions (2 on this and before page), a null TOC entry such as \cmd{caption[]\{Multiple page \ldots \}} was issued.} + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Cross reference in disquisition} + +%----------------------------------------------------------------------------- +\section{Clever Way of Referencing Labels Using \texttt{cleveref} Package} +\italk{Referring items automatically is a common activity in \LaTeX. Although there are basic commands available to refer (e.g., \cmd{ref}), which produces only the ``number'' of the item referred and we have to supply the context type (table, figure, equation, section, page, etc.), the use of \texttt{cleveref} package is an efficient way to do achieve this task. Shown next is the ``quote'' from the author of \texttt{cleveref} that used \texttt{quote (environment), singlespacing, raggedleft} commands.} + +\vspace{-4ex} +\textcolor{magenta}{ +\begin{quote} +\singlespacing +\raggedleft +\textit{The cleveref package enhances \LaTeX's cross-referencing features, allowing the format of cross-references to be determined automatically according to the ``type'' of cross-reference (equation, section, etc.) and the context in which the cross-reference is used.} +\\\hfill --- Toby Cubitt (2018) +\end{quote} +} + +%----------------------------------------------------------------------------- +\section{Customizing Cleveref Commands} +\italk{Refer to this package for more details and customization. The way (title case or not, abbreviated or not) the cross-referenced labels (e.g., fig. \emph{vs} Fig., etc.) can be modified using these commands. +} + +\begin{verbatim} +\Crefname{equation}{Eq.}{Eqs.} +\Crefname{figure}{Fig.}{Figs.} +\Crefname{table}{Tab.}{Tabs.} +\crefname{equation}{Eq.}{Eqs.} +\crefname{figure}{Fig.}{Figs.} +\crefname{table}{Tab.}{Tabs.} +\end{verbatim} + +\italk{Now issuing the commands and calling again produces this (normal black text used). And notice the difference in both the results of \cmd{Cref} and \cmd{cref}. By the way, \texttt{hyperlink} package was also used and is active, and clicking on the generated labels will take the user to the item directly. } + +\Crefname{figure}{Fig.}{Figs.} +\Crefname{table}{Tab.}{Tabs.} +\crefname{figure}{Fig.}{Figs.} +\crefname{table}{Tab.}{Tabs.} + +{\singlespacing +\begin{verbatim} +First: Refer to our first figure (\cref{fig1}) and second (\cref{fig2}). +Data is presented in \Cref{tab1}; also, look at \Cref{fig1} again, after +redefining the commands using: +\end{verbatim} +} +First: :Refer to our first figure (\cref{fig1}) and second (\cref{fig2}). Data is presented in \Cref{tab1}; also, look at \Cref{fig1} again, after redefining the commands using: + +\begin{verbatim} +\Crefname{figure}{Figure}{Figures} +\Crefname{table}{Table}{Tables} +\crefname{figure}{fig.}{figs.} +\crefname{table}{tab.}{tabs.} +\end{verbatim} + +\Crefname{figure}{Figure}{Figures} +\Crefname{table}{Table}{Tables} +\crefname{figure}{fig.}{figs.} +\crefname{table}{tab.}{tabs.} + +\italk{Re-issuing the commands with defaults (e.g., fig., figs., Figure, Table, eq., eqs., etc.).} + + +{\singlespacing +\begin{verbatim} +Second: Refer to our first figure (\cref{fig1}) and second (\cref{fig2}). Data is +presented in \Cref{tab1}; also, look at \Cref{fig1} again. +\end{verbatim} +} +Second: Refer to our first figure (\cref{fig1}) and second (\cref{fig2}). Data is presented in \Cref{tab1}; also, look at \Cref{fig1} again. + +\italk{We have used \cmd{cref\{\ldots\}} commands already in the previous chapters. The \vb{cleveref} package documentation may be referred for other commands and options. The package allows for referring ranges, multiple items, page numbers, and many more customization. +} + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Bibliography Citation} + +%----------------------------------------------------------------------------- +\section{Citing References Through \texttt{natbib} Package} +\italk{For bibliography management in \LaTeX\ \texttt{natbib} package is used by several journals \citep{daly2010natural}. This package is very stable and widely used. The commands like \cmd{citep\{\ldots\}} citation in parenthesis and \cmd{citet\{\ldots\}} citation in running text are quite useful in particular. The compatible styles with \texttt{natbib} and NDSU class are: \texttt{plainnat, abbrvnat, unsrtnat, rusnat, agsm, chicago, apalike}, and more may be added. \url{https://ctan.mirrors.hoobly.com/macros/latex/contrib/natbib/natbib.pdf} Once correct citation commands are issued a.k.a ``cite while you write'' the REFERENCE section with all listings will be generated. More information of the package can be obtained from the Documentation: \textcolor{magenta}{\url{https://ctan.mirrors.hoobly.com/macros/latex/contrib/natbib/natbib.pdf}} and Reference Sheet: \!\!\textcolor{magenta}{\url{https://ctan.mirrors.hoobly.com/macros/latex/contrib/natbib/natnotes.pdf}} +\textcolor{magenta}{\url{https://www.overleaf.com/learn/latex/Learn_LaTeX_in_30_minutes?utm_source=overleaf&utm_medium=email&utm_campaign=onboarding}}} + + +\begin{quote} +\singlespacing +\raggedleft +\textit{The \texttt{natbib} package is a reimplementation of the \LaTeX\ \cmd{cite} command, to work with both author-year and numerical citations. The \texttt{natbib} package supports not only the various author-year bibliography styles, but also those for standard numerical citations. In fact, it can also produce numerical citations even with an author-year bibliographic style, something that permits easy switching between the two citation modes.} + +\hfill --- Patrick W. Daly (2010) +\end{quote} + +\italk{Now the cite commands are in action. The in-text citation will be generated automatically based on the number of authors and year, and the listing on the next page will be an unnumbered chapter with ``apalike'' reference styles shown (NDSU recommended list). The reference bib file is stored in the same folder and that will be the common database (which can grow by the addition of reference entries), but the use of different style files (*.bst) automatically generates the listing based on their style. Any other style files, for example, supplied by journals, can also be used, but should be present in the same folder and the natbib package used in this document (line: 7) may be commented.} + +\italk{\citet{calvo2004using} found something, while \citet{bari2016identification} illustrated something more. } + +\italk{All these authors \citep{calvo2004using,cannayen2011latex,bari2016identification,sharma2012ndsu,baczkowski1990ndsu} carried out some research.} + +%----------------------------------------------------------------------------- +\section{Author-year and Numbered Citations of \texttt{natbib}} +\italk{Loading the \texttt{natbib} package with appropriate options in the preamble create the author-year or numbered citations. This was not coded into the class to allow for loading other referencing systems (e.g., \texttt{biblatex}) as desired.} + +{\singlespacing +\begin{verbatim} +\usepackage[round,sort&compress,authoryear]{natbib} % for author-year +(or) +\usepackage[numbers,sort&compress]{natbib} % for numbered citations +(or) +\usepackage[sort&compress]{natbib} +\citestyle{plain} +\end{verbatim} +} + +\italk{Or, the predefined citation styles (most accepted styles with right options), with basic loading of natbib (see above listing), are contained within the natbib code for the following bibliography styles can be used \citep{daly2010natural}. Obviously, appropriate combination will produce the desired results.\\} + +\vspace{-6ex} +\textcolor{magenta}{ +\begin{enumerate} +\item \texttt{plain} (the 4 base styles): square braces, numerical, commas plainnat etc.: \hl{square braces, author-year, commas}; +\item \texttt{agu} (American Geophysical Union): \hl{square, author-year, semi-colon}; +\item \texttt{egu} (European Geosciences Union): \hl{round, author-year, semi-colon}; +\item \texttt{agms, dcu, kluwer} (Harvard set): \hl{round, author-year}; +\item \texttt{cospar} (Committe on Space Research): \hl{slashes, numerical, comma}; +\item \texttt{nature} (Journal Nature): \hl{superscripts}. +\end{enumerate} +} + +\italk{ +The options available provide another means of specifying the punctuation +for citations to be used while loading the \texttt{natbib} package as \textcolor{magenta}{\cmd{usepackage}[\emph{options}]\texttt{\{natbib\}}} are: \textbullet\:round, \textbullet\:square, \textbullet\:curly, \textbullet\:angle, \textbullet\:semicolon, \textbullet\:authoryear, \textbullet\:numbers, \textbullet\:super, \textbullet\:sectionbib, \textbullet\:sort\&compress, \textbullet\:compress, \textbullet\:nonamebreak, \textbullet\:merge, \textbullet\:elide, and \textbullet\:mcite. Refer the package documentation \citep{daly2010natural}. +} + +%----------------------------------------------------------------------------- +\section{Using Bib\LaTeX\ for Citation} +\italk{Using Bib\LaTeX\ for citation will be similar to citation using BibTeX, especially when \vb{natbib} is used. As given in the class documentation the Bib\LaTeX\ will be setup using the following command: +} + +\vspace{2ex} +{\singlespacing +\begin{verbatim} +\usepackage[style=apa,natbib=true,backend=biber]{biblatex} +\end{verbatim} +} + +\italk{The compatible styles that can be used as option while loading Bib\LaTeX\/ are: \textbullet\:numeric, \textbullet\:numeric-comp, \textbullet\:alphabetic, \textbullet\:authoryear, \textbullet\:authoryear-icomp, \textbullet\:authortitle, \textbullet\:verbose, \textbullet\:reading, \textbullet\:draft, \textbullet\:apa, \textbullet\:chem-acs, \textbullet\:chem-angew, \textbullet\:chem-biochem, \textbullet\:chem-rsc, \textbullet\:ieee, \textbullet\:mla, \textbullet\:musuos, \textbullet\:nuture, \textbullet\:nejm, \textbullet\:phys, \textbullet\:science, and \textbullet\:oscola.} + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Other aspects in disquisition - Paper-styled Chapter} + +%----------------------------------------------------------------------------- +\section{SI units in thesis/disseration} +\italk{This is a section of my thesis. SI units are available, which provides correct spacing between the number and the uint. For example, \SI{120800600}{\m\squared} gives the thousands separator and correct spacing between the number and units. The command used to produce was \textbackslash\texttt{SI\{120800600\}\{\textbackslash m\textbackslash squared\}}. Also, refer to \texttt{siunitx} package documentation for several other commands and features.} + +%----------------------------------------------------------------------------- +\section{Handling Equations} +\italk{The \texttt{abovedisplayskip} through \texttt{setlength} to reduce the spacing above the equations. These equations can be referred using \texttt{cref} commands (\cref{eq1,eq2,eq3,eq4,eq5,eq6,eq7,eq8}). The code shows how the first 5 equations were produced:} + +\vspace{3ex} +{\onehalfspacing +\begin{verbatim} +\setlength{\abovedisplayskip}{-12pt} % required to adjust gap +\begin{align} +&\text{Convex area} = \frac{\text{Area}}{\text{Solidity}} \label{eq1} \\[1ex] +&\text{Hollowness} = \frac{\text{Convex area - Area}}{\text{Convex area}} +\label{eq2} \\[1ex] +&\text{Reverse aspect ratio (RAR)} = \frac{\text{1}}{\text{Aspect ratio}} +\label{eq3} \\[1ex] +&\text{Rectangularity} = \frac{\text{Area}}{\text{Bounding rectangle area}} +\label{eq4} \\[1ex] +&\text{Feret major axis ratio (FMA)} = \frac{\text{Feret diameter}} +{\text{Major axis}} \label{eq5} +\end{align} +\end{verbatim} +} + +\setlength{\abovedisplayskip}{-12pt} % required to adjust gap +\begin{align} +&\text{Convex area} = \frac{\text{Area}}{\text{Solidity}} \label{eq1} \\[1ex] +&\text{Hollowness} = \frac{\text{Convex area - Area}}{\text{Convex area}} \label{eq2} \\[1ex] +&\text{Reverse aspect ratio (RAR)} = \frac{\text{1}}{\text{Aspect ratio}} \label{eq3} \\[1ex] +&\text{Rectangularity} = \frac{\text{Area}}{\text{Bounding rectangle area}} \label{eq4} \\[1ex] +&\text{Feret major axis ratio (FMA)} = \frac{\text{Feret diameter}}{\text{Major axis}} \label{eq5} \\[1ex] +&\text{Convex area Feret ratio (CAF)} = \frac{\text{Convex area}}{\text{Feret diameter}^2} \label{eq6}\\[1ex] +&\text{Compactness} = \frac{\text{Area}}{\text{Feret diameter}} \label{eq7}\\[1ex] +&\text{Ratio of area to length (RAL)} = \frac{\text{Area}}{\text{Major axis}^2} \label{eq8} +\end{align} + +%----------------------------------------------------------------------------- +\section{Spacing adjustment around non-textual elements} +\textcolor{magenta}{Reproduced from the class documentation for ready reference, as this is important.} \italk{Usually, the spacing around the non-textual elements produced by \LaTeX\ will be good and based on typography principles. The environments that create these elements (e.g., tables, figures, equations) automatically supply an additional space to set the elements apart from the regular text and this is the expected and correct behavior. However, sometimes additional space will appear above or below these elements, which may be the result of fitting the elements with respect to others of the whole chapter. However, the spacing around the non-textual elements can be altered by one or any combination of the following to produce a consistent spacing around the non-textual elements:} +\begin{itemize} +\item +\italk{The blank line coded, usually left between paragraphs, might create additional space before the element (e.g., \texttt{equation}, \texttt{align}) and that can be removed to reduce the space above the element.} +\item +\italk{Proper use of vertical spacing \cmd{vspace\{\ldots\}} command with negative spacing arguments (e.g., \cmd{vspace\{-3ex\}}) can able to correct the blank space above the element. This can also be used when a blank line was issued to separate the regular text from the element. Positive vertical space can also be issued as needed.} +\item +\italk{When a set of equations was coded (e.g., \texttt{align}, \texttt{eqnarray}), it will be treated as a block and will not break and flow through multiple pages and gets pushed to the next page. This will create large gaps and can be broken into two or more subsets of equations to fit the page by repeating the environments.} +\item +\italk{The actual space around the equations (displayed items) is controlled be the \\ \cmd{abovedisplayskip[=] glue} and \cmd{belowdisplayskip[=] glue}. +The \texttt{glue} is called a ``rubber'' length stating a basic length with an allowed play on both positive and negative sides. The default value for these commands was ``\texttt{12pt plus 3pt minus 9pt}'', and is also valid to use the basic length directly as:} + +\cmd{abovedisplayskip=-12pt} + +\italk{Another way for issuing the command is using the basic \cmd{setlength} as \\ \cmd{setlength\{}\cmd{abovedisplayskip\}\{-12pt\}}. To have the regular behavior subsequently, the default should be restored by reissuing the commands using the default values.} +\item +\italk{In figures, the space above the caption (the space between the bottom of the image and the top of the caption) can be controlled by using the optional argument of the \texttt{myfig, myfigls, myfigap} and \texttt{myfigapls} commands. This optional argument was specifically developed to address this caption placement issue. This may be required only for necessary adjustments as the default (without option) will work well in most cases.} +\end{itemize} + +%----------------------------------------------------------------------------- +\section{Annotation Commands} +\italk{Using the defined highlight, new text, deleted text, replaced text, and notes commands, the annotation features can be used by the student and the advisor. All the annotations should be commented (using \%) before submission. The commands (\textcolor{magenta}{again reproduced}) are:} + +\textbackslash\texttt{hl\{Highlight\}} gives: \hl{Highlight}. This will be regular text. + +\textbackslash\texttt{nt\{Test new text.\}} gives: \nt{Test new text.} This will be regular text. + +\textbackslash\texttt{dt\{Deleted text.\}} gives: \dt{Deleted text.} This will be regular text. + +\textbackslash\texttt{rt\{The text to be deleted\}\{Which will be replaced by this!\}} gives: \rt{The text to be deleted}{Which will be replaced by this!} This will be regular text again. + +\textbackslash\texttt{notes\{Testing this To Do notes - for communication!\}} gives: \notes{Testing this To Do notes - for communication!} + +%----------------------------------------------------------------------------- +\section{Handling URLs} +\italk{The URL typesetting in some cases will create an issue. The URLs sometimes flow into the right margin limits and will not break like normal text. As URLs carry the function of pointing to web resources, breaking them with the usual ``hyphen,'' which is an additional character, will interfere with its pointing function.} + +\italk{The typical \cmd{url\{\ldots\}} command works most of the time; however, it fails to break the URL flowing into the right margin. This can be visualized with a ``draft'' option in the very first \cmd{documentclass[draft]\{\ldots\}} command. Making additional breaking ``after'' some characters will help the process of breaking URL, following the \texttt{url} package documentation. The command used are \cmd{UrlBreaks} and \cmd{do}. The whole set of alphabets (lower- and upper-case) and a few special symbols were coded in the class to break the URLs.} + +\italk{The following URL command:} +\vspace{-2ex} +\begin{verbatim} +\url{https://www.pearson.com/us/higher-education/program/Lamport-La-Te-X-A- +Document-Preparation-System-2nd-Edition/PGM159713.html} +\end{verbatim} + +\noindent \italk{produces an hyperlink (shown in magenta subsequently) that points $\Rightarrow$ }\textcolor{magenta}{\url{https://www.pearson.com/us/higher-education/program/Lamport-La-Te-X-A-Document-Preparation-System-2nd-Edition/PGM159713.html}} \italk{to the webpage. Also, notice how the URL was correctly broken to fit the margin, and hovering on the URL will show the complete working URL when clicked will take the user to the webpage.} + +\italk{In the bibliography files the URLs are included as \cmd{url\{\ldots\}} command in ``article'' or ``book'' or other compatible items as a ``note'' entry. Usually, this will be used for pointing \texttt{doi} or \texttt{www} resources. Refer to the \texttt{bib} file of this document for examples. } + +%----------------------------------------------------------------------------- +\section{Theorems Environment} + +\italk{In mathematical research documents, theorems and proofs are among the most common elements but others, such as lemmas, propositions, axioms, corollaries, conjectures, definitions, remarks, and cases, are also used steps. The best way to typeset them is to use the American Mathematical Society (AMS) \textcolor{magenta}{asmthm} package \citep{amsthm2017}, which is the modern method and provides a lot of customization.} + +\italk{It is natural to handle theorem elements as \LaTeX environments; however, because of several user-specific formats (e.g., numbering and variety of elements) that need to be specified, the document class do not provide predefined environments. The package documentation may be referred to define the necessary elements using \cmd{newtheorem} command, similar to \cmd{newenvironment} command to suit the user's need.} + +\italk{The following theorem and other elements were created after defining the environment shown subsequently in the preamble:} + +\begin{verbatim} +\newtheorem{theorem}{Theorem}[section] +\newtheorem{corollary}{Corollary}[theorem] +\newtheorem{lemma}{Lemma}[corollary] +\end{verbatim} + +\vspace{-0.5in} +\italk{ +\begin{theorem} +Let \(f(x)\) be our function that will do wonders and this function is enough to \emph{``end the world hunger''} --- but will it? Note the use of \cmd{emph\{\ldots\}} that made the world hunger upright! +\end{theorem} +\begin{theorem}[Pythagorus theorem] +\label{pytha} +This is that famous theorem we all studied at middle school, which we still remember and apply in our daily lives +\vspace{6ex} +\[ a^2 + b^2 = c^2 \qquad \emph{(or)} \qquad c = \sqrt{a^2 + b^2} \] +\end{theorem} +\vspace{-3ex} +\noindent where $a$ and $b$ are the lengths of the legs of the right triangle and $c$ is the hypotenuse. +The next corollary is a consequence of \cref{pytha} and is also useful. The use of \cmd{cref} correctly inserted the item ``theorem.'' +\begin{corollary} +It is a right rectangle whose sides measure \SI{3}{m}, \SI{4}{m}, and \SI{5}{m}. +\label{coro} +\end{corollary} +Lemma usually follows a corollary --- and there ends my knowledge of math. +\begin{lemma} +Given two line segments whose lengths are $p$ and $q$, we can add them and get a new length $r$ as \(r=p+q\). +\label{lem} +\end{lemma} +Theorems, corollaries, lemmas, and other elements can be referenced after defining the labels in an appropriate environment such as \cref{pytha}, \cref{coro}, \cref{lem} when a label is assigned. Again, \cmd{cref} commands produced the correct references and categories. +} + +%----------------------------------------------------------------------------- +\section{Fun Notes} +\italk{Some unexpected behavior, but logical behavior we will come across while using \LaTeX. And some of those are described here (``itemize'' environment is used to produce the bulleted list).} + +\begin{itemize} +\item +\italk{Note the position of the ``period'' in} {\LARGE F., O., T., P., V., W., and Y.} \italk{and compare it with H. --- happens with some fonts. Such encroachment can be rectified by inserting ``\cmd{@}'' between the letter and period as:} {\LARGE{\verb|F\@.|}} \italk{command.} + +\italk{Now the rectified version is:} {\LARGE F\@., O\@., T\@., P\@.; V\@.; W\@.; and Y\@.} + +\item +\italk{Notice the no space before the word ``environment'' \LaTeX environments with the code [\cmd{LaTeX environments}]. Using the spacing command ``\cmd{\:}'' (backslash-and-space) as [\cmd{LaTeX\textbackslash\:environments}] will create the enough space as \LaTeX\ environments.} +\end{itemize} + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\myheading{Seventh chapter without tables and figures} + +%----------------------------------------------------------------------------- +\section{Test 1} +\italk{Section text text text text text text text text text text text text text text text text text text text text text.} + +%------------------------------------------- +\subsection{Test 2} +\italk{Subsection works.} + +%------------------------------------------- +\subsubsection{Test 3} +\italk{Sub-subsection works.} +\kant[3] + +%------------------------------------------- +\paragraph{Test 4} +\italk{Paragraph works.} + + +%----------------------------------------------------------------------------- +\renewcommand{\bibname}{REFERENCES} +% Compatible natbib styles: plainnat, abbrvnat, unsrtnat, rusnat, agsm, chicago, apalike + +%bibtex used here +\biblio{apalike}{mybib}\label{biblio} + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\appendix % single and simple regular appendix + +%-------------------------------------------------- +\italk{This is a regular Appendix - where only one appendix is used. \textcolor{magenta}{In this document, we use both Appendix and Named Appendices --- which will be never the case and only one method is used --- but shown here for illustration}. This was slightly modified so that it correctly formats sections, subsections, sub subsections, figures, and tables. Here the label A is automatically supplied. The list of appendix figures and tables will be automatically updated. Obviously, for multiple appendices (A, B, C, etc.) the \cmd{namedappendices\{\ldots\}\{\ldots\}} should be used --- as followed subsequently.} + +\italk{A few handy commands developed for handling abstract regular and landscape figures are \cmd{myfigap}, \cmd{myfigapls} similar to regular figures with 1 optional + 5 arguments are: } + +\label{figv} +\vspace{2ex} +{\singlespacing +\begin{verbatim} +For regular appendix figures {1+5 inputs; } +\myfigap[2ex]{ht}{0.5}{appenddfig1.pdf}{My appendix caption goes here}{figA1} + +For landscape appendix figures {1+5 inputs} +\myfigapls[2.5ex]{p}{1.3}{appenddfig2.pdf}{My appendix caption goes here}{figA2} +\end{verbatim} +} + +\italk{Other elements such as equations are coded in the usual way. While tables use \texttt{appendixtable} environment in the usual way. Simple use of \texttt{table} environment will not number the tables correctly.} + +\italk{Appendices will not support the \cmd{cref\{\ldots\}} command only for \textcolor{magenta}{figures and tables} (as these were redefined in the class). However, the basic \cmd{ref\{\ldots\}} preceded by Figure or Table as required should be used. For other items, such as equations, and sections the \cmd{cref\{\ldots\}} works well. Check the code and outputs below (labels were defined in their respective environment):} + +{\singlespacing +\begin{verbatim} +Referred items: \cref{eqa1} text. \cref{sub1} text. \cref{figap1} text +\cref{aptab1} text. \\ + +Referred items: \ref{eqa1} text. Section \ref{sub1} text. Figure \ref{figap1} +text and Table \ref{aptab1} text. +\end{verbatim} +} + +\italk{Referred items: \cref{eqa1} text. \cref{sub1} text. \cref{figap1} text \cref{aptab1} text. \\ +Referred items: \ref{eqa1} text. \ref{sub1} text. Figure \ref{figap1} text and Table \ref{aptab1} text. +\\ \textcolor{magenta}{Notice the missing items (by \cmd{cref\{\ldots\}}) are marked as ??.}} + +%----------------------------------------------------------------------------- +\section{Appendix Figure} + +\myfigap[1.5ex]{h!}{0.45}{frog.jpg}{Appendix one - figure using myfigap command - figure captions go at the bottom and is long too.}{figap1} + +\italk{The code that created the figure above (Fig. \ref{figap1}; this cross reference was made using \cmd{ref\{\}} command) is:} + +{\onehalfspacing +\begin{verbatim} +\myfigap[1.5ex]{h!}{0.45}{frog.jpg}{Appendix one - figure using myfigap command - + figure captions go at the bottom and is long too.}{figap1} +\end{verbatim} +} + +\italk{Shown below is an equation \cref{eqa1}. } + +\vspace{-4ex} +\begin{equation} +y = mx + c +\label{eqa1} +\end{equation} + +%-------------------------------------------------- +\subsection{One of One} +\label{sub1} +\kant[2] + +\italk{The code that created the table (table~\ref{aptab1}) below is:} + +{\onehalfspacing +\begin{verbatim} +\begin{appendixtable}[h] +\centering +\caption{One appendix full-width table captions go at the top of the table.} +\setlength\tabcolsep{1.3in} +\begin{tabular}{lr} +\toprule +Number & Month \\ +\midrule +1 & January \\ +2 & February \\ +3 & March\\ +\bottomrule +\label{aptab1} +\end{tabular} +\end{appendixtable} +\end{verbatim} +} + +\begin{appendixtable}[h] +\centering +\caption{One appendix full-width table captions go at the top of the table.} +\setlength\tabcolsep{1.3in} +\begin{tabular}{cc} +\toprule +Number & Month \\ +\midrule +1 & January \\ +2 & February \\ +3 & March\\ +\bottomrule +\label{aptab1} +\end{tabular} +\end{appendixtable} + +%-------------------------------------------------- +\subsection{Two of One} + +\italk{Just another figure (fig.~\ref{figap2}) included for illustrating the lifting of the caption by -ve optional argument. } + +\myfigap[-4ex]{h!}{0.6}{frog.jpg}{Appendix one - figure 2 using myfigap command - figure captions go at the bottom and is long too, while demonstrating the -ve value lifting the caption up --- not acceptable though.}{figap2} + +%------------------------------------------- +\subsubsection{Subsubsection} +\italk{This also works.} + + +%-------------------------------------------------- +%-------------------------------------------------- +\namedappendices{A}{Named appendix title here} % Multiple named appendices + +\textcolor{magenta}{Note: As mentioned earlier the named appendices were included for illustration purposes. The application of both will interfere with the numbering of sections, subsections, tables, figures, and so on. One may find in TOC, LOAT, and LOAF the same numbers begin repeated, which is logical and correct behavior. But this is of \emph{no consequence} in real work as both appendix and named appendix will never be used in a single disquisition.} + +\italk{This named appendix was made using the command:} + +\begin{verbatim} +\namedappendices{A}{Named appendix title here} +\end{verbatim} + +%----------------------------------------------------------------------------- +\section{Section Test} + +I can include appendix material here. + +\italk{And the second figure using the shortcut command \texttt{myfigap} and uses a long caption that wraps around (refer code in page: \pageref{figv}).} + + +\myfigap{H}{0.4}{frog.jpg}{Named appendix figure using myfigap command - figure captions go at the bottom - a long long long long long long long long long long long long long long long long long long long long caption.}{figaa1} + +\kant[1] + +\begin{appendixtable}[h] +\centering +\caption{Appendix table (full-width) using \texttt{tabu} package with \texttt{booktabs} commands illustrating column width coefficient (2nd column is thrice the width of 1st) and automatic overflow of rows as a paragraph. Captions go at the top of the table and left-justified.} +\begin{tabu}{X X[3]} +\toprule +Number & Month \\ +\midrule +1 & January, Jan, Jan, Jan, Jan, Jan, Jan, Jan \\ +2 & February, Feb, Feb, Feb, Feb, Feb, Feb, Feb \\ +\cmidrule(lr){2-2} +3 & March, Mar, Mar, Mar, Mar, Mar, Mar, Mar, Mar, Mar, Mar, Mar, Mar, 2-rows\\ +\cmidrule(lr){2-2} +4 & April, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, Apr, 3-rows\\ +\bottomrule +\end{tabu} +\end{appendixtable} + +%----------------------------------------------------------------------------- +\section{Another Section} +Two sections shown. \kant[7] + +%------------------------------------------- +\subsection{Test 2} +Subsection works. + +%------------------------------------------- +\subsubsection{Test 3} +Sub-subsection works. + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\namedappendices{B}{Named second appendix title here} + +%----------------------------------------------------------------------------- +\section{Test} +I can include appendix material here. \italk{Table~\ref{apbtab1} produced.} + +\begin{appendixtable}[h] +\centering +\caption{Named appendix B full-width table ONE using \texttt{tabu} environment.} +\begin{tabu}{ *4{X[c]} } +\toprule +Number & Month & Same & Same\\ +\midrule +1 & January & January & January \\ +2 & February & February & February \\ +3 & March & March & March\\ +\bottomrule +\label{apbtab1} +\end{tabu} +\end{appendixtable} + +\vspace{-4ex} +\italk{Repeated table B1 (table~\ref{apbtab2})} + +\begin{appendixtable}[h] +\centering +\caption{Named appendix B full-width table TWO using \texttt{tabu} environment.} +\begin{tabu}{ *4{X[c]} } +\toprule +Number & Month & Same & Same\\ +\midrule +1 & January & January & January \\ +2 & February & February & February \\ +3 & March & March & March\\ +\bottomrule +\label{apbtab2} +\end{tabu} +\end{appendixtable} + +\vspace{-4ex} +\italk{Figure produced (fig.~\ref{figab1}) - small one though!} + +\myfigap{H}{0.15}{frog.jpg}{Named appendix B figure.}{figab1} + + +\italk{Now a landscape figure in appendix (fig.~\ref{figab2}, which can be found in \cpageref{figab2}), and the shortcut command \texttt{myfigapls} (refer code in \cpageref{figv}).} + +\myfigapls[2ex]{p}{0.9}{frog.jpg}{Fourth figure using myfigap command - figure captions go at the bottom}{figab2} + +%----------------------------------------------------------------------------- +\section{Normal Section} +\kant[11] + + +%----------------------------------------------------------------------------- +%----------------------------------------------------------------------------- +\namedappendices{C}{Third appendix title here} + +\italk{Note the \hl{important note} at the end of this appendix!} + +\kant[3] + +%----------------------------------------------------------------------------- +\section{Test1 and Program Source Code Listing} +I can include appendix material here. \kant[9] + +\italk{Computer program source codes, pseudocodes, and algorithms can be listed using the \vb{listings} package and loading the different options including the language used using \cmd{lstset\{arguments\}}. This package is an elaborate one and users should refer to the documentation for several features to suit their needs. An example of a section of Java program using \vb{lstlisting} environment (refer source code) is shown below as an illustration:} + +{\singlespacing +\begin{lstlisting} +//------------------------------------------------------------------------- +// +// Process the color image into a stack and extract all channels of HSB +// as global variable +// + public void extractHSBchannel(ImagePlus colimp){ + + ImageProcessor iporig = colimp.getProcessor(); + + ImagePlus impd = colimp.duplicate(); // required otherwise original will be used up + impd.show(); // required to generate the stacks + + IJ.run(impd, "HSB Stack", ""); + IJ.run("Stack to Images", ""); + int ni = WindowManager.getImageCount(); + + String[] flist = null; // blank array without size specificatiion + + flist = WindowManager.getImageTitles(); + + H_imp = WindowManager.getImage?("Hue"); // as an array or global variable other channels can also be preserved + S_imp = WindowManager.getImage?("Saturation"); + B_imp = WindowManager.getImage?("Brightness"); + } +// +//------------------------------------------------------------------------- +\end{lstlisting} +} + +%------------------------------------------- +\subsection{Test2} +I can include appendix material here. + +\italk{Shown below is another equation showing hypotenuse \Cref{eqc1}. The previous equation in the appendix one is \cref{eqa1} which was $y = mx + c$ in \cpageref{eqa1}. } + +\vspace{-3ex} +\begin{equation} +r^2 = x^2 + y^2 +\label{eqc1} +\end{equation} + +%------------------------------------------- +\vspace{-2ex} +\subsubsection{Test3} +I can include appendix material here. + +%------------------------------------------- +\paragraph{Test4} + +{\hl{Important note:} +\textcolor{magenta}{It should be noted that the final appendix should contain the appendix tables and figures to generate the List of Appendix Tables and List of Appendix Figures --- based on NDSU thesis class. Otherwise, these items will not be created.} +} + +\textcolor{magenta}{This issue is not present with regular chapters.} + +\italk{However, now we have the new \cmd{closeappendices} command to ensure the list of appendix tables and figures. This has to be given at the end of the last appendix.} + +\vspace{1cm} +\begin{center} +{\LARGE\bfseries +Happy {\LaTeX}ing, Thesis Writing, \\ +and Paper Publishing! +} +\end{center} + +\hfill {\footnotesize --- C. Igathinathane} +\closeappendices + +\vspace{0.5in} +\begin{center} +\italk{--- The End ---} +\end{center} +%-------------------------------------------------- + +\end{spacing} + +\end{document} +%-------------------------------------------------- +%-------------------------------------------------- +%--------------------------------------------------
\ No newline at end of file diff --git a/macros/latex/contrib/ndsu-thesis-2022/README b/macros/latex/contrib/ndsu-thesis-2022/README new file mode 100644 index 0000000000..24342c521a --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/README @@ -0,0 +1,30 @@ +This is the ndsu-thesis-2022 document class. This is an upgraded version of ndsu-thesis document class. Copyright 2022, Aaron Feickert, Jonathan Totushek, and Igathinathane Cannayen. + +This work may be distributed and/or modified under the conditions of the LaTeX Project Public License; LPPL Version 1.3c 2008-05-04 or (at your option) any later version. + +Copyright 1999 2002-2008 LaTeX3 Project + Everyone is allowed to distribute verbatim copies of this + license document, but modification of it is not allowed. + +The latest version of this license is in: https://www.latex-project.org/lppl.txt + +This work has the LPPL maintenance status `maintained'. + +The current maintainer of this work is Igathinathane Cannayen. +Contact: i.cannayen@ndsu for bug reports and enquires. + +This new class or the old can be used independently, and these classes are appropriately invoked through the documentclass command with required options. It can be used to produce disquisitions (MS and PhD) for submission to the NDSU Graduate School and the final acceptance rests with the University Dissertation and Thesis Coordinator, and the Graduate Committee. + +Files included are: + README - this information file + ndsu-thesis-2022.cls - class file + ndsu-thesis-2022-documentation.tex - class file documentation (source) + ndsu-thesis-2022-documentation.pdf - class file documentation + ndsu-example.tex - simple thesis example file (source) + ndsu-example.pdf - simple thesis example file + NDSU-Thesis-Extended.tex - extended thesis example illustrating several features (source) + NDSU-Thesis-Extended.pdf - extended thesis example illustrating several features + mybib.bib - sample bibliography database file used in theses examples + frog.jpg - free sample image file used in thesis example + figures - subfolder holding the images of documentation +%==================================================================
\ No newline at end of file diff --git a/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOA.pdf b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOA.pdf Binary files differnew file mode 100644 index 0000000000..f9ca9d6319 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOA.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOS.pdf b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOS.pdf Binary files differnew file mode 100644 index 0000000000..8eb1c85b5b --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-LOS.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/figures/fig-draftmargin.pdf b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-draftmargin.pdf Binary files differnew file mode 100644 index 0000000000..efdb42bc23 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/figures/fig-draftmargin.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/frog.jpg b/macros/latex/contrib/ndsu-thesis-2022/frog.jpg Binary files differnew file mode 100644 index 0000000000..61e61b1b3b --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/frog.jpg diff --git a/macros/latex/contrib/ndsu-thesis-2022/mybib.bib b/macros/latex/contrib/ndsu-thesis-2022/mybib.bib new file mode 100644 index 0000000000..3f49f81b22 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/mybib.bib @@ -0,0 +1,297 @@ +@incollection{acker2002hidden, + title={The hidden curriculum of dissertation advising}, + author={Acker, Sandra}, + booktitle={The hidden curriculum in higher education}, + pages={71--88}, + year={2002}, + publisher={Routledge} +} + +@article{blanton1983midwifing, + title={Midwifing the dissertation}, + author={Blanton, Judith S}, + journal={Teaching of Psychology}, + volume={10}, + number={2}, + pages={74--77}, + year={1983}, + publisher={Taylor \& Francis} +} + +@book{borden2006dissertation, + title={The dissertation}, + author={Borden, Iain}, + year={2006}, + publisher={Routledge} +} + +@book{butin2009education, + title={The education dissertation: {A} guide for practitioner scholars}, + author={Butin, Dan W}, + year={2009}, + publisher={Corwin Press} +} + +@article{cassuto2010advising, + title={Advising the struggling dissertation student}, + author={Cassuto, Leonard}, + journal={TheChronicle of Higher Education}, + volume={57}, + number={17}, + pages={51--53}, + year={2010} +} + +@misc{gajani2014, +title={12 most famous {Phd} theses in history}, +author={Gajani, A}, +month={April}, +year={2014}, +howpublished={Mr. Geek.me Web-blog}, +note={URL: \url{http://www.mrgeek.me/lists/12-most-famous-phd-theses-in-history/}} +} + +@misc{onlinephd2022, +title={60 {Famous Ph.D. Theses in History}}, +author={\mbox{Online~PhD~Degrees}}, +month={March}, +year={2022}, +howpublished={Online PhD Degrees (n.d.) Web-blog}, +note={URL: \url{https://www.online-phd-degrees.com/famous-ph-d-theses-history/}} +} + +@book{roberts2010dissertation, + title={The dissertation journey: {A} practical and comprehensive guide to planning, writing, and defending your dissertation}, + author={Roberts, Carol M}, + year={2010}, + publisher={Corwin Press} +} + +@article{roediger2004great, + title={Great dissertations: {M}ark {I}}, + author={Roediger III, Henry L}, + journal={APS Observer}, + volume={17}, + number={10}, + year={2004} +} + +@book{rudestam2014surviving, + title={Surviving your dissertation: {A} comprehensive guide to content and process}, + author={Rudestam, Kjell Erik and Newton, Rae R}, + year={2014}, + publisher={Sage publications} +} + +%%%%%%%%%%%%%%%%%%%%%%%%%%%%% + +@book{texbook, + author = {Donald E. Knuth}, + year = {1986}, + title = {The \TeX{} Book}, + publisher = {Addison-Wesley Professional} +} + +@book{lcompanion, + author = {Frank Mittelbach and Michel Gossens + and Johannes Braams and David Carlisle + and Chris Rowley}, + year = {2004}, + title = {The \LaTeX{} Companion}, + publisher = {Addison-Wesley Professional}, + edition = {2} +} + +@book{lamport94, + author={Leslie Lamport}, + title={\LaTeX\ -- {A Document Preparation System}}, + year={1994}, + publisher={Addison-Wesley}, + note={User's Guide and Reference Manual. \url{https://www.pearson.com/us/higher-education/program/Lamport-La-Te-X-A-Document-Preparation-System-2nd-Edition/PGM159713.html}}, + edition={{S}econd} +} + +@book{latex2e, + author = {Leslie Lamport}, + year = {1994}, + title = {\LaTeX: a Document Preparation System}, + publisher = {Addison Wesley}, + address = {Massachusetts}, + edition = {2} +} + +@article{knuth1984, + title={Literate Programming}, + author={Donald E. Knuth}, + journal={The Computer Journal}, + volume={27}, + number={2}, + pages={97--111}, + year={1984}, + publisher={Oxford University Press} +} + +@inproceedings{lesk1977, + title={Computer Typesetting of Technical Journals on {UNIX}}, + author={Michael Lesk and Brian Kernighan}, + booktitle={Proceedings of American Federation of + Information Processing Societies: 1977 + National Computer Conference}, + pages={879--888}, + year={1977}, + address={Dallas, Texas} +} + +@misc{amsthm2017, +title={Using the \texttt{amsthm} {P}ackage}, +author={AMS}, +month={September}, +year={2017}, +howpublished={Version 2.20.3, Publications Technical Group, American Mathematical Society}, +note={Documentation URL: \url{http://www.ams.org/arc/tex/amscls/amsthdoc.pdf}} +} + +@phdthesis{calvo2004using, + title={USING THE NDSU THESIS DOCUMENT CLASS FOR LATEX}, + author={Calvo, Jorge Alberto}, + year={2004}, + school={North Dakota State University}, + note={\url{https://www.ndsu.edu/fileadmin/math/Home_Page/Resources/Tex_and_LaTeX/LaTeX_Document_Class_for_NDSU_Disquisitions/mythesis.pdf}} +} + +@inproceedings{cannayen2011latex, + title={{LaTeX} for {Agricultural and Biological Engineers}}, + author={Igathinathane, Cannayen}, + booktitle={2011 Louisville, Kentucky, August 7-10, 2011}, + pages={1}, + year={2011}, + note={\url{https://elibrary.asabe.org/abstract.asp?aid=38487}}, + organization={American Society of Agricultural and Biological Engineers} +} + +@book{kopka2004guide, + title={A Guide to \LaTeX\ and Electronic Publishing}, + author={Kopka, H and Daly, PW}, + year={2004}, + publisher={Addison-Wesley}, + note={\url{https://www.math.ucdavis.edu/~tracy/courses/math129/Guide_To_LaTeX.pdf}}, + edition={{F}ourth} +} + +@book{notso2021, +title = {{The Not So Short Introduction} to LaTeX2e}, +author={Oetiker, Tobias and Partl, Hubert and Hyna, Irene and Schlegl, Elisabeth}, +note={\url{http://tug.ctan.org/info/lshort/english/lshort.pdf}}, +year = {2021} +} + +@article{pires2021teens, + title={What are teens doing with YouTube? Practices, uses and metaphors of the most popular audio-visual platform}, + author={Pires, Fernanda and Masanet, Maria-Jose and Scolari, Carlos A}, + journal={Information, Communication \& Society}, + volume={24}, + number={9}, + pages={1175--1191}, + year={2021}, + publisher={Taylor \& Francis} +} + +@book{pakin2021comp, + title={The Comprehensive \LaTeX\ Symbol List}, + author={Pakin, Scott}, + year={2021}, + publisher={CTAN. Documentation URL: \url{https://tug.ctan.org/info/symbols/comprehensive/symbols-a4.pdf}} +} + +@book{Chang2014cheat, + title={\LaTeXe\ Cheat Sheet}, + author={Winston Chang}, + year={2014}, + publisher={Documentation URL: \url{https://wch.github.io/latexsheet/latexsheet.pdf}} +} + +@book{Wikibook2016, + Author = {{Wikibook Contributors}}, + Note = {Documentation URL: http://upload.wikimedia.org/wikipedia/commons/2/2d/LaTeX.pdf. }, + Publisher = {Online source Wikibooks}, + Title = {{LaTeX}}, + Year = {2016}} + +@book{Goossens2008g, + Author = {Goossens, M. and Rahtz, S. and Mittelbach, F.}, + Isbn = {0321508920}, + Publisher = {Addison-Wesley Reading, MA}, + Title = {{The \LaTeX\ Graphics Companion}}, + Year = {2008}} + +@misc{Kern2007a, + Author = {Kern, U.}, + Note = {v2.11. Documentation URL: http://ctan.math.utah.edu/ctan/\mbox{tex-archive}/macros/latex/ + contrib/xcolor/xcolor2.pdf. }, + Title = {{Color extensions with the xcolor package - pstricks examples}}, + Year = {2007}} + +@misc{Kern2007, + Author = {Kern, U.}, + Note = {{v2.11. Documentation URL: http://ftp.math.purdue.edu/mirrors/ctan.org/macros/latex/ contrib/xcolor/xcolor.pdf.}}, + Title = {{Extending \LaTeX's color facilities: the xcolor package}}, + Year = {2007}} + +@book{Mittelbach2004, + Author = {Mittelbach, F. and Goossens, M. and Braams, J. and Carlisle, D. and Rowley, C.}, + Note = {ISBN: 0-201-36299-6}, + Publisher = {Addison-Wesley, Reading, Massachusetts, US}, + Title = {{The \LaTeX\, Companion}}, + Year = {2004}} + +@book{latxprojteam20, +title={\LaTeXe\ for authors}, +author={Frank Mittelbach}, +month={May}, +year={2020}, +publisher={1995--2020, \LaTeX\ Project Team. The \LaTeX\ Project. Documentation URL: \url{https://www.latex-project.org/help/documentation/usrguide.pdf}} +} + +@book{latxprojteam22, +title={New \LaTeX\ methods for authors (starting 2020)}, +author={Frank Mittelbach}, +month={February}, +year={2022}, +publisher={2020--2022, \LaTeX\ Project Team. The \LaTeX\ Project. Documentation URL: \url{https://www.latex-project.org/help/documentation/usrguide3.pdf}} +} + +@misc{daly2010natural, + title={Natural sciences citations and references ({A}uthor-Year and Numerical Schemes)}, + author={Daly, Patrick W}, + year={2010}, + note={Version 8.31b. URL: \url{https://ctan.math.utah.edu/ctan/tex-archive/macros/latex/contrib/natbib/natbib.pdf}} +} + +@article{bari2016identification, + title={Identification of heterotic patterns between expired proprietary, NDSU, and industry short-season maize inbred lines}, + author={Bari, Mohammed AA and Carena, Marcelo J and Pereira, Messias G}, + journal={Crop Breeding and Applied Biotechnology}, + volume={16}, + pages={274--281}, + year={2016}, + publisher={SciELO Brasil} +} + +@article{sharma2012ndsu, + title={{NDSU EarlyGEM}: Incorporating tropical and temperate elite exotic germplasm to increase the genetic diversity of short-season maize}, + author={Sharma, Santosh and Carena, Marcelo J}, + journal={Maydica}, + volume={57}, + number={1}, + pages={24--42}, + year={2012} +} + +@article{baczkowski1990ndsu, + title={NDSU undergraduate design projects for the disabled.}, + author={Baczkowski, LS and Enderle, JD and Krause, DJ and Rawson, JL}, + journal={Biomedical Sciences Instrumentation}, + volume={26}, + pages={95--99}, + year={1990} +} diff --git a/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.pdf b/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.pdf Binary files differnew file mode 100644 index 0000000000..847aa472fd --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.tex b/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.tex new file mode 100644 index 0000000000..304285205e --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/ndsu-example.tex @@ -0,0 +1,230 @@ +%**********************************START +\documentclass[ms-thesis,12pt,mathdesign]{ndsu-thesis-2022} + +%Refer documentation (ndsu-thesis-2022-documentation.pdf) for various options and commands + +%**********************************Packages, newcommands, and other customization +\usepackage[sort&compress]{natbib} +\citestyle{egu} % plain, agu, egu, agms, dcu, kluwer, cospar, nature +\newcommand\tend{\tempend{apalike}{mybib}} + +%**********************************First and second page material +\title{The Title of My M.S. Thesis} +\author{Samuel Fargo Bison} +\date{January 2022} +\progdeptchoice{Department} % Use Department (or) Program +\department{Mathematics} + +\cchair{Prof. John Adams} % Use actual committee members names +\cmembera{Prof. Abraham Lincoln} +\cmemberb{Prof. George Washington} +\cmemberc{Prof. Theodore Roosevelt} % If 3rd not required - delete this line +\approvaldate{12/14/2022} +\approver{Prof. James Garfield} + +%**********************************Front matter +\abstract{This is the abstract for my thesis. \\ \emph{Abstracts for doctoral +dissertations must use 350 words or less. Abstracts for master's papers or master's +theses must use 150 words or less.}\\ \kant[16]} % dummy text + +\acknowledgements{I acknowledge people here. \\ \emph{Acknowledgements text should be +placed here.} \\ \kant[15]} + +\dedication{This thesis is dedicated to my cat, Mr. Fluffles.\\ \emph{This section +dedicates the disquisition to a few significant people. The text must be double-spaced +and aligned center to the page.} \\ Which is already taken care of by this \LaTeX\ class.} + +\preface{You can put a preface here. \\ \emph{This section is optional!} \\ \kant[14]} + +\listofabbreviations{% may use title case +AC & Alternating Current \\ +NDSU & North Dakota State University \\ +ZL & Zeta Level} + +\listofsymbols{% may use sentence case +$A$ & Area (\si{\m\squared})\\ +$e$ & Euler's constant (\num{2.718281828}) \\ +$R^2$ & Coefficient of determination} + +%**********************************Document start +\begin{document} + +%**********************************First chapter - paper style +\mypaperheading{The First Chapter - Paper Style - Long title of this technical paper}{*} +{This paper is planned to be submitted as a peer-reviewed article \ldots\ more information +about the author(s), title, \emph{journal}, to be added.} + +\section{Abstract11} +Paper-styled chapters will have abstracts. Abstract of this chapter goes here. \kant[1] + +\section{Section12} +This is the first section of the thesis (1st level: 1.2. Section). \kant[2] + +\section{Section13} +This is the second section of the thesis (1st level: 1.3. Section). \kant[3] + +\subsection{Subsection131} +This is the subsection text (2nd level: 1.3.1. Subsection). \kant[4] + +\subsubsection{Subsubsection1311} +This is the subsection text (3rd level: 1.3.1.1. Subsubsection). \kant[5] + +\paragraph{Paragraph13111} +This is the subsection text (4th level: 1.3.1.1.1. Paragraph). \kant[6] + +\section{Table and Figure} +This is the third section of the thesis (1st level: 1.4. Section). This section +illustrates the inclusion of a simple table (\cref{tab:1}) and a figure shown later. + +\begin{table}[h] +\centering +\caption{Table captions go at the top of the table. This was long caption of the table +included in the first chapter --- so that we see how it breaks into another line and +having a single spacing. Usually tables are of full-width and are demonstrated subsequently.} +\vspace{-1ex} +\begin{tabular}{clr} +\toprule +Number & Month & Days\\ +\midrule +1 & January & 31\\ +2 & February & 28\\ +3 & March & 31\\ +\bottomrule +\end{tabular} +\label{tab:1} +\end{table} \kant[7] + +Now the figure (\cref{fig:1}) illustrates an example figure from the \texttt{mwe} package. + +\myfig{H}{0.6}{example-image-duck}{Caption for this example image in this first chapter.} +{fig:1} \kant[8-9] + +%**********************************Second chapter - regular +\myheading{The Second Chapter - Regular Style - Long title for this chapter} + +Regular style chapters will not have abstracts. General information or outline of the +chapter is given here --- before breaking into sections. + +\section{Excellent Results} +This is another section of the thesis (1st level: 2.1. Experimental Results). +\Cref{tab:2} presents the results in a tabular form that spans the entire width. +Please note the results shown (\cref{tab:2}) are preliminary. + +\begin{table}[ht] +\centering +\caption{Table spanning entire width (full-width) using \texttt{setlength} and +\texttt{tabcolsep}} +\vspace{-1ex} +\setlength{\tabcolsep}{3.75em} +\begin{tabular}{@{\hspace{2ex}} lccr @{\hspace{2ex}}} +\toprule +Number & Name of month & Days & Season\\ +\midrule +4 & April & 30 & Spring\\ +5 & May & 31 & Summer\\ +6 & June & 30 & Summer\\ +\bottomrule +\end{tabular} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: The \texttt{tablenotes} environment produces table footnotes. +\end{tablenotes} +\label{tab:2} +\end{table} \kant[7-8] + +\subsection{Minor Results} +This is a subsection of the thesis (1st level: 2.2. Experimental Results). \kant[8] +The \Cref{fig:2} is an example image with command showing all arguments including the optional +caption placement. The example figure (\cref{fig:2}) is included in the \texttt{mwe} package. + +\myfig[2ex]{H}{0.5}{example-image}{Caption for this example image demonstrating an optional +2ex vertical spacing. Compare this with a narrow caption spacing without optional argument in +\cref{fig:1}.}{fig:2} +\kant[8] + +\section{Some References} +Referring to all entries in the ``\texttt{mybib.bib}'' file to generate the citations here +and the listing using the \texttt{\textbackslash citep\{\ldots\}} ``natbib'' command +(cite parenthesis)\citep{texbook,lcompanion,latex2e,knuth1984,lesk1977,amsthm2017, +calvo2004using,cannayen2011latex,kopka2004guide,notso2021}. + +The same using \texttt{\textbackslash citet\{\ldots\}} command (cite text) in the running +text as: The authors \citet{texbook,lcompanion,latex2e,knuth1984,lesk1977,amsthm2017, +calvo2004using,cannayen2011latex,kopka2004guide,notso2021} have something to do +with \LaTeX. For most bibliography citation and list creation, these two commands +are sufficient. + +%**********************************Bibliography handling +\biblio{apalike}{mybib} % Shortcut command using style and bib-file arguments + +%**********************************Named appendix A +\namedappendices{A}{Named first appendix} +Appendix material can be included here. First including a figure (fig.~\ref{fig:ap1}). + +\section{Appendix A - Section With Figure} +\myfigap{H}{0.5}{example-image-golden}{A golden ratio rectangle image.}{fig:ap1} \kant[8] + +\section{Appendix A - Section With Table} +And, then including a table (table.~\ref{tab:ap1}). + +\begin{appendixtable}[h!] +\centering +\caption{Use of \texttt{tabu} environment for full-width table - applicable to both main text +and appendix. Note the use of \texttt{booktabs} commands and `X' parameters to reproduce +Table~\ref{tab:2}. } +\begin{tabu} {X X[2, c] X[2,c] X[r]} %X[2, c] = coef. = 2, align = center +\toprule +Number & Name of month & Days & Season\\ +\midrule +4 & April & 30 & Spring\\ +5 & May & 31 & Summer\\ +6 & June & 30 & Summer\\ +\bottomrule +\end{tabu} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: The \texttt{tablenotes} environment produces table footnotes. +Refer to \texttt{tabu} documentation for further details. +\end{tablenotes} +\label{tab:ap1} +\end{appendixtable} + +\subsection{Appendix A Subsection} +\kant[10] + +%**********************************Named Appendix B +\namedappendices{B}{Named second appendix} +Appendix material can be included here. First including a figure (fig.~\ref{fig:ap2}). + +\section{Appendix B - Section With Figure} +\kant[9] +\myfigap[0.5ex]{H}{0.7}{example-grid-100x100pt}{A $10 \times 10$ grid of different +concentric colors.}{fig:ap2} + +\section{Appendix B - Section With Table} +Now coding another appendix table (table.~\ref{tab:ap2}) that spans the entire width using +the manual method (using `tabcolsep' command; and `resize' command to fit large tables). + +\begin{appendixtable}[h] +\centering +\caption{Squares and cubes named appendix table using \texttt{siunitx} package.} +\setlength{\tabcolsep}{7.1ex} +\begin{tabular}{@{\hspace{2ex}} lcrr @{\hspace{2ex}}} +\toprule +Number & Square & Cubes & Fourth power\\ +\midrule +11 & 121 & \num{1331} & \num{14641}\\ +22 & 484 & \num{10648} & \num{234256}\\ +333 & \num{110889} & \num{36926037} & \num{12296370321}\\ +\bottomrule +\end{tabular} +\label{tab:ap2} +\end{appendixtable} + +\subsection{Appendix B Subsection} +\kant[11] + +\closeappendices % Closing (redundant) of appendices for LOAT and LOAF generation + +\end{document} +%**********************************END diff --git a/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.pdf b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.pdf Binary files differnew file mode 100644 index 0000000000..7ee8ceb3d3 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.pdf diff --git a/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.tex b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.tex new file mode 100644 index 0000000000..0e73103648 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022-documentation.tex @@ -0,0 +1,945 @@ +\documentclass{article} + +% Source file of ndsu-thesis-2022 class documentation (ndsu-thesis-2022-documentation.tex). The images used (3 total) are stored in /figures/ subfolder. + +%-------------------------------------------------------------- +\usepackage[nonewpage]{imakeidx} +\makeindex[intoc, columnseprule, columns=3] +\usepackage[top=1in,bottom=1.2in,left=1in,right=1in,letterpaper]{geometry} +\usepackage{verbatim} +\usepackage{tocloft} +\usepackage{xparse} +\usepackage{xspace} +\usepackage{xcolor} +\usepackage{booktabs} +\usepackage{graphicx} +\usepackage{siunitx} +\usepackage{soul} +\usepackage[colorinlistoftodos,prependcaption,textsize=scriptsize]{todonotes} +\usepackage{tikz} +\usepackage{multicol} +\usepackage[hidelinks]{hyperref} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\graphicspath{{./figures/}} + +\newcommand\cmd[1]{\textbackslash\texttt{#1}} +\newcommand\tb\textbackslash +\definecolor{newtext}{rgb}{0.1,0.6,0.1} +\newcommand\nt[1]{\textcolor{newtext}{#1}\xspace} % annotation command +\newcommand\dt[1]{\textcolor{red}{\st{#1}}\xspace} % annotation command +\newcommand\rt[2]{{\textcolor{red}{\st{#1}}}{\textcolor{newtext}{#2}}\xspace} % annotation command +\newcommand\notes[1]{\vspace{2ex}\todo[color=green!35, inline]{#1}} % todo notes +\newcommand\ix[1]{#1\index{#1}} % shortcut for index - #1 twice to retain text +\newcommand\ixt[1]{#1\index{\texttt{#1}}} % shortcut for index - #1 twice to retain text +\newcommand\ixl[1]{#1\lowercase{\index{#1}}} % shortcut for index +\newcommand\ixm[2]{#2\index{#1!#2}} % shortcut for index - muti level +\newcommand\ixmt[2]{\index{#1!\texttt{#2}}} % shortcut for index - mutilevel +\setlength{\parindent}{0.3in} + +\newcommand\ccmd[1]{ % shortcut for centered commands +\begin{center} +\begin{tabular}{l} +#1 +\end{tabular} +\end{center} +} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\title{\vspace{-1.5cm}Using the \texttt{ndsu-thesis-2022} \LaTeX\/ class --- Documentation} +\author{Aaron Feickert$\,^{a}$, Jonathan Totushek$\,^{a}$, and C. Igathinathane$\,^{b,\,*}$ \\ *\,Maintainer, Bug Reports and Enquires: Igathinathane Cannayen (\texttt{i.cannayen@ndsu.edu}) +} +\date{{\small $^{a}$\emph{Department of Mathematics, NDSU} \\ $^{b}$\emph{Department of Agricultural and Biosystems Engineering, NDSU}\\[2ex]} +12 July 2022} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\begin{document} +\maketitle + +\hrule +\begin{multicols}{2} +\scriptsize +\tableofcontents +\end{multicols} +\hrule + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Introduction} +The \texttt{ndsu-thesis-2022} \LaTeX\ is an updated version of the previous \texttt{ndsu-thesis} \ix{class} file. This class generates disquisitions intended to comply with the disquisition requirements of the North Dakota State University (NDSU) Graduate School. This class is not officially endorsed by NDSU or the NDSU Graduate School, but efforts are underway toward that goal. Since disquisition requirements are subject to change at any time, the user is advised that the most current disquisition style policies supersede this class. However, following the Graduate School approved template and several previously approved dissertations, this \LaTeX\ class was coded to incorporate the various required features and lessons learned while preparing theses/dissertations that got approved using the previous class in developing this version of the class. To ensure compliance with all NDSU Graduate School requirements, the user is encouraged to consult the NDSU Graduate School webpage and the links provided for detailed requirements and guidance on disquisition formatting guidelines, templates, section formatting, and examples (\url{https://www.ndsu.edu/gradschool/current_students/graduation/theses_dissertations_papers/disquisition_formatting}). + +The bundled \ix{template} or the \ix{example} provided at the end can be used as an easy starting point for start using the class. Modification of the class file's code may result in unexpected behavior and is at the user's own risk. We recommend including additional packages and commands in the source file (*.tex) itself for the desired customization. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Using and installing \LaTeX\ --- online and desktop environments} \index{online editor} \index{standalone editor} +Several online (e.g., Overleaf, Kile LaTex Editor, Authorea, Papeeria, and so on) and standalone desktop versions (e.g., TeXMaker, TeXWorks, TexShop, TeXStudio, and so on) of \LaTeX\ editors are available. Online editors are ``ready-to-go,'' with several templates, tutorials, and help documentation, where the user need not install the software but require an internet connection. The desktop version requires software installation and updating (not very frequent). Resources (text and video instructions) are available on both how to use the online editor and install the \LaTeX\ desktop version of users' choice. As \LaTeX\ is open source, most of these editors are free. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Documentclass Options} +These are the \ix{options} passed to the \ix{documentclass} command while calling the class. These options essentially affect the whole document and a \ix{default behavior} (no options specified, shown below) was also valid. +\ccmd{\cmd{documentclass\{ndsu-thesis-2022\}}} +The above default behavior with no \texttt{[options]} specified produces a Ph.D. dissertation in 12 pt font size with auto-numbered heading and justified text in computer modern font. However the command:\vspace{-2ex}\ccmd{\cmd{documentclass[ms-thesis,11pt,nonumber,nojustify,draft,showframe,times]\{ndsu-thesis-2022\}}} produces an M.S thesis in 11 pt font size unjustified paragraphs text with unnumbered heading in draft mode in Times Roman font and shows the frame using the set margins. The order in which these options are passed does not matter. The various options are briefly discussed subsequently. + +%-------------------------------------------------------------- +\subsection{Disquisition degree and type} +\label{degtype} +By default, this class assumes the document is a Ph.D. dissertation. Providing a degree option will accommodate other available degree and disquisition types: +\begin{center} +\begin{tabular}{lll} +\toprule +Option & Degree & Disquisition type \\ +\midrule +\texttt{[\ixm{degree}{phd}]} & Ph.D. & Dissertation \\ +\texttt{[\ixm{degree}{ms-thesis}]} & M.S. & Thesis \\ +\texttt{[\ixm{degree}{ms-paper}]} & M.S. & Paper \\ +\texttt{[\ixm{degree}{ma-thesis}]} & M.A. & Thesis \\ +\texttt{[\ixm{degree}{ma-paper}]} & M.A. & Paper\\ +\bottomrule +\end{tabular} +\end{center} + +%-------------------------------------------------------------- +\subsection{Font size} +The general \ix{font sizes} used with thesis are 10, 11, and 12 points and they vary with the selected font. The available options (any of these used) are: +\ccmd{\cmd{documentclass[10pt (or) 11pt (or) 12pt]\{ndsu-thesis-2022\}}} +The default was set as {\tt{12pt}}. + +%-------------------------------------------------------------- +\subsection{Auto-numbered, chapter-numbered, and unnumbered styles} +The three possible NDSU thesis styles with options included are: (i) Auto-numbered [default option]--- where chapters, sections, subsections, and so on will be numbers; (ii) Chapter-numbered [\ix{chapternumber}]--- where only chapters are numbered, while sections, subsections, and so on will not be numbered; and (iii) Unnumbered [\ix{nonumber}]--- where all headings such as chapters, sections, subsections, and so on will not be numbered. + +As the default is the numbered style, the chapter-numbered and unnumbered styles were produced by the ``chapternumber'' and ``nonumber'' options respectively as: \ccmd{\cmd{\ix{documentclass}[chapternumber (or) nonumber]\{ndsu-thesis-2022\}}}. The default was the ``Auto-numbered'' style. These options will have their specific effect on the numbering scheme of the tables and figures. + +%-------------------------------------------------------------- +\subsection{Paragraph text justification} +Based on their preference students can follow \ix{fully-justified} (with hyphenated words and word wrapping) or unjustified (no word breaking but right margin ragged, aka left-justified). As the default is justified, the \ix{left-justified} passages were produced by the \texttt{[\ix{nojustify}]} option. For justified style, nothing needs to be specified. NDSU approves both styles. + +%-------------------------------------------------------------- +\subsection{Draft and display \ix{document frames}} +You can use the \texttt{[\ix{draft}]} option to place the disquisition into draft mode. In this mode, \ix{margin overflows} are marked with a heavy black box to draw your attention to them; additionally, images are replaced by a \ix{placeholder} (see Fig.~\ref{fig:frame}). If you import other packages in your disquisition, they may also change their behavior when in draft mode. + +\begin{figure}[h!] +\centering +\vspace{-0.8ex} +\includegraphics[width=0.525\textwidth]{fig-draftmargin.pdf} + \caption{Use of \texttt{draft} and \texttt{showframe} options in \texttt{documentclass} producing image placeholder for quicker processing, document frames, and margin overflows.} +\label{fig:frame} +\end{figure} + +\indent The \texttt{[\ix{showframe}]} option (based on \texttt{\ix{geometry}} package) produces a frame around the text area which can be used to check how the text aligns with the margins (left, right, top, and bottom; see figure above). The illustration alongside displays the result of these options showing the overflowing text, bottom \ix{margin frame}, right margin frame, margin notes frames, and the \ix{overflow} heavy black box. The default behavior is these options were inactive. + +%-------------------------------------------------------------- +\subsection{Fonts} +The following \ix{font options} \texttt{[\ixm{font}{bookman}, \ixm{font}{charter}, \ixm{font}{gentium}, \ixm{font}{kpfonts}, \ixm{font}{libertine}, \ixm{font}{mathdesign}, \ixm{font}{mathptmx}, \ixm{font}{newcent}, \ixm{font}{palatino}, \ixm{font}{tgtermes}, \ixm{font}{times}, \ixm{font}{tgbonum}, \ixm{font}{tgpagella}, \ixm{font}{tgschola}, \ixm{font}{utopia}, \ixm{font}{zlmtt}]} are compatible with the class, and anyone can be used. The default was \LaTeX\ computer modern font. Users are urged to check the NDSU approved fonts and select that resembles them and use them with appropriate font sizes. + +%-------------------------------------------------------------- +\subsection{Advanced options}\label{adop} +Although not required for simple work, a few class options were made available to further automate the dissertation writing. The first option is \texttt{[\ix{chaptersbib}]}. This is intended to produce individual chapter bibliography and should only be used with Bib\LaTeX\/ and BibTeX will not support chapters bibliography --- based on this class. This option works with chapters processed as ``\ix{subfiles},'' where those chapters can be individually compiled and output generated. + +The second option is \texttt{[\ix{subfileref}]}. Subfiles, usually individual chapters, can be processed individually following the same style of the whole document. The information in the preamble of the main dissertation document (that pulls in and assembles all the chapters of the dissertation in individual files) was again derived and used as the preamble of the subfile. The required package ``\texttt{subfiles}'' was included in the class. For each chapter to be standalone, like a paper, the chapter should have the relevant bibliography as the last unnumbered section/chapter, and using this option in the main document will accomplish this. This option work with both Bib\LaTeX\/ and \ix{BibTeX}. The whole dissertation processing, obtaining contents from these individual subfiles, with intended combined bibliography chapter, should not also produce the individual chapters bibliography, therefore this option should not be used. Refer to the additional example in the class bundle that shows the necessary codes in the main and chapter files. + +The following table shows the various outcomes given the options: + +\begin{center} +\begin{tabular}{lp{4in}} +\toprule +Option & Outcomes \\ +\midrule +\texttt{[\ix{chaptersbib}]} only & Dissertation with individual chapters bibliography. Works with Bib\LaTeX\/ only. \\ +\texttt{[subfileref]} only & For individual chapter processing with bibliography. Works with both Bib\LaTeX\/ and BibTeX.\\ +\texttt{[]} none --- default & Dissertation with a combined bibliography as an unnumbered chapter. \\ +\texttt{[chaptersbib,subfileref]} both & \emph{Don't use}. Possible redundant bibliographies. Requires Bib\LaTeX\/. \\ +\bottomrule +\end{tabular} +\end{center} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Preamble Information} + +%-------------------------------------------------------------- +\subsection{General information - packages and shortcuts} +If your disquisition requires the use of additional \LaTeX\ packages, macro files, or other commands, include them in the preamble. Packages such as \texttt{\ix{natbib}} (author-year and number style citations) or other competent reference handling packages and their options can be loaded. Similarly, mathematical \ix{theorem environment}-related commands (theorem, corollary, lemma) through \cmd{newtheorem} of \texttt{amsthm} package, \texttt{caption} package setups through \cmd{captionsetup[\emph{type}]\{\emph{options}\}}, where \emph{\texttt{type}} = table, figure, or subfigure, and other shortcuts for repetitive longer commands or text can be defined in the preamble. As these are specific to the users and the requirements vary with the users of different specializations, these were not included in the class. Therefore suitable packages, commands, and shortcuts can be defined by the users. + +%-------------------------------------------------------------- +\subsection{Dissertation front pages} +Before issuing the \cmd{begin\{document\}} command, several pieces of preamble information are available. + +%-------------------------------------------------------------- +\subsubsection{Title} +Include the \ix{title} of the disquisition using the \cmd{title\{\ldots\}} command. This is required. + +%-------------------------------------------------------------- +\subsubsection{Author} +Include the full name of the disquisition \ix{author} using the \cmd{author\{\ldots\}} command. This is required. + +%-------------------------------------------------------------- +\subsubsection{Major \ix{department}/\ix{program} choice} +Specify whether it is ``Department'' or ``Program'' that is applicable using the \cmd{progdeptchoice\{\ldots\}} command. This will produce ultimately ``Major Department:'' or ``Major Program:'' based on the input choice. This is required. + +%-------------------------------------------------------------- +\subsubsection{Department or program} +Include the name of the major \ix{department} or \ix{program} using the \cmd{department\{\ldots\}} command. This is required. + +%-------------------------------------------------------------- +\subsubsection{Degree option} +If the major department or program has a \ix{degree} option, indicate this using the \cmd{degreeoption\{\ldots\}} command. This is optional. + +%-------------------------------------------------------------- +\subsubsection{Date} +Include the date of the final examination using the \cmd{\ix{date}\{\ldots\}} command. The accepted format of this date is \textit{month year} as: \cmd{date\{October 2022\}}. This is required. + +%-------------------------------------------------------------- +\subsubsection{Examining committee} +Include the Chair (or Co-Chairs) and members of the examining committee using separate commands. The \cmd{\ix{cchair}\{\ldots\}} command is used to indicate the committee Chair. Use \cmd{\ix{cochairZ}\{\ldots\}} to indicate any committee Co-Chair members, where \texttt{Z} is \texttt{a} or \texttt{b}. This class does not support more than two Co-Chairs and four Committee Members. Use the \cmd{cmemberX\{\ldots\}} to indicate other committee members, where \texttt{X} is \texttt{a}, \texttt{b}, \texttt{c}, or \texttt{d}. Use only as many of these commands as needed to list all committee members. + +%-------------------------------------------------------------- +\subsubsection{Approval information} +Use the \cmd{approvaldate\{\ldots\}} command to include the full date of \ix{disquisition approval} (i.e. month/date/year). This date is generally the date the thesis was approved by the Department Chair following the defense after the approval (usually electronically) of all committee members. Use \cmd{approver\{\ldots\}} to include the Department Chair who approved the disquisition. Both commands are required. + +%-------------------------------------------------------------- +\subsection{Dissertation front matter} + +\subsubsection{Abstract} +Use the \cmd{\ix{abstract}\{\ldots\}} command to include the disquisition abstract. Abstracts for doctoral dissertations must use 350 words or less. Abstracts for master's papers or master's theses must use 150 words or less. This is required. + +%-------------------------------------------------------------- +\subsubsection{Acknowledgements} +If the disquisition includes \ix{acknowledgements}, include them using the \cmd{acknowledgements\{\ldots\}} command. This is optional. + +%-------------------------------------------------------------- +\subsubsection{Dedication} +If the disquisition includes a dedication, include it using the \cmd{\ix{dedication}\{\ldots\}} command. This is optional. + +%-------------------------------------------------------------- +\subsubsection{Preface} +If the disquisition includes a \ix{preface}, include it using the \cmd{preface\{\ldots\}} command. This is optional. The NDSU guidelines state: +\begin{quote} +``\emph{The Preface can provide an autobiographical account of how the disquisition came to be or include a significant quote that drove your research. Follow the General Requirements for font, spacing, and page numbers for prefatory materials.}'' +\end{quote} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Automatic Components} +Several \ix{automatic components} will be generated, as a part of the front matter, based on the source code of the dissertation and are briefly described. Based on the department, requirement, and style of the thesis some of the items such as, lists of abbreviations, symbols, and appendix tables and figures (Secs.~\ref{sloa}--\ref{sloat}) may be dropped from the coding. + +%-------------------------------------------------------------- +\subsection{Table of contents} +The \ix{table of contents} (\ix{TOC}) gets automatically generated with entries up to three levels sections (\cmd{subsection}). The dissertation may have further levels of sections but they are not shown in the TOC. + +%-------------------------------------------------------------- +\subsection{List of \ix{table}s and \ix{figure}s} +The \ix{list of tables} (\ix{LOT}) and \ix{list of figures} (\ix{LOF}) will be generated based on the table and figure full captions in the \texttt{table} and \texttt{figure} environments. New commands for handling figures such as \cmd{myfig\{1+5 arguments\}}, and \cmd{myfigls\{1+5 arguments\}} with their own \texttt{[optional]} argument to adjust the position of the caption with respect to figure element were defined. + +%-------------------------------------------------------------- +\subsection{List of abbreviations}\label{sloa} +The collection of abbreviations used in the dissertation can be made in to a \ix{list of abbreviations} (\ix{LOA}) using the \cmd{listofabbreviations\{\ldots\} command. This collection should be alphabetized before coding. This will be a two-column tabular entry. A two entry example of LOA code and the output are shown below: +\begin{tabbing} +xxxx\= \kill +\> \cmd{listofabbreviations\{} \\ +\> \texttt{AC \& Alternating current\tb\tb} \\ +\> \texttt{NDSU \& North Dakota State University\}} +\end{tabbing} +} +{\vspace*{-0.65in}\hspace*{3.7in}\includegraphics[width=0.45\textwidth]{fig-LOA.pdf}} + +%-------------------------------------------------------------- +\subsection{List of symbols}\label{slos} +The collection of all technical symbols used in the dissertation, usually coded in ``math'' mode, can be made into a \ix{list of symbols} (\ix{LOS}) using the \cmd{listofsymbols\{\ldots\}} command. This collection should be alphabetized before coding and math mode should be used as required. This will be a two-column tabular entry. A three-entry example of LOS also using the \texttt{siunitx} package and the output are shown below: +\begin{tabbing} +xxxx\= \kill +\> \cmd{listofsymbols\{} \\ +\> \texttt{\$A\$ \& Area (\tb si\{\tb m\tb squared\}) \tb \tb} \\ +\> \texttt{\$c\$ \& Speed of light (\tb SI\{299.792\}\{\tb km\tb per\tb s\})\tb \tb} \\ +\> \texttt{\$R\^{}2\$ \& Coefficient of determination}\} +\end{tabbing} +{\vspace*{-0.8in}\hspace*{3.95in}\includegraphics[width=0.5\textwidth]{fig-LOS.pdf}} + +%-------------------------------------------------------------- +\subsection{List of appendix tables and figures}\label{sloat} +The \ix{list of appendix tables} (\ix{LOAT}) and \ix{list of appendix figures} (\ix{LOAF}) will be generated based on the appendix table and figure full captions in the \texttt{appendixtable} and \texttt{appendixfigure} environments. New commands such as \cmd{myfigap\{5 arguments\}} and \cmd{myfigapls\{5 arguments\}} plus one \texttt{[optional]} argument for adjusting the caption placement for regular and landscape figures were defined. + +The \cmd{\ix{closeappendices}} command should be issued at the end of the last appendix, which ensures the automatic creation of the LOAT and LOAF when the appendices had tables and figures. If the appendices had only tables or only figures then the commands \cmd{closeappendixtables} or \cmd{closeappendixfigures} should be used to avoid blank entries. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Beginning the Document} +After including the necessary preamble information, use \cmd{begin\{document\}} to start the \ix{document}. This command automatically generates the necessary cover pages and other automatic components. The usual \cmd{\ix{maketitle}} command should not be used, as it was already issued in the class. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Headings}\label{heading} +Major headings (e.g. chapters) are issued using the \cmd{myheading\{\ldots\}} command. This command supersedes the usual \cmd{\ix{chapter}} command, which should not be used. The following shows the hierarchy of headings: +\ccmd{ +\cmd{\ixm{heading}{myheading}\{\ldots\}} \hspace{0.6in} Produces all-caps chapter headings automatically - 0th level\\ +\cmd{\ixm{heading}{mypaperheading}\{\}\{\}\{\}} \hspace{2.9ex} Produces all-caps paper chapter headings with footnote - 0th level\\ +\cmd{\ixm{heading}{section}\{\ldots\}} \hspace{0.74in} Produces centered, bold headings (use title case) - 1st level\\ +\cmd{\ixm{heading}{subsection}\{\ldots\}} \hspace{0.52in} Produces left-aligned, bold headings (use title case) - 2nd level\\ +\cmd{\ixm{heading}{subsubsection}\{\ldots\}}\hspace{0.35in} Produces left-aligned, bold, italic headings (use sentence case) - 3rd level\\ +\cmd{\ixm{heading}{paragraph}\{\ldots\}}\hspace{0.64in} Produces left-aligned, italic headings (use sentence case) - 4th level +} + +Each \cmd{myheading\{\ldots\}} or \cmd{mypaperheading\{3 args\}} command starts a new page and entry in the table of contents. The regular chapter command is simple and takes one argument which is the title of the chapter as \cmd{myheading\{title\}}. The paper-styled chapter takes three arguments that address the title and footnote as + \cmd{mypaperheading\{title\}\{footnotemark\}\{footnotetext\}}. The \texttt{title} is common to both styles and will be rendered as all-caps irrespective of the input. The \texttt{footnotemark} usually be an asterisk (*), but can be any valid footnote mark including math symbols. The footnote mark will be used in the footnote text but will not feature in the TOC. The footnote text will be rendered as a footnote on the same page and automatically uses the input footnote mark. + +In general, the paper-styled chapter requires an ``Abstract'' section (title coded as a section), while the regular chapter does not. The class is coded to produce a consistent space between the title and the text (or section) below the title; however when necessary \cmd{vspace\{+ve or -ve\}} can be issued before the plain introductory text or section command to adjust this vertical space. + +Instances of \cmd{subsubsection\{\ldots\}} and \cmd{paragraph\{\ldots\}} do not appear in the TOC, though they are included in the document. Other than the chapter headings, the rest of the item headings should be coded by the user manually with appropriate capitalization (title and sentence cases). + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Dummy Text and Images}\index{dummy text} \index{dummy images} +Users will be curious to see what their thesis/dissertation will look like quickly without using the actual texts and figures. The class comes loaded with necessary packages such as \texttt{kantlipsum}\index{kantlipsum} (for dummy text --- philosophical prose paragraphs in English) and \texttt{mwe}\index{mwe} (``minimal working examples'' for dummy images). These will help visualize the whole document (fonts, spacings, and layout) with minimal effort, and this is a common practice among the typesetters to use such dummy text and images. Commands from these packages are used in the thesis example (Sec.~\ref{example}). + +Commands like \cmd{kant[1]} or \cmd{kant[4-8]} will produce single or multiple dummy text paragraphs. Similarly, dummy images included in the \texttt{mwe} package can be accessed using their specific names and can be used as the image argument in the \cmd{includegraphics} command, which means that the user need not use their images. Some of the commonly used examples images are: \texttt{example-image}, \texttt{example-image-a}, \texttt{example-image-b}, \texttt{example-image-c}, \texttt{example-image-16x10}, \texttt{example-image-golden}, \texttt{example-image-pl} \texttt{ain}, \texttt{example-image-duck}, \texttt{example-image-empty}, and \texttt{example-} \texttt{grid-100x100pt}\index{example images}. Refer to the documentation of these packages for further information. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Tables and Figures} +\subsection{Tables} +Different kinds of tables, such as simple table without caption (\texttt{\ixm{table}{tabular}}), table with \ixm{table}{caption} (\texttt{table}), table with \ixm{table}{footnote} (\texttt{\ixm{table}{threeparttable}}), table spanning entire text width (\texttt{\ixm{table}{tabu}}), table spanning multiple pages (\texttt{\ixm{table}{longtable}}), and table in \ixm{table}{landscape} page (\texttt{\ixm{table}{pdflscape}}) can be coded following the documentation of respective packages, and no shortcuts were defined as they were not practical. Using \texttt{\ixm{table}{booktabs}} package professional quality tables (Sec.~\ref{degtype}) can be created. + +%-------------------------------------------------------------- +\subsubsection{Full-width tables --- tabu environment}\index{table!full-width} +Full-width tables are suggested for NDSU theses/dissertations. A quick and efficient method of creating tables that automatically span the entire textwidth is the use of \texttt{tabu} environment instead of the usual \texttt{tabular} inside the \texttt{table} environment. The \texttt{tabu} environment uses a special column justification code X (default \& options). This X code allots fixed column width based on the number of columns specified (default) and customizes individual columns' proportional width using coefficients with options. The \texttt{tabu} also takes the usual \texttt{l, c, r,} and \texttt{p} justification codes as well as the commands of \texttt{booktab} in the usual manner. The \texttt{tabu} environment has several special features such as, specifying exclusive \texttt{math} mode column (no \$ symbols required for individual items), SI units features, colored lines and cells, and so on (See package documentation). + +%-------------------------------------------------------------- +\subsubsection{Full-width tables --- manual method} \index{table!full-width} +However, for the best control of tables, especially with more columns, a combination of \cmd{resizebox} (resizing the entire table - mostly for scaling down) and \cmd{tabcolsep} (maintaining the column separation space) works the best. Thus, the command \cmd{\ixm{table}{resizebox}\{\cmd{\ixm{table}{columnwidth}}\}}\{!\} makes the table to span the entire text width of the page. This will expand or shrink the contents of the table to fit the entire width. It should be fine with the fonts shrink to fit the width, but will not be when the fonts enlarge (especially when the table is small and has only a few columns). In such situations, the space between the columns can be adjusted using the \cmd{\ixm{table}{tabcolsep}\{\ldots\}} command, where increased spacing reduces the font size and \emph{vice versa}. Thus, by using these commands (including \texttt{tabu}) in combination the tables and the font size can be scaled down to fit the page with the proper font size. + +%-------------------------------------------------------------- +\subsubsection{Table row spacing and fonts} +The row spacing can be adjusted, if desired, using \cmd{renewcommand}\{\cmd{\ixm{table}{arraystretch}}\}\{\ldots\} inside the table environment. For example, a value of 1.75 for the arraystretch will be similar to the double line spacing; and without this command, the row spacing will be single line spacing. Table footnotes can be added through \texttt{\ixm{table}{tablenotes}} environment placed inside \texttt{table} environment after the \texttt{tabular} and \texttt{resize} blocks. The font size can be altered by selecting the standard sizes (e.g., \cmd{footnotesize}, \cmd{small}) within the \texttt{tablenotes} environment. + +%-------------------------------------------------------------- +\subsubsection{Landscape tables} +When a table has more columns of information, the most common solution is the landscape orientation which is achieved through \texttt{\ixm{table}{landscape}} environment by enclosing the \texttt{table} codes (which may contain other elements) inside \texttt{landscape} environment block (between \cmd{begin\{landscape\}} and \cmd{end\{landscape\}}). With landscape usually the placement option will be [p] and the whole width should be set around 1.32 times the \cmd{\ix{columnwidth}}, or adjusted suitably to leave acceptable margins all around. + +%-------------------------------------------------------------- +\subsection{Figures}\label{figs} +It should be noted that the manual coding of figures using ``\texttt{figure}'' environment with \cmd{\ixm{figure}{includegraphics}\{\ldots\}} \ixm{figure}{centering}, \ixm{figure}{resize}, \ixm{figure}{caption} and \ixm{figure}{label}s is the direct approach. + +%-------------------------------------------------------------- +\subsubsection{Shortcuts for figures --- direct and optional} +However, for convenience, a set of single command shortcuts, with five arguments plus one optional argument are defined. These commands specify (1) [optional] vertical placement of the caption (moving it up and down with respect to the bottom of the figure, especially for images with excessive or too less whitespace), (2) placement, (3) size factor, (4) input file, (5) caption, and (6) label were defined to produce figures (regular and landscape). The default caption's \texttt{aboveskip} is \verb|0ex|, and this value can be changed using the optional argument. Following are the examples of figure shortcuts for regular and landscape figures without and with the optional argument. These shortcuts are automatically included in the LOF and LOT that appear after the TOC. \index{figure!myfig} \index{figure!myfigls} + +\begin{flushleft} +\hspace{0.2cm} +\begin{minipage}{0ex} +\begin{verbatim} + \myfig{ht}{0.7}{image1.jpg}{Caption for this regular figure}{fig:1} + \myfig[1.5ex]{ht}{0.7}{image1o.jpg}{Figure caption with placement option}{fig:1o} + + \myfigls{p}{1.32}{image2.pdf}{Caption for this landscape figure}{fig:2ls} + \myfigls[2ex]{p}{1.31}{image3.pdf}{Landscape figure caption with placement option}{fig:3ls} +\end{verbatim} +\end{minipage} +\end{flushleft} + +%------------------------ +Sometimes, excessive spaces were observed above and below the figures and tables (floating elements) as well as equations with respect to the text around. The use of vertical spacing (+ve or -ve; e.g., \cmd{vspace\{4pt\}} and \cmd{vspace\{-6pt\}}) around the floating elements can help in the adjustment of their placements. \index{figure!placement} The \ix{vertical spacing} commands can be issued before and after these environments (as required) to fix the spacing. Coding tables and figures will automatically create the LOT and LOF. A similar approach can be used for appendix figures (Sec.~\ref{apfigtab}). + +%-------------------------------------------------------------- +\subsection{Captions} +Because of the way spacing is handled, \ix{caption}s in \texttt{table} environments must appear at the top of the table, while captions in \texttt{figure} environments must appear at the bottom of the figure. If you use both \cmd{caption} and \cmd{label} commands in these environments, the \cmd{caption} command must come before the \cmd{label} command to ensure the environment is numbered correctly. The captions are coded in such a way that shorter ones are centered and longer ones are left-justified; however, as default the table captions are left-justified and can be changed, as outlined subsequently, to fit the requirement. The style of the caption can be basic or specific to the department, usually following the parent technical society's leading journal. The style of labeling (e.g., regular \emph{vs} bold \emph{vs} italic, naming: Fig. \emph{vs} fig. \emph{vs} Figure, etc.) can also be adopted from the leading journal. The various options available for caption using the \texttt{caption} package (already loaded) can be set through the \cmd{\ix{captionsetup}\{\ldots\}} command. The common options are \texttt{position, skip, belowskip, aboveskip, font, labelfont, labelsep, singlelinecheck, format, justification,} and so on. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Equations} +About handling \ix{equation}s, the NDSU's guidelines state ``When coding equations, the guidelines call for the equation to be center-aligned, with the equation number aligned flush with the right margin.'' The strong suit of \LaTeX\ is the professional manner it typesets the equations and mathematical elements. Show below is the distance formula that was defined and referred (eq.~\ref{eq:1dist}), which satisfies NDSU's guidelines: +\begin{equation} +\text{Distance formula:} \quad d = \sqrt{(y_2-y_1)^2+(x_2-x_1)^2} +\label{eq:1dist} +\end{equation} +\noindent where, $d$ is the distance; and $x_1, y_1, x_2$ and $y_2$ are the coordinates of the two points. The equations can be displayed (e.g., eq.~\ref{eq:1dist}) produced by \$\$\ldots\$\$ or \textbackslash[\ldots\textbackslash] or \texttt{equation} environment; and the inline as: $ax^2 + bx + c = 0$ produced by \$\ldots\$ or \textbackslash(\ldots\textbackslash). There exists several other commands are available to produce the equations through several packages (e.g., \texttt{align, array, eqnarray, gather, split}) and any imaginable mathematical information can be coded. Also \LaTeX\ supports a huge list of symbols (Refer: The Comprehensive \LaTeX\ Symbol List; 18,150 symbols; 449 pages) that can be used in general text or equations. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{References/Bibliography} +The two most common bibliography management systems are \ixm{bibliography}{BibTeX} and \ixm{bibliography}{Bib\LaTeX\/}; the former being simpler and the latter being modern and highly versatile. Reference or bibliography chapter or section can be combined into a \ixm{bibliography}{stand-alone chapter} (whole) or the reference listing can be included in all \ixm{bibliography}{individual chapters}. The bibliography listing in individual chapters sometimes desired by the user can be easily coded using the advanced Bib\LaTeX, which is also coded in the class. Both systems (individual or whole) use the same reference data in the form of \texttt{*.bib} file. The authors recommend using any of the systems by appropriately employing the system-specific commands. \index{bibliography!individual chapter} \index{bibliography!whole} + +%-------------------------------------------------------------- +\subsection{Using \ix{BibTeX}} + +%-------------------------------------------------------------- +\subsubsection{Cite while you write (CWYW) using natbib}\ +The \texttt{\ix{natbib}} package for bibliography management is widely used and very stable and follows the CWYW paradigm. The package produces both author-year and numerical citations. The commands like \cmd{citep\{\ldots\}} citation in parenthesis and \cmd{citet\{\ldots\}} citation in running text are quite useful in particular. These commands will produce the following outputs, for example: ``(Author et al., 2022)'' and ``Author et al. (2022) found \ldots''. The compatible styles (\texttt{*.bst}) with \texttt{natbib} and NDSU class are: \texttt{plainnat, abbrvnat, unsrtnat, rusnat, agsm, chicago, apalike}, and so on. For other commands, the \texttt{natbib} package documentation should be referred. As \texttt{natbib} is an optional bibliography system, it was not coded in the class, and to use \texttt{natbib} the following code should be in the preamble: +\ccmd{ +\cmd{usepackage[sort\&compress]\{natbib\}}\\ +\cmd{\ixm{bibliography}{citestyle}\{arms\} \% plain, agu, egu, arms, agms, dcu, kluwer, cospar, nature} +} + +It is convenient to load the \texttt{natbib} package with minimal options, as shown above, and choose predefined \cmd{citestyle\{option\}} options producing several styles defined in the package. It is also possible to load the package with the options directly as well in one command. + +%-------------------------------------------------------------- +\subsubsection{Bibliography generation and files handling} +The two basic commands that is required to implement BibTeX system are: +\ccmd{ +\cmd{bibliographystyle\{\textit{style}\}} \\ +\cmd{bibliography\{\textit{name-of-bib-file}\}} +} + +However, a single shortcut command developed to replace the above is: +\ccmd{ +\cmd{\ixm{bibliography}{biblio}\{\textit{style}\}\{\textit{name-of-bib-file}\}} +} + +The ``style'' of bibliography (\texttt{.bst}) entries (typically \texttt{plainnat} or \texttt{apalike}), is controlled by the first argument; the user is referred to the BibTeX manual for formatting details and other available styles, such as those provided by the peer-reviewed journals related to the specialization. The ``name'' used in the second argument must be the same as the name of the bibliography (\texttt{.bib}) file, but with the extension removed. Once correct citation commands (\cmd{\ix{citep}\{\ldots\}} and/or \cmd{\ix{citet}\{\ldots\}}) are issued following CWYW, the citation with proper reference number or entry will appear in the text and listings in the proper style (based on *.bst) will be generated. The above shortcut generates an unnumbered chapter with the title REFERENCES (accepted by NDSU) and also a corresponding TOC entry. + +These commands (or equivalent commands if the user uses a different bibliography management system) are optional but are required if the disquisition includes references. Basic bibliography citation command is \cmd{cite\{\ldots\}}. +\index{bibliography!citep} \index{bibliography!citet} + +%-------------------------------------------------------------- +\subsection{Using \ix{Bib\LaTeX}} +The Bib\LaTeX\/ package provides advanced bibliographic facilities for use with LaTeX. Good working knowledge in LaTeX should be sufficient to design new bibliography and citation styles using this system. The Bib\LaTeX\/ works with the backend (program) ``\ixm{Bib\LaTeX\ }{biber}'', which is used to process the bibliography data files and then performs all sorting, label generation, and many more operations. This package also supports subdivided bibliographies, multiple bibliographies within one document, customizable sorting, \ixm{Bib\LaTeX\ }{multiple bibliographies} with different sorting, customizable labels and bibliographies may be subdivided into parts and/or segmented by topics. Users are urged to refer to the package documentation for various features (\url{https://ctan.org/pkg/biblatex?lang=en}). + +%-------------------------------------------------------------- +\subsubsection{Commands, cite, bibliography generation and files handling} + +The basic commands that invoke the Bib\LaTeX\/ system, which has to be issued in the preamble, are: +\ccmd{ +\cmd{usepackage[style=apa,natbib=true,backend=biber]\{biblatex\}}\\ +\cmd{\ixm{Bib\LaTeX\ }{addbibresource}\{\textit{name-of-bib-file}\}} +} + +In the above Bib\LaTeX\/ command's option the bibliography information processing program ``biber'' was used as a backend program. The options also loads ``apa'' style and ``natbib'' handling (allowing the \cmd{citep\{\ldots\}} and \cmd{citet\{\ldots\}} commands in Bib\LaTeX\/ ) as an example. The documentation and other resources (\url{http://tug.ctan.org/info/biblatex-cheatsheet/biblatex-cheatsheet.pdf}) may be referred for common \ixm{Bib\LaTeX\ }{options} and details of the package. The compatible styles used with Bib\LaTeX\/ are: \texttt{numeric, numeric-comp, alphabetic, authoryear, authoryear-icomp, authortitle, verbose, reading, \\draft, apa, chem-acs, chem-angew, chem-biochem, chem-rsc, ieee, mla, musuos, nuture, nejm, phys, science,} and \texttt{oscola}. Users can use an appropriate style to match their specialization style guide. + +With the package and bib file(s) loaded and processed, the reference listing can be generated anywhere in the document by issuing: +\ccmd{ +\cmd{\ixm{Bib\LaTeX\ }{printbibliography}[heading=bibintoc,title=REFERENCES]} +} + +The options ``\texttt{heading=bibintoc}'' makes an unnumbered chapter and includes the heading in the TOC and ``\texttt{title=REFERENCES}'' changes the default title from BIBLIOGRAPHY to REFERENCES. The \cmd{printbibliography} command when issued at the end of the chapters will create a ``combined'' REFERENCES chapter. + +%-------------------------------------------------------------- +\subsubsection{Individual chapters bibliography (multiple)} +Sometimes it is desired to have a bibliography listing in every chapter, as the last unnumbered section, especially with the paper-style chapters. Chapters bibliography can be easily processed using Bib\LaTeX\/ than using \ix{BibTeX}. For the bibliography listings only drawn from individual chapters they have to be restricted in the \texttt{refsection} environment as: +\ccmd{ +\cmd{begin\{\ix{refsection}\}}\\[1ex] +\hspace{0.2in}\ldots Chapter's text starting with abstract, sections/subsections, and so on, \\ +\hspace{0.2in}with citations using \cmd{cite\{\ldots\}} and other citation commands \ldots \\[1ex] +\cmd{printbibliography[heading=subbibintoc,title=\{References\}]}\\ +\cmd{end\{refsection\}} +} + +The options of the \cmd{printbibliography} command such as ``\texttt{heading=subbibintoc}'' will make the bibliography as unnumbered section and also creates a corresponding TOC entry, while ``\texttt{title=References}'' renames the default title. \index{documentclass} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Appendix} + +%-------------------------------------------------------------- +\subsection{Single and multiple named appendices} +If the disquisition includes a single \ix{appendix} or multiple named appendices, one of two commands must be used to produce them. If the dissertation has only one appendix, use the \cmd{appendix} command to begin it. This command generates an un-lettered APPENDIX chapter that can have sections, subsections, and so on, as well as tables, figures, and other elements. + +If multiple named appendices are necessary, use the \cmd{\ix{namedappendices}\{\emph{\ldots}\}\{\emph{\ldots}\}} that can also contain other elements. Following are two examples of the named appendices: +\ccmd{ +\cmd{namedappendices\}\{A\}\{First named appendix title here\}}\\ +\cmd{namedappendices\}\{B\}\{Second named appendix title here\}} +} + +These appendix commands are optional but are required if the disquisition includes an appendix. The appendix must follow the unnumbered REFERENCES chapter. NDSU's guidelines on appendices only allow named appendices with letters (e.g., ``APPENDIX A'', ``APPENDIX B''), while numerical or other styles (``APPENDIX 1'', ``APPENDIX 2'', ``APPENDIX I'', ``APPENDIX II'', and so forth) are not accepted. + +It is necessary to generate the listing of appendices in TOC up to subsection level (A.1.1), similar to the regular chapters. To achieve this necessary codes were included in the class. + +%-------------------------------------------------------------- +\subsection{Appendix figures and tables}\label{apfigtab} +If the \ix{appendix} contains figures or tables, use the \texttt{\ixm{appendix}{appendixfigure}} and \texttt{\ixm{appendix}{appendixtable}} environments to generate them. These special environments ensure that the figures and tables appear in separate tables that appear after the table of contents. The usual \texttt{figure} and \texttt{table} environments should not be used in the appendix. The same rules for centering, captions, and labels used in normal \texttt{figure} and \texttt{table} environments apply to \texttt{appendixfigure} and \texttt{appendixtable} environments. It should be noted that the manual coding of \texttt{appendixfigure} is also possible with basic commands. + +Similar to figures handled in the regular chapters (Sec.~\ref{figs}), for appendix figures as well, single command shortcuts dealing with appendix figures and appendix landscape figures with necessary arguments and one optional argument for caption vertical placement, were defined to produce the figures. Following are the examples of figure shortcuts for appendix regular, and landscape figures: \index{appendix!myfigap} \index{appendix!myfigapls} + +\begin{flushleft} +\hspace{-0.2cm} +\begin{minipage}{0ex} +\begin{verbatim} + \myfigap{H}{0.6}{image_ap1.jpg}{Caption for this appendix regular figure}{fig:ap1} + \myfigap[12mm]{H}{0.6}{image_ap2.jpg}{Appendix landscape figure caption}{fig:ap2} + + \myfigapls{p}{1.32}{image_ap3.pdf}{Caption for this appendix landscape figure}{f:ap3ls} + \myfigapls[1.5ex]{p}{1.33}{image_ap4.pdf}{Appendix landscape figure caption}{f:ap4ls} +\end{verbatim} +\end{minipage} +\end{flushleft} + +%-------------------------------------------------------------- +\subsection{Closing appendices}\label{apfigtab} + When the last appendix does not contain the appendix table and figure, for the automatic creation of \ixm{appendix}{LOAT} and \ixm{appendix}{LOAF}, the \cmd{closeappendices} command should be issued in the overall code somewhere before \cmd{end\{document\}} after the last appendix. If the last appendix had both table(s) and figure(s), then issuing this command is not necessary but okay to issue it anyhow for completeness. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Thesis Example}\label{example}\index{example thesis} +Below is a brief example of an M.S. thesis that includes all required and several optional elements. An attempt was made to cover most of the aspects (prefatory items, chapters, sections, tables, figures, appendices, etc.) encountered during the preparation of disquisition using \LaTeX, therefore the example is relatively elaborate. This example M.S. thesis code shown is included in the file named ``\texttt{ndsu-example.tex}''. In this example, the examining committee includes the Committee Chair, no Co-Chairs, and only two additional Committee Members. For this example, \textsc{Bib}\TeX\ was used to manage references, which would be included in a file named \texttt{mybib.bib} separately. + +Another extended file named ``\texttt{NDSU-Thesis-Extended.tex}'' containing several additional comments and features was made available in the package folder as a supporting file. The code below (\texttt{ndsu-example.tex}) will also work when directly extracted (selected and copied) and compiled. + +\begin{verbatim} +%**********************************START +\documentclass[ms-thesis,12pt,mathdesign]{ndsu-thesis-2022} + +%Refer documentation (ndsu-thesis-2022-documentation.pdf) for various options and commands + +%**********************************Packages, newcommands, and other customization +\usepackage[sort&compress]{natbib} +\citestyle{egu} % plain, agu, egu, agms, dcu, kluwer, cospar, nature +\newcommand\tend{\tempend{apalike}{mybib}} + +%**********************************First and second page material +\title{The Title of My M.S. Thesis} +\author{Samuel Fargo Bison} +\date{January 2022} +\progdeptchoice{Department} % Use Department (or) Program +\department{Mathematics} + +\cchair{Prof. John Adams} % Use actual committee members names +\cmembera{Prof. Abraham Lincoln} +\cmemberb{Prof. George Washington} +\cmemberc{Prof. Theodore Roosevelt} % If 3rd not required - delete this line +\approvaldate{12/14/2022} +\approver{Prof. James Garfield} + +%**********************************Front matter +\abstract{This is the abstract for my thesis. \\ \emph{Abstracts for doctoral +dissertations must use 350 words or less. Abstracts for master's papers or master's +theses must use 150 words or less.}\\ \kant[16]} % dummy text + +\acknowledgements{I acknowledge people here. \\ \emph{Acknowledgements text should be +placed here.} \\ \kant[15]} + +\dedication{This thesis is dedicated to my cat, Mr. Fluffles.\\ \emph{This section +dedicates the disquisition to a few significant people. The text must be double-spaced +and aligned center to the page.} \\ Which is already taken care of by this \LaTeX\ class.} + +\preface{You can put a preface here. \\ \emph{This section is optional!} \\ \kant[14]} + +\listofabbreviations{% may use title case +AC & Alternating Current \\ +NDSU & North Dakota State University \\ +ZL & Zeta Level} + +\listofsymbols{% may use sentence case +$A$ & Area (\si{\m\squared})\\ +$e$ & Euler's constant (\num{2.718281828}) \\ +$R^2$ & Coefficient of determination} + +%**********************************Document start +\begin{document} + +%**********************************First chapter - paper style +\mypaperheading{The First Chapter - Paper Style - Long title of this technical paper}{*} +{This paper is planned to be submitted as a peer-reviewed article \ldots\ more information +about the author(s), title, \emph{journal}, to be added.} + +\section{Abstract11} +Paper-styled chapters will have abstracts. Abstract of this chapter goes here. \kant[1] + +\section{Section12} +This is the first section of the thesis (1st level: 1.2. Section). \kant[2] + +\section{Section13} +This is the second section of the thesis (1st level: 1.3. Section). \kant[3] + +\subsection{Subsection131} +This is the subsection text (2nd level: 1.3.1. Subsection). \kant[4] + +\subsubsection{Subsubsection1311} +This is the subsection text (3rd level: 1.3.1.1. Subsubsection). \kant[5] + +\paragraph{Paragraph13111} +This is the subsection text (4th level: 1.3.1.1.1. Paragraph). \kant[6] + +\section{Table and Figure} +This is the third section of the thesis (1st level: 1.4. Section). This section +illustrates the inclusion of a simple table (\cref{tab:1}) and a figure shown later. + +\begin{table}[h] +\centering +\caption{Table captions go at the top of the table. This was long caption of the table +included in the first chapter --- so that we see how it breaks into another line and +having a single spacing. Usually tables are of full-width and are demonstrated subsequently.} +\vspace{-1ex} +\begin{tabular}{clr} +\toprule +Number & Month & Days\\ +\midrule +1 & January & 31\\ +2 & February & 28\\ +3 & March & 31\\ +\bottomrule +\end{tabular} +\label{tab:1} +\end{table} \kant[7] + +Now the figure (\cref{fig:1}) illustrates an example figure from the \texttt{mwe} package. + +\myfig{H}{0.6}{example-image-duck}{Caption for this example image in this first chapter.} +{fig:1} \kant[8-9] + +%**********************************Second chapter - regular +\myheading{The Second Chapter - Regular Style - Long title for this chapter} + +Regular style chapters will not have abstracts. General information or outline of the +chapter is given here --- before breaking into sections. + +\section{Excellent Results} +This is another section of the thesis (1st level: 2.1. Experimental Results). +\Cref{tab:2} presents the results in a tabular form that spans the entire width. +Please note the results shown (\cref{tab:2}) are preliminary. + +\begin{table}[ht] +\centering +\caption{Table spanning entire width (full-width) using \texttt{setlength} and +\texttt{tabcolsep}} +\vspace{-1ex} +\setlength{\tabcolsep}{3.75em} +\begin{tabular}{@{\hspace{2ex}} lccr @{\hspace{2ex}}} +\toprule +Number & Name of month & Days & Season\\ +\midrule +4 & April & 30 & Spring\\ +5 & May & 31 & Summer\\ +6 & June & 30 & Summer\\ +\bottomrule +\end{tabular} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: The \texttt{tablenotes} environment produces table footnotes. +\end{tablenotes} +\label{tab:2} +\end{table} \kant[7-8] + +\subsection{Minor Results} +This is a subsection of the thesis (1st level: 2.2. Experimental Results). \kant[8] +The \Cref{fig:2} is an example image with command showing all arguments including the optional +caption placement. The example figure (\cref{fig:2}) is included in the \texttt{mwe} package. + +\myfig[2ex]{H}{0.5}{example-image}{Caption for this example image demonstrating an optional +2ex vertical spacing. Compare this with a narrow caption spacing without optional argument in +\cref{fig:1}.}{fig:2} +\kant[8] + +\section{Some References} +Referring to all entries in the ``\texttt{mybib.bib}'' file to generate the citations here +and the listing using the \texttt{\textbackslash citep\{\ldots\}} ``natbib'' command +(cite parenthesis)\citep{texbook,lcompanion,latex2e,knuth1984,lesk1977,amsthm2017, +calvo2004using,cannayen2011latex,kopka2004guide,notso2021}. + +The same using \texttt{\textbackslash citet\{\ldots\}} command (cite text) in the running +text as: The authors \citet{texbook,lcompanion,latex2e,knuth1984,lesk1977,amsthm2017, +calvo2004using,cannayen2011latex,kopka2004guide,notso2021} have something to do +with \LaTeX. For most bibliography citation and list creation, these two commands +are sufficient. + +%**********************************Bibliography handling +\biblio{apalike}{mybib} % Shortcut command using style and bib-file arguments + +%**********************************Named appendix A +\namedappendices{A}{Named first appendix} +Appendix material can be included here. First including a figure (fig.~\ref{fig:ap1}). + +\section{Appendix A - Section With Figure} +\myfigap{H}{0.5}{example-image-golden}{A golden ratio rectangle image.}{fig:ap1} \kant[8] + +\section{Appendix A - Section With Table} +And, then including a table (table.~\ref{tab:ap1}). + +\begin{appendixtable}[h!] +\centering +\caption{Use of \texttt{tabu} environment for full-width table - applicable to both main text +and appendix. Note the use of \texttt{booktabs} commands and `X' parameters to reproduce +Table~\ref{tab:2}. } +\begin{tabu} {X X[2, c] X[2,c] X[r]} %X[2, c] = coef. = 2, align = center +\toprule +Number & Name of month & Days & Season\\ +\midrule +4 & April & 30 & Spring\\ +5 & May & 31 & Summer\\ +6 & June & 30 & Summer\\ +\bottomrule +\end{tabu} +\begin{tablenotes}[flushleft] +\footnotesize +\item \hspace{-1ex} \emph{Note}: The \texttt{tablenotes} environment produces table footnotes. +Refer to \texttt{tabu} documentation for further details. +\end{tablenotes} +\label{tab:ap1} +\end{appendixtable} + +\subsection{Appendix A Subsection} +\kant[10] + +%**********************************Named Appendix B +\namedappendices{B}{Named second appendix} +Appendix material can be included here. First including a figure (fig.~\ref{fig:ap2}). + +\section{Appendix B - Section With Figure} +\kant[9] +\myfigap[0.5ex]{H}{0.7}{example-grid-100x100pt}{A $10 \times 10$ grid of different +concentric colors.}{fig:ap2} + +\section{Appendix B - Section With Table} +Now coding another appendix table (table.~\ref{tab:ap2}) that spans the entire width using +the manual method (using `tabcolsep' command; and `resize' command to fit large tables). + +\begin{appendixtable}[h] +\centering +\caption{Squares and cubes named appendix table using \texttt{siunitx} package.} +\setlength{\tabcolsep}{7.1ex} +\begin{tabular}{@{\hspace{2ex}} lcrr @{\hspace{2ex}}} +\toprule +Number & Square & Cubes & Fourth power\\ +\midrule +11 & 121 & \num{1331} & \num{14641}\\ +22 & 484 & \num{10648} & \num{234256}\\ +333 & \num{110889} & \num{36926037} & \num{12296370321}\\ +\bottomrule +\end{tabular} +\label{tab:ap2} +\end{appendixtable} + +\subsection{Appendix B Subsection} +\kant[11] + +\closeappendices % Closing (redundant) of appendices for LOAT and LOAF generation + +\end{document} +%**********************************END +\end{verbatim} + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Additional Information I --- Special Commands} + +%------------------------------------------- +\subsection{Whole document text spacing} +NDSU mandates double-spacing for the body paragraphs text. A default double-spacing setting in MS Word produces 23 lines per page while \LaTeX\ \cmd{\ix{doublespacing}} produces 27. Any of these lines per page defaults in the respective systems are acceptable. To recreate the line spacing of 23 lines per page in \LaTeX\ was produced by defining \cmd{newcommand\tb \ix{myspacing}\{1.9\}} in the preamble and issuing: +\begin{center} +\cmd{begin\{spacing\}\{\tb myspacing\}} \hspace{0.3cm} +\ldots All other text \ldots \hspace{0.3cm} +\cmd{end\{spacing\}} +\end{center} + +This \texttt{spacing} command should immediately follow \cmd{begin\{document\}} and closed just before the \\\cmd{end\{document\}}. Other values of \cmd{myspacing} will produce other spacings. The \cmd{myspacing} was not used in the ``Thesis Example'' (Sec.~\ref{example}) and the class by default produces 27 lines per page. + +However, for the front matter, the {\tt spacing} environment should be enclosed within the front matter component. For example, the abstract with different spacing (than the default 27 lines per page) should be coded as: + +\begin{center} +\cmd{abstract\{} \hspace{0.05cm} +\cmd{begin\{spacing\}\{\tb myspacing\}} \hspace{0.15cm} +\ldots Abstract text \ldots \hspace{0.2cm} \hspace{0.15cm} +\cmd{end\{spacing\}} \} +\end{center} + +A similar approach should be followed for other components such as \ix{acknowledgments}, dedication, and preface. + +%------------------------------------------- +\subsection{Annotation commands} +While developing the dissertation the text undergoes several revisions and suggestions will be provided by the advisor and colleagues. To make suggestions as well as to present the carried out revisions colored annotations will be helpful to draw users' attention quickly. Therefore, special annotation commands for \ix{highlighting}, \ix{new text}, \ix{deleted text}, \ix{replaced text}, and notes were defined in the class. These annotation features can be used by the student and the advisor reviewing the dissertation draft. The \texttt{soul} and \texttt{\ix{todonotes}} packages were used to develop these commands, and their documentation may be referred for customization. All the \ix{annotations} can be searched and deleted before submission, and these processes can be even automated by search expressions (e.g., regular expression). The annotation commands with usage are shown subsequently: + +\vspace{2ex} +\tb\texttt{hl\{Highlight\}} gives: \hl{Highlight}. This will be regular text. + +\tb\texttt{nt\{Test new text.\}} gives: \nt{Test new text.} This will be regular text. + +\tb\texttt{dt\{Deleted text.\}} gives: \dt{Deleted text.} This will be regular text. + +\tb\texttt{rt\{The text to be deleted\}\{Which will be replaced by this!\}} gives: + +\rt{The text to be deleted}{Which will be replaced by this!} This will be regular text again. + +\tb\texttt{notes\{To Do notes - for interactive communication!\}} gives: \notes{To Do notes - for interactive communication!} + +%-------------------------------------------------------------- +\subsection{Subfigures} + + Multiple figures (\ix{subfigures}) under a common caption can be handled through \texttt{subfig} package. The subfigures can be individually sized, captioned, labeled, and referenced. The sub-caption numbering is ``alphabetic'' by default (holds 26 --- and for more subfigures, other options are available) and will be automatically generated. The number of images that occupy a single row can be readily coded with commands, such as \cmd{\ix{subfloat}\{\ldots\}}, \cmd{hspace\{\ldots\}}, and newline (\tb\tb). Refer to accompanied class instructions for examples. + +%-------------------------------------------------------------- +\subsection{Flowchart - \ix{tikz} package} +Flowcharts, schemes, geometrical diagrams, circuit diagrams, and data visualization graphs are common in technical writing. These elements can be created elsewhere and included in the dissertation as an image or high-quality (vector graphics) can be created using codes directly. The Ti\emph{k}Z package, based on \TeX\ is an excellent and elaborate package (manual having $>1300$ pages) that can be used for creating high-quality graphics that serve the needs of any technical documentation (Example Fig.~\ref{fig:fc}). Going through the manual of Ti\emph{k}Z and the gallery will give information on the package capabilities and how that can be used in the dissertation. An example of a \ix{flowchart} created through Ti\emph{k}Z code is shown below: \index{tikzpicture} + +\usetikzlibrary{shapes,arrows,shadows} + +\begin{figure}[h!] +\centering +\begin{tikzpicture}[node distance = 3.5cm, every node/.style={scale=0.85}] +\tikzstyle{block} = [rectangle, drop shadow, draw, fill=green!30, text width=7em, text centered, rounded corners] +\tikzstyle{line} = [draw, -latex'] +\tikzstyle{cloud} = [draw, drop shadow, ellipse, fill=pink, minimum height=2.6em] + + \node [cloud] (start) {\texttt{Start}}; + \node [block, right of=start, node distance = 3cm] (read){Read inputs}; + \node [block, fill=blue!15, right of=read] (pros) {Process data \\ (Data cleaning and grouping)}; + \node [block, fill=blue!15, right of=pros] (ana) {Analyze results \\ (Fit model and interpret)}; + \node [block, text width=11em, node distance = 4.2cm, right of=ana] (rep) {Generate reports \\ (For general and technical consumptions with images and tables)}; + \node [cloud, right of=rep,node distance = 3.5cm] (stop) {\texttt{End}}; + \path [line, thick] (start) -- (read); + \path [line, thick] (read) -- (pros); + \path [line, thick] (pros) -- (ana); + \path [line, thick] (ana) -- (rep); + \path [line, thick] (rep) -- (stop); +\end{tikzpicture} +\caption{A high-quality flowchart created using the Ti\emph{k}Z package.} +\label{fig:fc} +\end{figure} + +%-------------------------------------------------------------- +\subsection{Clever reference --- \ix{cross-referencing} items and labels} +Referring to items automatically using the defined labels is a common activity in \LaTeX\ and is called cross-reference. Although there are basic commands available to refer (e.g., fig.~\cmd{ref\{label\}}), the use of \texttt{\ix{cleveref}} package is an efficient way to achieve this task. This package enhances \LaTeX's cross-referencing to automatically detect the ``type'' of the item cross-referenced (e.g., equation, section, tables, figures, etc.) based on the context of the cross-reference. This means a single command of \cmd{cref\{label\}} or \cmd{Cref\{label\}} with the label will produce the correct output (e.g., fig.~1.1, eq.~3, Figure~1.1, Equation~3, etc.). Refer to this package for more details and customization. However, \texttt{cleveref} commands will not work with the appendix tables and appendix figures only, where the basic commands (\cmd{ref\{\ldots\}}) should be used. \index{cref} \index{Cref} + +%-------------------------------------------------------------- +\subsection{Temporary ending} +While reviewing/revising a large document, it will be efficient to compile only the chapter/section that was currently working. Rather than simply ending the document, it will be helpful to generate the citations in the text and a list of references at the \ix{temporary end}. As the commands that generate the reference listing need two files (style: \texttt{*.bst} and bibliography database: \texttt{*.bib}), which will be varying with users, it is better to code this command in the preamble. + +For this purpose, a shortcut \cmd{tend} defined by \cmd{newcommand\tb tend\{\cmd{tempend\{*.bst\}\{*.bib\}\}}} should be placed in the preamble of the source code (\texttt{*.tex}) with suitable names of \texttt{*.bst} and \texttt{*.bib} files (no extension required). Once this is done, the \cmd{tend} can be issued inside any chapter to activate this temporary ending feature. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section{Additional Information II --- Some Tips For Customization} + +%------------------------------------------- +\subsection{General suggestions} +NDSU Graduate School Formatting Guidelines ( +\url{https://www.ndsu.edu/sites/default/files/2021-09/Format-Guidelines-2021.pdf}) should be adhered to and the guidelines to be referred for various aspects of developing the work. Following are some of the \ix{general suggestions} while developing the thesis/dissertation: +\begin{itemize} +\item +All content-related decisions should be made by the student, advisor, and committee, and should follow any rules or conventions established within your program, department, or field. +\item +Students are highly encouraged to follow the prevalent style manual of the discipline (e.g., MLA, APA, Chicago, IEEE, etc.) while formatting the thesis (especially formatting of tables, figures, and other non-textual elements). In the instances where the Graduate School guidelines contradict the style manual for your discipline, the former takes precedence. However, if a generic style is applied consistently throughout all items it will also be approved. During format review, a consistent application of one style is accepted. In short, consistency is KEY. +\item +Paper-based or regular thesis/dissertation chapters (two possible styles) should follow NDSU format guidelines consistently across all chapters and use the prevalent \ix{style manual} of the discipline. +\item +References, tables, and figures should follow the most appropriate style manual of the discipline. Some have the caption centered and set in bold font. +\item +A footnote should be included if the chapter is \ix{co-authored} (an example of this is in NDSU guidelines) and including publication information in the footnote or in the Acknowledgments section is recommended. +\item +The general recommendation about spacing between items and their surrounding non-textual content (equations, figures, tables, quotes, pseudocode, etc.) is to set a consistent spacing between items and their surrounding content as seen in most academic publications. +\item +Table (and figure) captions should be in the same font size as general text; however, text inside tables and footnotes may be in smaller font size as needed to fit the item within the page margins. +\item +NDSU guidelines have a number of very specific rules (e.g., Table of Contents and Prefatory List formatting, abstract word count, headings, body text paragraphs, etc.); however, they give a lot of flexibility for what is not covered, and give the student (and committee) control of the written content. +\item +It should be noted that \LaTeX\ is a vast program with numerous facilities and resources that students can use while developing their thesis/dissertation and improve the document quality. All regular \LaTeX\ commands and features work well with the NDSU thesis class. +\end{itemize} + +%------------------------------------------- +\subsection{Spacing adjustment around non-textual elements} +Usually, the \ix{spacing} around the non-textual elements produced by \LaTeX\ will be good and based on typography principles. The environments that create these elements (e.g., tables, figures, equations) automatically supply an additional space to set the elements apart from the regular text and this is the expected and correct behavior. However, sometimes additional space will appear above or below these elements, which may be the result of fitting the elements with respect to others of the whole chapter. However, the spacing around the non-textual elements can be altered by one or any combination of the following to produce a consistent spacing around the non-textual elements: +\begin{itemize} +\item +The blank line coded, usually left between paragraphs, might create additional space before the element (e.g., +\texttt{equation}, \texttt{align}) and that can be removed to reduce the space above the element. +\item +Proper use of vertical spacing \cmd{\ix{vspace}\{\ldots\}} command with \ix{negative spacing} arguments (e.g., \cmd{vspace +\{-3ex\}}) can able to correct the blank space above the element. This can also be used when a blank line was issued to separate the regular text from the element. Positive vertical space can also be issued as needed. +\item +When a set of equations was coded (e.g., \texttt{\ix{align}}, \texttt{\ix{eqnarray}}), it will be treated as a block and will not break and flow through multiple pages and gets pushed to the next page. This will create large gaps and can be broken into two or more subsets of equations to fit the page by repeating the environments. +\item +The actual space around the equations (displayed items) is controlled be the +\cmd{\ix{abovedisplayskip}[=] glue} and \cmd{\ix{belowdisplayskip}[=] glue}. +The \texttt{glue} is called a ``rubber'' length stating a basic length with an allowed play on both positive and negative sides. The default value for these commands was ``\texttt{12pt plus 3pt minus 9pt}'', and is also valid to use the basic length directly as: +\ccmd{\cmd{abovedisplayskip=-12pt}} +Another way for issuing the command is using the basic \cmd{setlength} as \cmd{setlength\{\tb abovedisplayskip\} +\{-12pt\}}. To have the regular behavior subsequently, the default should be restored by reissuing the commands using the default values. +\item +In figures, the space above the caption (the space between the bottom of the image and the top of the caption) can be controlled by using the optional argument of the \texttt{myfig, myfigls, myfigap} and \texttt{myfigapls} commands. This optional argument was specifically developed to address this caption placement issue. This may be required only for necessary adjustments as the default (without option) will work well in most cases. +\end{itemize} + +%------------------------------------------- +\subsection{Line numbers for the whole document} +Sometimes using line numbers will be helpful while communicating with the advisor or others, where specific locations of the document can be pointed. Line numbers are generated using the package \texttt{lineno}, which is coded into the class, by the following command: +\ccmd{\cmd{\ix{linenumbers}}} +This command can be issued at the beginning or at any point, and numbers will appear in the left margin after the command. Of course, this command should be removed or commented while finalizing the thesis. + +%------------------------------------------- +\subsection{Figures in separate folder} +Several images (graphs, drawings, and pictures) were used while developing a thesis or paper. It will be convenient to store all these images in a subfolder to reduce the clutter. The following command should be issued in the preamble indicating the name of the subfolder (e.g., \texttt{figures}) relative to the main \texttt{.tex} file as: +\ccmd{\cmd{\ix{graphicspath}\{\{./figures/\}\}}} +The type of image files applicable are: \texttt{jpg, pdf, png,} and \texttt{eps}. It is also possible to give an absolute path to the images folder in the above command. + +%------------------------------------------- +\subsection{Chapter styles}\index{chapter styles} +Two styles namely, regular- and paper-styled chapters are generally followed. The regular is a traditional style where the whole thesis/dissertation is considered as a single document where individual chapters exclusively deal with aspects like introduction, literature review, methods, results, discussion or results and discussion, references, and appendices reflecting all studies carried in the research on these individual chapters. Even though this style produces a consolidated document and is solid in its own merit, which ties all research aspects of the study together in corresponding chapters, a good deal of rewriting will be necessary from the authors if they want to publish the contents as individual peer-reviewed journal articles. + +The paper-styled chapters are stand-alone chapters complete with all sections (abstract, introduction, literature review, \ldots, references) and are the modern trend. In this style, some amount of repetition among chapters is unavoidable (especially in methods, analysis, and references). However, as the chapters are already in paper-style, it is very easy to format them to suit the requirement of any peer-reviewed journal for submission. It is also possible to have individual chapter references (Bib\LaTeX) or a combined reference chapter (both Bib\TeX\ and Bib\LaTeX). With \LaTeX\ it is easy to create stand-alone papers with references for submission from a paper-styled disquisition with a combined reference chapter. As outlined earlier, the commands that start these chapters are +\cmd{myheading\{\ldots\}} or \cmd{mypaperheading\{3 args\}} (Sec.\,\ref{heading}). It is a good idea to consult the advisor before committing to these styles, for they are different and substantial rewriting is involved to switch back and forth. + +%------------------------------------------- +\vspace{-1.77ex} +\subsection{Chapters as \ix{individual files}} +When the length of chapters gets long it will be better managed into individual \texttt{*.tex} files. Then the thesis file will become a collection of such individual files and will be highly compact. The individual chapters are coded using either of these commands: +\ccmd{ +\cmd{\ix{input}\{filename\}}\\ +\cmd{\ix{include}\{filename\}}\\ +} +The \cmd{input\{filename\}} imports the codes from the \texttt{filename.tex} into the main file at the location where this command was issued. This is equivalent to typing all the code commands from the individual file into the main file. The \cmd{include\{filename\}} issues a \cmd{clearpage} before and after inserting the contents and had better speed than the \cmd{input\{filename\}} command. With such commands in place, it is possible to compile only the chapter the user wants to work on by commenting others, and this approach saves unnecessary compilation or reduces \ix{compilation times}. + +%------------------------------------------- +\subsection{Chapters as \ix{subfiles}} +Another useful method of handling chapters is the application of subfiles (Sec.~\ref{adop}) that allows for individual files to be complied and generate outputs. Subfiles are standalone documents that derive the preamble from the main document (e.g., my-dissertation.tex) and represent each chapter (e.g., chapter1-intro.tex, chapter2-methods.tex). The text of the ``subfile'' will have the following structure: +\ccmd{ +\cmd{\ix{documentclass}[my-dissertation.tex]\{subfiles\}} \\ +\cmd{begin\{document\}} \\ +\hspace{0.2in}\ldots Entire chapter's text from title, abstract, sections/subsections, and \\ +\hspace{0.2in} so on, with citations using citation and bibliography commands \ldots \\[1ex] +\cmd{end\{document\}} +} + +While the ``main'' file (my-dissertation.tex) will have the following structure (similar to Sec. \ref{example} ``Thesis Example''): +\ccmd{ +\cmd{documentclass[options]\{ndsu-thesis-2022\}} \\ +\hspace{0.2in}\ldots Preamble information \ldots \\ +\cmd{begin\{document\}} \\ + \cmd{subfile\{chapter1-intro.tex\}}\\ + \cmd{subfile\{chapter2-methods.tex\}}\\ +\hspace{0.2in}\ldots Bibliography commands, if required \ldots \\ +\cmd{end\{document\}} +} + +It can be observed that the main file assembles all the chapters in subfiles, while each subfile borrows the class and preamble from the main file. All the subfiles can be kept in the same folder of the main file or can be stored separately in a subfolder but appropriately adding the paths in both the files (Refer to the additional example in the class bundle for the use of subfiles and paths). + +%------------------------------------------- +\subsection{Defining and using \ix{specific commands}, environments, and packages} +As it is not possible to write a class to satisfy the specific requirements of the several departments of NDSU, most of the major features as outlined in this document were coded into the NDSU class, and the users can add necessary features in their source code specific to their requirement. This approach gives flexibility making the class compact and useful. Mathematics, physics, chemistry, literature, etc. departments may use specific symbols and environments that other departments (e.g., agriculture) do not for their thesis. This means that based on the requirement, if not already the packages already loaded in the class, the necessary packages can be loaded in the source files and they work with the class. Another aspect is bibliography style and management, which varies with different departments. To deal with this the necessary style files (\texttt{*.bst}) should be kept in the same folder as \texttt{*.tex} or the appropriate path specified in the source code. + +Specific packages (e.g., bibliography management), \ix{new commands} (shortcuts), and new environments (e.g., theorem, proof, etc.,) can be included in the preamble. These specific items are best left to individual users, as others may not need this --- hence they are not included in the class deliberately. \index{specific packages} + +%------------------------------------------- +\subsection{Voice of the developers!} +It is interesting to know what the original developers of \TeX\ and \LaTeX\ have to say about this system of document preparation. Following are the quotes from the developers about how people feel, perceive, and use the system for their documentation needs. + +\begin{quote} +``\emph{I never expected \TeX\ to be the universal thing that people would turn to for the quick-and-dirty stuff. I always thought of it as something that you turned to if you cared enough to send the very best.}'' \hfill --- \ix{Donald Knuth} (Developer of \TeX\ [on which \LaTeX\ is based]) +\end{quote} + +\vspace{-2ex} +\begin{quote} +``\emph{\LaTeX\ is easy to use --- if you're one of the 2\,\% of the population who thinks logically and can read an instruction manual. The other 98\,\% of the population would find it very hard or impossible to use.}'' \hfill --- \ix{Leslie Lamport} (Developer of \LaTeX) +\end{quote} + +It is safe to assume that students who came this far should have ``cared enough'' to improve the quality of their thesis/dissertation, and some who may think they are in the 98\,\% might discover that they have better logical skills than they originally believed. Furthermore, using \LaTeX\ for the documentation needs (e.g., thesis/dissertation, paper, report, book, letter, CV, and so on) should be considered a useful skill in itself that students can pick up and use throughout their carrier. + +%-------------------------------------------------------------- +%-------------------------------------------------------------- +\section*{Acknowledgements}\index{acknowledgements} +\addcontentsline{toc}{section}{Acknowledgements} +The authors gratefully appreciate the leadership and inputs from Danjel Nygard, Dissertation and Thesis Coordinator, NDSU, Fargo, ND, in developing this ``ndsu-thesis-2022'' \LaTeX\/ class. The support and involvement of James Thorne, Ph.D. Student, Department of Mathematics, NDSU, Fargo, ND, the maintainer of the previous version of this class in CTAN, is also highly appreciated. + +%-------------------------------------------------------------- +\printindex +%-------------------------------------------------------------- + +\begin{center} +\vspace{2ex} +--- $ \star \star \star$ --- +\end{center} +\end{document} + +%------------------------------------------------------------------------------ +%------------------------------------------------------------------------------ +%------------------------------------------------------------------------------
\ No newline at end of file diff --git a/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022.cls b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022.cls new file mode 100644 index 0000000000..cf1e61c111 --- /dev/null +++ b/macros/latex/contrib/ndsu-thesis-2022/ndsu-thesis-2022.cls @@ -0,0 +1,752 @@ +% --- README file contents of the ndsu-thesis-2022 LaTeX document class +% +% This is the ndsu-thesis-2022 document class. This is an upgraded version of +% ndsu-thesis document class. Copyright 2022, Aaron Feickert, Jonathan Totushek, +% and Igathinathane Cannayen. +% +% This work may be distributed and/or modified under the conditions of the LaTeX +% Project Public License; LPPL Version 1.3c 2008-05-04 or (at your option) any +% later version. +% +% Copyright 1999 2002-2008 LaTeX3 Project +% Everyone is allowed to distribute verbatim copies of this +% license document, but modification of it is not allowed. +% +% The latest version of this license is in: https://www.latex-project.org/lppl.txt +% +% This work has the LPPL maintenance status `maintained'. +% +% The current maintainer of this work is Igathinathane Cannayen. +% Contact: i.cannayen@ndsu for bug reports and enquires. +% +% This new class or the old can be used independently, and these classes are +% appropriately invoked through the documentclass command with required options. +% It can be used to produce disquisitions (MS and PhD) for submission to the NDSU +% Graduate School and the final acceptance rests with the University Dissertation +% and Thesis Coordinator, and the Graduate Committee. +% +% Files included are: +% README - this information file +% ndsu-thesis-2022.cls - class file +% ndsu-thesis-2022-documentation.tex - class file documentation (source) +% ndsu-thesis-2022-documentation.pdf - class file documentation +% ndsu-example.tex - simple thesis example file (source) +% ndsu-example.pdf - simple thesis example file +% NDSU-Thesis-Extended.tex - extended thesis example illustrating several +% features (source) +% NDSU-Thesis-Extended.pdf - extended thesis example illustrating several +% features +% mybib.bib - sample bibliography database file used in theses examples +% frog.jpg - free sample image file used in extended thesis example +% figures - subfolder holding the images of documentation +% +% --- End README content --- +% +%--------------------------------------------------------------------------------------------------------- +%--------------------------------------------------------------------------------------------------------- +% Several upgrades as commands and options were performed by +% C. Igathinathane ABEN, NDSU. Bug reports/Enquiries: i.cannayen@ndsu.edu +% Numbered and non-numbered versions +% Justification (full and raggedright) +% Whole document point sizes +% Fonts options +% SI units +% Show frame using geometry package +% URL breaking and URL font same as text +% Long tables +% Landscape figures and tables +% Subfigures and multi-page figures +% Captions small centered long left justified +% URL same font as text +% Chapter styles nonumber, chapternumber, and default numbered +% Major heading (chapter) font, linespacing, above and below skips +% Subfiles capability - standalone chapter compilation +% Programs and algorithm listing with listings package +% BibTeX , BibLaTeX plus subfiles compilation +% Friendly natbib style citations +% Clever reference with cleveref package +% Figures shortcuts with optional caption vertical placement +% Full-width tables with tabu package +% Figure & table caption (#>9) horizontal space adjustment +% +% Last updated: 2022-07-10 +%--------------------------------------------------------------------------------------------------------- +%--------------------------------------------------------------------------------------------------------- +% +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{ndsu-thesis-2022}[2022/07/10 NDSU Thesis Class] +\DeclareOption{draft}{\PassOptionsToClass{draft}{book}} +\def\@@ptsize{12pt} +\DeclareOption{10pt}{\def\@@ptsize{10pt}} +\DeclareOption{11pt}{\def\@@ptsize{11pt}} +\DeclareOption{12pt}{\def\@@ptsize{12pt}} +\DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}} +\ProcessOptions\relax +\LoadClass[oneside,notitlepage,\@@ptsize]{book} + +% RequirePackage command and other essential packages used +\RequirePackage[utf8]{inputenc} +\RequirePackage[T1]{fontenc} +\RequirePackage[obeyspaces,spaces,hyphens]{url} +\RequirePackage[linktocpage,breaklinks,linktoc=all,hidelinks]{hyperref} +\RequirePackage[colorinlistoftodos,prependcaption,textsize=scriptsize]{todonotes} +\RequirePackage{lineno} +\RequirePackage{setspace} +\RequirePackage{amsmath} +\RequirePackage{amsfonts} +\RequirePackage{amssymb} +\RequirePackage{titling} +\RequirePackage{ifthen} +\RequirePackage{titlesec} +\RequirePackage{indentfirst} +\RequirePackage[titles]{tocloft} +\RequirePackage{soul} +\RequirePackage{xcolor} +\RequirePackage{etoolbox} +\RequirePackage{mwe} +\RequirePackage{kantlipsum} +\RequirePackage{subfig} +\RequirePackage[figure,table]{totalcount} +\RequirePackage[nottoc]{tocbibind} +\RequirePackage[within=chapter]{newfloat} +\RequirePackage[labelsep=period]{caption} +\RequirePackage{comment} +\RequirePackage{tikz} +\usetikzlibrary{matrix,arrows,decorations.pathmorphing} +\RequirePackage{etoolbox} +\RequirePackage{tocloft} +\RequirePackage{xtab} +\RequirePackage{siunitx} % [binary-units = true] +\RequirePackage{float} +\RequirePackage{booktabs} +\RequirePackage{pdflscape} +\RequirePackage{booktabs} +\RequirePackage{tabularx} +\RequirePackage{longtable} +\RequirePackage{threeparttable} +\RequirePackage{threeparttablex} +\RequirePackage{xspace} +\RequirePackage{rotating} +\RequirePackage{listings} +\RequirePackage{tabu} +\RequirePackage{comment} +\RequirePackage{enumitem} +\RequirePackage[american]{babel} % english +\RequirePackage{csquotes} +\RequirePackage[export]{adjustbox} +\RequirePackage[nameinlink]{cleveref} %capitalise, noabbrev + +% Url better breaking + defining characters (alphabets and others) to break +\Urlmuskip=0mu plus 1mu\relax + +\def\UrlBreaks{\do\.\do\@\do\\\do\/\do\!\do\_\do\|\do\;\do\>\do\]% + \do\)\do\,\do\?\do\'\do\+\do\=\do\#% + \do\/\do\a\do\b\do\c\do\d\do\e\do\f% + \do\g\do\h\do\i\do\j\do\k\do\l\do\m%f + \do\n\do\o\do\p\do\q\do\r\do\s\do\t% + \do\u\do\v\do\w\do\x\do\y\do\z% + \do\A\do\B\do\C\do\D\do\E\do\F\do\G%g + \do\H\do\I\do\J\do\K\do\L\do\M\do\N% + \do\O\do\P\do\Q\do\R\do\S\do\T\do\U% + \do\V\do\W\do\X\do\Y\do\Z}% + +% Overall +\urlstyle{same} % same font used for url than the regular tt font +\captionsetup[figure]{singlelinecheck=true} % for figures (centered and left) +\setlist{nosep, leftmargin=0.5in} % enumerate setup (no extra line spacing and let margin at 0.5in like other indent +\newbool{whole} % to be used with main and subfiles +\setbool{whole}{true} % false produces refs individual subfiles - default +\newbool{biblatexused} % to be used with main and subfiles +\setbool{biblatexused}{false} % false produces refs individual subfiles - default +\newbool{subcomp} % to be used with main and subfiles +\setbool{subcomp}{false} % false produces refs individual subfiles - default + +% Spacing between number and captions (table and figures) +\setlength{\cfttabnumwidth}{2.5em} % table - tocloft package +\setlength{\cftfignumwidth}{2.5em} % figure - tocloft package + +% Basic spacing +\setcounter{secnumdepth}{5} +\setlength{\intextsep}{\baselineskip} +\singlespacing + +% Degree options +\newcommand{\thesistype}{phd} +\DeclareOption{phd}{\renewcommand{\thesistype}{phd}} +\DeclareOption{ms-thesis}{\renewcommand{\thesistype}{ms-thesis}} +\DeclareOption{ms-paper}{\renewcommand{\thesistype}{ms-paper}} +\DeclareOption{ma-thesis}{\renewcommand{\thesistype}{ma-thesis}} +\DeclareOption{ma-paper}{\renewcommand{\thesistype}{ma-paper}} +\ProcessOptions + +% Nonumber and chapter number (only chapters numbered) options - two types of NDSU templates (Now offering 3 types) +\newcommand{\numbertype}{none} +\DeclareOption{nonumber}{\renewcommand{\numbertype}{nonumber}} +\DeclareOption{chapternumber}{\renewcommand{\numbertype}{chapternumber}} +\ProcessOptions +\ifthenelse{\equal{\numbertype}{nonumber}}{\setcounter{secnumdepth}{-1}}{ +\ifthenelse{\equal{\numbertype}{chapternumber}}{\setcounter{secnumdepth}{0}}{ +}}{} + +% Justification option for the whole document - default is justified nojustify is ragged-right format. NDSU default is "ragged-right" but allows "justified" format as well +\newcommand{\justifytype}{none1} +\DeclareOption{nojustify}{\renewcommand{\justifytype}{nojustify}} +\ProcessOptions +\ifthenelse{\equal{\justifytype}{nojustify}}{\AtBeginDocument{\raggedright}}{} + +% Font options: Any one can be used bookman, charter, gentium, kpfonts, libertine, lmodern, mathdesign, mathptmx, newcent, palatino, tgtermes, times, tgbonum, tgpagella, tgschola, utopia, zlmtt. Note: all will not support the math characters - in such cases, only the math font falls back to the default computer modern. SI units also will be influenced. + +\newcommand{\fonttype}{none2} +\DeclareOption{bookman}{\renewcommand{\fonttype}{bookman}} +\DeclareOption{charter}{\renewcommand{\fonttype}{charter}} +\DeclareOption{gentium}{\renewcommand{\fonttype}{gentium}} +\DeclareOption{kpfonts}{\renewcommand{\fonttype}{kpfonts}} +\DeclareOption{libertine}{\renewcommand{\fonttype}{libertine}} +\DeclareOption{lmodern}{\renewcommand{\fonttype}{lmodern}} +\DeclareOption{mathdesign}{\renewcommand{\fonttype}{mathdesign}} +\DeclareOption{mathptmx}{\renewcommand{\fonttype}{mathptmx}} +\DeclareOption{newcent}{\renewcommand{\fonttype}{newcent}} +\DeclareOption{palatino}{\renewcommand{\fonttype}{palatino}} +\DeclareOption{tgtermes}{\renewcommand{\fonttype}{tgtermes}} +\DeclareOption{times}{\renewcommand{\fonttype}{times}} +\DeclareOption{tgbonum}{\renewcommand{\fonttype}{tgbonum}} +\DeclareOption{tgpagella}{\renewcommand{\fonttype}{tgpagella}} +\DeclareOption{tgschola}{\renewcommand{\fonttype}{tgschola}} +\DeclareOption{utopia}{\renewcommand{\fonttype}{utopia}} +\DeclareOption{zlmtt}{\renewcommand{\fonttype}{zlmtt}} +\ProcessOptions + +\ifthenelse{\equal{\fonttype}{bookman}}{\usepackage{bookman}}{ +\ifthenelse{\equal{\fonttype}{charter}}{\usepackage{charter}}{ +\ifthenelse{\equal{\fonttype}{gentium}}{\usepackage{gentium}}{ +\ifthenelse{\equal{\fonttype}{kpfonts}}{\usepackage{kpfonts}}{ +\ifthenelse{\equal{\fonttype}{libertine}}{\usepackage{libertine}}{ +\ifthenelse{\equal{\fonttype}{lmodern}}{\usepackage{lmodern}}{ +\ifthenelse{\equal{\fonttype}{mathdesign}}{\usepackage[bitstream-charter]{mathdesign}}{ +\ifthenelse{\equal{\fonttype}{mathptmx}}{\usepackage{mathptmx}}{ +\ifthenelse{\equal{\fonttype}{newcent}}{\usepackage{newcent}}{ +\ifthenelse{\equal{\fonttype}{palatino}}{\usepackage{palatino}}{ +\ifthenelse{\equal{\fonttype}{tgtermes}}{\usepackage{tgtermes}}{ +\ifthenelse{\equal{\fonttype}{times}}{\usepackage{times}}{ +\ifthenelse{\equal{\fonttype}{tgbonum}}{\usepackage{tgbonum}}{ +\ifthenelse{\equal{\fonttype}{tgpagella}}{\usepackage{tgpagella}}{ +\ifthenelse{\equal{\fonttype}{tgschola}}{\usepackage{tgschola}}{ +\ifthenelse{\equal{\fonttype}{utopia}}{\usepackage{utopia}}{ +\ifthenelse{\equal{\fonttype}{zlmtt}}{\usepackage{zlmtt}} +}}}}}}}}}}}}}}}}{} + +% Showframe +\newcommand{\frameshow}{none3} +\DeclareOption{showframe}{\renewcommand{\frameshow}{showframe}} +\ProcessOptions +\ifthenelse{\equal{\frameshow}{showframe}} +{\RequirePackage[top=1in,bottom=1.25in,left=1in,right=1in,letterpaper,showframe]{geometry}}{\RequirePackage[top=1in,bottom=1.25in,left=1in,right=1in,letterpaper]{geometry}} + +% ChapterBibliography +\newcommand{\chapbib}{none4} +\DeclareOption{chaptersbib}{\renewcommand{\chapbib}{chaptersbib}} +\ProcessOptions +\ifthenelse{\equal{\chapbib}{chaptersbib}} +{\setbool{whole}{false} +\setbool{biblatexused}{true}} +{\setbool{whole}{true} +\setbool{biblatexused}{false}} + +% Subfile compilation +\newcommand{\subcom}{none5} +\DeclareOption{subfileref}{\renewcommand{\subcom}{subfileref}} +\ProcessOptions +\ifthenelse{\equal{\subcom}{subfileref}} +{\setbool{subcomp}{true}} +{\setbool{subcomp}{false}} + +% Table of contents tweaks +\addto\captionsamerican{\renewcommand{\contentsname}{TABLE OF CONTENTS}} +\addto\captionsamerican{\renewcommand{\listtablename}{LIST OF TABLES}} +\addto\captionsamerican{\renewcommand{\listfigurename}{LIST OF FIGURES}} +\renewcommand{\cftchapfont}{\normalfont} +\renewcommand{\cftchappagefont}{\normalfont} +\renewcommand{\cftchapleader}{\cftdotfill{\cftdotsep}} +\renewcommand{\cftchapaftersnum}{.} +\renewcommand{\cftfigaftersnum}{.} +\renewcommand{\cfttabaftersnum}{.} +\renewcommand{\cftsecaftersnum}{.} +\renewcommand{\cftsubsecaftersnum}{.} +\setlength{\cftbeforesecskip}{0.5\baselineskip} +\setlength{\cftbeforesubsecskip}{0.5\baselineskip} +\setlength{\cftbeforetabskip}{0.5\baselineskip} +\setlength{\cftbeforefigskip}{0.5\baselineskip} +\setlength{\cftfigindent}{0em} +\setlength{\cfttabindent}{0em} +\DeclareTotalCounter{appendixfigure} +\DeclareTotalCounter{appendixtable} +\DeclareFloatingEnvironment[fileext=loaf,placement={ht},listname={LIST OF APPENDIX FIGURES},name=Figure]{appendixfigure} +\DeclareFloatingEnvironment[fileext=loat,placement={ht},listname={LIST OF APPENDIX TABLES},name=Table]{appendixtable} + +% Fix table captions and row spacing +%\AtBeginEnvironment{tabular}{\singlespacing} +\captionsetup[table]{position=top,skip=\baselineskip, singlelinecheck=false} % left-aligned +\captionsetup[appendixtable]{position=top,skip=0.75\baselineskip,singlelinecheck=false} % left-aligned + +% Defines custom paper information +\newcommand\papertype[1]{\def\@papertype{#1}} +\let\@papertype=\@empty +\ifthenelse{\equal{\thesistype}{phd}}{\papertype{Dissertation}}{ +\ifthenelse{\equal{\thesistype}{ms-thesis}}{\papertype{Thesis}}{ +\ifthenelse{\equal{\thesistype}{ms-paper}}{\papertype{Paper}}{ +\ifthenelse{\equal{\thesistype}{ma-thesis}}{\papertype{Thesis}}{ +\ifthenelse{\equal{\thesistype}{ma-paper}}{\papertype{Paper}}}}}}{} + +\newcommand\degree[1]{\def\@degree{#1}} +\let\@degree=\@empty +\ifthenelse{\equal{\thesistype}{phd}}{\degree{DOCTOR OF PHILOSOPHY}}{ +\ifthenelse{\equal{\thesistype}{ms-thesis}}{\degree{MASTER OF SCIENCE}}{ +\ifthenelse{\equal{\thesistype}{ms-paper}}{\degree{MASTER OF SCIENCE}}{ +\ifthenelse{\equal{\thesistype}{ma-thesis}}{\degree{MASTER OF ARTS}}{ +\ifthenelse{\equal{\thesistype}{ma-paper}}{\degree{MASTER OF ARTS}}}}}}{} + +% to produce Major Program or Major Department +\newcommand\progdeptchoice[1]{\def\@progdeptchoice{#1}} +\let\@progdeptchoice=\@empty + +\newcommand\department[1]{\def\@department{#1}} +\let\@department=\@empty + +\newcommand\degreeoption[1]{\def\@degreeoption{Option:\\#1}} +\let\@degreeoption=\@empty + +\newcommand\approvaldate[1]{\def\@approvaldate{#1}} +\let\@approvaldate=\@empty + +\newcommand\approver[1]{\def\@approver{#1}} +\let\@approver=\@empty + +\renewcommand\title[1]{\def\@title{\uppercase{#1}}} +\let\@title=\@empty + +% Committee information +\newcommand\cchair[1]{\def\@cchair{#1\vspace{.05in}\hrule\vspace{.05in} + {\tiny Chair}\\}\vspace{.2 in}} +\let\@cchair=\@empty +\newcommand\cochaira[1]{\def\@cochaira{#1\vspace{.05in}\hrule\vspace{.05in} + {\tiny Co-Chair}\\}\vspace{.2 in}} +\let\@cochaira=\@empty +\newcommand\cochairb[1]{\def\@cochairb{#1\vspace{.05in}\hrule\vspace{.05in} + {\tiny Co-Chair}\\}\vspace{.2 in}} +\let\@cochairb=\@empty +\newcommand\cmembera[1]{\def\@cmembera{#1\vspace{.05in} + \hrule\vspace{.2in}}} +\let\@cmembera=\@empty +\newcommand\cmemberb[1]{\def\@cmemberb{#1\vspace{.05in} + \hrule\vspace{.2in}}} +\let\@cmemberb=\@empty +\newcommand\cmemberc[1]{\def\@cmemberc{#1\vspace{.05in} + \hrule\vspace{.2in}}} +\let\@cmemberc=\@empty +\newcommand\cmemberd[1]{\def\@cmemberd{#1\vspace{.05in} + \hrule\vspace{.2in}}} +\let\@cmemberd=\@empty + +% Other frontmatter sections +\newcommand\abstract[1]{\def\@abstract{\setlength\parindent{0.5in}\clearpage\chapter*{ABSTRACT}\addcontentsline{toc}{chapter}{ABSTRACT}#1}} +\let\@abstract=\@empty + +\newcommand\acknowledgements[1]{\def\@acknowledgements{\clearpage\chapter*{ACKNOWLEDGEMENTS}\addcontentsline{toc}{chapter}{ACKNOWLEDGEMENTS}#1}} +\let\@acknowledgements=\@empty + +\newcommand\dedication[1]{\def\@dedication{\clearpage\chapter*{DEDICATION}\addcontentsline{toc}{chapter}{DEDICATION}\begin{center}#1\end{center}}} +\let\@dedication=\@empty + +\newcommand\preface[1]{\def\@preface{\clearpage\chapter*{PREFACE}\addcontentsline{toc}{chapter}{PREFACE}#1}} +\let\@preface=\@empty + +% LIST OF ABBREVIATIONS - Igathi +% A 2-col tabular environment; Usage: SI & System International - flowing over multipage +\newcommand\listofabbreviations[1]{ +\def\@listofabbreviations{\clearpage\chapter*{\vspace{-1ex}LIST OF ABBREVIATIONS}\addcontentsline{toc}{chapter}{LIST OF ABBREVIATIONS} +\vspace{-2ex} +\renewcommand{\arraystretch}{1.5} +\begin{singlespace} +\xentrystretch{-0.1} +\begin{xtabular}{>{\hspace{-0.05in}}p{2.3in}<{\dotfill}@{}p{3.5in}} +#1 +\end{xtabular} +\end{singlespace} +\renewcommand{\arraystretch}{1} +}} +\let\@listofabbreviations=\@empty + +% LIST OF SYMBOLS - Igathi +% A 2-col tabular environment; Usage: $\alpha$ & The angle ($\dg$) +\newcommand\listofsymbols[1]{ +\def\@listofsymbols{\clearpage\chapter*{\vspace{-1ex}LIST OF SYMBOLS}\addcontentsline{toc}{chapter}{LIST OF SYMBOLS} +\vspace{-2ex} +\renewcommand{\arraystretch}{1.5} +\begin{singlespace} +\xentrystretch{-0.1} +\begin{xtabular}{>{\hspace{-0.05in}}p{2.3in}<{\dotfill}@{}p{3.5in}} +#1 +\end{xtabular} +\end{singlespace} +\renewcommand{\arraystretch}{1} +}} +\let\@listofsymbols=\@empty + +% Title page +\setlength{\droptitle}{-1in} +\pretitle{\doublespacing \vfill \begin{center}} +\posttitle{\vfill \singlespacing A \@papertype \\ Submitted to the Graduate Faculty \\ of the \\ North Dakota State University \\ of Agriculture and Applied Science \end{center}} +\preauthor{\vfill \begin{center} By \\ \vspace{\baselineskip}} +\postauthor{\vfill \singlespacing In Partial Fulfillment of the Requirements \\ for the Degree of \\ \@degree \vfill Major~\@progdeptchoice: \\ \@department \end{center}} +\predate{\vfill \begin{center}} +\postdate{\vfill Fargo, North Dakota \end{center}} + +% These control the frontmatter sections +\newcommand{\makeapproval}{ +\clearpage +\thispagestyle{empty} +\doublespacing +\vfill +\begingroup + \centering {\Large \textbf{NORTH DAKOTA STATE UNIVERSITY}} \\ + {\large Graduate School} \\ + \vspace{.1in} + \hrule height 1pt + \begin{center} + \parbox{5.5in}{ + \begin{center} + \textbf{Title} \\ + \@title + \vspace{.2in} + \hrule + \vspace{.2in} + \textbf{By} \\ + \@author + \vspace{.2in} + \hrule + \end{center} + } + \end{center} +\endgroup +\vspace{-1.2\baselineskip} +\vfill +\begingroup +\leftskip1em +\rightskip\leftskip +{\noindent The Supervisory Committee certifies that this \MakeLowercase{\@papertype} complies with North Dakota State University's regulations and meets the accepted standards for the degree of}\\ +\par +\endgroup + +\begin{center} +\textbf{\@degree} +\vfill +\parbox{5.5in}{ + \hspace{-0.35in}SUPERVISORY COMMITTEE: \\[0.06in] + \@cchair + \@cochaira + \@cochairb + \@cmembera + \@cmemberb + \@cmemberc + \@cmemberd +} +\parbox{5.5in}{ + \vspace{0.2in}\hspace{-0.35in}Approved: \\[0.1in] + \noindent \parbox{1.5in}{\centering\@approvaldate\vspace{.05in}\hrule\vspace{.05in}{\tiny Date}} \hfill + \parbox{3in}{\centering\@approver\vspace{.05in}\hrule\vspace{.05in}{\tiny Department Chair}} +} +\end{center} +} + +\newlength{\standardchapnumwidth} +\AtBeginDocument{\setlength{\standardchapnumwidth}{\cftchapnumwidth}} +\AtBeginDocument{\frontmatter \maketitle\thispagestyle{empty} \makeapproval \@abstract \@acknowledgements \@dedication \@preface + +\begin{singlespace}\tableofcontents\end{singlespace} +\iftotaltables +\begingroup + \renewcommand*{\addvspace}[1]{} + \begin{singlespace}\listoftables\end{singlespace} +\endgroup +\fi +\iftotalfigures +\begingroup + \renewcommand*{\addvspace}[1]{} + \begin{singlespace}\listoffigures\end{singlespace} +\endgroup +\fi + +\@listofabbreviations +\@listofsymbols + +\iftotalappendixtables\begin{singlespace}\listofappendixtables\end{singlespace}\fi +\iftotalappendixfigures\begin{singlespace}\listofappendixfigures\end{singlespace}\fi +\mainmatter} + +\pagestyle{plain} +\addtocontents{lot}{\noindent\underline{Table}\hfill \underline{Page}\par} +\addtocontents{lof}{\noindent\underline{Figure}\hfill \underline{Page}\par} +\addtocontents{loat}{\noindent\underline{Table}\hfill \underline{Page}\par} +\addtocontents{loaf}{\noindent\underline{Figure}\hfill \underline{Page}\par} +\addtocontents{loa}{\noindent\underline{Figure}\hfill \underline{Page}\par} + +% Labels chapters correctly +\newcommand{\heading}[1]{\chapter{\uppercase{#1}}} + +% Format headings correctly +% Chapter title centered properly - Use \myheading{} command +\titleformat{\chapter} + {\centering\normalfont\bfseries\setstretch{1.6}} + {{\large\MakeUppercase{{\chaptertitlename}}\ }}{0em}{\large\MakeUppercase} + \titlespacing*{\chapter}{0pt}{-0.6\baselineskip}{0.4\baselineskip} + +% Two versions based on "nonumber" option other two carry chapter numbers +\ifthenelse{\equal{\numbertype}{nonumber}}{ +\newcommand{\myheading}[1]{\chapter[\uppercase{#1}]{{#1}}} +}{ +\newcommand{\myheading}[1]{\chapter[\uppercase{#1}]{\thechapter.~{#1}}} +} + +\newcommand\blfootnote[1]{ + \begingroup + \renewcommand\thefootnote{}\footnote{#1}% + \addtocounter{footnote}{-1}% + \endgroup +} + +% Usage: \mypaperheading{Title}{footnote mark}{footnote text} - 3 arguments + +\ifthenelse{\equal{\numbertype}{nonumber}}{ +\newcommand{\mypaperheading}[3]{\chapter[\uppercase{#1}]{{#1\,#2}\vspace{-3.2ex}}\blfootnote{\raggedright#2\,#3}} +}{ +\newcommand{\mypaperheading}[3]{\chapter[\uppercase{#1}]{\thechapter.~{#1\,#2}\vspace{-3.2ex}}\blfootnote{\raggedright#2\,#3}} +} + +% NDSU - MAJOR HEADING - Centered, bold, All Caps, e.g., 1. MAJOR HEADING + +\titleformat{\section} + {\centering\normalfont\bfseries}{\thesection.}{0.3em}{} + \titlespacing*{\section}{0pt}{*0}{0pt} +% NDSU - First Level Subheading - Centered, bold, Title Case, +% e.g., 1.1. First Level Subheading + +\titleformat{\subsection} % Igathi + {\normalfont\bfseries}{\thesubsection.}{0.3em}{} + \titlespacing*{\subsection}{0pt}{*0}{0pt} +% NDSU - Second Level Subheading - Left aligned, bold, Title Case, +% e.g., 1.1.1.Second Level Subheading + +\titleformat{\subsubsection} % Igathi + {\normalfont\bfseries\itshape}{\thesubsubsection.}{0.3em}{} + \titlespacing*{\subsubsection}{0pt}{*0}{0pt} +% NDSU - Third level subheading - Left aligned, bold, italics, Sentence case, +% e.g., 1.1.1.1. Third level subheading + +\titleformat{\paragraph} + {\normalfont\itshape}{\theparagraph.}{0.3em}{} + \titlespacing*{\paragraph}{0pt}{*0}{0pt} +% Not in NDSU - Fourth level subheading - Left aligned, italics, Sentence case, +%e.g., 1.1.1.1.1. Fourth level subheading + +\newcommand\bibtocsubstart{ % used in latter command +\newpage +\phantomsection +\addcontentsline{toc}{chapter}{REFERENCES} +\addtocontents{toc}{\protect\setcounter{tocdepth}{-1}} +\renewcommand{\refname}{\vspace{-0.45in}} +\renewcommand{\bibname}{REFERENCES} +} + +% Usage: \biblio{reference-styleFile}{reference-bibFile} - Command to have references +\newcommand\biblio[2]{ +\bibtocsubstart +\bibliographystyle{#1} % *.bst file +\bibliography{#2} % *.bib file +\addtocontents{toc}{\protect\setcounter{tocdepth}{1}} +} + +% Usage: \tempend{reference-styleFile}{reference-bibFile} - Command to end temporarily +\newcommand\tempend[2]{ +\bibtocsubstart +\bibliographystyle{#1} % *.bst file +\bibliography{#2} % *.bib file +\addtocontents{toc}{\protect\setcounter{tocdepth}{1}} +\end{spacing} +\end{document} +} + +% Generate appendices with the correct numbering - modified +\renewcommand{\appendix}{ + \chapter*{APPENDIX} + \setcounter{appendixfigure}{0} + \renewcommand{\appendixfigurename}{Figure} + \renewcommand{\theappendixfigure}{A\arabic{appendixfigure}} + \setcounter{appendixtable}{0} + \renewcommand{\appendixtablename}{Table} + \renewcommand{\theappendixtable}{A\arabic{appendixtable}} + \addtocontents{toc}{\setlength{\protect\cftchapnumwidth}{0pt}} + \addcontentsline{toc}{chapter}{APPENDIX} + \renewcommand{\thesection}{A.\arabic{section}} + \setcounter{section}{0} + \renewcommand{\theequation}{A.\arabic{equation}} + \addtocontents{toc}{\protect\setcounter{tocdepth}{2}}% toc up to subsection +} + +% Usage: \namedappendices{A}{Appendix title} +\newcommand{\namedappendices}[2]{ % for multiple appendices + \chapter*{APPENDIX #1. #2} + \setcounter{appendixfigure}{0} + \renewcommand{\appendixfigurename}{Figure} + \renewcommand{\theappendixfigure}{#1\arabic{appendixfigure}} + \setcounter{appendixtable}{0} + \renewcommand{\appendixtablename}{Table} + \renewcommand{\theappendixtable}{#1\arabic{appendixtable}} + \addtocontents{toc}{\setlength{\protect\cftchapnumwidth}{0pt}} + \addcontentsline{toc}{chapter}{APPENDIX #1.{\hspace{1.5ex}}\uppercase{#2}} + \renewcommand{\thesection}{#1.\arabic{section}} +% \addcontentsline{toc}{section}{#1.\arabic{section}} + \setcounter{section}{0} + \renewcommand{\theequation}{#1.\arabic{equation}} + \addtocontents{toc}{\protect\setcounter{tocdepth}{2}}% toc up to subsection +} + +% New(er) commands +%--------------------------------------------------------------- + +% suppressing Chapter labels and leaving only the number +\addto\captionsamerican{% +\renewcommand\chaptername{}} + +% Command to ensure list of both appendix tables and figures +% Usage: \closeappendices on the last named appendix at the end or separately before the \end{document} +\newcommand{\closeappendices}{ % Igathi +\renewcommand{\appendixfigurename}{} +\renewcommand{\theappendixfigure}{} +\renewcommand{\appendixtablename}{} +\renewcommand{\theappendixtable}{} +\begin{appendixfigure}[H] +\caption[]{} +\end{appendixfigure} +\begin{appendixtable}[H] +\caption[]{} +\end{appendixtable} +\vspace{-25ex} +} + +% the thesis had only appendix tables +\newcommand{\closeappendixtables}{ % Igathi +\renewcommand{\appendixtablename}{} +\renewcommand{\theappendixtable}{} +\begin{appendixtable}[H] +\caption[]{} +\end{appendixtable} +\vspace{-25ex} +} + +% the thesis had only appendix figures +\newcommand{\closeappendixfigures}{ % Igathi +\renewcommand{\appendixfigurename}{} +\renewcommand{\theappendixfigure}{} +\begin{appendixfigure}[H] +\caption[]{} +\end{appendixfigure} +\vspace{-25ex} +} + +\newcommand\vsalign{\vspace{-4ex}} +\newcommand\vseqn{\vspace{-2ex}} + +% Example usage: +% \myfig[aboveskip=3ex]{placement=ht}{width=0.8}{file=fig1.pdf}{caption=My caption goes here}{label=fig1} +% \myfig[aboveskip]{ht}{0.8}{fig1.pdf}{My caption goes here}{fig1} + +% Regular figure command with placement (htpbH as first argument) +\newcommand{\myfig}[6][0ex]{%3.5 earlier +\vspace{2ex} +\begin{figure}[#2] +\centering +\captionsetup{aboveskip = #1 plus 2pt minus 2pt, belowskip = 0pt} %, singlelinecheck=true for centering; 14 pt + \includegraphics[width=#3\textwidth]{#4} + \vspace{5pt} + \caption{#5} + \label{#6} +\end{figure} +} + +% Example usage: +% \myfigls[aboveskip]{ht}{0.8}{fig1.pdf}{My caption goes here}{fig1} + +% Landscape figure command with placement (htpbH as first argument) +\newcommand{\myfigls}[6][0ex]{ +\begin{landscape} +\begin{figure}[#2] +\centering +\captionsetup{aboveskip = #1 plus 2pt minus 2pt, belowskip = 0pt} %, singlelinecheck=true for centering + \includegraphics[width=#3\textwidth]{#4} + \vspace{5pt} + \caption{#5} + \label{#6} +\end{figure} +\end{landscape} +} + +% Example usage: +% \myfigap[aboveskip]{ht}{0.5}{appenddfig1.pdf}{My appendix caption goes here}{figA1} + +% Appendix figure command - with placement (htpbH as first argument) +\newcommand{\myfigap}[6][0ex]{ +\vspace{2ex} +\begin{appendixfigure}[#2] +\centering +\captionsetup{belowskip = 0pt, aboveskip = #1 plus 2pt minus 2pt} %, singlelinecheck=true for centering + \includegraphics[width=#3\textwidth]{#4} + \vspace{5pt} + \caption[#5]{#5} + \label{#6} +\end{appendixfigure} +} + +% Example usage: +% \myfigapls{ht}{0.5}{appenddfig1.pdf}{My appendix caption goes here}{figA1} + +% Appendix landscape figure command - with placement (htpbH as first argument) +\newcommand{\myfigapls}[6][0ex]{ +\begin{landscape} +\begin{appendixfigure}[#2] +\centering +\captionsetup{belowskip = 0pt, aboveskip = #1 plus 2pt minus 2pt} %, singlelinecheck=true for centering + \includegraphics[width=#3\textwidth]{#4} + \vspace{5pt} + \caption[#5]{#5} + \label{#6} +\end{appendixfigure} +\end{landscape} +} + +\definecolor{newtext}{rgb}{0.1,0.6,0.1} +\newcommand\dt[1]{\textcolor{red}{\st{#1}}\xspace} +\newcommand\nt[1]{\textcolor{newtext}{#1}\xspace} +\newcommand\rt[2]{{\textcolor{red}{\st{#1}}}{\textcolor{newtext}{#2}}\xspace} +\newcommand\notes[1]{\vspace{2ex}\todo[color=green!35, inline]{#1}} + +\newcommand\mt[1]{\text{#1}} % math text +\newcommand\pt[1]{\qty[mode = text]{#1}{\percent}\xspace} % \qty{}{} new SI command +\newcommand\pr[1]{\qty[mode = text]{#1}{\percent}\xspace} +\newcommand\dg[1]{\qty[mode = text]{#1}{\degreeCelsius}\xspace} + +\newcommand\SU[2]{\qty[mode = text]{#1}{#2}\xspace} % redefined using qty +\newcommand\su[1]{\unit[mode = text]{#1}\xspace} % redefined using qty +\newcommand\no[1]{\num[mode = text]{#1}\xspace} % redefined using qty + + +\setlength\abovedisplayskip{6pt plus 3pt minus 3pt} +\setlength\abovedisplayshortskip{0pt plus 3pt minus 3pt} +\setlength\belowdisplayskip{6pt plus 3pt minus 3pt} +\setlength\belowdisplayshortskip{3pt plus 1pt minus 1pt} + +\RequirePackage{subfiles} % Best loaded last in the preamble + +\widowpenalty=10000 +\clubpenalty=10000 + +\endinput diff --git a/macros/xetex/latex/bidi/README b/macros/xetex/latex/bidi/README index 799fbd337f..54530a724a 100644 --- a/macros/xetex/latex/bidi/README +++ b/macros/xetex/latex/bidi/README @@ -1,6 +1,6 @@ ___________________ The bidi package -v39.0 +v39.1 This package provides a convenient interface for typesetting bidirectional texts in Plain TeX and LaTeX, using XeTeX engine. @@ -25,7 +25,7 @@ The announcements for the new releases of the package will also appear in the Discussions space under the Announcements category. -Current version release date: 2022/07/10 +Current version release date: 2022/07/12 ___________________________________________ Vafa Khalighi diff --git a/macros/xetex/latex/bidi/bidi-doc-intro.ltx b/macros/xetex/latex/bidi/bidi-doc-intro.ltx index 684abe72f6..7449154097 100644 --- a/macros/xetex/latex/bidi/bidi-doc-intro.ltx +++ b/macros/xetex/latex/bidi/bidi-doc-intro.ltx @@ -20,7 +20,7 @@ If you use \textsf{bidi} package to write any input \TeX\ document, and then run * Copyright (c) 2007--2022 Vafa Khalighi * Copyright (c) 2018--2020 bidi-tex GitHub Organization * -* v39.0, 2022/07/10 +* v39.1, 2022/07/12 * * License: LaTeX Project Public License, version * 1.3c or higher (your choice) diff --git a/macros/xetex/latex/bidi/bidi-doc-title.ltx b/macros/xetex/latex/bidi/bidi-doc-title.ltx index 175b239e1d..3a16e32ccb 100644 --- a/macros/xetex/latex/bidi/bidi-doc-title.ltx +++ b/macros/xetex/latex/bidi/bidi-doc-title.ltx @@ -3,7 +3,7 @@ \begin{document} \title{\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}}\\ \LARGE Bidirectional typesetting in plain \TeX{} and \LaTeX, using \XeTeX{} engine\\[5pt] -\large User documentation for \textcolor{blue!65!black}{version 39.0}} +\large User documentation for \textcolor{blue!65!black}{version 39.1}} \author{Vafa Khalighi\thanks{Thanks to the bidi-tex GitHub organization consisted of David Carlisle and other members of the {\LaTeX} team to maintain the package in the period 2018--2020.}} \setcounter{page}{0} \thispagestyle{empty} @@ -13,7 +13,7 @@ \textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}} \Large -User documentation for \textcolor{blue!65!black}{version 39.0}} +User documentation for \textcolor{blue!65!black}{version 39.1}} \vskip 0pt plus 3fill \textit{\large to my Master, \textbf{Ferdowsi The Great}} diff --git a/macros/xetex/latex/bidi/bidi-doc.ltx b/macros/xetex/latex/bidi/bidi-doc.ltx index da07921788..4157cb16de 100644 --- a/macros/xetex/latex/bidi/bidi-doc.ltx +++ b/macros/xetex/latex/bidi/bidi-doc.ltx @@ -1,7 +1,7 @@ \documentclass{ltxdoc} \input{bidi-doc-preamble.ltx} \hypersetup{% - pdftitle={User documentation for version 39.0 of the bidi + pdftitle={User documentation for version 39.1 of the bidi package}% } \begin{document} diff --git a/macros/xetex/latex/bidi/bidi-doc.pdf b/macros/xetex/latex/bidi/bidi-doc.pdf Binary files differindex c454035c7d..9f7026185c 100644 --- a/macros/xetex/latex/bidi/bidi-doc.pdf +++ b/macros/xetex/latex/bidi/bidi-doc.pdf diff --git a/macros/xetex/latex/bidi/bidi.dtx b/macros/xetex/latex/bidi/bidi.dtx index d6863a47a8..d081d45275 100644 --- a/macros/xetex/latex/bidi/bidi.dtx +++ b/macros/xetex/latex/bidi/bidi.dtx @@ -5,7 +5,7 @@ %<*readme> ___________________ The bidi package -v39.0 +v39.1 This package provides a convenient interface for typesetting bidirectional texts in Plain TeX and LaTeX, using XeTeX engine. @@ -30,7 +30,7 @@ The announcements for the new releases of the package will also appear in the Discussions space under the Announcements category. -Current version release date: 2022/07/10 +Current version release date: 2022/07/12 ___________________________________________ Vafa Khalighi @@ -267,7 +267,7 @@ by Vafa Khalighi. \documentclass{ltxdoc} \input{bidi-doc-preamble.ltx} \hypersetup{% - pdftitle={Source documentation for version 39.0 of the bidi + pdftitle={Source documentation for version 39.1 of the bidi package}% } \EnableCrossrefs @@ -286,7 +286,7 @@ by Vafa Khalighi. % \GetFileInfo{\jobname.dtx} % \title{\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}}\\ %\LARGE Bidirectional typesetting in plain \TeX{} and \LaTeX, using \XeTeX{} engine\\[5pt] -%\large Source documentation for \textcolor{blue!65!black}{version 39.0}} +%\large Source documentation for \textcolor{blue!65!black}{version 39.1}} % \author{Vafa Khalighi\thanks{Thanks to the bidi-tex GitHub organization consisted of David Carlisle and other members of the {\LaTeX} team to maintain the package in the period 2018--2020.}} %\setcounter{page}{0} %\thispagestyle{empty} @@ -296,7 +296,7 @@ by Vafa Khalighi. %\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}} % %\Large -%Source documentation for \textcolor{blue!65!black}{version 39.0}} +%Source documentation for \textcolor{blue!65!black}{version 39.1}} % %\vskip 0pt plus 3fill %\textit{\large to my Master, \textbf{Ferdowsi The Great}} @@ -345,7 +345,7 @@ by Vafa Khalighi. %\iffalse %<*table> %\fi -%% \CheckSum{55412} +%% \CheckSum{55408} %% \CharacterTable %% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z %% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z @@ -4589,8 +4589,8 @@ by Vafa Khalighi. % \section{File \texttt{bidi.sty}} % \begin{macrocode} \NeedsTeXFormat{LaTeX2e} -\def\bididate{2022/07/10} -\def\bidi@version{39.0} +\def\bididate{2022/07/12} +\def\bidi@version{39.1} \ProvidesPackage{bidi}[\bididate\space v\bidi@version\space Bidirectional typesetting in plain TeX and LaTeX] \edef\@bidi@info{****************************************************^^J% @@ -4677,7 +4677,7 @@ Bidirectional typesetting in plain TeX and LaTeX] } \newcommand*{\@bidi@pdfcustomproperties}{% This is the bidi package, Version \bidi@version, - Released July 10, 2022. + Released July 12, 2022. } \newcommand*{\bidi@beamer@ragged}{} \@RTLmainfalse @@ -4921,9 +4921,9 @@ Bidirectional typesetting in plain TeX and LaTeX] %\fi % \section{File \texttt{bidi.tex}} % \begin{macrocode} -\def\bididate{2022/07/10} +\def\bididate{2022/07/12} \catcode`@=11 -\def\bidi@version{39.0} +\def\bidi@version{39.1} \let \protect \relax \newlinechar`\^^J \edef\@bidi@info{****************************************************^^J% @@ -5025,7 +5025,7 @@ Bidirectional typesetting in plain TeX and LaTeX] } \def\@bidi@pdfcustomproperties{% This is the bidi package, Version \bidi@version, - Released July 10, 2022. + Released July 12, 2022. } \def\bidi@pdfm@mark{% \special{pdf:% @@ -12541,7 +12541,7 @@ bidi implementation of tufte title] %\fi % \section{File \texttt{extrafootnotefeatures-xetex-bidi.def}} % \begin{macrocode} -\ProvidesFile{extrafootnotefeatures-xetex-bidi.def}[2022/07/10 v2.2 bidi extra footnote features for XeTeX engine] +\ProvidesFile{extrafootnotefeatures-xetex-bidi.def}[2022/07/12 v2.3 bidi extra footnote features for XeTeX engine] \newdimen\bidi@columnwidth \def\bidi@floathook{% \bidi@columnwidth\columnwidth @@ -12793,6 +12793,7 @@ bidi implementation of tufte title] \@tempskipa\skip#1% \bidi@ifmulticol{\divide\@tempskipa\col@number}{}% \edef\bidi@footskip{\vskip\the\@tempskipa\relax}% + \bidi@removexfootskip \ifvoid\footins \global\setbox\footins\vbox{#2#3}% \else @@ -12858,12 +12859,12 @@ bidi implementation of tufte title] }% } \newinsert\footinsv@r -\skip\footinsv@r\bigskipamount +\skip\footinsv@r\skip\footins \count\footinsv@r=1000 % no magnifcation \dimen\footinsv@r=\footinsdim \m@make@footstart{v@r} \newinsert\footinsv@l -\skip\footinsv@l\bigskipamount +\skip\footinsv@l\skip\footins \count\footinsv@l=1000 % no magnifcation \dimen\footinsv@l=\footinsdim \m@make@footstart{v@l} @@ -14208,6 +14209,10 @@ bidi implementation of tufte title] \let\bidi@xparaskip\relax \@onlypreamble\AddExtraParaSkip \@onlypreamble\bidi@xparaskip +\def\bidi@startparafootskip#1{% + \global\advance\skip#1\bidi@paraskip +} +\@onlypreamble\bidi@startparafootskip \bidi@ensure@newcommand{\paragraphfootnotes}{% \@namedef{foottextfontv@r}{\foottextfont}% % [RS] \@namedef{foottextfontv@l}{\LTRfoottextfont}% @@ -14217,6 +14222,7 @@ bidi implementation of tufte title] \let\@RTLfootnotetext\@paraRTLfootnotetext \dimen\footinsv@r=\footinsdim \count\footinsv@r=1000\relax + \let\bidi@removexfootskip\bidi@removexparafootskip \m@make@para@footgroup{v@r}% \m@make@para@footstart{v@r}% \let\@footgroupv@r\@para@footgroupv@r @@ -14255,11 +14261,13 @@ bidi implementation of tufte title] \bidi@xparaskip \xdef\bidi@paraskip{\the\@tempdima\relax}% \endgroup + \bidi@startparafootskip\footinsv@r + \bidi@startparafootskip\footinsv@l } \@ifstar\bidi@star@footmarkwidth\bidi@normal@footmarkwidth } \newcommand{\normalRTLparaLTRfootnotes}{% - \@namedef{foottextfontv@r}{\foottextfont}% + \@namedef{foottextfontv@l}{\LTRfoottextfont}% \@bidi@before@Hy@hyperfootnotes \if@RTL@footnote \let\@footnotetext\m@mold@footnotetext @@ -14268,14 +14276,9 @@ bidi implementation of tufte title] \fi \let\@LTRfootnotetext\@paraLTRfootnotetext \let\@RTLfootnotetext\m@mold@RTLfootnotetext - \dimen\footinsv@r=\footinsdim - \count\footinsv@r=1000\relax - \m@make@para@footgroup{v@r}% - \m@make@para@footstart{v@r}% - \let\@footgroupv@r\@para@footgroupv@r - \let\@footstartv@r\@para@footstartv@r \dimen\footinsv@l=\footinsdim \count\footinsv@l=1000\relax + \let\bidi@removexfootskip\bidi@removexparafootskip \bidi@make@para@LTRfootgroup{v@l}% \m@make@para@footstart{v@l}% \let\@LTRfootgroupv@l\@para@LTRfootgroupv@l @@ -14288,9 +14291,7 @@ bidi implementation of tufte title] \let\@mpLTRfootnotetext\@mpparaLTRfootnotetext \let\@mpRTLfootnotetext\m@mold@mpRTLfootnotetext \@bidi@after@Hy@hyperfootnotes - \m@make@mppara@footgroup{v@r}% \bidi@make@mppara@LTRfootgroup{v@l}% - \let\mp@footgroupv@r\@mppara@footgroupv@r \let\mp@LTRfootgroupv@l\@mppara@LTRfootgroupv@l \g@addto@macro\bidi@floathook{% \begingroup @@ -14312,6 +14313,7 @@ bidi implementation of tufte title] \bidi@xparaskip \xdef\bidi@paraskip{\the\@tempdima\relax}% \endgroup + \bidi@startparafootskip\footinsv@l } \@ifstar\bidi@star@footmarkwidth\bidi@normal@footmarkwidth } @@ -14424,8 +14426,6 @@ bidi implementation of tufte title] \m@mungebox}\m@mmf@prepare} \bidi@ensure@newcommand{\m@make@para@footgroup}[1]{% \@namedef{@para@footgroup#1}{% - \advance\@tempskipa -\bidi@paraskip - \edef\bidi@footskip{\vskip\the\@tempskipa\relax}% \unvbox\@nameuse{footins#1} \@RTLtrue \m@mmakehboxofhboxes @@ -14437,8 +14437,6 @@ bidi implementation of tufte title] \noindent\unhbox0\par}} \bidi@ensure@newcommand{\bidi@make@para@LTRfootgroup}[1]{% \@namedef{@para@LTRfootgroup#1}{% - \advance\@tempskipa -\bidi@paraskip - \edef\bidi@footskip{\vskip\the\@tempskipa\relax}% \unvbox\@nameuse{footins#1} \@RTLfalse \m@mmakehboxofhboxes @@ -14448,6 +14446,11 @@ bidi implementation of tufte title] \def\baselinestretch{\m@m@footnote@spacing}% \@nameuse{foottextfont#1}% \noindent\unhbox0\par}} +\newcommand{\bidi@removexparafootskip}{% + \advance\@tempskipa -\bidi@paraskip + \edef\bidi@footskip{\vskip\the\@tempskipa\relax}% +} +\let\bidi@removexfootskip\relax \bidi@ensure@newcommand{\m@make@mppara@footgroup}[1]{% \@namedef{@mppara@footgroup#1}{% \unvbox\@nameuse{@mpfootins#1} @@ -14468,7 +14471,6 @@ bidi implementation of tufte title] \noindent\unhbox0\par}} \bidi@ensure@newcommand{\m@make@para@footstart}[1]{% \@namedef{@para@footstart#1}{% - \global\advance\skip\@nameuse{footins#1}\bidi@paraskip \leftskip=\z@ \rightskip=\z@ \parindent=\z@ diff --git a/macros/xetex/latex/bidi/bidi.pdf b/macros/xetex/latex/bidi/bidi.pdf Binary files differindex 219aa88c62..152a05a677 100644 --- a/macros/xetex/latex/bidi/bidi.pdf +++ b/macros/xetex/latex/bidi/bidi.pdf |