%\renewcommand\appendix{% % \renewcommand\section{% % \newpage\thispagestyle{plain}% % \secdef\Appendix\sAppendix}% % \setcounter{section}{0}% % \renewcommand\thesection{\Alph{section}}% %} %\newcommand\Appendix[2][?]{% % \refstepcounter{section}% % \addcontentsline{toc}{appendix}% % {\protect\numberline{\appendixname~\thesection} #1}% % {\flushright\large\bfseries\appendixname\ \thesection\par % \centering#2\par}% % \addvspace{\baselineskip}} %\newcommand\sAppendix[1]{% % {\flushright\large\bfseries\appendixname\par % \centering#1\par}% % \addvspace{\baselineskip}} \newtheorem{corl}{Corollary}[section] \newtheorem{lem}{Lemma}[section] \newtheorem{thm}{Theorem}[section] \newtheorem{conj}{Conjecture}[section] \newtheorem{prop}{Property}[section] \newtheorem{defn}{Definition}[section] \newtheorem{notations}{Notations}[section] \newtheorem{notation}{Notation}[section] \newtheorem{assumption}{Assumption}[section] \newtheorem{remark}{Remark}[section] \newtheorem{problem}{Problem}[section] \newtheorem{ex}{Example}[section] \newtheorem{algor}{Algorithm}[section] \newcommand{\lcm}{ \ensuremath{\mathrm{LCM} \xspace }} \newcommand{\ifrac}[2]{ \ensuremath{#1\kern-.08em /#2}} \newcommand{\lcd}{ \ensuremath{\mathrm{LCD} \xspace }} \newcommand{\lcdd}[2] { \mathrm{LCD}\left\{#1,#2\right\} } \newcommand\fracf[2] { \genfrac{}{}{}{0}{\hspace{1.5pt}#1\hspace{1.5pt}}{#2} } %longdiv v.1 (1994) macro by Donald Arseneau. \newcount\gpten % (global) power-of-ten -- tells which digit we are doing \countdef\rtot2 % running total -- remainder so far \countdef\LDscratch4 % scratch \def\longdiv#1#2{% \vtop{\normalbaselines \offinterlineskip \setbox\strutbox\hbox{\vrule height 2.1ex depth .5ex width0ex}% \def\showdig{$\underline{\the\LDscratch\strut}$\cr\the\rtot\strut\cr \noalign{\kern-.2ex}}% \global\rtot=#1\relax \count0=\rtot\divide\count0by#2\edef\quotient{\the\count0}%\show\quotient % make list macro out of digits in quotient: \def\temp##1{\ifx##1\temp\else \noexpand\dodig ##1\expandafter\temp\fi}% \edef\routine{\expandafter\temp\quotient\temp}% % process list to give power-of-ten: \def\dodig##1{\global\multiply\gpten by10 }\global\gpten=1 \routine % to display effect of one digit in quotient (zero ignored): \def\dodig##1{\global\divide\gpten by10 \LDscratch =\gpten \multiply\LDscratch by##1% \multiply\LDscratch by#2% \global\advance\rtot-\LDscratch \relax \ifnum\LDscratch>0 \showdig \fi % must hide \cr in a macro to skip it }% \tabskip=0pt \halign{\hfil##\cr % \halign for entire division problem $\quotient$\strut\cr #2$\,\overline{\vphantom{\big)}% \hbox{\smash{\raise3.5\fontdimen8\textfont3\hbox{$\big)$}}}% \mkern2mu \the\rtot}$\cr\noalign{\kern-.2ex} \routine \cr % do each digit in quotient }}}