%%
%% This is file `lwarp.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% lwarp.dtx  (with options: `package')
%% This is a generated file.
%% Copyright 2016 Brian Dunn
%% 
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3
%% of this license or (at your option) any later version.
%% The latest version of this license is in
%%   http://www.latex-project.org/lppl.txt
%% and version 1.3 or later is part of all distributions of LaTeX
%% version 2005/12/01 or later.
\NeedsTeXFormat{LaTeX2e}[1999/12/01]
\ProvidesPackage{lwarp}
    [2017/02/09 v0.20  Allows LaTeX to directly produce HTML5 output.]







\RequirePackage{iftex}

\ifLuaTeX
\RequirePackage{luatex85}% until the geometry package is updated
\fi

\RequirePackage{newunicodechar}

\newunicodechar{⨯}{\texttimes}

\ifPDFTeX
\newunicodechar{ﬀ}{ff}
\newunicodechar{ﬁ}{fi}
\newunicodechar{ﬂ}{fl}
\newunicodechar{ﬃ}{ffi}
\newunicodechar{ﬄ}{ffl}
\newunicodechar{—}{---}
\newunicodechar{–}{--}
\RequirePackage{upquote}
\else
\fi
\RequirePackage{etoolbox}[2011/01/03]

\RequirePackage{ifplatform}% sense op-system platform
\RequirePackage{comment}
\excludecomment{testing}

\RequirePackage{kvoptions}
\SetupKeyvalOptions{family=LWR,prefix=LWR@}

\newbool{warpingprint}
\newbool{warpingHTML}
\newbool{mathjax}

