%\documentclass[sunil1,ChapterTOCs]{sunil}
\documentclass[sunil1]{sunil}

\oddsidemargin=5.25pc
\evensidemargin=5.5pc
\topmargin=3.5pc

% LOAD PACKAGES
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{graphicx}
\usepackage{subfigure}
\usepackage{latexsym}
\usepackage{pstcol,pstricks,pst-text,pst-grad,pst-node}
\usepackage{wasysym}
\usepackage{marvosym}
\usepackage{amscd}
\usepackage{psfrag}
\usepackage{pxfonts}

\usepackage{makeidx}
\makeindex

%\usepackage{showidx}
\usepackage{multicol}
\frenchspacing
\tolerance=5000

\usepackage{setspace}


% CONTROL CAPTION FONTS
\newcommand{\captionfonts}{\textrm{}}
\makeatletter  % Allow the use of @ in command names
\long\def\@makecaption#1#2{%
  \vskip\abovecaptionskip
 \sbox\@tempboxa{{\captionfonts #1: #2}}%
  \ifdim \wd\@tempboxa >\hsize
    {\captionfonts #1: #2\par}
 \else
    \hbox to\hsize{\hfil\box\@tempboxa\hfil}%
  \fi
  \vskip\belowcaptionskip}
\makeatother   % Cancel the effect of \makeatletter


% LOAD MY MACRO FILE CONSISTING OF SHORTCUTS FOR SYMBOLS AND COMMANDS. FOR EXAMPLE, MY SHORTCUT
%%%%%%FOR $\displaystyle ...$ is $\ds ...$.

\input{My_Macros.tex}

% USE A HEADER CONSISTING OF CHAPTER NUMBER ON LEFT AND SECTION NUMBER ON RIGHT
\usepackage{fancyhdr}
    \renewcommand{\chaptermark}[1]{         % Lower Case Chapter marker style
      \markboth{\chaptername\ \thechapter.\ #1}{}} %
    \renewcommand{\sectionmark}[1]{        % Lower case Section marker style
      \markright{\thesection.\ #1}}         %
    \fancyhead[LE,RO]{\bfseries\thepage}    % Page number (boldface) in left on even
                                            % pages and right on odd pages
    \fancyhead[RE]{\bfseries\leftmark}      % Chapter in the right on even pages
    \fancyhead[LO]{\bfseries\rightmark}     % Section in the left on odd pages



% CREATE THEOREM-LIKE STRUCTURES

\theoremstyle{definition}
\newtheorem{definition}{Definition}[section]
\newtheorem{theorem}{Theorem}[section]
\newtheorem{activity}{Sample Application }[section]

%Exercise indentation
\newlength{\exerciseindent}
\setlength{\exerciseindent}{1 cm}

\newtheorem{waypoint}{Waypoint}[section]
\newenvironment{progress_ck}[1][.9\linewidth]
{ \vspace{.1in} \noindent \begin{center}\begin{minipage}[c]{#1}
\centering
$\Diamondblack$  \rule{ .9 \linewidth}{.025 in}  $\Diamondblack$
% $\Diamondblack$ \hrulefill $\Diamondblack$
\begin{waypoint}}
{\end{waypoint}  $\Diamondblack$ \rule{ .9 \linewidth}{.025 in} $\Diamondblack$ \end{minipage} \end{center}}

\newcounter{progress_ck_counter}


% START OF MAIN DOCUMENT BODY

\begin{document}
\frontmatter
\pagestyle{empty}
\title{Linear and Nonlinear\\
Programming with Maple:\\
An Interactive, Applications-Based Approach}
\author{Paul E. Fishback}
\date{\today}
\maketitle

\clearemptydoublepage

    \newenvironment{dedication}
      {%\cleardoublepage
      \vspace*{\stretch{1}} \begin{center}  \LARGE}
      {\end{center} \vspace*{\stretch{3}} }
    \begin{dedication}
    \emph{\textbf{For Barb, Andy, and Margaret}}
\end{dedication}

\clearemptydoublepage
\newpage
\clearemptydoublepage

\setcounter{page}{7}

\tableofcontents

\clearemptydoublepage
\addcontentsline{toc}{chapter}{\numberline{}List of Figures}
\listoffigures

\clearemptydoublepage
\addcontentsline{toc}{chapter}{\numberline{}List of Tables}
\listoftables

\clearemptydoublepage
\addcontentsline{toc}{chapter}{\numberline{}Foreword}
\include{Foreword}

\mainmatter

\renewcommand{\sectionmark}[1]{\markright{\thesection. #1}}

\part{Linear Programming}\label{P:Linear_Programming}
\setcounter{chapter}{0}
\chapter{An Introduction to Linear Programming}\label{C:Intro_Linear_Programming}
 \include{LP_Prototype_Standard_Form}
  \include{LP_Graphical}
 \include{LP_BFS}
 \clearemptydoublepage

 \chapter{The Simplex Algorithm}\label{C:Simplex_Algorithm}
 \include{Simplex}
\include{Special_cases}
\include{Big_M}
\include{Partitioned_Matrix_View_Simplex}
 \include{Revised_Simplex}
 \include{LP_Interior_Method}

 \clearemptydoublepage
\chapter{Standard Applications of Linear Programming}\label{C:Standard_Applications}
 \include{Maple_Diet_Problem}
 \include{Transportation_Transshipment}
 \include{ShortestPath_MaximumFlow}

 \clearemptydoublepage
 \chapter{Duality and Sensitivity Analysis}\label{C:Duality_Sensitivity}
 \include{Duality}
 \include{Sensitivity}
 \include{Dual_Simplex}

 \clearemptydoublepage
 \chapter{Integer Linear Programming}\label{C:Integer_Linear_Programming}
 \include{Intro_IP_Branch_and_Bound_Method}
\include{IP_Cutting_Plane_Algorithm}
\clearemptydoublepage

\renewcommand{\sectionmark}[1]{\markright{\thesection. #1}}

\part{Nonlinear Programming}\label{P:Nonlinear_Programming}
\chapter{Algebraic Methods for Unconstrained Problems}\label{C:UnconstrainedAlgebraicMethods}
\include{Overview_of_NLP}
\include{differentiability_gradient}
\include{sufficient_first_order_convexity}
\include{sufficient_SECOND_order_convexity}

\clearemptydoublepage
\chapter{Numeric Tools for Unconstrained NLPs}\label{C:Numeric_Methods}
\include{SteepestDescentMethod}
\include{NewtonsMethod}
\include{LevenbergMarquardt}

\clearemptydoublepage
\chapter{Methods for Constrained Nonlinear Problems}\label{C:Nonlinear_Problems}
\include{Lagrangian-KKTTheorem}
\include{ConvexNLPs}
\include{SaddlePointCriteria}
\include{QuadraticProgramming}
\include{SequentialQuadraticProgramming}

\clearemptydoublepage

\appendix

\renewcommand{\chaptermark}[1]{         % Lower Case Chapter marker style
      \markboth{Appendix A}{}} %
    \renewcommand{\sectionmark}[1]{        % Lower case Section marker style
      \markright{\thesection.\ #1}}         %

\chapter{Projects}
\include{Projects/project_land_levelling}
\include{Projects/project_Welches_logistics_model}
\include{Projects/project_scheduling_prison_guards}
\include{Projects/project_breast_cancer_diagnosis}
 \include{Projects/project_markowitz_portfolio}
\include{Projects/project_predator_prey_bimatrix_game}


\clearemptydoublepage

\renewcommand{\chaptermark}[1]{         % Lower Case Chapter marker style
      \markboth{Appendix B}{}} %
    \renewcommand{\sectionmark}[1]{        % Lower case Section marker style
      \markright{Important Results from Linear Algebra}}         %
\include{Linear_Algebra_Appendix}

\clearemptydoublepage

\renewcommand{\chaptermark}[1]{         % Lower Case Chapter marker style
      \markboth{Appendix C}{}} %
    \renewcommand{\sectionmark}[1]{        % Lower case Section marker style
      \markright{Getting Started with Maple}}         %
\include{Maple_Getting_Started}

\clearemptydoublepage

\renewcommand{\chaptermark}[1]{         % Lower Case Chapter marker style
      \markboth{Appendix D}{Summary of Maple Commands}} %
           % Lower case Section marker style
      %\markright{Summary of Maple Commands}         %
\include{Maple_Appendix}

\clearemptydoublepage
\newpage
\clearemptydoublepage

\backmatter

\clearemptydoublepage
\markboth{Bibliography}{Bibliography}
\include{references}

\clearemptydoublepage
\markboth{Index}{Index}
\printindex
\end{document}