\newcommand{\warpprintonly}[1]{\ifbool{warpingprint}{#1}{}}
\newcommand{\warpHTMLonly}[1]{\ifbool{warpingHTML}{#1}{}}

\includecomment{warpall}

\DeclareVoidOption{warpprint}{%
\PackageInfo{lwarp}{Using option 'warpprint'}
\includecomment{warpprint}%
\excludecomment{warpHTML}%
\booltrue{warpingprint}%
\boolfalse{warpingHTML}%
}

\DeclareVoidOption{warpHTML}{%
\PackageInfo{lwarp}{Using option 'warpHTML'}
\excludecomment{warpprint}%
\includecomment{warpHTML}%
\booltrue{warpingHTML}%
\boolfalse{warpingprint}%
}

\DeclareVoidOption{mathsvg}{%
\PackageInfo{lwarp}{Using option 'mathsvg'}
\boolfalse{mathjax}%
}
\DeclareVoidOption{mathjax}{%
\PackageInfo{lwarp}{Using option 'mathjax'}
\booltrue{mathjax}%
}

\DeclareStringOption[\jobname]{BaseJobname}

\includecomment{warpprint}%
\excludecomment{warpHTML}%
\booltrue{warpingprint}%
\boolfalse{warpingHTML}%
\boolfalse{mathjax}%


\ProcessKeyvalOptions*\relax

\providecommand*{\BaseJobname}{\LWR@BaseJobname}

\def\@nameedef#1{\expandafter\edef\csname #1\endcsname}



\begin{warpall}


\RequirePackage{iftex}
\newif\ifxetexorluatex
\ifXeTeX
    \xetexorluatextrue
\else
    \ifLuaTeX
        \xetexorluatextrue
    \else
        \xetexorluatexfalse
    \fi
\fi

\end{warpall}

\begin{warpHTML}
\ifxetexorluatex
\defaultfontfeatures[\rmfamily]{Ligatures={NoCommon,TeX}}
\defaultfontfeatures[\sffamily]{Ligatures={NoCommon,TeX}}
\defaultfontfeatures[\ttfamily]{Ligatures=NoCommon}
\else

\RequirePackage {microtype}

\microtypesetup{
protrusion=false,
expansion=false,
tracking=false,
kerning=false,
spacing=false}

\DisableLigatures[f,q,t,T,Q]{encoding = *,family = *}
\fi
\end{warpHTML}

\begin{warpHTML}
\RequirePackage[paperheight=190in,paperwidth=20in,%
left=7in,right=7in,%
top=1in,bottom=1in,%
]{geometry}
\end{warpHTML}

\begin{warpall}

\RequirePackage{xparse}

\end{warpall}

\begin{warpHTML}

\RequirePackage{expl3}



\RequirePackage{gettitlestring}

\RequirePackage{everyhook}
\end{warpHTML}

\begin{warpall}

\RequirePackage{fancyvrb}

\end{warpall}

\begin{warpHTML}

\RequirePackage{xifthen}

\RequirePackage{xstring}

\RequirePackage{makeidx}
\makeindex

\RequirePackage{calc}

\RequirePackage{newfloat}

\RequirePackage{caption}

\RequirePackage{subcaption}

\RequirePackage{enumitem}
\setlist[itemize]{leftmargin=0em}
\setlist[enumerate]{leftmargin=0em}
\setlist[description]{leftmargin=0em}

\RequirePackage[continuous]{pagenote}
\makepagenote
\let\LWR@origmakepagenote\makepagenote
\let\LWR@origprintnotes\printnotes
\let\LWR@origpagenote\pagenote
\end{warpHTML}

\begin{warpall}

\RequirePackage{titling}

\end{warpall}

\begin{warpHTML}

\RequirePackage{zref}

\PassOptionsToPackage{leqno,fleqn}{amsmath}
\RequirePackage{amsmath}

\RequirePackage{environ}

\RequirePackage[nopatches]{titleps}
\let\LWR@origpagestyle\pagestyle
\renewcommand*{\pagestyle}[1]{}
\let\LWR@origthispagestyle\thispagestyle
\renewcommand*{\thispagestyle}[1]{}
\let\LWR@origpagenumbering\pagenumbering
\renewcommand*{\pagenumbering}[1]{}


\RequirePackage{xfrac}

\RequirePackage{printlen}

\end{warpHTML}

\begin{warpHTML}

\let\LWR@origRequirePackage\RequirePackage

\newcommand*{\LWR@requirepackagenames}{}

\newcommand*\LWR@findword[3][,]{%
    \StrBetween[#3,\numexpr#3+1]{#1#2#1}{#1}{#1}%
}
\newcommand*{\LWR@lookforpackagename}[1]{
\LWR@findword{\LWR@requirepackagenames}{#1}[\LWR@strresult]
\IfStrEq{\LWR@strresult}{}
{}% no filename
{% yes filename
\IfFileExists{lwarp-\LWR@strresult.sty}
{% latex_html_ file found
\StrSubstitute
{\LWR@requirepackagenames}
{\LWR@strresult}
{lwarp-\LWR@strresult}[\LWR@requirepackagenames]
}
{}% no latex_html_* file
}% yes filename
}
\RenewDocumentCommand{\RequirePackage}{o m o}{%
\renewcommand*{\LWR@requirepackagenames}{#2}
\LWR@lookforpackagename{1}
\LWR@lookforpackagename{2}
\LWR@lookforpackagename{3}
\LWR@lookforpackagename{4}
\LWR@lookforpackagename{5}
\LWR@lookforpackagename{6}
\LWR@lookforpackagename{7}
\LWR@lookforpackagename{8}
\LWR@lookforpackagename{9}
\IfValueTF{#1}
{% options given
\IfValueTF{#3}% version given?
{\LWR@origRequirePackage[#1]{\LWR@requirepackagenames}[#3]}
{\LWR@origRequirePackage[#1]{\LWR@requirepackagenames}}
}
{% no options given
\IfValueTF{#3}% version given?
{\LWR@origRequirePackage{\LWR@requirepackagenames}[#3]}
{\LWR@origRequirePackage{\LWR@requirepackagenames}}
}
}
\let\usepackage\RequirePackage

\NewDocumentCommand{\LWR@ProvidesPackagePass}{m o}{
\PackageInfo{lwarp}{Using the lwarp version of package `#1', including options,}%
\IfValueTF{#2}
{\ProvidesPackage{lwarp-#1}[#2]}
{\ProvidesPackage{lwarp-#1}}
\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{#1}}
\ProcessOptions\relax

\IfValueTF{#2}
{\LWR@origRequirePackage{#1}[#2]}
{\LWR@origRequirePackage{#1}}
}

\NewDocumentCommand{\LWR@ProvidesPackageDrop}{m o}{
\PackageInfo{lwarp}{Using the lwarp version of package `#1', discarding options,}%
\IfValueTF{#2}
{\ProvidesPackage{lwarp-#1}[#2]}
{\ProvidesPackage{lwarp-#1}}
\DeclareOption*{}
\ProcessOptions\relax
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LWR@copyfile}[2]{%
\newwrite\copyfile  % open the file to write to
\immediate\openout\copyfile=#2
\newread\file      % open the file to read from
\openin\file=#1
\begingroup\endlinechar=-1
\makeatletter
\loop\unless\ifeof\file
  \read\file to\fileline  % Read one line and store it into \fileline
  \immediate\write\copyfile{\unexpanded\expandafter{\fileline}}%
\repeat
\closeout\copyfile
\endgroup
}

\end{warpHTML}


\newbool{LWR@tracinglwarp}
\newcommand{\tracinglwarp}{\booltrue{LWR@tracinglwarp}}
\newcommand{\LWR@traceinfo}[1]{%
\ifbool{LWR@tracinglwarp}%
{\PackageInfo{lwarp}{#1 : }}%
{}%
}


\begin{warpHTML}

\let\LWR@origtextit\textit
\let\LWR@origtextbf\textbf
\let\LWR@origtexttt\texttt
\let\LWR@origtextsc\textsc
\let\LWR@origtextsf\textsf
\let\LWR@origtextrm\textrm
\let\LWR@origbfseries\bfseries
\let\LWR@origrmfamily\rmfamily
\let\LWR@origttfamily\ttfamily
\let\LWR@orignormalfont\normalfont

\let\LWR@origraggedright\raggedright
\let\LWR@origonecolumn\onecolumn

\let\LWR@origtextsuperscript\textsuperscript
\let\LWR@origtextsubscript\textsubscript

\let\LWR@origscriptsize\scriptsize

\let\LWR@orignewpage\newpage

\let\LWR@origminipage\minipage
\let\LWR@origendminipage\endminipage

\let\LWR@orignewline\newline

\let\LWR@origitem\item

\let\LWR@origpar\par

\let\LWR@origfootnote\footnote
\let\LWR@orig@mpfootnotetext\@mpfootnotetext

\let\LWR@origclearpage\clearpage
\let\clearpage\relax
\let\cleardoublepage\relax

\end{warpHTML}

\begin{warpall}
\newbool{usingOSwindows}
\boolfalse{usingOSwindows}


\newcommand*{\OSPathSymbol}{/}

\newcommand*{\OSmkdir}{mkdir } % trailing space is required

\newcommand*{\OSrm}{rm }

\newcommand*{\OSmv}{mv }

\newcommand*{\OSShellPath}{/bin/sh}


\newcommand*{\warpOSwindows}
{
\booltrue{usingOSwindows}
\renewcommand*{\OSPathSymbol}{\@backslashchar}
\renewcommand*{\OSmkdir}{MD }
\renewcommand*{\OSrm}{DEL }
\renewcommand*{\OSmv}{MOVE }
}
\ifwindows
\warpOSwindows
\fi

\end{warpall}


\begin{warpHTML}



\newcommand*{\LWR@depthnone}{-5}
\newcommand*{\LWR@depthfinished}{-4}
\newcommand*{\LWR@depthpart}{-1}
\newcommand*{\LWR@depthchapter}{0}
\newcommand*{\LWR@depthsection}{1}
\newcommand*{\LWR@depthsubsection}{2}
\newcommand*{\LWR@depthsubsubsection}{3}
\newcommand*{\LWR@depthparagraph}{4}
\newcommand*{\LWR@depthsubparagraph}{5}
\newcommand*{\LWR@depthlist}{6}
\newcommand*{\LWR@depthlistitem}{7}


\newcommand*{\LWR@closeone}{}% top of the stack
\newcommand*{\LWR@closetwo}{}
\newcommand*{\LWR@closethree}{}
\newcommand*{\LWR@closefour}{}
\newcommand*{\LWR@closefive}{}
\newcommand*{\LWR@closesix}{}
\newcommand*{\LWR@closeseven}{}
\newcommand*{\LWR@closeeight}{}
\newcommand*{\LWR@closenine}{}
\newcommand*{\LWR@closeten}{}
\newcommand*{\LWR@closeeleven}{}
\newcommand*{\LWR@closetwelve}{}




\newcommand*{\LWR@closedepthone}{\LWR@depthnone}% top of the stack
\newcommand*{\LWR@closedepthtwo}{\LWR@depthnone}
\newcommand*{\LWR@closedepththree}{\LWR@depthnone}
\newcommand*{\LWR@closedepthfour}{\LWR@depthnone}
\newcommand*{\LWR@closedepthfive}{\LWR@depthnone}
\newcommand*{\LWR@closedepthsix}{\LWR@depthnone}
\newcommand*{\LWR@closedepthseven}{\LWR@depthnone}
\newcommand*{\LWR@closedeptheight}{\LWR@depthnone}
\newcommand*{\LWR@closedepthnine}{\LWR@depthnone}
\newcommand*{\LWR@closedepthten}{\LWR@depthnone}
\newcommand*{\LWR@closedeptheleven}{\LWR@depthnone}
\newcommand*{\LWR@closedepthtwelve}{\LWR@depthnone}



\NewDocumentCommand{\pushclose}{m m}
{
\let\LWR@closetwelve\LWR@closeeleven
\let\LWR@closeeleven\LWR@closeten
\let\LWR@closeten\LWR@closenine
\let\LWR@closenine\LWR@closeeight
\let\LWR@closeeight\LWR@closeseven
\let\LWR@closeseven\LWR@closesix
\let\LWR@closesix\LWR@closefive
\let\LWR@closefive\LWR@closefour
\let\LWR@closefour\LWR@closethree
\let\LWR@closethree\LWR@closetwo
\let\LWR@closetwo\LWR@closeone
\let\LWR@closeone#1
\let\LWR@closedepthtwelve\LWR@closedeptheleven
\let\LWR@closedepthelevel\LWR@closedepthten
\let\LWR@closedepthten\LWR@closedepthnine
\let\LWR@closedepthnine\LWR@closedeptheight
\let\LWR@closedeptheight\LWR@closedepthseven
\let\LWR@closedepthseven\LWR@closedepthsix
\let\LWR@closedepthsix\LWR@closedepthfive
\let\LWR@closedepthfive\LWR@closedepthfour
\let\LWR@closedepthfour\LWR@closedepththree
\let\LWR@closedepththree\LWR@closedepthtwo
\let\LWR@closedepthtwo\LWR@closedepthone
\let\LWR@closedepthone#2
}


\newcommand*{\popclose}
{
\let\LWR@closeone\LWR@closetwo
\let\LWR@closetwo\LWR@closethree
\let\LWR@closethree\LWR@closefour
\let\LWR@closefour\LWR@closefive
\let\LWR@closefive\LWR@closesix
\let\LWR@closesix\LWR@closeseven
\let\LWR@closeseven\LWR@closeeight
\let\LWR@closeeight\LWR@closenine
\let\LWR@closenine\LWR@closeten
\let\LWR@closeten\LWR@closeeleven
\let\LWR@closeeleven\LWR@closetwelve
\let\LWR@closedepthone\LWR@closedepthtwo
\let\LWR@closedepthtwo\LWR@closedepththree
\let\LWR@closedepththree\LWR@closedepthfour
\let\LWR@closedepthfour\LWR@closedepthfive
\let\LWR@closedepthfive\LWR@closedepthsix
\let\LWR@closedepthsix\LWR@closedepthseven
\let\LWR@closedepthseven\LWR@closedeptheight
\let\LWR@closedeptheight\LWR@closedepthnine
\let\LWR@closedepthnine\LWR@closedepthten
\let\LWR@closedepthten\LWR@closedeptheleven
\let\LWR@closedeptheleven\LWR@closedepthtwelve
}

\end{warpHTML}

\begin{warpHTML}
\NewDocumentCommand{\LWR@setexparray}{m m m}{%
\expandafter\edef\csname #1#2\endcsname{\expandonce#3}%
}
\newcommand*{\LWR@getexparray}[2]{\csuse{#1#2}}

\end{warpHTML}


\begin{warpHTML}

\let\LWR@origampersand\&
\newcommand*{\HTMLentity}[1]{\LWR@origampersand#1;}
\newcommand*{\HTMLunicode}[1]{\HTMLentity{\#x#1}}

\renewcommand*{\&}{\HTMLentity{amp}}

\let\LWR@origtextless\textless
\renewcommand*{\textless}{\HTMLentity{lt}}

\let\LWR@origtextgreater\textgreater
\renewcommand*{\textgreater}{\HTMLentity{gt}}

\end{warpHTML}



\begin{warpall}

\providecommand*{\BaseJobname}{\jobname}

\providecommand*{\HTMLFileName}{}
\providecommand*{\HomeHTMLFileName}{\BaseJobname}

\newcommand*{\SetHTMLFileNumber}[1]{%
\setcounter{LWR@htmlfilenumber}{#1}%
}

\newbool{FileSectionNames}
\booltrue{FileSectionNames}

\end{warpall}

\begin{warpHTML}

\newcounter{LWR@htmlfilenumber}
\setcounter{LWR@htmlfilenumber}{0}

\newcommand*{\LWR@htmlsectionfilename}[1]{%
\LWR@traceinfo{LWR@htmlsectionfilename A}%
\LWR@traceinfo{about to assign temp}%
\edef\LWR@tempone{#1}%
\LWR@traceinfo{about to compare with ??}%
\ifthenelse{\equal{\LWR@tempone}{??}}%
{%
\LWR@traceinfo{found ??}%
}{%
\LWR@traceinfo{not found ??}%
}%
\LWR@traceinfo{about to compare with zero or empty}%
\ifthenelse{%
\equal{\LWR@tempone}{0}%
\OR \equal{\LWR@tempone}{}%
\OR \equal{\LWR@tempone}{??}%
}%
{%
\LWR@traceinfo{LWR@htmlsectionfilename B \HomeHTMLFileName.html}%
\HomeHTMLFileName.html%
}%
{%
\LWR@traceinfo{LWR@htmlsectionfilename C}%
\ifthenelse{%
\equal{\HTMLFileName}{} \AND \equal{\LWR@tempone}{Index} \OR \equal{\LWR@tempone}{index}%
}%
{\_#1.html}%
{\HTMLFileName#1.html}%
}%
\LWR@traceinfo{LWR@htmlsectionfilename Z}%
}

\newcommand*{\LWR@htmlrefsectionfilename}[1]{%
\LWR@traceinfo{LWR@htmlrefsectionfilename A: !#1!}%
\LWR@htmlsectionfilename{\LWR@htmlfileref{#1}}%
\LWR@traceinfo{LWR@htmlrefsectionfilename B}%
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LinkHome}{%
\LWR@subhyperrefclass{%
\HomeHTMLFileName.html}%
{Home}{linkhome}%
}

\newcommand*{\LWR@topnavigation}{
\LWR@htmlelementclassline{nav}{topnavigation}{\LinkHome}
}

\newcommand*{\LWR@botnavigation}{
\LWR@htmlelementclassline{nav}{botnavigation}{\LinkHome}
}

\end{warpHTML}



\begin{warpHTML}

\newcommand*{\PrintStack}{
\LWR@startpars
\LWR@closedepthone{} \LWR@closedepthtwo{} \LWR@closedepththree{}
\LWR@closedepthfour{} \LWR@closedepthfive{} \LWR@closedepthsix{}
\LWR@closedepthseven{} \LWR@closedeptheight{} \LWR@closedepthnine{}
\LWR@closedepthten{} \LWR@closedeptheleven{} \LWR@closedepthtwelve{}
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LWR@closeoneprevious}{%

\LWR@closeone{}

\popclose{}
}

\newcommand*{\LWR@closeprevious}[1]{
\LWR@stoppars
\whiledo{\not\(\LWR@closedepthone<#1\)}{\LWR@closeoneprevious}
}

\end{warpHTML}


\begin{warpHTML}


\newcommand*{\LWR@tagpart}{h2}
\newcommand*{\LWR@tagpartend}{/h2}
\newcommand*{\LWR@tagchapter}{h3}
\newcommand*{\LWR@tagchapterend}{/h3}
\newcommand*{\LWR@tagsection}{h4}
\newcommand*{\LWR@tagsectionend}{/h4}
\newcommand*{\LWR@tagsubsection}{h5}
\newcommand*{\LWR@tagsubsectionend}{/h5}
\newcommand*{\LWR@tagsubsubsection}{h6}
\newcommand*{\LWR@tagsubsubsectionend}{/h6}
\newcommand*{\LWR@tagparagraph}{span class="paragraph"{}}
\newcommand*{\LWR@tagparagraphend}{/span}
\newcommand*{\LWR@tagsubparagraph}{span class="subparagraph"{}}
\newcommand*{\LWR@tagsubparagraphend}{/span}

\newcommand*{\LWR@tagregularparagraph}{p}


\newcommand*{\LWR@htmltagc}[1]{%
{%
\LWR@origttfamily%
\LWR@origtextless#1\LWR@origtextgreater%
}%
}

\newenvironment*{LWR@nestspan}
{%
\addtocounter{LWR@spandepth}{1}%
\RenewDocumentEnvironment{minipage}{O{t} o O{t} m}{}{}%
}%
{\addtocounter{LWR@spandepth}{-1}}

\NewDocumentCommand{\LWR@htmlspan}{m +m}{%
\LWR@ensuredoingapar%
\LWR@htmltagc{#1}%
\begin{LWR@nestspan}%
#2%
\LWR@htmltagc{/#1}%
\end{LWR@nestspan}%
}

\NewDocumentCommand{\LWR@htmlspanclass}{m o +m}{%
\LWR@ensuredoingapar%
\LWR@subhtmlelementclass{span}{#1}[#2]%
\begin{LWR@nestspan}%
#3%
\LWR@htmltagc{/span}%
\end{LWR@nestspan}%
}


\newcommand*{\LWR@htmltagb}[1]{%
\LWR@htmltagc{#1}%
\endgroup%
}

\newcommand*{\LWR@htmltag}{%
\begingroup\catcode`\_=12
\LWR@htmltagb%
}


\newcommand*{\LWR@htmlopencomment}{%
\begingroup\LWR@origttfamily\LWR@origtextless{}!{-}{-}\endgroup%
}

\newcommand*{\LWR@htmlclosecomment}{%
\begingroup\LWR@origttfamily{-}{-}\LWR@origtextgreater{}\endgroup%
}

\newcommand{\LWR@htmlcomment}[1]{%
\LWR@htmlopencomment{}%
\LWR@origtextrm{#1}%
\LWR@htmlclosecomment{}}
\newcommand{\LWR@htmlblockcommentb}[1]
{\LWR@stoppars\LWR@htmlcomment{#1}\LWR@startpars\endgroup}

\newcommand{\LWR@htmlblockcomment}
{%
\begingroup\catcode`\_=12%
\LWR@htmlblockcommentb%
}

\newcommand*{\LWR@htmlblocktag}[1]{%
\LWR@stoppars%
\LWR@htmltag{#1}%
\LWR@startpars%
}

\NewDocumentCommand{\LWR@htmlblocktagcomment}{m +m}{%
\LWR@stoppars%
\LWR@htmltag{#1}\LWR@htmlcomment{#2}\LWR@orignewline%
\LWR@startpars%
}


\NewDocumentCommand{\LWR@subhtmlelementclass}{m m o}{%
\IfValueTF{#3}%
{% option
\ifthenelse{\equal{#3}{}}%
{\LWR@htmltag{#1 class="#2"}}% empty option
{\LWR@htmltag{#1 class="#2" style="#3"}}% non-empty option
}% option
{\LWR@htmltag{#1 class="#2"}}% no option
}

\NewDocumentCommand{\LWR@htmlelementclass}{m m o}{%
\LWR@stoppars%
\LWR@subhtmlelementclass{#1}{#2}[#3]%
\LWR@startpars%
}

\newcommand*{\LWR@htmlelementclassend}[2]{%
\LWR@stoppars%
\LWR@htmltag{/#1}%
\LWR@htmlcomment{End of #1 ``#2''}%
\LWR@startpars%
}

\NewDocumentCommand{\LWR@htmldivclass}{m o}{%
\LWR@htmlelementclass{div}{#1}[#2]%
}

\newcommand*{\LWR@htmldivclassend}[1]{%
\LWR@htmlelementclassend{div}{#1}%
}



\NewDocumentCommand{\LWR@htmlelementclassline}{m m o +m}{%
\LWR@stoppars
\LWR@subhtmlelementclass{#1}{#2}[#3]%
#4%
\LWR@htmltag{/#1}
\LWR@startpars
}


\newcommand*{\LWR@htmlelement}[1]{%
\LWR@htmlblocktag{#1}
}

\newcommand*{\LWR@htmlelementend}[1]{%
\LWR@stoppars
\LWR@htmltag{/#1}
\LWR@startpars
}

\end{warpHTML}




\begin{warpHTML}
\NewDocumentEnvironment{BlockClass}{m o}
{
\LWR@htmldivclass{#1}[#2]
}
{
\LWR@htmldivclassend{#1}
}
\end{warpHTML}
\begin{warpprint}
\NewDocumentEnvironment{BlockClass}{m o}{}{}
\end{warpprint}
\begin{warpHTML}
\newcommand{\BlockClassSingle}[2]{%
\LWR@htmlelementclassline{div}{#1}{#2}%
}
\end{warpHTML}
\begin{warpprint}
\newcommand{\BlockClassSingle}[2]{#2}
\end{warpprint}

\begin{warpHTML}
\NewDocumentCommand{\InlineClass}{m o m}{%
\LWR@htmlspanclass{#1}[#2]{#3}%
}
\end{warpHTML}
\begin{warpprint}
\NewDocumentCommand{\InlineClass}{m o m}{#3}
\end{warpprint}


\begin{warpHTML}

\newcommand*{\LWR@printclosepart}
    {\LWR@htmlcomment{Closing part}}
\newcommand*{\LWR@printclosechapter}
    {\LWR@htmlcomment{Closing chapter}}
\newcommand*{\LWR@printclosesection}
    {\LWR@htmlcomment{Closing section}}
\newcommand*{\LWR@printclosesubsection}
    {\LWR@htmlcomment{Closing subsection}}
\newcommand*{\LWR@printclosesubsubsection}
    {\LWR@htmlcomment{Closing subsubsection}}
\newcommand*{\LWR@printcloseparagraph}
    {\LWR@htmlcomment{Closing paragraph}}
\newcommand*{\LWR@printclosesubparagraph}
    {\LWR@htmlcomment{Closing subparagraph}}

\newcommand*{\LWR@printcloselistitem}
    {\LWR@htmltag{/li}}
\newcommand*{\LWR@printclosedescitem}
    {\LWR@htmltag{/dd}}
\newcommand*{\LWR@printcloseitemize}
    {\LWR@htmltag{/ul}}
\newcommand*{\LWR@printcloseenumerate}
    {\LWR@htmltag{/ol}}
\newcommand*{\LWR@printclosedescription}
    {\LWR@htmltag{/dl}}

\end{warpHTML}


\begin{warpHTML}

\newcounter{LWR@spandepth}
\setcounter{LWR@spandepth}{0}

\newbool{LWR@doingstartpars}
\boolfalse{LWR@doingstartpars}

\newbool{LWR@doingapar}
\global\boolfalse{LWR@doingapar}

\newcommand*{\LWR@ensuredoingapar}{%
\ifbool{LWR@doingstartpars}%
{\global\booltrue{LWR@doingapar}}%
{}%
}

\newcommand*{\LWR@openparagraph}
{%
\ifbool{LWR@doingstartpars}%
{% handling pars
\ifthenelse{%
\cnttest{\value{LWR@lateximagedepth}}{>}{0} \OR%
\cnttest{\value{LWR@spandepth}}{>}{0}%
}% nested par tags?
{}% no nested par tags
{% yes nest par tags
\LWR@htmltagc{\LWR@tagregularparagraph}%
\ifnumcomp{\@listdepth}{>}{0}%
{%
\LWR@orighspace{1in}%
}{}%
\global\booltrue{LWR@doingapar}%
\let\par\LWR@closeparagraph%
}% end of yes nest par tags
}% end of handling pars
{}% not handling pars
}

\newcommand*{\LWR@closeparagraph}
{%
\ifbool{LWR@doingapar}%
{% handling pars
\ifthenelse{%
\cnttest{\value{LWR@lateximagedepth}}{>}{0} \OR%
\cnttest{\value{LWR@spandepth}}{>}{0}%
}%
{% no nested par tags
\ifthenelse{%
\cnttest{\value{LWR@spandepth}}{>}{0}%
\AND%
\cnttest{\value{LWR@lateximagedepth}}{=}{0}%
}%
{%
\ifbool{LWR@intabularmetadata}{}{\unskip\LWR@htmltagc{br /}}%
}%
{}%
}% no nested par tags
{% yes nest par tags
\unskip%
\LWR@htmltagc{/\LWR@tagregularparagraph}%
\global\boolfalse{LWR@doingapar}%
\global\boolfalse{LWR@minipagethispar}%
}% end of yes nest par tags
}% end of handling pars
{% not handling pars
\ifthenelse{\cnttest{\value{LWR@spandepth}}{>}{0}}%
{\ifbool{LWR@intabularmetadata}{}{\unskip\LWR@htmltagc{br /}}}%
{}%
}% not handling pars
\LWR@origpar%
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LWR@startpars}%
{%
\ifbool{LWR@doingstartpars}%
{}%
{%
\PushPreHook{par}{\LWR@openparagraph}%
\let\par\LWR@closeparagraph

}% an intentionally blank line
\global\setbool{LWR@doingstartpars}{true}%
\global\boolfalse{LWR@doingapar}%
}

\newcommand*{\LWR@stoppars}%
{%
\ifbool{LWR@doingapar}%
{%
\unskip%
\LWR@htmltagc{/\LWR@tagregularparagraph}%
\global\boolfalse{LWR@doingapar}%
\global\boolfalse{LWR@minipagethispar}

}% an intentionally blank line
{}%
\ifbool{LWR@doingstartpars}%
{%
\ClearPreHook{par}%
}%
{}%
\global\setbool{LWR@doingstartpars}{false}%
\global\boolfalse{LWR@doingapar}%
}

\end{warpHTML}


\begin{warpall}

\newcommand{\LWR@firstpagetop}{} % for the home page alone
\newcommand{\LWR@pagetop}{} % for all other pages
\newcommand{\LWR@pagebottom}{}

\newcommand{\LWR@setfirstpagetopb}[1]{%
\renewcommand{\LWR@firstpagetop}{#1}
\catcode`\_=8
}
\newcommand{\SetFirstPageTop}{%
\catcode`\_=12
\LWR@setfirstpagetopb
}
\newcommand{\LWR@setpagetopb}[1]{%
\renewcommand{\LWR@pagetop}{#1}
\catcode`\_=8
}
\newcommand{\SetPageTop}{%
\catcode`\_=12
\LWR@setpagetopb
}
\newcommand{\LWR@setpagebottomb}[1]{%
\renewcommand{\LWR@pagebottom}{#1}
\catcode`\_=8
}
\newcommand{\SetPageBottom}{%
\catcode`\_=12
\LWR@setpagebottomb
}

\end{warpall}


\begin{warpHTML}


\newcommand*{\LWR@currentcss}{lwarp.css}

\newcommand*{\LWR@newcssb}[1]{%
\renewcommand*{\LWR@currentcss}{#1}
\catcode`\_=8
}

\newcommand*{\NewCSS}{
\catcode`\_=12
\LWR@newcssb
}
\end{warpHTML}
\begin{warpprint}
\newcommand*{\NewCSS}[1]{}
\end{warpprint}


\begin{warpHTML}


\newcommand{\LWR@currentHTMLdescription}{}

\newcommand{\NewHTMLdescription}[1]{%
\renewcommand{\LWR@currentHTMLdescription}{#1}
}

\end{warpHTML}
\begin{warpprint}
\newcommand{\NewHTMLdescription}[1]{}
\end{warpprint}

\begin{warpHTML}

\AtEndPreamble{

\renewcommand*{\notedivision}
    {\BlockClassSingle{footnoteheader}{}}


\renewcommand{\pagenotesubhead}[2]{}
\let\footnote\LWR@origpagenote
\renewcommand{\notenuminnotes}[1]{%
  \textsuperscript{#1} }

\let\LWR@orignoteentry\noteentry
\renewcommand{\noteentry}[4]{%
\begingroup%
\renewcommand*{\@currentlabel}{#1}%
\renewcommand*{\cref@currentlabel}{[pagenote][#1][]{#1}}%
\LWR@orignoteentry{#1}{#2}{#3}{#4}%
\endgroup%
}

\newcommand*{\LWR@printpendingnotes}{
\ifthenelse{\cnttest{\value{pagenote}}{>}{0}}%
{
\begin{BlockClass}{footnotes}
\LWR@origprintnotes*
\setcounter{pagenote}{0}
\end{BlockClass}
}
{}
}

}% \AtEndPreamble

\end{warpHTML}

\begin{warpHTML}

\renewcommand{\marginpar}[2][]{%
\LWR@htmlspanclass{marginpar}{#2}%
}

\end{warpHTML}


\begin{warpall}

\newcounter{FileDepth}
\setcounter{FileDepth}{-5}

\newbool{CombineHigherDepths}
\booltrue{CombineHigherDepths}

\end{warpall}

\begin{warpHTML}

\newcommand*{\LWR@thisfilename}{}

\newcommand*{\LWR@thisnewfilename}{}

\newcommand*{\LWR@filenamenoblanks}[1]{%
\begingroup

\renewcommand*{\HTMLunicode}[1]{}
\renewcommand*{\HTMLentity}[1]{##1}
\renewcommand*{\LWR@htmltagc}[1]{}
\DeclareExpandableDocumentCommand{\InlineClass}{m o m}{##3}
\renewcommand*{\&}{and}
\renewcommand{\textit}[1]{##1}
\renewcommand{\textsc}[1]{##1}
\renewcommand{\textsl}[1]{##1}
\renewcommand{\textbf}[1]{##1}
\renewcommand{\texttt}[1]{##1}
\renewcommand{\textsf}[1]{##1}
\renewcommand{\textrm}[1]{##1}
\renewcommand{\textsuperscript}[1]{##1}
\renewcommand{\textsubscript}[1]{##1}
\edef\LWR@thisnewfilename{#1}
\fullexpandarg
\StrSubstitute{\LWR@thisnewfilename}{ }{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{,}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{'}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}%
{\LWR@origampersand}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{+}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{,}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{/}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{:}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{;}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{=}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{?}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{@}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{"}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}%
{\textless}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}%
{\textgreater}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{\#}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{\%}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{\{}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{\}}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{|}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}%
{\textbackslash}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{^}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{~{}}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{[}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{]}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{`}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-s-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-S-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-a-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-A-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-an-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-AN-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-to-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-TO-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-by-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-BY-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-of-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-OF-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-and-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-AND-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-for-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-FOR-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-the-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-THE-}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{-----}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{----}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{---}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{--}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{—}{-}[\LWR@thisnewfilename]
\StrSubstitute{\LWR@thisnewfilename}{–}{-}[\LWR@thisnewfilename]
\global\let\LWR@thisfilename\LWR@thisnewfilename% return a global result
\endgroup
}

\newcommand*{\LWR@newhtmlfile}[1]{


\LWR@htmlelementclassend{section}{textbody}

\LWR@printpendingnotes

\LWR@htmlelement{footer}

\LWR@pagebottom

\LWR@htmlelementend{footer}

\ifnumcomp{\value{LWR@htmlfilenumber}}{>}{0}{\LWR@botnavigation}{}

\LWR@stoppars
\LWR@htmltag{/body}\LWR@orignewline
\LWR@htmltag{/html}\LWR@orignewline

\addtocounter{LWR@htmlfilenumber}{1}%

\ifbool{FileSectionNames}%
{\LWR@filenamenoblanks{#1}}
{\renewcommand*{\LWR@thisfilename}{\theLWR@htmlfilenumber}}

\LWR@htmlblockcomment{%
\LWR@origtexttt{|Start file|%
\LWR@htmlsectionfilename{\LWR@thisfilename}|}%
}

\LWR@stoppars

\LWR@filestart{ — #1}% there is an EMdash in front of the #1

\LWR@topnavigation

\LWR@htmlelement{header}

\LWR@pagetop

\LWR@htmlelementend{header}

\LWR@printthetitle

\LWR@sidetoc

\LWR@htmlelementclass{section}{textbody}

\LWR@stoppars

\setcounter{LWR@latestautopage}{\value{page}}
}

\end{warpHTML}


\begin{warpHTML}
\newbool{LWR@mainmatter}
\DeclareDocumentCommand{\mainmatter}{}{%
\booltrue{LWR@mainmatter}%
}

\DeclareDocumentCommand{\frontmatter}{}{%
\boolfalse{LWR@mainmatter}%
}

\DeclareDocumentCommand{\backmatter}{}{%
\boolfalse{LWR@mainmatter}
}
\newcommand*{\LWR@sectionnumber}[1]{%
\InlineClass{sectionnumber}{#1} %
}

\newcommand*{\LWR@createautosec}[1]{%
\LWR@htmltag{#1 id="autosec-\thepage"{}}%
}

\NewDocumentCommand{\LWR@pushoneclose}{m m}{\pushclose{#2}{#1}}

\NewDocumentCommand{\LWR@startnewdepth}{m m}{%
\LWR@closeprevious{#1}%
\LWR@pushoneclose{#1}{#2}%
}
\newcounter{LWR@prevFileDepth}
\setcounter{LWR@prevFileDepth}{\LWR@depthsubparagraph}
\DeclareDocumentCommand{\LWR@section}{m m m m}{%
\LWR@traceinfo{LWR@section}%
\LWR@stoppars%
\global\boolfalse{LWR@minipagethispar}%
\LWR@orignewpage%

\LWR@traceinfo{LWR@section: testing about to start a new HTML file}%
\IfBooleanTF{#1}{}{% not starred
\ifthenelse{%
\cnttest{\csuse{LWR@depth#4}}{<=}{\value{FileDepth}}%
\AND%
\(%
\NOT\boolean{CombineHigherDepths}\OR%
\cnttest{\csuse{LWR@depth#4}}{<=}{\value{LWR@prevFileDepth}}%
\)%
}%
{% new file
\LWR@traceinfo{LWR@section: new HTML file}%
\IfNoValueTF{#2}%
{\LWR@newhtmlfile{#3}}%
{\LWR@newhtmlfile{#2}}%
}% new file
{}% not new file
}% not starred
\LWR@traceinfo{LWR@section: about to LWR@setlatestname}%
\IfValueTF{#2}{\LWR@setlatestname{#2}}{\LWR@setlatestname{#3}}%

\LWR@htmlcomment{Opening #4 ``#3''{}}

\ifthenelse{%
\cnttest{\csuse{LWR@depth#4}}{>=}{\LWR@depthparagraph}%
}%
{\LWR@startpars}
{}
\LWR@createautosec{\csuse{LWR@tag#4}}%
\IfBooleanTF{#1}%
{}% starred
{% not starred
\ifthenelse{%
\cnttest{\csuse{LWR@depth#4}}{<=}{\value{secnumdepth}}%
}%
{% if secnumdepth
\LWR@traceinfo{LWR@section: about to test main matter}%
\ifbool{LWR@mainmatter}%
{%
\LWR@traceinfo{LWR@section: yes mainmatter}%
\refstepcounter{#4}%
\LWR@traceinfo{LWR@section: about to addcontentsline}%
\addcontentsline{toc}{#4}%
{\protect\LWR@sectionnumber{\csuse{the#4}}%
\IfValueTF{#2}{#2}{#3}}%
\LWR@traceinfo{LWR@section: finished addcontentsline}%
}% end of if main matter
{% not main matter
\LWR@traceinfo{LWR@section: no main matter}%
\addcontentsline{toc}{#4}{\IfValueTF{#2}{#2}{#3}}%
}% end of not main matter
}% end of secnumdepth
{%
\addcontentsline{toc}{#4}{\IfValueTF{#2}{#2}{#3}}%
}%
\ifbool{LWR@mainmatter}%
{%
\ifthenelse{%
\(\cnttest{\csuse{LWR@depth#4}}{<=}%
{\value{secnumdepth}}\) \AND
\(\cnttest{\csuse{LWR@depth#4}}{<=}{\LWR@depthpart}\)
}%
{\csuse{#4name}~{}}%
{}%
\LWR@traceinfo{LWR@section: about to print section number}%
\ifthenelse{%
\cnttest{\csuse{LWR@depth#4}}{<=}{\value{secnumdepth}}%
}%
{\protect\LWR@sectionnumber{\csuse{the#4}}}%
{}%
\LWR@traceinfo{LWR@section: finished print section number}%
}{}%
}% end of not starred
#3
\LWR@htmltag{\csuse{LWR@tag#4end}}%
\label{autopage-\thepage}%
\ifthenelse{%
\cnttest{\csuse{LWR@depth#4}}{<}{\LWR@depthparagraph}}%
{\LWR@startpars}%
{}%
\IfBooleanTF{#1}{}{% not starred
\setcounter{LWR@prevFileDepth}{\csuse{LWR@depth#4}}%
}% not starred
\LWR@traceinfo{LWR@section: done}%
}


\@ifundefined{chapter}
{}
{%
\DeclareDocumentCommand{\part}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthpart}{\LWR@printclosepart}%

\LWR@section{#1}{#2}{#3}{part}%
}
}

\@ifundefined{chapter}
{}
{%
\DeclareDocumentCommand{\chapter}{s o m}{%
\LWR@traceinfo{chapter #3}%
\LWR@stoppars%
\LWR@startnewdepth{\LWR@depthchapter}{\LWR@printclosechapter}%

\LWR@traceinfo{chapter: about to LWR@section}%
\LWR@section{#1}{#2}{#3}{chapter}%
\LWR@traceinfo{chapter: done}%
}
}

\DeclareDocumentCommand{\section}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthsection}{\LWR@printclosesection}%

\LWR@section{#1}{#2}{#3}{section}%
}

\DeclareDocumentCommand{\subsection}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthsubsection}{\LWR@printclosesubsection}%

\LWR@section{#1}{#2}{#3}{subsection}%
}

\DeclareDocumentCommand{\subsubsection}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthsubsubsection}%
{\LWR@printclosesubsubsection}%

\LWR@section{#1}{#2}{#3}{subsubsection}%
}

\DeclareDocumentCommand{\paragraph}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthparagraph}{\LWR@printcloseparagraph}%

\LWR@section{#1}{#2}{#3}{paragraph}%
}

\DeclareDocumentCommand{\subparagraph}{s o m}{%
\LWR@stoppars%

\LWR@startnewdepth{\LWR@depthsubparagraph}{\LWR@printclosesubparagraph}%

\LWR@section{#1}{#2}{#3}{subparagraph}%
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\MetaLanguage}{en-US}

\newcommand*{\LWR@filestart}[1]{
\begingroup
\renewcommand{\textit}[1]{##1}% not used in filenames
\renewcommand{\textsc}[1]{##1}
\renewcommand{\textsl}[1]{##1}
\renewcommand{\textbf}[1]{##1}
\renewcommand{\texttt}[1]{##1}
\renewcommand{\textsf}[1]{##1}
\renewcommand{\textrm}[1]{##1}
\renewcommand{\textsuperscript}[1]{##1}
\renewcommand{\textsubscript}[1]{##1}
\renewcommand*{\HTMLunicode}[1]{}
\renewcommand*{\HTMLentity}[1]{}
\RenewDocumentCommand{\LWR@htmlspanclass}{m o +m}{##3}
\DeclareExpandableDocumentCommand{\InlineClass}{m o m}{##3}
\LWR@htmltag{!DOCTYPE html}\LWR@orignewline
\LWR@htmltag{html lang="\MetaLanguage"{}}\LWR@orignewline
\LWR@htmltag{head}\LWR@orignewline
\LWR@htmltag{meta charset="UTF-8" /}\LWR@orignewline
\LWR@htmltag{meta name="generator" content="LaTeX lwarp package" /}%
    \LWR@orignewline
\ifdefempty{\LWR@currentHTMLdescription}{}{%
\LWR@htmltag{%
meta name="description" content="\LWR@currentHTMLdescription" /}%
    \LWR@orignewline
}%
\LWR@htmltag{meta name="viewport" %
content="width=device-width, initial-scale=1.0" /}%
    \LWR@orignewline
\LWR@htmltag{!{-}{-}[if lt IE 9]}\LWR@orignewline
\LWR@htmltag{%
script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"{}}
\LWR@htmltag{/script}\LWR@orignewline
\LWR@htmltag{![endif]{-}{-}}\LWR@orignewline
\LWR@htmltag{title}\thetitle#1\LWR@htmltag{/title}\LWR@orignewline
\LWR@htmltag{%
link rel="stylesheet" type="text/css" href="\LWR@currentcss" /}%
\LWR@orignewline
\ifbool{mathjax}%
{%
\boolfalse{LWR@verbtags}
\VerbatimInput{lwarp_mathjax.txt}%
\booltrue{LWR@verbtags}
\LWR@stoppars
}% end of mathjax
{}%
\LWR@htmltag{/head}\LWR@orignewline
\LWR@htmltag{body}\LWR@orignewline
\endgroup
}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LWR@LwarpStart}
{%
\edef\LWR@strresult{\HomeHTMLFileName}
\edef\HomeHTMLFileName{\detokenize\expandafter{\LWR@strresult}}
\edef\LWR@strresult{\HTMLFileName}
\edef\HTMLFileName{\detokenize\expandafter{\LWR@strresult}}
\LWR@origonecolumn%
\LWR@origscriptsize%
\LWR@origraggedright%
\let\\\LWR@endofline%
\linespread{1.3}%
\setlength{\parindent}{0pt}
\setlength{\parskip}{2ex}
\ifbool{usingOSwindows}
{% Windows:
\immediate\openout\LWR@file=lateximages.cmd
}
{% Unix:
\immediate\openout\LWR@file=lateximages.sh
\immediate\write\LWR@file{\LWR@hashmark!\OSShellPath}
}
\immediate\write\LWR@file{\OSmkdir lateximages\OSPathSymbol}
\setlength{\belowcaptionskip}{-3ex}
\renewcommand{\ps@plain}{}
\renewcommand*{\centering}{}
\renewcommand*{\raggedleft}{}
\renewcommand*{\raggedright}{}
\let\LWR@origtabular\tabular
\let\LWR@origendtabular\endtabular
\let\tabular\LWR@tabular
\let\endtabular\endLWR@tabular
\let\LWR@origcaption\caption
\let\ltx@label\LWR@htmlmathlabel
\let\TeX\LWR@TeX
\let\LaTeX\LWR@LaTeX
\let\LuaTeX\LWR@LuaTeX
\let\LuaLaTeX\LWR@LuaLaTeX
\let\XeTeX\LWR@XeTeX
\let\XeLaTeX\LWR@XeLaTeX
\let\ConTeXt\LWR@ConTeXt
\let\textcolor\LWR@textcolor
\let\pagecolor\LWR@pagecolor
\let\colorbox\LWR@colorbox
\let\fcolorbox\LWR@fcolorbox
\let\rotatebox\LWR@rotatebox
\let\scalebox\LWR@scalebox
\let\reflectbox\LWR@reflectbox
\global\boolfalse{LWR@doingapar}
\global\boolfalse{LWR@doingstartpars}
\LWR@filestart{}
\LWR@htmltag{header}\LWR@orignewline
\LWR@startpars
\LWR@firstpagetop
\LWR@stoppars
\LWR@htmltag{/header}\LWR@orignewline
\LWR@htmltag{section class="textbody"{}}
\LWR@origpagestyle{empty}
\mainmatter
\LWR@origpagenumbering{arabic}
\if@titlepage
   \thanksmarkseries{arabic}
\else
   \thanksmarkseries{fnsymbol}
\fi
\fvset{frame=none}%
\catcode`\&=\active
\LWR@startpars
}

\end{warpHTML}


\begin{warpHTML}


\newcommand*{\LWR@requesttoc}[2]{%
\ifbool{#1}
{
\expandafter\newwrite\csuse{tf@#2}
\immediate\openout \csuse{tf@#2} \jobname.#2\relax
}{}
}

\newcommand*{\LWR@LwarpEnd}
{
\LWR@stoppars
\LWR@closeprevious{\LWR@depthfinished}

\LWR@htmlelementclassend{section}{textbody}
\LWR@printpendingnotes
\LWR@htmlelement{footer}

\LWR@pagebottom

\LWR@htmlelementend{footer}

\ifnumcomp{\value{LWR@htmlfilenumber}}{>}{0}{\LWR@botnavigation}{}
\LWR@stoppars% final stop of all paragraphs
\LWR@htmltag{/body}\LWR@orignewline
\LWR@htmltag{/html}\LWR@orignewline
\LWR@orignewpage
\immediate\closeout\LWR@file
}

\end{warpHTML}


\begin{warpHTML}
\newrobustcmd{\affiliation}[1]{\\ \InlineClass{affiliation}{#1}}
\end{warpHTML}
\begin{warpprint}
\newrobustcmd{\affiliation}[1]{\\ \textsc{\small#1}}
\end{warpprint}
\begin{warpall}
\renewcommand{\author}[1]{%
\gdef\@author{#1}
\begingroup
  \renewcommand{\thanks}[1]{}
  \renewcommand{\and}{\unskip, }
  \renewcommand{\thanksmark}[1]{}
  \renewcommand{\thanksgap}[1]{}
  \renewcommand{\affiliation}[1]{}
  \protected@xdef\theauthor{#1}
\endgroup}
\newcommand{\published}[1]{%
\gdef\@published{#1}
\begingroup
  \renewcommand{\thanks}[1]{}
  \renewcommand{\thanksmark}[1]{}
  \renewcommand{\thanksgap}[1]{}
  \protected@xdef\thepublished{#1}
\endgroup
}
\newcommand{\@published}{}
\newcommand{\thepublished}{}
\newcommand{\subtitle}[1]{%
\gdef\@subtitle{#1}
\begingroup
  \renewcommand{\thanks}[1]{}
  \renewcommand{\thanksmark}[1]{}
  \renewcommand{\thanksgap}[1]{}
  \protected@xdef\thesubtitle{#1}
\endgroup
}
\newcommand{\@subtitle}{}
\newcommand{\thesubtitle}{}
\end{warpall}
\begin{warpHTML}
\renewenvironment*{titlepage}
    {\BlockClass{titlepage}\LWR@subminipage}
    {\LWR@endsubminipage\endBlockClass}
\renewenvironment*{titlingpage}
{%
\begin{titlepage}
\LWR@maketitlesetup
\let\maketitle\LWR@titlingmaketitle
}
{
\end{titlepage}
\@bscontmark
}
\end{warpHTML}

\begin{warpall}
\newcommand*{\printthanks}{\@thanks}
\AtEndEnvironment{titlingpage}{\@bscontmark}
\end{warpall}

\begin{warpHTML}
\newcommand{\prepublished}[1]{%
\def\@bsprepublished{\BlockClass{published}#1}%
}

\newcommand{\postpublished}[1]{%
\def\@bspostpublished{#1\endBlockClass}%
}

\renewcommand{\pretitle}[1]{%
\def\@bspretitle{#1\LWR@stoppars\LWR@htmltag{h1}}%
}

\renewcommand{\posttitle}[1]{%
\def\@bsposttitle{\LWR@htmltag{/h1}\LWR@startpars#1}%
}

\newcommand{\presubtitle}[1]{%
\def\@bspresubtitle{\BlockClass{subtitle}#1}%
}

\newcommand{\postsubtitle}[1]{%
\def\@bspostsubtitle{#1\endBlockClass}%
}

\renewcommand{\preauthor}[1]{%
\def\@bspreauthor{\BlockClass{author}#1}%
}

\renewcommand{\postauthor}[1]{%
\def\@bspostauthor{#1\endBlockClass}%
}

\renewcommand{\predate}[1]{%
\def\@bspredate{#1\BlockClass{titledate}}%
}

\renewcommand{\postdate}[1]{%
\def\@bspostdate{\endBlockClass#1}%
}

\prepublished{\begin{center}}
\postpublished{\par\end{center}}

\pretitle{\begin{center}}
\posttitle{\par\end{center}}

\presubtitle{\begin{center}}
\postsubtitle{\par\end{center}}

\preauthor{\begin{center}%
\begin{tabular}[t]{c}%
}
\postauthor{\end{tabular}\par\end{center}}

\predate{\begin{center}}
\postdate{\par\end{center}}
\newcommand*{\printpublished}{
\ifthenelse{\equal{\thepublished}{}}
{}
{
\begin{BlockClass}{published}
\@published
\end{BlockClass}
}
}

\newcommand*{\printtitle}
{
\LWR@stoppars
\LWR@htmltag{h1}%
\@title%
\LWR@htmltag{/h1}
\LWR@startpars
}
\newcommand*{\LWR@printthetitle}
{
\LWR@stoppars
\LWR@htmltag{h1}%
\thetitle%
\LWR@htmltag{/h1}
\LWR@startpars
}

\newcommand*{\printsubtitle}{
\ifthenelse{\equal{\thesubtitle}{}}
{}
{
\begin{BlockClass}{subtitle}
\@subtitle
\end{BlockClass}
}
}

\newcommand*{\printauthor}{
\begin{BlockClass}{author}
\begin{tabular}{c}\@author\end{tabular}
\end{BlockClass}
}

\newcommand*{\printdate}{%
\begin{BlockClass}{titledate}
\@date
\end{BlockClass}
}

\end{warpHTML}

\begin{warpprint}

\newcommand*{\printpublished}{{\Large\scshape\@published}}

\newcommand*{\printtitle}{{\Huge\@title}}

\newcommand*{\printsubtitle}{{\Large\itshape\@subtitle\bigskip}}

\newcommand*{\printauthor}
    {{\large\begin{tabular}[t]{c}\@author\end{tabular}}}

\newcommand*{\printdate}{{\small\textit{\@date}}}
\providecommand{\maketitle}{}
\if@titlepage
  \renewcommand{\maketitle}{\begin{titlepage}%
    \let\footnotesize\small
    \let\footnoterule\relax
    \let \footnote \thanks
    \@bsmarkseries
      \def\@makefnmark{\rlap{\@textsuperscript{%
         \normalfont\@bsthanksheadpre \tamark \@bsthanksheadpost}}}%
      \long\def\@makefntext##1{\makethanksmark ##1}
    \null\vfil
    \vskip 60\p@
    \vspace*{\droptitle}
    \maketitlehooka
    \ifcsempty{@published}
{}
{{\@bsprepublished \@published \@bspostpublished}\maketitlehookaa}
    {\@bspretitle \@title \@bsposttitle}
    \ifcsempty{@subtitle}
{}
{\maketitlehookaaa{\@bspresubtitle \@subtitle \@bspostsubtitle}}
    \maketitlehookb
    {\@bspreauthor \@author \@bspostauthor}
    \maketitlehookc
    {\@bspredate \@date \@bspostdate}
    \maketitlehookd
    \par
    \@thanks
    \vfil\null
    \end{titlepage}%
    \@bscontmark  %  \setcounter{footnote}{0}%
%%%    \@bsmtitlempty
  } % end titlepage defs
\else
  \renewcommand{\maketitle}{\par
    \begingroup
      \@bsmarkseries
      \def\@makefnmark{\rlap{\@textsuperscript{%
         \normalfont\@bsthanksheadpre \tamark \@bsthanksheadpost}}}%
      \long\def\@makefntext##1{\makethanksmark ##1}
      \if@twocolumn
        \ifnum \col@number=\@ne
          \@maketitle
        \else
          \twocolumn[\@maketitle]%
        \fi
      \else
        \newpage
        \global\@topnum\z@
        \@maketitle
      \fi
      \thispagestyle{plain}\@thanks
    \endgroup
    \@bscontmark  %  \setcounter{footnote}{0}%
%%%    \@bsmtitlempty
  } % end non-titlepage

  \def\@maketitle{%
    \newpage
    \null
    \vskip 2em%
          \vspace*{\droptitle}
    \maketitlehooka
    \ifcsempty{@published}
{}
{{\@bsprepublished \@published \@bspostpublished}\maketitlehookaa}
    {\@bspretitle \@title \@bsposttitle}
    \ifcsempty{@subtitle}
{}
{\maketitlehookaaa{\@bspresubtitle \@subtitle \@bspostsubtitle}}
    \maketitlehookb
    {\@bspreauthor \@author \@bspostauthor}
    \maketitlehookc
    {\@bspredate \@date \@bspostdate}
    \maketitlehookd
    \par
    \vskip 1.5em}
\fi

\providecommand{\maketitlehookaa}{}

\providecommand{\maketitlehookaaa}{}

\newcommand{\prepublished}[1]{%
\def\@bsprepublished{#1}%
}

\newcommand{\postpublished}[1]{%
\def\@bspostpublished{#1}%
}

\newcommand{\presubtitle}[1]{%
\def\@bspresubtitle{#1}%
}
\newcommand{\postsubtitle}[1]{%
\def\@bspostsubtitle{#1}%
}
\if@titlepage
\prepublished{
\vspace*{-\baselineskip}\vspace*{-\medskipamount}\vspace*{-2em}
\begin{center}}
\postpublished{\par\end{center}\vskip 2em}

\presubtitle{\unskip\begin{center}\unskip}
\postsubtitle{\par\end{center}\vskip 2em}
\else
\prepublished{\begin{center}}
\postpublished{\par\end{center}\vskip 0.5em}

\presubtitle{\begin{center}\unskip}
\postsubtitle{\par\end{center}\vskip 0.5em}
\fi
\end{warpprint}
\begin{warpHTML}
\newcommand*{\LWR@maketitlesetup}{%
\@bsmarkseries
\@mpbsmarkseries
\def\@makefnmark{\textsuperscript{\thefootnote}}%
\long\def\@makefntext##1{%
\makethanksmark \LWR@orighspace{1in}
##1\LWR@htmltagc{/\LWR@tagregularparagraph}%
}%
}

\def\@fnsymbol#1{\ensuremath{\ifcase#1\or *\or \dagger\or \ddagger\or
   \mathsection\or \mathparagraph\or \text{\HTMLunicode{2016}}\or
   **\or \dagger\dagger \or \ddagger\ddagger \else\@ctrerr\fi}}
\renewcommand*{\maketitle}{%
\begin{titlepage}
\LWR@maketitlesetup
\@maketitle
\@thanks
\end{titlepage}
\@bscontmark
}

\DeclareDocumentCommand{\@maketitle}{}{%
\maketitlehooka
\ifcsempty{@published}
{}
{{\@bsprepublished \@published \@bspostpublished}\maketitlehookaa}
{\@bspretitle \@title \@bsposttitle}
\ifcsempty{@subtitle}
{}
{\maketitlehookaaa{\@bspresubtitle \@subtitle \@bspostsubtitle}}
\maketitlehookb
{\@bspreauthor \@author \@bspostauthor}
\maketitlehookc
{\@bspredate \@date \@bspostdate}
\maketitlehookd
}

\providecommand{\maketitlehookaa}{}
\providecommand{\maketitlehookaaa}{}

\newcommand*{\LWR@titlingmaketitle}{%
\@maketitle
\@thanks
}

\let\LWR@origthanksmarkseries\thanksmarkseries
\renewcommand{\thanksmarkseries}[1]{%
\def\@mpbsmarkseries{%
\renewcommand*{\thempfootnote}{\@nameuse{#1}{mpfootnote}}}
\LWR@origthanksmarkseries{#1}
}
\end{warpHTML}


\begin{warpHTML}

\providecommand*{\abstractname}{Abstract}
\DeclareDocumentEnvironment{abstract}{}
{
\BlockClass{abstract}
\BlockClassSingle{abstracttitle}{\abstractname}
}
{
\endBlockClass
}

\end{warpHTML}





\begin{warpHTML}
\newcommand{\attribution}[1]{%
\InlineClass{attribution}{—\,#1}}% emdash
\end{warpHTML}
\begin{warpprint}
\newcommand{\attribution}[1]{\textsc{---\,#1}}
\end{warpprint}

\begin{warpHTML}
\newcommand{\citetitle}[1]{%
\InlineClass{citetitle}{—\,#1}}% emdash
\end{warpHTML}
\begin{warpprint}
\newcommand{\citetitle}[1]{\textsl{---\,#1}}
\end{warpprint}


\begin{warpHTML}
\renewenvironment*{quote}
{\LWR@htmlblocktag{blockquote}}
{\LWR@htmlblocktag{/blockquote}}

\renewenvironment*{quotation}
{\LWR@htmlblocktag{blockquotation}}
{\LWR@htmlblocktag{/blockquotation}}

\end{warpHTML}

\begin{warpall}

\newlength{\HTMLvleftskip}
\setlength{\HTMLvleftskip}{1em}

\newlength{\HTMLleftmargini}
\setlength{\HTMLleftmargini}{4.5em}

\end{warpall}

\begin{warpHTML}

\AfterEndPreamble{
\AtBeginEnvironment{verse}
{%
\ifdef{\vleftskip}{%
\setlength{\vleftskip}{\HTMLvleftskip}
\setlength{\leftmargini}{\HTMLleftmargini}
}{}
\LWR@atbeginverbatim{verse}
\unskip\vspace{-\baselineskip}
}
\AfterEndEnvironment{verse}{
\unskip\vspace{-\baselineskip}
\LWR@afterendverbatim
}
\ifdef{\poemtitle}{
\DeclareDocumentCommand{\@vstypeptitle}{m}{%
   \vspace{\beforepoemtitleskip}%
   {\InlineClass{poemtitle}{\poemtitlefont #1}\par}%
   \vspace{\afterpoemtitleskip}%
 }
}{}

}
\end{warpHTML}


\begin{warpHTML}

\AfterEndPreamble{
\AtBeginEnvironment{verbatim}{\LWR@atbeginverbatim{verbatim}\unskip\vspace*{-\baselineskip}}
\AfterEndEnvironment{verbatim}{\unskip\vspace*{-\baselineskip}\LWR@afterendverbatim}
}

\end{warpHTML}


\begin{warpall}
\newlength{\VerbatimHTMLWidth}
\setlength{\VerbatimHTMLWidth}{4in}
\end{warpall}

\begin{warpHTML}
\newbool{LWR@verbtags}
\booltrue{LWR@verbtags}

\renewcommand{\VerbatimFootnotes}{
\PackageError{lwarp}
{Verbatim footnotes are not yet supported by lwarp.}
{This may be improved when lwarp uses LaTeX footnotes instead of pagenotes.}
}

\newcommand*{\LWR@atbeginverbatim}[1]
{%
\setlength{\parskip}{0ex}%
\LWR@stoppars%
\ifbool{LWR@verbtags}{\LWR@htmltag{pre class="#1"{}}}{}%
\LWR@origttfamily%
\let\hspace\LWR@orighspace%
}

\newcommand*{\LWR@afterendverbatim}{%
\unskip%
\ifbool{LWR@verbtags}{\noindent\LWR@htmltag{/pre}

}{}%
\LWR@startpars%
}
\newcommand*{\LWR@Verbatimclass}{fancyvrb}
\NewDocumentEnvironment{VerbatimClass}{m O{}}
{%
\renewcommand*{\LWR@Verbatimclass}{#1}%
\LWR@origVerbatim[#2]%
}
{\endVerbatim}
\AfterEndPreamble{
\let\LWR@origVerbatim\Verbatim
\renewcommand*{\Verbatim}{%
\renewcommand*{\LWR@Verbatimclass}{fancyvrb}%
\LWR@origVerbatim%
}
\newcommand*{\LWR@fvstartnone}{%
\ifbool{LWR@verbtags}{\hbox to\z@{\LWR@htmltagc{div class="\LWR@Verbatimclass"}}}{}%
\hbox to\z@{\LWR@atbeginverbatim{verbatim}}%
}

\newcommand*{\LWR@fvendnone}{%
\hbox to\z@{\LWR@afterendverbatim}%
\ifbool{LWR@verbtags}{\hbox to\z@{\LWR@htmltagc{/div}}}{}%
}

\newcommand*{\LWR@fvstartsingle}{%
\LWR@fvstartnone%
\FV@BeginListFrame@Single%
}

\newcommand*{\LWR@fvendsingle}{%
\FV@EndListFrame@Single%
\LWR@fvendnone%
}

\newcommand*{\LWR@fvstartline}{%
\LWR@fvstartnone%
\FV@BeginListFrame@Lines%
}

\newcommand*{\LWR@fvendline}{%
\FV@EndListFrame@Lines%
\LWR@fvendnone%
}
\def\FV@Frame@none{%
\let\FV@BeginListFrame\LWR@fvstartnone%
\let\FV@LeftListFrame\relax%
\let\FV@RightListFrame\relax%
\let\FV@EndListFrame\LWR@fvendnone}

\def\FV@Frame@single{%
\let\FV@BeginListFrame\LWR@fvstartsingle%
\let\FV@LeftListFrame\FV@LeftListFrame@Single%
\let\FV@RightListFrame\FV@RightListFrame@Single%
\let\FV@EndListFrame\LWR@fvendsingle}

\def\FV@Frame@lines{%
\let\FV@BeginListFrame\LWR@fvstartline%
\let\FV@LeftListFrame\relax%
\let\FV@RightListFrame\relax%
\let\FV@EndListFrame\LWR@fvendline}

\def\FV@Frame@topline{%
\let\FV@BeginListFrame\LWR@fvstartline%
\let\FV@LeftListFrame\relax%
\let\FV@RightListFrame\relax%
\let\FV@EndListFrame\LWR@fvendnone}

\def\FV@Frame@bottomline{%
\let\FV@BeginListFrame\LWR@fvstartnone%
\let\FV@LeftListFrame\relax%
\let\FV@RightListFrame\relax%
\let\FV@EndListFrame\LWR@fvendline}

\def\FV@Frame@leftline{%
\ifx\FancyVerbFillColor\relax%
\let\FV@FrameFillLine\relax%
\else%
\@tempdima\FV@FrameRule\relax%
\multiply\@tempdima-\tw@%
\edef\FV@FrameFillLine{%
{\noexpand\FancyVerbFillColor{\vrule\@width\number\@tempdima sp}%
\kern-\number\@tempdima sp}}%
\fi%
\let\FV@BeginListFrame\LWR@fvstartnone%
\let\FV@LeftListFrame\FV@LeftListFrame@Single%
\let\FV@RightListFrame\relax%
\let\FV@EndListFrame\LWR@fvendnone}
\def\FV@SingleFrameLine#1{%
  \hbox to\z@{%
    \ifnum#1=\z@\relax
      \let\FV@Label\FV@LabelBegin
    \else
      \let\FV@Label\FV@LabelEnd
    \fi
    \ifx\FV@Label\relax
    \else
      \ifnum#1=\z@
        \ifx\FV@LabelPositionTopLine\relax
\else
        \LWR@htmltagc{div class="fancyvrblabel"}
\LWR@origtextrm{\FV@LabelBegin}% \textrm preserves emdash
\LWR@htmltagc{/div}
\fi
      \else
        \ifx\FV@LabelPositionBottomLine\relax
\else
        \LWR@htmltagc{div class="fancyvrblabel"}
\LWR@origtextrm{\FV@LabelEnd}
\LWR@htmltagc{/div}
\fi
      \fi

    \fi
    \hss
}
}
\def\FV@ListProcessLine#1{%
   \hbox to \hsize{%
      \hbox to \VerbatimHTMLWidth {%
       \ifcsvoid{FV@LeftListNumber}{}{\kern 2.5em}%
\FV@LeftListNumber%
      \FancyVerbFormatLine{#1}%
      \hss%
      \FV@RightListNumber%
}%
      \hss% required to avoid underfull hboxes
}
}

\AtBeginEnvironment{BVerbatim}
{
\LWR@atbeginverbatim{bverbatim}

}

\AfterEndEnvironment{BVerbatim}
{
\leavevmode\par\vspace{-\baselineskip}
\LWR@afterendverbatim
}



} % \AfterEndPreamble


\end{warpHTML}


\begin{warpHTML}

\renewcommand{\@begintheorem}[2]{%
\LWR@htmldivclass{theorem}
\InlineClass{theoremlabel}{#1\ #2\ }
\LWR@htmldivclass{theoremcontents}
}
\renewcommand{\@opargbegintheorem}[3]{%
\BlockClass{theorem}
\InlineClass{theoremlabel}{#1\ #2\ (#3)\ }
\BlockClass{theoremcontents}
}
\renewcommand*{\@endtheorem}{%
\endBlockClass% theoremcontents
\endBlockClass% theorem
}

\end{warpHTML}



\begin{warpHTML}

\let\LWR@origitem\item

\newcommand*{\LWR@itemizeitem}{%
\LWR@stoppars%
\LWR@startnewdepth{\LWR@depthlistitem}{\LWR@printcloselistitem{}}%
\LWR@htmltag{li}%
\LWR@startpars%
\LWR@origitem%
}


\AtBeginEnvironment{itemize}{\LWR@itemizestart}

\newcommand*{\LWR@itemizestart}{%
\LWR@stoppars%
\LWR@pushoneclose{\LWR@depthlist}{\LWR@printcloseitemize{}}%
\LWR@htmltag{ul style="list-style-type:none"{}}%
\LWR@startpars%
\let\item\LWR@itemizeitem%
}

\AtEndEnvironment{itemize}{\LWR@itemizeend}

\newcommand*{\LWR@itemizeend}{%
\LWR@stoppars%
\LWR@closeprevious{\LWR@depthlistitem}%
\LWR@closeoneprevious{}%
\LWR@startpars%
}



\AtBeginEnvironment{enumerate}{\LWR@enumeratestart}

\newcommand*{\LWR@enumeratestart}{%
\LWR@stoppars%
\LWR@pushoneclose{\LWR@depthlist}{\LWR@printcloseitemize{}}%
\LWR@htmltag{ul style="list-style-type:none"{}}%
\LWR@startpars%
\let\item\LWR@itemizeitem%
}

\AtEndEnvironment{enumerate}{\LWR@enumerateend}

\newcommand*{\LWR@enumerateend}{%
\LWR@stoppars%
\LWR@closeprevious{\LWR@depthlistitem}%
\LWR@closeoneprevious{}%
\LWR@startpars%
}


\newcommand*{\LWR@descitem}[1][]%
{%
\LWR@stoppars%
\LWR@setlatestname{#1}%
\LWR@startnewdepth{\LWR@depthlistitem}{\LWR@printclosedescitem{}}%
\LWR@origitem[]%
\LWR@orighspace{1in}
\LWR@htmltag{dt}#1\LWR@htmltag{/dt}%
\LWR@orignewline%
\LWR@htmltag{dd}%
\LWR@startpars%
}

\AtBeginEnvironment{description}{\LWR@descriptionstart}

\newcommand*{\LWR@descriptionstart}{%
\LWR@stoppars%
\LWR@pushoneclose{\LWR@depthlist}{\LWR@printclosedescription{}}%
\LWR@htmltag{dl}%
\LWR@startpars%
\let\item\LWR@descitem%
}

\AtEndEnvironment{description}{\LWR@descriptionend}

\newcommand*{\LWR@descriptionend}{%
\LWR@stoppars%
\LWR@closeprevious{\LWR@depthlistitem}%
\LWR@closeoneprevious{}%
\LWR@startpars%
}

\let\LWR@orignewlist\newlist

\renewcommand*{\newlist}[3]{%
\LWR@orignewlist{#1}{#2}{#3}%
\AtBeginEnvironment{#1}{\csuse{LWR@#2start}}%
\AtEndEnvironment{#1}{\csuse{LWR@#2end}}%
}

\end{warpHTML}



\begin{warpHTML}

\newcommand\LWR@mynexttoken\relax




\def\LWR@futurenonspacelet#1{\def\LWR@cs{#1}%
\afterassignment\LWR@fnslone\let\nexttoken= }
\def\LWR@fnslone{\expandafter\futurelet\LWR@cs\LWR@fnsltwo}
\def\LWR@fnsltwo{%
\expandafter\ifx\LWR@cs\@sptoken\let\next=\@BTfnslthree%
\else\let\next=\nexttoken\fi\next}
\def\@BTfnslthree{\afterassignment\LWR@fnslone\let\next= }

\newcommand*{\LWR@getmynexttoken}{%
\LWR@futurenonspacelet\LWR@mynexttoken\LWR@tabledatacolumntag
}


\newbool{LWR@startedrow}
\boolfalse{LWR@startedrow}

\newbool{LWR@doinghline}
\boolfalse{LWR@doinghline}

\newbool{LWR@doingtbrule}
\boolfalse{LWR@doingtbrule}

\newbool{LWR@tableparcell}

\newbool{LWR@skippingmrowcell}

\newbool{LWR@intabularmetadata}
\boolfalse{LWR@intabularmetadata}


\newcommand*{\LWR@closetabledatacell}{%
\global\booltrue{LWR@intabularmetadata}%
\ifbool{LWR@exitingtabular}{}%
{% not exiting tabular
\ifbool{LWR@skippingmrowcell}{}%
{% not skippingmrowcell
\unskip%
\LWR@getexparray{LWR@colafterspec}{\theLWR@tablecolspos}%
\LWR@getexparray{LWR@colatspec}{\theLWR@tablecolspos}%
\ifbool{LWR@tableparcell}{\LWR@stoppars}{}%
\global\boolfalse{LWR@tableparcell}%
\unskip\LWR@htmltag{/td}\LWR@orignewline%
}% not skipping mrowcell
}% not exiting tabular
\global\boolfalse{LWR@skippingmrowcell}%
}

\newcounter{LWR@tabulardepth}
\setcounter{LWR@tabulardepth}{0}

\def\LWR@origampmacro{&}
\begingroup
\catcode`\&=\active

\gdef&{%
\ifthenelse{\cnttest{\value{LWR@tabulardepth}}{>}{0}}%
{%
\unskip%
\LWR@closetabledatacell%
\addtocounter{LWR@tablecolspos}{1}%
\LWR@getmynexttoken%
}%
{\LWR@origampmacro}%
}
\endgroup


\NewDocumentCommand{\LWR@tabularendofline}{s o}
{%
\LWR@closetabledatacell%
\LWR@htmltag{/tr}\LWR@orignewline
\global\booltrue{LWR@intabularmetadata}
\global\boolfalse{LWR@startedrow}
\global\boolfalse{LWR@doinghline}%
\global\boolfalse{LWR@doingtbrule}%
\LWR@clearmidrules%
\setcounter{LWR@tablecolspos}{1}
\LWR@getmynexttoken%
}


\newcommand*{\LWR@colsresult}{}%temp storage for column format results
\newcommand*{\LWR@pposition}{}
\newcommand*{\LWR@pleft}{}
\newcommand*{\LWR@pright}{}

\newcommand*{\LWR@tablecolspec}{}

\newcommand*{\LWR@strresult}{}

\newcommand*{\LWR@origcolspec}{}

\newcounter{LWR@tablecolswidth}

\newcounter{LWR@tablecolspos}

\newcounter{LWR@tabletotalcols}

\newcounter{LWR@tabletotalcolsnext}


\newcommand*{\LWR@parseatcolumn}{%
\LWR@traceinfo{at column}%
\addtocounter{LWR@tablecolspos}{1}%
\LWR@traceinfo{about to read the next token:}%
\expandarg%
\StrChar{\LWR@origcolspec}{\theLWR@tablecolspos}[\LWR@strresult]
\fullexpandarg%
\LWR@traceinfo{have now read the next token}%
\ifthenelse{\cnttest{\value{LWR@tabletotalcols}}=0}
{% left edge of the table:
\LWR@traceinfo{at the left edge}%
\LWR@setexparray{LWR@colatspec}{leftedge}{\LWR@strresult}%
\LWR@traceinfo{finished with the def}%
}%
{% not at the left edge:
\LWR@traceinfo{not at the left edge}%
\LWR@setexparray{LWR@colatspec}{\theLWR@tabletotalcols}{\LWR@strresult}%
\LWR@traceinfo{at \theLWR@tabletotalcols: \LWR@colatspec(\theLWR@tabletotalcols)!}%
}%
\let\LWR@strresult\relax%
}
\newcommand*{\LWR@parsebeforecolumn}{%
\addtocounter{LWR@tablecolspos}{1}%
\expandarg%
\StrChar{\LWR@origcolspec}{\theLWR@tablecolspos}[\LWR@strresult]%
\fullexpandarg%
\LWR@setexparray{LWR@colbeforespec}{\theLWR@tabletotalcolsnext}{\LWR@strresult}%
\let\LWR@strresult\relax%
}
\newcommand*{\LWR@parseaftercolumn}{%
\addtocounter{LWR@tablecolspos}{1}%
\expandarg%
\StrChar{\LWR@origcolspec}{\theLWR@tablecolspos}[\LWR@strresult]%
\fullexpandarg%
\LWR@setexparray{LWR@colafterspec}{\theLWR@tabletotalcols}{\LWR@strresult}%
\let\LWR@strresult\relax%
}
\newcommand*{\LWR@parseskipcolumn}{%
}
\newcommand*{\LWR@parsenormalcolumn}[1]{%
\appto\LWR@tablecolspec{#1}%
\addtocounter{LWR@tabletotalcols}{1}%
\addtocounter{LWR@tabletotalcolsnext}{1}%
\LWR@setexparray{LWR@colatspec}{\theLWR@tabletotalcolsnext}{\relax}%
\LWR@setexparray{LWR@colbeforespec}{\theLWR@tabletotalcolsnext}{\relax}%
\LWR@setexparray{LWR@colafterspec}{\theLWR@tabletotalcolsnext}{\relax}%
}


\newcommand*{\LWR@parsepcolumn}[1]{%
\LWR@parsenormalcolumn{#1}%
\addtocounter{LWR@tablecolspos}{1}%
}


\newcommand*{\LWR@parsetablecols}[1]{%
\LWR@traceinfo{LWR@parsetablecols started}%
\renewcommand*{\LWR@origcolspec}{#1}%
\renewcommand*{\LWR@tablecolspec}{}%
\setcounter{LWR@tabletotalcols}{0}%
\setcounter{LWR@tabletotalcolsnext}{1}%
\LWR@setexparray{LWR@colatspec}{leftedge}{\relax}%
\LWR@setexparray{LWR@colatspec}{1}{\relax}%
\LWR@setexparray{LWR@colatspec}{2}{\relax}%
\LWR@setexparray{LWR@colatspec}{3}{\relax}%
\LWR@setexparray{LWR@colbeforespec}{1}{\relax}%
\LWR@setexparray{LWR@colbeforespec}{2}{\relax}%
\LWR@setexparray{LWR@colbeforespec}{3}{\relax}%
\LWR@setexparray{LWR@colafterspec}{1}{\relax}%
\LWR@setexparray{LWR@colafterspec}{2}{\relax}%
\LWR@setexparray{LWR@colafterspec}{3}{\relax}%
\setcounter{LWR@tablecolspos}{1}%
\LWR@traceinfo{about to StrLen}%
\noexpandarg%
\StrLen{#1}[\LWR@strresult]%
\fullexpandarg%
\LWR@traceinfo{finished StrLen}%
\setcounter{LWR@tablecolswidth}{\LWR@strresult}%
\whiledo{\not\value{LWR@tablecolspos}>\value{LWR@tablecolswidth}}{%
\noexpandarg%
\StrChar{#1}{\theLWR@tablecolspos}[\LWR@strresult]%
\fullexpandarg%
\IfStrEq{\LWR@strresult}{l}{\LWR@parsenormalcolumn{l}}{}%
\IfStrEq{\LWR@strresult}{c}{\LWR@parsenormalcolumn{c}}{}%
\IfStrEq{\LWR@strresult}{r}{\LWR@parsenormalcolumn{r}}{}%
\IfStrEq{\LWR@strresult}{S}{\LWR@parsenormalcolumn{r}}{}%
\IfStrEq{\LWR@strresult}{\detokenize{@}}{\LWR@parseatcolumn}{}%
\IfStrEq{\LWR@strresult}{>}{\LWR@parsebeforecolumn}{}%
\IfStrEq{\LWR@strresult}{<}{\LWR@parseaftercolumn}{}%
\IfStrEq{\LWR@strresult}{!}{\LWR@parseskipcolumn}{}%
\IfStrEq{\LWR@strresult}{p}{\LWR@parsepcolumn{p}}{}%
\IfStrEq{\LWR@strresult}{m}{\LWR@parsepcolumn{m}}{}%
\IfStrEq{\LWR@strresult}{b}{\LWR@parsepcolumn{b}}{}%
\IfStrEq{\LWR@strresult}{P}{\LWR@parsepcolumn{P}}{}%
\IfStrEq{\LWR@strresult}{M}{\LWR@parsepcolumn{M}}{}%
\IfStrEq{\LWR@strresult}{B}{\LWR@parsepcolumn{B}}{}%
\addtocounter{LWR@tablecolspos}{1}%
}%
}%


\newcommand*{\LWR@maybenewtablerow}
{%
\ifbool{LWR@startedrow}%
{}% started the row
{% not started the row
\global\booltrue{LWR@startedrow}%
\global\booltrue{LWR@intabularmetadata}%
\ifbool{LWR@doinghline}%
{\LWR@htmltag{tr class="hline"{}}\LWR@orignewline}%
{% not doing hline
\ifbool{LWR@doingtbrule}%
{\LWR@htmltag{tr class="tbrule"{}}\LWR@orignewline}%
{\LWR@htmltag{tr}\LWR@orignewline}%
}% end of not doing hline
}% end of not started the row
}


\newcommand*{\LWR@tabledatasinglecolumntag}%
{%
\LWR@maybenewtablerow%
\ifbool{LWR@exitingtabular}{}%
{% not exiting tabular
\StrChar{\LWR@tablecolspec}{\theLWR@tablecolspos}[\LWR@strresult]%
\LWR@htmltag{td class="td%
\LWR@strresult%
\ifthenelse{\equal{\LWR@getexparray{LWR@midrules}{\theLWR@tablecolspos}}{Y}}{rule}{}%
"{}}%
\ifthenelse{%
\equal{\LWR@strresult}{p}\OR%
\equal{\LWR@strresult}{m}\OR%
\equal{\LWR@strresult}{b}\OR%
\equal{\LWR@strresult}{P}\OR%
\equal{\LWR@strresult}{M}\OR%
\equal{\LWR@strresult}{B}%
}%
{% allow pars
\LWR@startpars%
\global\booltrue{LWR@tableparcell}%
}% allow pars
{}% no pars
\ifthenelse{\cnttest{\value{LWR@tablecolspos}}=1}%
{\LWR@getexparray{LWR@colatspec}{leftedge}}% left edge
{}% not left edge
\LWR@getexparray{LWR@colbeforespec}{\theLWR@tablecolspos}%
\global\boolfalse{LWR@intabularmetadata}%
}% not exiting tabular
}%


\newcounter{LWR@midrulecounter}

\newcommand*{\LWR@clearmidrules}
{%
\setcounter{LWR@midrulecounter}{1}%
\whiledo{%
\cnttest{\value{LWR@midrulecounter}}{<=}{\value{LWR@tablecolswidth}}%
}%
{%
\LWR@setexparray{LWR@midrules}{\theLWR@midrulecounter}{\relax}%
\addtocounter{LWR@midrulecounter}{1}%
}%
}

\newcommand*{\LWR@subcmidrule}[4]{%
\setcounter{LWR@midrulecounter}{#3}%
\whiledo{\cnttest{\value{LWR@midrulecounter}}{<=}{#4}}%
{%
\LWR@setexparray{LWR@midrules}{\theLWR@midrulecounter}{Y}%
\addtocounter{LWR@midrulecounter}{1}%
}% end of the whiledo
}

\NewDocumentCommand{\LWR@docmidrule}{o d() >{\SplitArgument{1}{-}}m}%
{\LWR@subcmidrule{#1}{#2}#3}



\newcounter{LWR@tablemulticolswidth}
\newcounter{LWR@tablemulticolspos}

\newcommand*{\LWR@printmccoltype}[1]{%
\LWR@traceinfo{lwr@printmccoltype -#1-}%
\StrChar{#1}{\theLWR@tablemulticolspos}[\LWR@strresult]%
\IfStrEq{\LWR@strresult}{l}{l}{}%
\IfStrEq{\LWR@strresult}{c}{c}{}%
\IfStrEq{\LWR@strresult}{r}{r}{}%
\IfStrEq{\LWR@strresult}{p}{p}{}%
\IfStrEq{\LWR@strresult}{m}{m}{}%
\IfStrEq{\LWR@strresult}{b}{b}{}%
\IfStrEq{\LWR@strresult}{P}{P}{}%
\IfStrEq{\LWR@strresult}{M}{M}{}%
\IfStrEq{\LWR@strresult}{B}{B}{}%
\IfStrEq{\LWR@strresult}{S}{r}{}%
\LWR@traceinfo{lwr@printmccoltype done}%
}

\newcommand*{\LWR@multicolpartext}{%
\LWR@startpars%
\LWR@multicoltext%
\LWR@stoppars%
}

\newcommand*{\LWR@multicolother}[1]{%
\addtocounter{LWR@tablemulticolspos}{1}%
\StrChar{#1}{\theLWR@tablemulticolspos}[\LWR@strresult]%
\LWR@strresult%
}

\newcommand*{\LWR@printmccoldata}[1]{%
\LWR@traceinfo{lwr@printmccoldata -#1}%
\StrChar{#1}{\theLWR@tablemulticolspos}[\LWR@strresult]%
\IfStrEq{\LWR@strresult}{l}{\LWR@multicoltext}{}%
\IfStrEq{\LWR@strresult}{c}{\LWR@multicoltext}{}%
\IfStrEq{\LWR@strresult}{r}{\LWR@multicoltext}{}%
\IfStrEq{\LWR@strresult}{p}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{m}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{b}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{P}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{M}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{B}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{S}{\LWR@multicolpartext}{}%
\IfStrEq{\LWR@strresult}{\detokenize{@}}{\LWR@multicolother{#1}}{}%
\IfStrEq{\LWR@strresult}{\detokenize{>}}{\LWR@multicolother{#1}}{}%
\IfStrEq{\LWR@strresult}{\detokenize{<}}{\LWR@multicolother{#1}}{}%
\LWR@traceinfo{lwr@printmccoldata done}%
}

\newcommand*{\LWR@parsemulticolumnalignment}[2]{%
\setcounter{LWR@tablemulticolspos}{1}%
\StrLen{#1}[\LWR@strresult]%
\setcounter{LWR@tablemulticolswidth}{\LWR@strresult}%
\whiledo{%
\not\value{LWR@tablemulticolspos}>\value{LWR@tablemulticolswidth}%
}%
{%
#2{#1}%
\addtocounter{LWR@tablemulticolspos}{1}%
}%
}


\newcommand{\LWR@multicoltext}{}

\NewDocumentCommand{\LWR@domulticolumn}{m m +m}{%
\LWR@traceinfo{lwr@domulticolumn -#1- -#2-}%
\renewcommand{\LWR@multicoltext}{#3}%
\LWR@maybenewtablerow%
\LWR@htmltag{td colspan="#1"
 class="td%
\LWR@parsemulticolumnalignment{#2}{\LWR@printmccoltype}%
\ifthenelse{\equal{\LWR@getexparray{LWR@midrules}{\theLWR@tablecolspos}}{Y}}{rule}{}%
"%
}% end of the opening table data tag
\global\boolfalse{LWR@intabularmetadata}%
\LWR@parsemulticolumnalignment{#2}{\LWR@printmccoldata}%
}


\newbool{LWR@starredlongtable}
\boolfalse{LWR@starredlongtable}
\providecommand*{\LTcaptype}{table}
\NewDocumentCommand{\LWR@longtabledatacaptiontag}{s o +m}
{%
\IfValueTF{#2}{% optional given?
\ifthenelse{\equal{#2}{}}% optional empty?
{\LWR@setlatestname{#3}}% empty
{\LWR@setlatestname{#2}}% given and non-empty
}% optional given
{\LWR@setlatestname{#3}}% no optional
\LWR@domulticolumn{\theLWR@tabletotalcols}{P}{% \LWR@domulticolumn
\IfBooleanTF{#1}% star?
{% yes star
\LWR@htmlblocktag{figcaption}%
#3%
\LWR@htmlblocktag{/figcaption}%
}%
{% No star:
\ifbool{LWR@starredlongtable}%
{%
\ifthenelse{\equal{#2}{}}% TOC entry
{}%
{%
\refstepcounter{\LTcaptype}%
\protected@edef\@currentlabel{%
\csuse{p@\LTcaptype}\csuse{the\LTcaptype}}%
}%
}{}%
\LWR@htmlblocktag{figcaption}%
\csuse{fnum@\LTcaptype}\CaptionSeparator#3%
\LWR@htmlblocktag{/figcaption}%
\ifthenelse{\equal{#2}{}}% TOC entry empty
{}%
{% TOC entry not empty
\IfNoValueTF{#2}% No TOC entry?
{% No TOC entry
\addcontentsline%
{\csuse{ext@\LTcaptype}}%
{\LTcaptype}%
{%
\protect\numberline%
{\csuse{p@\LTcaptype}\csuse{the\LTcaptype}}%
{\ignorespaces #3\protect\relax}%
}%
}% end of No TOC entry
{% yes TOC entry
\addcontentsline%
{\csuse{ext@\LTcaptype}}%
{\LTcaptype}%
{%
\protect\numberline%
{\csuse{p@\LTcaptype}\csuse{the\LTcaptype}}%
{\ignorespaces #2\protect\relax}%
}%
}% end of yes TOC entry
}% end of TOC entry not empty
}% end of no star
}% end of \LWR@domulticolumn

\addtocounter{LWR@tablecolspos}{\theLWR@tabletotalcols}
\addtocounter{LWR@tablecolspos}{-1}

}


\NewDocumentCommand{\LWR@tabledatamulticolumntag}{m m +m}%
{%
\LWR@domulticolumn{#1}{#2}{#3}%
\addtocounter{LWR@tablecolspos}{#1}%
\addtocounter{LWR@tablecolspos}{-1}%
}



\NewDocumentCommand{\LWR@tabledatamultirowtag}{m o m o m}%
{%
\LWR@maybenewtablerow%
\LWR@htmltag{td rowspan="#1" class="td%
\StrChar{\LWR@tablecolspec}{\theLWR@tablecolspos}%
\ifthenelse{\equal{\LWR@getexparray{LWR@midrules}{\theLWR@tablecolspos}}{Y}}{rule}{}%
"{}}
\begingroup \let\\\LWR@endofline #5 \endgroup
\LWR@stoppars%
\global\boolfalse{LWR@intabularmetadata}%
}%

\newcommand*{\LWR@donothing}{}
\newcommand*{\LWR@domidrule}{\booltrue{LWR@doinghline}}
\newcommand*{\LWR@dotbrule}{\booltrue{LWR@doingtbrule}}


\newbool{LWR@exitingtabular}
\newcommand*{\LWR@tabledatacolumntag}%
{%
\let\mynext\LWR@tabledatasinglecolumntag%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\end}}%
{\booltrue{LWR@exitingtabular}}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\caption}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\multicolumn}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\multirow}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\mrowcell}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\hline}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\toprule}}%
{%
\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\midrule}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\cmidrule}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\cline}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\bottomrule}}%
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\warpprintonly}}
{\let\mynext\LWR@donothing}{}%
\ifthenelse{\isequivalentto{\LWR@mynexttoken}{\warpHTMLonly}}
{\let\mynext\LWR@donothing}{}%
\mynext%
}

\end{warpHTML}



\begin{warpall}
\newcommand*{\mrowcell}{}
\end{warpall}


\begin{warpHTML}

\newenvironment*{LWR@tabular}[2][]
{%
\LWR@traceinfo{tabular started}%
\begingroup%
\addtocounter{LWR@tabulardepth}{1}%
\global\boolfalse{LWR@startedrow}%
\global\boolfalse{LWR@doinghline}%
\global\boolfalse{LWR@doingtbrule}%
\boolfalse{LWR@exitingtabular}%
\global\booltrue{LWR@intabularmetadata}%
\LWR@htmlblocktag{table}%
\LWR@parsetablecols{#2}%
\LWR@stoppars%
\setcounter{LWR@tablecolspos}{1}%
\LWR@clearmidrules%
\let\\\LWR@tabularendofline%
\renewcommand*{\hline}{\LWR@domidrule\LWR@getmynexttoken}%
\newcommand*{\midrule}{\LWR@domidrule\LWR@getmynexttoken}%
\NewDocumentCommand{\cmidrule}{o d() m}%
{\LWR@docmidrule[##1](##2){##3}\LWR@getmynexttoken}%
\RenewDocumentCommand{\cline}{m}%
{\LWR@docmidrule{##1}\LWR@getmynexttoken}%
\newcommand*{\toprule}{\LWR@dotbrule\LWR@getmynexttoken}%
\newcommand*{\bottomrule}{\LWR@dotbrule\LWR@getmynexttoken}%
\let\multicolumn\LWR@tabledatamulticolumntag%
\let\multirow\LWR@tabledatamultirowtag%
\renewcommand*{\mrowcell}{\global\booltrue{LWR@skippingmrowcell}}%
\let\caption\LWR@longtabledatacaptiontag%
\global\boolfalse{LWR@tableparcell}%
\global\boolfalse{LWR@skippingmrowcell}%
\LWR@getmynexttoken%
}%
{%
\LWR@closetabledatacell%
\LWR@htmlblocktag{/tr}%
\LWR@htmlblocktag{/table}%
\global\boolfalse{LWR@intabularmetadata}%
\addtocounter{LWR@tabulardepth}{-1}%
\endgroup%
}

\end{warpHTML}




\begin{warpHTML}


\newcommand*{\@currentlabelname}{}
\def\LWR@stripperiod#1.\ltx@empty#2\@nil{#1}%
\newcommand*{\LWR@setlatestname}[1]{%
\GetTitleStringExpand{#1}%
\edef\@currentlabelname{\detokenize\expandafter{\GetTitleStringResult}}%
\edef\@currentlabelname{%
\expandafter\LWR@stripperiod\@currentlabelname%
\ltx@empty.\ltx@empty\@nil%
}%
}


\zref@newlist{special}
\zref@newprop{zLWR@name}{\@currentlabelname}
\zref@newprop{zLWR@htmlfilenumber}{%
\ifbool{FileSectionNames}{\LWR@thisfilename}{\theLWR@htmlfilenumber}%
}%
\zref@newprop{zLWR@lateximagedepth}{\arabic{LWR@lateximagedepth}}
\zref@newprop{zLWR@lateximagenumber}{\arabic{LWR@lateximagenumber}}
\zref@addprop{special}{zLWR@name}
\zref@addprop{special}{zLWR@htmlfilenumber}
\zref@addprop{special}{zLWR@lateximagedepth}
\zref@addprop{special}{zLWR@lateximagenumber}
\newcommand*{\LWR@spref}[2]{%
\zref@extractdefault{#1}{#2}{??}}
\newcommand*{\LWR@nameref}[1]{%
\LWR@spref{#1}{zLWR@name}%
}
\newcommand*{\LWR@htmlfileref}[1]{%
\LWR@traceinfo{LWR@htmlfileref A: !#1!}%
\LWR@spref{#1}{zLWR@htmlfilenumber}%
\LWR@traceinfo{LWR@htmlfileref B}%
}
\newcommand*{\LWR@lateximagedepthref}[1]{%
\LWR@spref{#1}{zLWR@lateximagedepth}%
}
\newcommand*{\LWR@lateximagenumberref}[1]{%
\LWR@spref{#1}{zLWR@lateximagenumber}%
}
\newcommand*{\LWR@splabel}[1]{%
\LWR@setlatestname{\@currentlabelname}%
\zref@labelbylist{#1}{special}}


\newcommand*{\LWR@subsublabel}[1]{%
\ifthenelse{\cnttest{\value{LWR@lateximagedepth}}{>}{0}}%
{}%
{% not lateximage
\ifbool{LWR@doingstartpars}%
{% pars allowed
\ifbool{LWR@doingapar}
{% par started
\LWR@htmltag{a id="#1"{}}\LWR@htmltag{/a}%
}% par started
{% par not started
\LWR@stoppars%
\LWR@htmltag{a id="#1"{}}\LWR@htmltag{/a}%
\LWR@startpars%
}% par not started
}% pars allowed
{% pars not allowed
\LWR@htmltag{a id="#1"{}}\LWR@htmltag{/a}%
}% pars not allowed
}% not lateximage
}

\newcommand*{\LWR@sublabel}[1]{%
\LWR@traceinfo{LWR@sublabel: !#1!}%
\LWR@origlabel{#1}%
\LWR@traceinfo{about to splabel}%
\LWR@traceinfo{filesectionnames is \ifbool{FileSectionNames}{true}{false}}%
\LWR@traceinfo{LWR@thisfilename is !\LWR@thisfilename!}%
\LWR@traceinfo{LWR@htmlfilenumber is \theLWR@htmlfilenumber}%
\LWR@splabel{#1}%
\LWR@subsublabel{#1}%
\LWR@traceinfo{finished with LWR@sublabel}%
}
\newcommand*{\LWR@newlabel}[1]{%
\LWR@traceinfo{lwr@newlabel: !#1!}%
\LWR@sublabel{#1}%
\LWR@traceinfo{lwr@newlabel: done}%
}


\newcommand*{\LWR@startref}[1]
{%
\edef\LWR@lidref{\LWR@lateximagedepthref{#1}}
\LWR@htmltag{a href="%
\LWR@htmlrefsectionfilename{#1}%
\#%
\ifthenelse{\equal{\LWR@lidref}{??}}%
{??}%
{%
\ifthenelse{\cnttest{\LWR@lidref}{>}{0}}%
{%
lateximage\LWR@lateximagenumberref{#1}%
}%
{%
#1%
}%
}%
"{}}%
}

\NewDocumentCommand{\LWR@newref}{s m}{%
\LWR@traceinfo{LWR@newref #2}%
\IfBooleanTF{#1}%
{\LWR@origref{#2}}%
{%
\LWR@startref{#2}%
\LWR@origref{#2}%
\LWR@htmltag{/a}%
}%
}


\newcommand*{\pagerefPageFor}{page for}
\NewDocumentCommand{\LWR@newpageref}{s m}{%
\IfBooleanTF{#1}%
{(\pagerefPageFor\ \LWR@origref{#2})}%
{(\cpageref{#2})}%
}

\newcommand*{\nameref}[1]{%
\LWR@traceinfo{nameref A}%
\LWR@startref{#1}%
\LWR@traceinfo{nameref B}%
\LWR@nameref{#1}%
\LWR@traceinfo{nameref C}%
\LWR@htmltag{/a}%
\LWR@traceinfo{nameref D}%
}





\NewDocumentCommand{\LWR@subhyperref}{m +m}{%
\LWR@htmltag{a href="{#1}" target="\_{}blank"\LWR@orignewline}#2\LWR@htmltag{/a}%
\LWR@ensuredoingapar%
}

\NewDocumentCommand{\LWR@subhyperrefclass}{m +m m}{%
\LWR@htmltag{a href="{#1}"
class="#3"\LWR@orignewline}#2\LWR@htmltag{/a}%
\LWR@ensuredoingapar%
}

\NewDocumentCommand{\LWR@hrefb}{O{} m +m}{%
\LWR@subhyperref{#2}{#3}%
\endgroup%
\LWR@ensuredoingapar%
}

\newcommand{\href}{%
\LWR@ensuredoingapar%
\begingroup%
\catcode`\_=12
\LWR@hrefb%
}

\newcommand*{\LWR@nolinkurlb}[1]{#1\endgroup\LWR@ensuredoingapar}

\newcommand{\nolinkurl}{%
\LWR@ensuredoingapar%
\begingroup\catcode`\_=12
\LWR@nolinkurlb%
}

\newcommand*{\LWR@urlb}[1]{%
\href{#1}{#1}%
\endgroup%
\LWR@ensuredoingapar%
}

\newcommand{\url}{%
\LWR@ensuredoingapar%
\begingroup\catcode`\_=12
\LWR@urlb%
}

\newcommand*{\LWR@subinlineimage}[5][]{%
\ifthenelse{\equal{#1}{}}%
{\LWR@htmltag{img src="#3.#4" alt="#3" style="#5" class="#2"{}}}%
{\LWR@htmltag{img src="#3.#4" alt="#1" style="#5" class="#2"{}}}%
}

\end{warpHTML}






\begin{warpHTML}

\NewDocumentCommand{\LWR@floatbegin}{m o}{%
\LWR@stoppars
\addtocounter{LWR@thisfloat}{1}%
\booltrue{LWR@freezethisfloat}%
\begingroup
\LWR@origraggedright
\LWR@htmltag{figure id="autofloat-\arabic{LWR@thisfloat}" class="#1"}
\renewcommand*{\@captype}{#1}
\caption@settype{#1}
\LWR@startpars
}
\let\@float\LWR@floatbegin
\let\@dblfloat\LWR@floatbegin
\newcommand*{\LWR@floatend}{%
\LWR@stoppars%
\LWR@htmlelementend{figure}%
\endgroup%
\boolfalse{LWR@freezethisfloat}%
\LWR@startpars%
}
\let\end@float\LWR@floatend
\let\end@dblfloat\LWR@floatend

\newcounter{LWR@thisfloat}

\newbool{LWR@freezethisfloat}
\boolfalse{LWR@freezethisfloat}

\newcommand*{\LWR@maybeincthisfloat}{%
\ifbool{LWR@freezethisfloat}{}{\addtocounter{LWR@thisfloat}{1}}%
}

\newcommand*{\@captype}{}


\AtBeginDocument{\providecommand*{\CaptionSeparator}{:~}}

\AtBeginDocument{\renewcommand{\@makecaption}[2]{#1\CaptionSeparator#2}}


\newcounter{LWR@nextautofloat}
\newcounter{LWR@nextautopage}
\newcommand*{\LWRsetnextfloat}[2]{%
\setcounter{LWR@nextautopage}{#1}%
\setcounter{LWR@nextautofloat}{#2}%
}

\newcounter{LWR@latestautopage}% updated each new HTML file
\setcounter{LWR@latestautopage}{1}

\let\LWR@origcaption@begin\caption@begin
\let\LWR@origcaption@end\caption@end
\let\LWR@orig@@par\@@par

\newcommand{\LWR@caption@begin}
{
\LWR@traceinfo{LWR@caption@begin}%
\begingroup%
\renewcommand{\@@par}{\LWR@closeparagraph\LWR@orig@@par}%
\RenewDocumentEnvironment{minipage}{O{t} o O{t} m}{}{}%
\LWR@htmlblocktag{figcaption}%
\LWR@origcaption@begin%
}

\newcommand{\LWR@caption@end}
{%
\LWR@origcaption@end%
\vspace*{\baselineskip}%
\LWR@htmlblocktag{/figcaption}%
\endgroup%
\LWR@traceinfo{LWR@caption@end: done}%
}

\let\caption@begin\LWR@caption@begin
\let\caption@end\LWR@caption@end

\let\LWR@origcaptionlistentry\captionlistentry

\renewcommand*{\captionlistentry}{%
\LWR@maybeincthisfloat%
\LWR@ensuredoingapar%
\LWR@htmltag{a id="autofloat-\arabic{LWR@thisfloat}"{}}\LWR@htmltag{/a}%
\LWR@origcaptionlistentry%
}

\def\LWR@LTcaptionlistentry{%
\LWR@ensuredoingapar%
\LWR@htmltag{a id="autofloat-\arabic{LWR@thisfloat}"{}}\LWR@htmltag{/a}%
  \bgroup
  \@ifstar{\egroup\LWR@LT@captionlistentry}% gobble *
          {\egroup\LWR@LT@captionlistentry}}%
\def\LWR@LT@captionlistentry#1{%
  \caption@listentry\@firstoftwo[\LTcaptype]{#1}}%

\let\LWR@origaddcontentsline\addcontentsline

\renewcommand*{\addcontentsline}[3]{%
\ifthenelse{\equal{#1}{toc}}{}{%
\addtocontents{\@nameuse{ext@#2}}{%
\protect\LWRsetnextfloat%
{\arabic{LWR@latestautopage}}%
{\arabic{LWR@thisfloat}}%
}%
}%
\LWR@origaddcontentsline{#1}{#2}{#3}%
}

\AtBeginDocument{
\let\LWR@origcaptionof\captionof

\renewcommand*{\captionof}{%
\LWR@maybeincthisfloat%
\LWR@stoppars
\LWR@htmltag{a id="autofloat-\arabic{LWR@thisfloat}"{}}\LWR@htmltag{/a}%
\LWR@origcaptionof%
}
}

\end{warpHTML}


\begin{warpHTML}



\newcommand*{\LWR@myshorttoc}[1]{
\LWR@ensuredoingapar
\IfFileExists{\jobname.#1}{
\begingroup
\makeatletter
\@input{\jobname.#1}
\endgroup
}%
{}%
}

\NewDocumentCommand{\LWR@subtableofcontents}{m m}{%
\@ifundefined{chapter}
{\LWR@closeprevious{\LWR@depthsection}}
{\LWR@closeprevious{\LWR@depthchapter}}
\LWR@printpendingnotes
\@ifundefined{chapter}{\section*{#2}}{\chapter*{#2}}
\LWR@htmlelementclass{nav}{#1}
\LWR@myshorttoc{#1}
\LWR@htmlelementclassend{nav}{#1}
}

\let\LWR@orig@starttoc\@starttoc

\renewcommand{\@starttoc}[1]{
\LWR@htmlelementclass{nav}{#1}
\LWR@orig@starttoc{#1}
\LWR@htmlelementclassend{nav}{#1}
}
\let\LWR@origtableofcontents\tableofcontents
\let\LWR@origlistoffigures\listoffigures
\let\LWR@origlistoftables\listoftables
\renewcommand*{\tableofcontents}{%
\LWR@copyfile{\jobname.toc}{\jobname.sidetoc}%
\LWR@printpendingnotes%
\LWR@origtableofcontents%
}
\renewcommand*{\listoffigures}{\LWR@printpendingnotes\LWR@origlistoffigures}
\renewcommand*{\listoftables}{\LWR@printpendingnotes\LWR@origlistoftables}


\NewDocumentCommand{\listof}{m +m}{%
\LWR@subtableofcontents{\@nameuse{ext@#1}}{#2}
\expandafter\newwrite\csname tf@\csname ext@#1\endcsname\endcsname
\immediate\openout \csname tf@\csname ext@#1\endcsname\endcsname
    \jobname.\csuse{ext@#1}\relax
}



\end{warpHTML}

\begin{warpall}

\newcounter{SideTOCDepth}
\setcounter{SideTOCDepth}{1}

\newcommand{\sidetocname}{Contents}

\end{warpall}

\begin{warpHTML}

\newcommand*{\LWR@sidetoc}{
\LWR@stoppars

\LWR@htmlelementclass{nav}{sidetoc}

\setcounter{tocdepth}{\value{SideTOCDepth}}

\begin{BlockClass}{sidetoctitle}
\sidetocname
\end{BlockClass}
\begin{BlockClass}{sidetoccontents}
\LinkHome

\LWR@myshorttoc{sidetoc}
\end{BlockClass}
\LWR@htmlelementclassend{nav}{sidetoc}
}


\renewcommand*{\numberline}[1]{%
\LWR@sectionnumber{#1}%
}

\NewDocumentCommand{\hypertoc}{m m +m m}{%
\ifthenelse{\cnttest{#1}{<=}{\value{tocdepth}}}{%
\LWR@startpars%
\LWR@subhyperrefclass{%
\LWR@htmlrefsectionfilename{autopage-#4}\#autosec-#4}{#3}{#2}%
\LWR@stoppars%
}
{}
}


\newcommand{\hypertocfloat}[4]{%
\LWR@startpars
\LWR@subhyperrefclass{%
\LWR@htmlrefsectionfilename{autopage-\arabic{LWR@nextautopage}}%
\#autofloat-\arabic{LWR@nextautofloat}}%
{#3}{#2}%
\LWR@stoppars%
}

\renewcommand{\l@part}[2]{\hypertoc{-1}{tocpart}{#1}{#2}}
\DeclareDocumentCommand{\l@chapter}{m m}
{\hypertoc{0}{tocchapter}{#1}{#2}}
\renewcommand{\l@section}[2]{\hypertoc{1}{tocsection}{#1}{#2}}
\renewcommand{\l@subsection}[2]{\hypertoc{2}{tocsubsection}{#1}{#2}}
\renewcommand{\l@subsubsection}[2]
{\hypertoc{3}{tocsubsubsection}{#1}{#2}}
\renewcommand{\l@paragraph}[2]{\hypertoc{4}{tocparagraph}{#1}{#2}}
\renewcommand{\l@subparagraph}[2]{\hypertoc{5}{tocsubparagraph}{#1}{#2}}
\renewcommand{\l@figure}[2]{\hypertocfloat{1}{tocfigure}{#1}{#2}}
\renewcommand{\l@table}[2]{\hypertocfloat{1}{toctable}{#1}{#2}}

\end{warpHTML}



\begin{warpHTML}

\@ifundefined{chapter}
{\newcommand*{\LWR@indexsection}{\section{\indexname}}}
{\newcommand*{\LWR@indexsection}{\chapter{\indexname}}}

\let\LWR@origprintindex\printindex

\renewcommand*{\printindex}
{
\LWR@indexsection
\LWR@startpars
\LWR@origprintindex
}

\renewenvironment*{theindex}{%
\let\item\LWR@indexitem%
\let\subitem\LWR@indexsubitem%
\let\subsubitem\LWR@indexsubsubitem%
}{}

\newcommand{\LWR@indexitem}{

\InlineClass{indexitem}{}
}

\newcommand{\LWR@indexsubitem}{

\InlineClass{indexsubitem}{}
}

\newcommand{\LWR@indexsubsubitem}{

\InlineClass{indexsubsubitem}{}
}

\newcommand*{\hyperindexref}[1]{
\LWR@htmltag{a href="%
\LWR@htmlrefsectionfilename{autopage-#1}\#autosec-#1"{}}%
\LWR@origref{autopage-#1}\enskip\LWR@nameref{autopage-#1}%
\LWR@htmltag{/a}%
}

\end{warpHTML}

\begin{warpprint}
\newcommand{\hyperindexref}[1]{#1}
\end{warpprint}


\begin{warpHTML}

\let\LWR@origtextdollar\$

\renewcommand*{\$}{%
\LWR@htmltagc{span}%
\LWR@origtextdollar%
\LWR@htmltagc{/span}%
}

\newcounter{LWR@externalfilecnt}


\let\LWR@origdollar=$
\let\secondorigdollar=$% balance for editor syntax highlighting

\let\LWR@origopenparen\(
\let\LWR@origcloseparen\)

\begingroup
\catcode`\$=\active%
\protected\gdef${\@ifnextchar$\LWR@doubledollar\LWR@singledollar}%

\gdef\LWR@doubledollar$#1$${
\ifbool{mathjax}%
{\textbackslash[\LWR@HTMLsanitize{#1}\textbackslash]}
{% not mathjax

\begin{lateximage}%
[\textbackslash{[} \LWR@HTMLsanitize{#1} \textbackslash{]}]%
\LWR@origdollar\LWR@origdollar#1\LWR@origdollar\LWR@origdollar%
\end{lateximage}

}
}%

\gdef\LWR@singledollar#1${%
\ifbool{mathjax}%
{\textbackslash(\LWR@HTMLsanitize{#1}\textbackslash)}
{% not mathjax
\begin{lateximage}%
[\textbackslash( \LWR@HTMLsanitize{#1} \textbackslash)]%
\LWR@origdollar#1\LWR@origdollar%
\end{lateximage}%
}%
}%

\gdef\(#1\){$#1$}
\gdef\[#1\]{$$#1$$}

\endgroup

\let\math\relax
\let\endmath\relax
\let\displaymath\relax
\let\enddisplaymath\relax

\NewEnviron{math}{\expandafter\(\BODY\)}
\NewEnviron{displaymath}{\expandafter\[\BODY\]\@ignoretrue}

\AtBeginDocument{\catcode`\$=\active}

\newcounter{LWR@nextequation}
\newcommand*{\LWR@syncmathjax}{%
\ifcsdef{thechapter}{
\BlockClassSingle{hidden}{
\textbackslash(
\textbackslash{}seteqsection \{\thechapter\}
\textbackslash)
}
}
{}% not using chapters

\ifthenelse{\cnttest{\value{equation}}>0}
{
\setcounter{LWR@nextequation}{\value{equation}}
\addtocounter{LWR@nextequation}{1}
\BlockClassSingle{hidden}{
\textbackslash(
\textbackslash{}seteqnumber \{\arabic{LWR@nextequation}\}
\textbackslash)
}
}{}% not eq > 1
}

\newcommand*{\LWR@restoremathlatexformatting}{%
\let\hspace\LWR@orighspace%
\let\rule\LWR@origrule%
\let\,\LWR@origcomma% disable HTML short unbreakable space
\let\textit\LWR@origtextit%
\let\textbf\LWR@origtextbf%
\let\texttt\LWR@origtexttt%
\let\textsc\LWR@origtextsc%
\let\textsf\LWR@origtextsf%
\let\textrm\LWR@origtextrm%
\renewcommand*{\thefootnote}{\fnsymbol{footnote}}%
\let\textsuperscript\LWR@origtextsuperscript%
\let\textsubscript\LWR@origtextsubscript%
\let~\LWR@origtilde%
\let\enskip\LWR@origenskip%
\let\quad\LWR@origquad%
\let\qquad\LWR@origqquad%
}

\NewDocumentCommand{\LWR@hidelatexequation}{m +m}{%
\LWR@stoppars
\LWR@htmlopencomment

\begingroup
\csuse{LWR@orig#1}
\LWR@restoremathlatexformatting
#2
\csuse{LWR@origend#1}
\endgroup

\LWR@htmlclosecomment
\LWR@startpars
}

\NewDocumentCommand{\LWR@addmathjax}{m +m}{%

\textbackslash{}begin\{#1\}
\LWR@HTMLsanitizeexpand{\detokenize\expandafter{#2}}
\textbackslash{}end\{#1\}

}

\let\LWR@origequation\equation
\let\LWR@origendequation\endequation
\let\equation\relax
\let\endequation\relax

\NewEnviron{equation}{%

\ifbool{mathjax}
{
\LWR@syncmathjax
\LWR@hidelatexequation{equation}{\BODY}
}
{% not mathjax
\begin{lateximage}[(\theequation) \textbackslash{begin\{equation\}}%
 \LWR@HTMLsanitizeexpand{\detokenize\expandafter{\BODY}}%
 \textbackslash{end\{equation\}}]% alt tag
\LWR@origequation
\BODY% contents collected by NewEnviron
\LWR@origendequation
\end{lateximage}%
}

}[\ifbool{mathjax}{\LWR@addmathjax{equation}{\BODY}}{}]

\newbool{LWR@amsmultline}
\boolfalse{LWR@amsmultline}


\newcommand*{\LWR@htmlmathlabel}[1]{%
\LWR@traceinfo{LWR@htmlmathlabel #1}%
\ifbool{mathjax}{%
\text{
\ifbool{LWR@amsmultline}{}{\hspace*{\totwidth@}}
\LWR@htmlclosecomment\LWR@sublabel{\@firstofone#1}\LWR@htmlopencomment}%
}%
{\LWR@sublabel{\@firstofone#1}}%
}

\newcommand*{\LWR@beginhideamsmath}{
\LWR@stoppars

\LWR@htmlopencomment

\begingroup
\LWR@restoremathlatexformatting
}

\newcommand*{\LWR@endhideamsmath}{
\endgroup

\LWR@htmlclosecomment

\LWR@startpars
}



\BeforeBeginEnvironment{multline}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\booltrue{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{multline}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\boolfalse{LWR@amsmultline}
\LWR@addmathjax{multline}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{multline*}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\booltrue{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{multline*}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\boolfalse{LWR@amsmultline}
\LWR@addmathjax{multline*}{\the\@envbody}
}
{\endlateximage}

}


\BeforeBeginEnvironment{gather}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{gather}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{gather}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{gather*}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{gather*}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{gather*}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{align}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{align}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{align}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{align*}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{align*}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{align*}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{flalign}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{flalign}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{flalign}{\the\@envbody}
}
{\endlateximage}

}

\BeforeBeginEnvironment{flalign*}{
\ifbool{mathjax}
{
\LWR@syncmathjax
\boolfalse{LWR@amsmultline}
\LWR@beginhideamsmath
}
{
\lateximage[LWRAMSMATHBODY]
}
}

\AfterEndEnvironment{flalign*}{

\ifbool{mathjax}
{
\LWR@endhideamsmath
\LWR@addmathjax{flalign*}{\the\@envbody}
}
{\endlateximage}

}

\end{warpHTML}


\begin{warpHTML}
\newpagestyle{LWR@commentfooterstyle}{
\sethead{}{}{}
\setfoot{\LWR@htmlopencomment}{}{}
}

\newcounter{LWR@lateximagenumber}
\setcounter{LWR@lateximagenumber}{0}
\newcounter{LWR@lateximagedepth}
\setcounter{LWR@lateximagedepth}{0}

\ifcsdef{LWR@file}{}{\newwrite{\LWR@file}}
\edef\LWR@hashmark{\string#} % for use in \write
\edef\LWR@percent{\@percentchar} % for use in \write

\newcounter{LWR@nextpage}

\end{warpHTML}

\begin{warpall}

\newcommand*{\LateximageFontSizeName}{normalsize}

\end{warpall}

\begin{warpHTML}

\newcommand{\LWR@HTMLsanitize}[1]{%
\protect\StrSubstitute{\detokenize{#1}}%
{\detokenize{&}}%
{\detokenize{&amp;}}[\LWR@strresult]%
\protect\StrSubstitute{\detokenize\expandafter{\LWR@strresult}}%
{\detokenize{<}}%
{\detokenize{&lt;}}%
[\LWR@strresult]%
\protect\StrSubstitute{\detokenize\expandafter{\LWR@strresult}}%
{\detokenize{>}}%
{\detokenize{&gt;}}%
[\LWR@strresult]%
\protect\StrSubstitute{\detokenize\expandafter{\LWR@strresult}}%
{\detokenize{##}}%
{\#}%
[\LWR@strresult]%
\LWR@strresult%
}

\newcommand{\LWR@HTMLsanitizeexpand}[1]{%
\protect\StrSubstitute{\detokenize\expandafter{#1}}%
{\detokenize{&}}%
{\detokenize{&amp;}}%
[\LWR@strresult]%
\protect\StrSubstitute{\detokenize\expandafter{\LWR@strresult}}%
{\detokenize{<}}%
{\detokenize{&lt;}}%
[\LWR@strresult]%
\protect\StrSubstitute{\detokenize\expandafter{\LWR@strresult}}%
{\detokenize{>}}%
{\detokenize{&gt;}}%
[\LWR@strresult]%
\LWR@strresult%
}

\NewDocumentEnvironment{lateximage}{O{image}}{%
\ifthenelse{\cnttest{\value{LWR@lateximagedepth}}{>}{0}}%
{%
\addtocounter{LWR@lateximagedepth}{1}%
}%
{% start of outer-most lateximage
\addtocounter{LWR@lateximagenumber}{1}%
\boolfalse{mathjax}
\LWR@ensuredoingapar%
\addtocounter{LWR@externalfilecnt}{1}%
\setcounter{LWR@nextpage}{\thepage}%
\addtocounter{LWR@nextpage}{1}%
\LWR@htmltag{span id="lateximage\arabic{LWR@lateximagenumber}" %
class="lateximagesource"{}} \LWR@orignewline
\immediate\write\LWR@file{%
  pdfseparate -f  \theLWR@nextpage  \space -l %
  \theLWR@nextpage \space %
  \jobname.pdf lateximagetemp-\LWR@percent d.pdf}%
\immediate\write\LWR@file{%
  pdfcrop --hires lateximagetemp-\theLWR@nextpage.pdf
    lateximage-\theLWR@externalfilecnt.pdf}%
\immediate\write\LWR@file{%
  pdftocairo  -svg  lateximage-\theLWR@externalfilecnt.pdf
    lateximage-\theLWR@externalfilecnt.svg}%
\immediate\write\LWR@file{%
  \OSmv lateximage-\theLWR@externalfilecnt.svg %
  lateximages\OSPathSymbol}%
\immediate\write\LWR@file{%
  \OSrm lateximage-\theLWR@externalfilecnt.pdf
       lateximagetemp-\theLWR@nextpage.pdf}%
\LWR@origthispagestyle{LWR@commentfooterstyle}%
\addtocounter{LWR@lateximagedepth}{1}%
\LWR@orignewpage%
\LWR@origminipage{6in}%
\csuse{LWR@orig\LateximageFontSizeName}%
\let\hspace\LWR@orighspace%
\let\rule\LWR@origrule%
\let\,\LWR@origcomma% disable HTML short unbreakable space
\let\textit\LWR@origtextit%
\let\textbf\LWR@origtextbf%
\let\texttt\LWR@origtexttt%
\let\textsc\LWR@origtextsc%
\let\textsf\LWR@origtextsf%
\let\textrm\LWR@origtextrm%
\renewcommand*{\thefootnote}{\fnsymbol{footnote}}%
\let\textsuperscript\LWR@origtextsuperscript%
\let\textsubscript\LWR@origtextsubscript%
\let~\LWR@origtilde%
\let\enskip\LWR@origenskip%
\let\quad\LWR@origquad%
\let\qquad\LWR@origqquad%
\let\tabular\LWR@origtabular%
\let\endtabular\LWR@origendtabular%
\let\newline\LWR@orignewline%
}% end of outer-most lateximage
}% end of \begin{lateximage}
{% start of \end{lateximage}
\ifthenelse{\cnttest{\value{LWR@lateximagedepth}}{>}{1}}%
{%
\addtocounter{LWR@lateximagedepth}{-1}%
}%
{% end of outer-most lateximage
\LWR@origendminipage%
\LWR@orignewpage%
\LWR@origscriptsize%
\LWR@htmlclosecomment{}\LWR@orignewline%
\ifthenelse{\equal{#1}{LWRAMSMATHBODY}}%
{%
\LWR@subinlineimage[%
\LWR@HTMLsanitizeexpand{\detokenize\expandafter{\the\@envbody}}%
]%
{lateximage}%
{lateximages\OSPathSymbol{}lateximage-\theLWR@externalfilecnt}%
{svg}%
{}%
}%
{%
\LWR@subinlineimage[#1]{lateximage}%
{lateximages\OSPathSymbol{}lateximage-\theLWR@externalfilecnt}{svg}{}%
}%
\LWR@ensuredoingapar%
\LWR@htmltag{/span}%
\LWR@htmlcomment{End of lateximage}%
\addtocounter{LWR@lateximagedepth}{-1}%
}% end of outer-most lateximage
}%
\end{warpHTML}
\begin{warpprint}
\newenvironment{lateximage}[1][]{\begingroup}{\endgroup}
\end{warpprint}


\begin{warpHTML}

\renewenvironment*{center}
{\BlockClass{center}}
{\endBlockClass}

\renewenvironment*{flushright}
{\BlockClass{flushright}}
{\endBlockClass}

\renewenvironment*{flushleft}
{\BlockClass{flushleft}}
{\endBlockClass}

\end{warpHTML}



\begin{warpHTML}

\PassOptionsToPackage{
detect-mode=true,
per-mode=symbol, % fraction is not seen by pdftotext
text-celsius = {\HTMLentity{deg}C},
text-degree = {\HTMLentity{deg}},
}{siunitx}

\end{warpHTML}


\begin{warpHTML}


\newcommand*{\thisgraphicspath}{{}}
\renewcommand*{\graphicspath}[1]{\renewcommand*{\thisgraphicspath}{#1}}


\renewcommand*{\DeclareGraphicsExtensions}[1]{}
\renewcommand*{\DeclareGraphicsRule}[4]{}


\renewcommand*{\unitspace}{}

\newlength{\LWR@igwidth}
\newlength{\LWR@igheight}
\newcommand*{\LWR@igwidthstyle}{}
\newcommand*{\LWR@igheightstyle}{}
\newcommand*{\LWR@igorigin}{}
\newcommand*{\LWR@igangle}{}
\newcommand*{\LWR@igxscale}{1}
\newcommand*{\LWR@igyscale}{1}
\newcommand*{\LWR@igclass}{inlineimage}

\define@key{igraph}{width}{%
\setlength{\LWR@igwidth}{#1}%
\ifthenelse{\lengthtest{\LWR@igwidth > 0pt}}%
{%
\uselengthunit{PT}%
\renewcommand*{\LWR@igwidthstyle}{width:\rndprintlength{\LWR@igwidth}}%
\IfEndWith{#1}{ex}%
{\renewcommand*{\LWR@igwidthstyle}{width:#1}}% yes ex
{}% not ex
\IfEndWith{#1}{em}%
{\renewcommand*{\LWR@igwidthstyle}{width:#1}}% yes em
{}% not em
\IfEndWith{#1}{\%}%
{\renewcommand*{\LWR@igwidthstyle}{width:#1}}% yes percent
{}% not percent
\IfEndWith{#1}{px}%
{\renewcommand*{\LWR@igwidthstyle}{width:#1}}% yes px
{}% not px
}{}% end of length > 0pt
}
\define@key{igraph}{height}{%
\setlength{\LWR@igheight}{#1}%
\ifthenelse{\lengthtest{\LWR@igheight > 0pt}}%
{%
\uselengthunit{PT}%
\renewcommand*{\LWR@igheightstyle}{%
height:\rndprintlength{\LWR@igheight} %
}%
\IfEndWith{#1}{ex}%
{\renewcommand*{\LWR@igheightstyle}{height:#1}}% yes ex
{}% not ex
\IfEndWith{#1}{em}%
{\renewcommand*{\LWR@igheightstyle}{height:#1}}% yes em
{}% not em
\IfEndWith{#1}{\%}%
{\renewcommand*{\LWR@igheightstyle}{height:#1}}% yes percent
{}% not percent
\IfEndWith{#1}{px}%
{\renewcommand*{\LWR@igheightstyle}{height:#1}}% yes px
{}% not px
}{}% end of length > 0pt
}
\define@key{igraph}{origin}{%
\renewcommand*{\LWR@igorigin}{#1}%
}
\define@key{igraph}{angle}{\renewcommand*{\LWR@igangle}{#1}}
\define@key{igraph}{class}{\renewcommand*{\LWR@igclass}{#1}}

\define@key{igraph}{scale}{%
\renewcommand*{\LWR@igxscale}{#1}%
\renewcommand*{\LWR@igyscale}{#1}}
\define@key{igraph}{bb}{}
\define@key{igraph}{bbllx}{}
\define@key{igraph}{bblly}{}
\define@key{igraph}{bburx}{}
\define@key{igraph}{bbury}{}
\define@key{igraph}{natwidth}{}
\define@key{igraph}{natheight}{}
\define@key{igraph}{hiresbb}{}
\define@key{igraph}{viewport}{}
\define@key{igraph}{trim}{}
\define@key{igraph}{totalheight}{}
\define@key{igraph}{keepaspectratio}{}
\define@key{igraph}{clip}{}
\define@key{igraph}{draft}{}
\define@key{igraph}{type}{}
\define@key{igraph}{ext}{}
\define@key{igraph}{read}{}
\define@key{igraph}{command}{}

\newcommand*{\LWR@rotstyle}[2]{%
 #1transform:rotate(-#2deg);
}

\newcommand*{\LWR@scalestyle}[3]{%
 #1transform:scale(#2,#3);
}


\newbool{LWR@infloatrow}
\boolfalse{LWR@infloatrow}

\newcommand*{\LWR@imageextension}{}
\newcommand*{\LWR@expgraphicsfilename}{}


\newcommand*{\LWR@includegraphicsb}[2][]
{%
\LWR@origtilde \LWR@orignewline%
\ifthenelse{\cnttest{\value{LWR@minipagedepth}}{=}{0}}{%
\ifbool{LWR@infloatrow}%
{}
{% not in a minipage or a floatrow:
\setlength{\linewidth}{6in}%
\setlength{\textwidth}{6in}%
\setlength{\textheight}{9in}%
}%
}{}%
\edef\LWR@expgraphicsfilename{#2}
\renewcommand*{\LWR@imageextension}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.jpg}%
{\renewcommand*{\LWR@imageextension}{.jpg}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.JPG}%
{\renewcommand*{\LWR@imageextension}{.JPG}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.png}%
{\renewcommand*{\LWR@imageextension}{.png}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.PNG}%
{\renewcommand*{\LWR@imageextension}{.PNG}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.gif}%
{\renewcommand*{\LWR@imageextension}{.gif}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.GIF}%
{\renewcommand*{\LWR@imageextension}{.GIF}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.svg}%
{\renewcommand*{\LWR@imageextension}{.svg}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.SVG}%
{\renewcommand*{\LWR@imageextension}{.SVG}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.svgz}%
{\renewcommand*{\LWR@imageextension}{.svgz}}{}%
\IfFileExists{\detokenize\expandafter\thisgraphicspath\LWR@expgraphicsfilename.SVGZ}%
{\renewcommand*{\LWR@imageextension}{.SVGZ}}{}%
\StrSubstitute{\detokenize\expandafter{\LWR@expgraphicsfilename}}%
{\detokenize{.pdf}}{\detokenize{.svg}}[\LWR@strresult]%
\StrSubstitute{\LWR@strresult}%
{\detokenize{.PDF}}{\detokenize{.SVG}}[\LWR@strresult]%
\large%
\setlength{\LWR@igwidth}{0pt}%
\setlength{\LWR@igheight}{0pt}%
\renewcommand*{\LWR@igwidthstyle}{}%
\renewcommand*{\LWR@igheightstyle}{}%
\renewcommand*{\LWR@igorigin}{}%
\renewcommand*{\LWR@igangle}{}%
\renewcommand*{\LWR@igxscale}{1}%
\renewcommand*{\LWR@igyscale}{1}%
\renewcommand*{\LWR@igclass}{inlineimage}%
\setkeys{igraph}{#1}%
\href{\thisgraphicspath\LWR@strresult\LWR@imageextension}%
{% start of href
\LWR@htmltag{% start of image tags
img src="\thisgraphicspath\LWR@strresult\LWR@imageextension" \LWR@orignewline
\LWR@origtilde{} alt="\LWR@strresult" \LWR@orignewline
\ifthenelse{
\NOT\equal{\LWR@igwidthstyle}{} \OR
\NOT\equal{\LWR@igheightstyle}{} \OR
\NOT\equal{\LWR@igorigin}{} \OR
\NOT\equal{\LWR@igangle}{} \OR
\NOT\equal{\LWR@igxscale}{1} \OR
\NOT\equal{\LWR@igyscale}{1}
}%
{\LWR@origtilde{} style="%
\ifthenelse{\NOT\equal{\LWR@igwidthstyle}{}}%
{\LWR@igwidthstyle;}{}%
\ifthenelse{\NOT\equal{\LWR@igheightstyle}{}}%
{\LWR@igheightstyle;}{}%
\ifthenelse{\NOT\equal{\LWR@igorigin}{}}%
{\LWR@origtilde{} transform-origin: \LWR@originnames{\LWR@igorigin}; \LWR@orignewline}{}%
\ifthenelse{\NOT\equal{\LWR@igangle}{}}%
{%
\LWR@rotstyle{-ms-}{\LWR@igangle}%
\LWR@rotstyle{-webkit-}{\LWR@igangle}%
\LWR@rotstyle{}{\LWR@igangle%
}}{}%
\ifthenelse{\NOT\equal{\LWR@igxscale}{1}\OR%
\NOT\equal{\LWR@igyscale}{1}}%
{\LWR@scalestyle{-ms-}{\LWR@igxscale}{\LWR@igyscale}%
\LWR@scalestyle{-webkit-}{\LWR@igxscale}{\LWR@igyscale}%
\LWR@scalestyle{}{\LWR@igxscale}{\LWR@igyscale}}{}%
" \LWR@orignewline}{}%
\LWR@origtilde{} class="\LWR@igclass" \LWR@orignewline%
}% end of image tags
}% end of href
\endgroup
\LWR@origscriptsize
}





\renewcommand*{\includegraphics}
{%
\LWR@ensuredoingapar%
\begingroup%
\LWR@includegraphicsb%
}

\end{warpHTML}

\begin{warpprint}
\define@key{Gin}{class}{}
\end{warpprint}


\begin{warpHTML}

\newcommand*{\LWR@rotboxorigin}{}
\newcommand*{\LWR@originname}[1]{%
\ifthenelse{\equal{#1}{t}}{top}{}%
\ifthenelse{\equal{#1}{b}}{bottom}{}%
\ifthenelse{\equal{#1}{c}}{center}{}%
\ifthenelse{\equal{#1}{l}}{left}{}%
\ifthenelse{\equal{#1}{r}}{right}{}%
}
\newcommand*{\LWR@originnames}[1]{%
\StrChar{#1}{1}[\LWR@strresult]%
\LWR@originname{\LWR@strresult}
\StrChar{#1}{2}[\LWR@strresult]%
\LWR@originname{\LWR@strresult}
}
\define@key{krotbox}{origin}{%
\renewcommand*{\LWR@rotboxorigin}{#1}%
}
\define@key{krotbox}{x}{}
\define@key{krotbox}{y}{}
\define@key{krotbox}{units}{}
\NewDocumentCommand{\LWR@rotatebox}{O{} m +m}{%
\renewcommand*{\LWR@rotboxorigin}{}
\setkeys{krotbox}{#1}%
\LWR@htmltagc{span style="display: inline-block;
\ifthenelse{\NOT\equal{\LWR@rotboxorigin}{}}%
{transform-origin: \LWR@originnames{\LWR@rotboxorigin};\LWR@origtilde}{}%
\LWR@rotstyle{-ms-}{#2} %
\LWR@rotstyle{-webkit-}{#2} %
\LWR@rotstyle{}{#2} %
"{}}\LWR@orignewline%
\begin{LWR@nestspan}%
#3%
\LWR@htmltagc{/span}%
\end{LWR@nestspan}%
}

\NewDocumentCommand{\LWR@scalebox}{m o m}{%
\LWR@htmltagc{span style="display: inline-block; %
\LWR@scalestyle{-ms-}{#1}{\IfNoValueTF{#2}{#1}{#2}} %
\LWR@scalestyle{-webkit-}{#1}{\IfNoValueTF{#2}{#1}{#2}} %
\LWR@scalestyle{}{#1}{\IfNoValueTF{#2}{#1}{#2}} %
"{}}%
\begin{LWR@nestspan}%
#3%
\LWR@htmltagc{/span}%
\end{LWR@nestspan}%
}

\newcommand{\LWR@reflectbox}[1]{\LWR@scalebox{-1}[1]{#1}}

\end{warpHTML}


\begin{warpHTML}

\renewcommand{\resizebox}[3]{#3}

\end{warpHTML}





\begin{warpHTML}


\AtEndPreamble{
\RequirePackage{cleveref}
\crefname{pagenote}{note}{notes}
}
\AfterEndPreamble{




\renewcommand*{\@@setcref}[2]{#1{\ref{#2}}{}{}}


\renewcommand{\@@setcrefrange}[3]{%
#1{\ref{#2}}{\ref{#3}}{}{}{}{}}


\newcommand*{\cpagerefFor}{for}

\renewcommand*{\@@setcpageref}[2]{%
#1{\cpagerefFor\ \cref{#2}}{}{}%
}


\renewcommand{\@@setcpagerefrange}[3]{%
#1{\cpagerefFor\ \cref{#2}}{\cref{#3}}{}{}{}{}}

\let\LWR@origlabel\label
\let\label\LWR@newlabel
\let\LWR@origref\ref
\let\ref\LWR@newref% \end{ syntax highlighting
\let\LWR@origpageref\pageref
\let\pageref\LWR@newpageref

}% AfterEndPreamble

\end{warpHTML}



\begin{warpHTML}

\BeforeBeginEnvironment{picture}{

\lateximage}

\AfterEndEnvironment{picture}{\endlateximage

}

\end{warpHTML}



\begin{warpHTML}

\newbool{LWR@tikzbabel}
\boolfalse{LWR@tikzbabel}

\AtBeginDocument{
\@ifpackageloaded{tikz}{
\@ifpackagelater{tikz}{2013/12/20}% Test for Tikz version v3.0.0
{\booltrue{LWR@tikzbabel}}
{\boolfalse{LWR@tikzbabel}}
}{}
}

\BeforeBeginEnvironment{tikzpicture}{%

\lateximage
\ifbool{LWR@tikzbabel}
{}
{\catcode`\$=3} % dollar sign is math shift
}

\AfterEndEnvironment{tikzpicture}{%
\endlateximage

\ifbool{LWR@tikzbabel}
{}
{\catcode`\$=\active}
}

\end{warpHTML}


\begin{warpHTML}


\newcounter{LWR@minipagedepth}
\setcounter{LWR@minipagedepth}{0}

\newlength{\LWR@minipagewidth}
\newlength{\LWR@minipageheight}
\let\LWR@origminipage\minipage
\let\LWR@origendminipage\endminipage
\NewDocumentCommand{\LWR@nullrule}{o m m}{}
\newcommand{\LWR@makefntext}[1]{%
\begingroup%
\let\rule\LWR@nullrule%
\textsuperscript{\@thefnmark} #1%
\endgroup%
\LWR@htmltagc{/\LWR@tagregularparagraph}%
}
\newcommand*{\LWR@makefnmark}{\textsuperscript{\@thefnmark}}

\def\LWR@endminipage{%
    \par
    \unskip
    \ifvoid\@mpfootins\else
      \vskip\skip\@mpfootins
      \normalcolor
\LWR@htmldivclass{mpfootnotes}
      \unvbox\@mpfootins
\LWR@htmldivclassend{mpfootnotes}
    \fi
    \@minipagefalse
  \color@endgroup
  \egroup
  \expandafter\@iiiparbox\@mpargs{\unvbox\@tempboxa}}

\newcommand*{\LWR@subminipage}{%
\LWR@stoppars
\LWR@origminipage{6in}
\LWR@origraggedright%
\let\footnote\LWR@origfootnote%
\let\@makefntext\LWR@makefntext%
\let\@makefnmark\LWR@makefnmark%
\LWR@startpars%
}

\newcommand*{\LWR@endsubminipage}{%
\LWR@stoppars%
\LWR@endminipage% The following empty line is required:

}

\newbool{LWR@minipagefullwidth}
\boolfalse{LWR@minipagefullwidth}
\newcommand*{\minipagefullwidth}{\booltrue{LWR@minipagefullwidth}}
\end{warpHTML}
\begin{warpprint}
\newcommand*{\minipagefullwidth}{}
\end{warpprint}
\begin{warpHTML}
\newbool{LWR@minipagethispar}
\boolfalse{LWR@minipagethispar}
\RenewDocumentEnvironment{minipage}{O{t} o O{t} m}
{%
\LWR@traceinfo{starting minipage}%
\uselengthunit{in}%
\setlength{\LWR@minipagewidth}{#4}%
\ifthenelse{\cnttest{\value{LWR@minipagedepth}}{=}{0}}{%
\addtolength{\LWR@minipagewidth}{3em}% room for frames
\setlength{\linewidth}{6in}%
\setlength{\textwidth}{6in}%
\setlength{\textheight}{9in}%
}{}%
\addtocounter{LWR@minipagedepth}{1}%
\setlength{\LWR@minipageheight}{\textheight}% default unless specified
\IfValueTF{#2}{\setlength{\LWR@minipageheight}{#2}}{}%
\LWR@stoppars%
\LWR@traceinfo{minipage: creating div class}%
\LWR@htmltag{div class="minipage" style="%
\ifthenelse{\equal{#1}{t}}{vertical-align: bottom ; }{}%
\ifthenelse{\equal{#1}{c}}{vertical-align: middle ; }{}%
\ifthenelse{\equal{#1}{b}}{vertical-align: top ; }{}%
\ifthenelse{\equal{#3}{t}}{justify-content: flex-start ; }{}%
\ifthenelse{\equal{#3}{c}}{justify-content: center ; }{}%
\ifthenelse{\equal{#3}{b}}{justify-content: flex-end ; }{}%
\ifthenelse{\equal{#3}{s}}{justify-content: space-between ; }{}%
\LWR@traceinfo{minipage: about to print the width}%
\uselengthunit{PT}%
\ifbool{LWR@minipagefullwidth}%
{\boolfalse{LWR@minipagefullwidth}}%
{%
\ifthenelse{\lengthtest{#4}=\linewidth}%
{}%
{width:\rndprintlength{\LWR@minipagewidth} ; }%
}%
\LWR@traceinfo{minipage: about to print the height}%
\IfValueTF{#2}{height:\rndprintlength{\LWR@minipageheight} ; }{}%
"{}}%

\LWR@origminipage{6in}% The preceding empty line is required.
\setlength{\linewidth}{#4}% the original width
\setlength{\textwidth}{6in}%
\setlength{\textheight}{9in}%
\LWR@origraggedright%
\let\footnote\LWR@origfootnote%
\let\@makefntext\LWR@makefntext%
\let\@makefnmark\LWR@makefnmark%
\LWR@startpars%
\LWR@traceinfo{minipage: finished starting the minipage}%
}
{%
\LWR@stoppars%
\LWR@endminipage% The following empty line is required:

\LWR@htmldivclassend{minipage}%
\vspace{1\baselineskip}% required for subcaption
\addtocounter{LWR@minipagedepth}{-1}%
\LWR@startpars%
\global\booltrue{LWR@minipagethispar}%
}
\RenewDocumentCommand{\parbox}{O{t} o O{t} m m}
{
\begin{minipage}[#1][#2][#3]{#4}
#5
\end{minipage}
}
\RenewDocumentCommand{\makebox}{o o m}{%
\mbox{#3}
}
\RenewDocumentCommand{\framebox}{o o m}{%
\fbox{#3}
}
\let\LWR@origfbox\fbox
\renewcommand*{\fbox}[1]{%
\InlineClass{framebox}{#1}%
}
\RenewDocumentCommand{\raisebox}{m o o m}{%
#4%
}

\end{warpHTML}


\begin{warpHTML}

\renewcommand{\emph}[1]{\LWR@htmlspan{em}{#1}}

\renewcommand{\textmd}[1]{\LWR@htmlspan{textmd}{#1}}

\renewcommand{\textbf}[1]{\LWR@htmlspan{b}{#1}}

\renewcommand{\textrm}[1]{\InlineClass{textrm}{#1}}

\renewcommand{\textsf}[1]{\InlineClass{textsf}{#1}}

\renewcommand{\texttt}[1]{\LWR@htmlspan{kbd}{#1}}

\renewcommand{\textup}[1]{\LWR@htmlspan{textup}{#1}}

\renewcommand{\textit}[1]{\LWR@htmlspan{i}{#1}}

\renewcommand{\textsc}[1]{\InlineClass{textsc}{#1}}

\renewcommand{\textnormal}[1]{\textmd{\textrm{\textup{#1}}}}

\renewcommand*{\mdseries}{}

\renewcommand*{\bfseries}{}

\renewcommand*{\rmfamily}{}

\renewcommand*{\sffamily}{}

\renewcommand*{\ttfamily}{}

\renewcommand*{\upshape}{}

\renewcommand*{\itshape}{}

\renewcommand*{\scshape}{}

\renewcommand*{\normalfont}{}


\renewcommand{\sp}[1]{\text{<sup>#1</sup>}{}}


\renewcommand{\sb}[1]{\text{<sub>#1</sub>}{}}

\renewcommand{\textsuperscript}[1]{\LWR@htmlspan{sup}{#1}}

\renewcommand{\textsubscript}[1]{\LWR@htmlspan{sub}{#1}}

\AtBeginDocument{\let\up\textsuperscript}

\AtBeginDocument{\let\fup\textsuperscript}

\renewcommand*{\hfill}{\qquad}

\renewcommand*{\hrulefill}{\rule{1in}{1pt}}

\renewcommand*{\dotfill}{\dots}

\end{warpHTML}


\begin{warpHTML}

\let\LWR@origcomma\,
\let\LWR@origtilde~
\let\LWR@origenskip\enskip
\let\LWR@origquad\quad
\let\LWR@origqquad\qquad
\let\LWR@orighspace\hspace
\let\LWR@origrule\rule

\renewcommand*{\,}{\HTMLunicode{202f}} % HTML thin non-breakable space
\renewcommand*{~}{\HTMLentity{nbsp}}
\renewcommand*{\textellipsis}{\HTMLunicode{2026}}
\let\LWR@orignormalsize\normalsize
\let\LWR@origsmall\small
\let\LWR@origfootnotesize\footnotesize
\let\LWR@origscriptsize\scriptsize
\let\LWR@origtiny\tiny
\let\LWR@origlarge\large
\let\LWR@origLarge\Large
\let\LWR@origLARGE\LARGE
\let\LWR@orighuge\huge
\let\LWR@origHuge\Huge
\renewcommand*{\normalsize}{}
\renewcommand*{\small}{}
\renewcommand*{\footnotesize}{}
\renewcommand*{\scriptsize}{}
\renewcommand*{\tiny}{}
\renewcommand*{\large}{}
\renewcommand*{\Large}{}
\renewcommand*{\LARGE}{}
\renewcommand*{\huge}{}
\renewcommand*{\Huge}{}

\renewcommand*{\onecolumn}{}

\renewcommand{\twocolumn}[1][]{

#1

}

\newcommand*{\LWR@newlinebr}{\unskip\LWR@htmltag{br /}\LWR@orignewline}%
\let\newline\LWR@newlinebr

\NewDocumentCommand{\LWR@endofline}{s o}
{%
\newline%
}

\newcommand*{\LWR@minipagestartpars}{%
\ifbool{LWR@minipagethispar}%
{%
\LWR@startpars%
}{}%
}

\newcommand*{\LWR@minipagestoppars}{%
\ifbool{LWR@minipagethispar}%
{%
\LWR@stoppars%
}{}%
}

\renewcommand*{\quad}{%
\LWR@minipagestoppars%
\HTMLunicode{2001}%
\LWR@minipagestartpars%
}

\renewcommand*{\qquad}{\quad\quad}

\renewcommand*{\enskip}{%
\LWR@minipagestoppars%
\HTMLunicode{2000}%
\LWR@minipagestartpars%
}

\newlength{\LWR@tempwidth}
\newlength{\LWR@tempheight}
\newlength{\LWR@tempraise}


\NewDocumentCommand{\LWR@hspace}{s m}{%
\setlength{\LWR@tempwidth}{#2}%
\ifthenelse{\dimtest{\LWR@tempwidth}{=}{0pt}}{}{%
\LWR@minipagestoppars%
\ifthenelse{\dimtest{\LWR@tempwidth}{=}{.16667em}}
{%
\HTMLunicode{2009}% thin breakable space
}%
{%
\uselengthunit{PT}%
\LWR@htmltagc{%
span style="width:\printlength{\LWR@tempwidth}; display:inline-block;"%
}%
\LWR@htmltagc{/span}%
}%
\LWR@minipagestartpars%
}%
}
\let\hspace\LWR@hspace

\renewcommand*{\linebreak}[1][]{\newline}

\renewcommand*{\nolinebreak}[1][]{}

\renewcommand*{\pagebreak}[1][]{

}

\renewcommand*{\nopagebreak}[1][]{}

\RenewDocumentCommand{\enlargethispage}{s m}{}

\NewDocumentCommand{\LWR@rule}{o m m}{%
\setlength{\LWR@tempwidth}{#2}%
\ifthenelse{\lengthtest{\LWR@tempwidth=0pt}}
{}% zero- width
{% non-zero width
\ifthenelse{\lengthtest{\LWR@tempwidth>0pt}\AND%
\lengthtest{\LWR@tempwidth<1pt}}%
{\setlength{\LWR@tempwidth}{1pt}}{}%
\setlength{\LWR@tempheight}{#3}%
\ifthenelse{\lengthtest{\LWR@tempheight>0pt}\AND%
\lengthtest{\LWR@tempheight<1pt}}%
{\setlength{\LWR@tempheight}{1pt}}{}%
\LWR@minipagestoppars%
\uselengthunit{PT}%
\LWR@htmltagc{%
span
style=" %
background:\LWR@currenttextcolor; %
width:\printlength{\LWR@tempwidth}; %
height:\printlength{\LWR@tempheight}; %
\IfValueTF{#1}%
{%
\setlength{\LWR@tempraise}{0pt-#1}%
\setlength{\LWR@tempraise}{\LWR@tempraise*2}%
\LWR@orignewline%
-ms-transform: translate(0pt,\printlength{\LWR@tempraise}); %
\LWR@orignewline%
-webkit-transform: translate(0pt,\printlength{\LWR@tempraise}); %
\LWR@orignewline%
transform: translate(0pt,\printlength{\LWR@tempraise}); %
\LWR@orignewline%
}{}%
display:inline-block;"%
}%
\LWR@htmltagc{/span}%
\LWR@minipagestartpars%
}% non-zero width
}
\let\rule\LWR@rule

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\phantomsection}{\section*{}}

\end{warpHTML}


\begin{warpHTML}

\newcommand*{\LWR@TeX}
{\InlineClass{latexlogofont}%
{\InlineClass{latexlogo}{T\textsubscript{e}X}}}
\newcommand*{\LWR@LaTeX}
{\InlineClass{latexlogofont}%
{\InlineClass{latexlogo}%
{L\textsuperscript{a}T\textsubscript{e}X}}}

\renewcommand*{\LaTeXe}
{\LaTeX\InlineClass{latexlogofont}%
{\,2\textsubscript{\textit{\HTMLunicode{3B5}}}}}
\newcommand*{\LWR@LuaTeX}{\InlineClass{latexlogofont}{Lua}\TeX}
\newcommand*{\LWR@LuaLaTeX}{\InlineClass{latexlogofont}{Lua}\LaTeX}
\newcommand*{\Xe}
  {X\textsubscript{\HTMLunicode{18e}}}
\newcommand*{\LWR@XeTeX}{\InlineClass{xetexlogo}{\Xe}\TeX}
\newcommand*{\LWR@XeLaTeX}{\InlineClass{xelatexlogo}{\Xe}\LaTeX}
\newcommand*{\LWR@ConTeXt}
{\InlineClass{latexlogofont}{Con}\TeX{}%
\InlineClass{latexlogofont}{t}}
\providecommand*{\BibTeX}
{\InlineClass{latexlogofont}{B\textsc{ib}}\TeX}

\newcommand*{\MakeIndex}
{\InlineClass{latexlogofont}{\textit{MakeIndex}}}
\AtBeginDocument{\DeclareDocumentCommand{\AmS}{}
{\InlineClass{amslogo}{\textit{A\textsubscript{M}S}}}}
\newcommand*{\MiKTeX}{\InlineClass{latexlogofont}{MiK}\TeX}
\newcommand*{\LyX}{\InlineClass{lyxlogo}{LyX}}
\end{warpHTML}
\begin{warpprint}
\newcommand*{\XeTeXrevE}
  {\hspace{-.1667em}\raisebox{-.5ex}{\reflectbox{E}}\hspace{-.125em}}
\providecommand*{\XeTeX}{\mbox{X\XeTeXrevE\TeX}}
\providecommand*{\XeLaTeX}{\mbox{X\XeTeXrevE\LaTeX}}
\providecommand*{\AmS}{%
\leavevmode\hbox{$\mathcal A\kern-.2em\lower.376ex%
\hbox{$\mathcal M$}\kern-.2em\mathcal S$}}
\newcommand*{\LyX}{\textsf{LyX}}
\providecommand*{\LuaTeX}{\mbox{Lua\TeX}}
\providecommand*{\LuaLaTeX}{\mbox{Lua\LaTeX}}
\providecommand*{\BibTeX}{\mbox{B\textsc{ib}\TeX}}
\providecommand*{\MakeIndex}{\mbox{\textit{MakeIndex}}}
\providecommand*{\ConTeXt}{\mbox{Con\TeX{}t}}
\providecommand*{\MiKTeX}{\mbox{MiK\TeX}}
\end{warpprint}


\begin{warpHTML}

\AfterEndPreamble{\LWR@LwarpStart}
\AtEndDocument{\LWR@LwarpEnd}

\end{warpHTML}



\providecommand*{\HomeHTMLFileName}{\BaseJobname}
\providecommand*{\HTMLFileName}{}
\providecommand*{\UseLatexmk}{false}

\begin{warpprint}
\ifcsdef{LWR@file}{}{\newwrite{\LWR@file}}
\immediate\openout\LWR@file=lwarpmk.conf
\ifwindows
\immediate\write\LWR@file{opsystem = "Windows"}
\else
\immediate\write\LWR@file{opsystem = "Unix"}
\fi
\ifPDFTeX
\immediate\write\LWR@file{latexname = "pdflatex"}
\fi
\ifXeTeX
\immediate\write\LWR@file{latexname = "xelatex"}
\fi
\ifLuaTeX
\immediate\write\LWR@file{latexname = "lualatex"}
\fi
\immediate\write\LWR@file{sourcename = "\jobname"}
\immediate\write\LWR@file{%
homehtmlfilename = "\HomeHTMLFileName"%
}
\immediate\write\LWR@file{htmlfilename = "\HTMLFileName"}
\immediate\write\LWR@file{uselatexmk = "\UseLatexmk"}
\immediate\closeout\LWR@file
\end{warpprint}














































































\endinput
%%
%% End of file `lwarp.sty'.
