\newenvironment{remark}{\medskip\noindent {\em Remark:}}{}
\newenvironment{remarks}{\medskip\noindent {\em Remarks:} \begin{enumerate}}{\end{enumerate}}
\newenvironment{example}{\medskip\noindent {\em Example:}}{}
\newenvironment{examples}{\medskip\noindent {\em Examples:} \begin{enumerate}}{\end{enumerate}}
\newenvironment{lemmaproof}{\def\proofname{Proof of Lemma}%
\@qedfalse\medskip\noindent%
\let\@startproofcipher=\@startlemmaproofcipher
\let\@endproofcipher=\@endlemmaproofcipher
\begin{proof}}{\end{proof}}
\newenvironment{sublemmaproof}{\def\proofname{Proof of Sublemma}%
\@qedfalse\medskip\noindent%
\let\@startproofcipher=\@startlemmaproofcipher
\let\@endproofcipher=\@endlemmaproofcipher
\begin{proof}}{\end{proof}}
\def\proofname{Proof}
\newenvironment{proof}{\@qedfalse\medskip\noindent%
{\emph{\proofname}\ \@startproofcipher}}{\qed}

\newtheorem{theorem}{Theorem}
\newtheorem{proposition}{Proposition}
\newtheorem{definition}{Definition}
% \newtheorem{corollary}{Corollary}
\newtheorem{corollary}{Corollary}
\newtheorem{Corollary}{Corollary}
\renewcommand{\theCorollary}{}
%\newtheorem{lemma}{Lemma}
\newtheorem{lemma}{Lemma}
\newtheorem{Lemma}{Lemma}
\renewcommand{\theLemma}{}
\newtheorem{sublemma}{Sublemma}
\renewcommand{\thesublemma}{}

\let\union=\cup
\let\Union=\bigcup
\let\intersection=\cap
\let\Intersection=\bigcap
\let\tensor=\otimes
\let\implies=\Longrightarrow
\let\iff=\Longleftrightarrow
\let\oneone=\longleftrightarrow
\let\normal=\triangleleft
\let\divides=\mid
\def\exactdivides{\mid\mid}
\def\notdivides{\nmid}
\def\Forall{\mbox{ for all }}
%\def\GF{\mathbf{GF}}
\newcommand{\GF}[1]{\mathbb{F}_#1}

\newcommand{\R}{\mathbb{R}}
\newcommand{\C}{\mathbb{C}}
\newcommand{\Z}{\mathbb{Z}}
\newcommand{\N}{\mathbb{N}}
\newcommand{\Q}{\mathbb{Q}}
\newcommand{\U}{\mathbb{U}}
\newcommand{\A}{\mathbb{A}}
\newcommand{\I}{\mathbb{I}}
\renewcommand{\H}{\mathbb{H}}
\newcommand{\T}{\mathbb{T}}
\renewcommand{\P}{\mathbb{P}}
\newcommand{\E}{\mathcal{E}}
\newcommand{\F}{\mathcal{F}}
\newcommand{\DD}{\mathcal{D}}
\newcommand{\FF}{\mathcal{F}}
\newcommand{\HH}{\mathcal{H}}
\renewcommand{\SS}{\mathcal{S}}
\newcommand{\abs}[1]{|#1|}
\newcommand{\norm}[1]{\|#1\|}
\renewcommand{\a}{\frak{a}}
\renewcommand{\b}{\frak{b}}
\renewcommand{\c}{\frak{c}}
\newcommand{\p}{\frak{p}}
\newcommand{\q}{\frak{q}}
\newcommand{\Mat}{\operatorname{Mat}}
\newcommand{\tr}{\operatorname{tr}}
%\newcommand{\ker}{\operatorname{ker}}
\newcommand{\im}{\operatorname{im}}
\newcommand{\ad}{\operatorname{ad}}
\newcommand{\Ad}{\operatorname{Ad}}
\newcommand{\Aut}{\operatorname{Aut}}
\newcommand{\der}{\operatorname{der}}
\newcommand{\Char}{\operatorname{char}}
\newcommand{\rank}{\operatorname{rank}}
\newcommand{\sgn}{\operatorname{sgn}}
\newcommand{\order}{\operatorname{order}}
\newcommand{\ord}{\operatorname{ord}}
\newcommand{\lcm}{\operatorname{lcm}}
\newcommand{\GL}{\operatorname{GL}}
\newcommand{\SL}{\operatorname{SL}}
\newcommand{\PSL}{\operatorname{PSL}}
\newcommand{\Latt}{\mathscr{L}}

\newcommand{\Fbox}[1]{\fbox{$\displaystyle #1$}}
\newcommand{\Span}[1]{\langle#1\rangle}

\def\preamble{\small\quotation\noindent\ignorespaces}
\def\endpreamble{\endquotation}

\def\postamble{\small\quotation\noindent Summary: }
\def\endpostamble{\endquotation}

\let\io=\includeonly

\font\msxm=msam10
\def\@startproofcipher{\msxm{I}}
\def\@endproofcipher{\msxm{J}}
\def\@startlemmaproofcipher{\msxm{B}}
\def\@endlemmaproofcipher{\msxm{C}}

%\def\@endproofo{{\vbox{\hrule\hbox{%
%   \vrule height1.3ex\hskip0.8ex\vrule}\hrule
%  }}}
\def\@endproofo{{\@endproofcipher}}
%\def\@endprooft{\hspace{2em}\@endproofo}
\def\@endprooft{\hspace{1em}\@endproofo}
\def\@endproofnd{\global\@proofendtrue}
\def\@endproofd{\eqno{\@endproofo}}
%
% Define a new flag ``numbering mode'' that tells us when
% LaTeX will generate its own numbers.
%
%
\newif\if@numberingmode
\newif\if@proofend
\@numberingmodefalse
%
% Change the equation environment to set the numbering
% mode.
%
\def\equation{$$ % $$ BRACE MATCHING HACK
\refstepcounter{equation}\@numberingmodetrue}
%
\def\endequation{\eqno{\if@proofend\@endproofo\global\@proofendfalse\fi
\@eqnnum} % $$ BRACE MATCHING HACK
$$\global\@ignoretrue\@numberingmodefalse}

\def\@@eqncr{\let\@tempa\relax 
    \ifcase\@eqcnt \def\@tempa{& & &}\or \def\@tempa{& &} 
      \else \def\@tempa{&}\fi 
     \@tempa \if@proofend\@endproofo\global\@proofendfalse\fi
     \if@eqnsw\@eqnnum\stepcounter{equation}\fi
     \global\@eqnswtrue\global\@eqcnt\z@\cr}
%
% \def\[{\relax\ifmmode\@badmath\else
%     \ifvmode \nointerlineskip \makebox[.6\linewidth]\fi$$%%$$ BRACE MATCH HACK
% \fi}
 
% \def\]{\relax\ifmmode\ifinner\@badmath\else$$\fi%%$$ BRACE MATCH HACK
%         \else \@badmath \fi\ignorespaces}

%\def\]{\relax\if@qed\ifmmode\ifinner\@badmath\else$$\fi%%$$ BRACE MATCH HACK
%        \else \@badmath \fi\fi\ignorespaces}

%
% The \endproof macro to generate end-of-proof markers.
% Usage:
% In text:
%    . . . and this concludes our proof.\endproof
% In displayed equations:
%    $$ x \ge 0 \endproof $$
% In latex environments:
%  \begin{eqnarray}
%    .
%    .
%   x & \ge & 0 \endproof
%  \end{eqnarray}
% Also works in the equation environment.
%
\newif\if@qed
\def\qed{%
\if@qed
\else
  \ifmmode
     \if@numberingmode
       \@endproofnd
     \else
       \@endproofd
     \fi
  \else
    \@endprooft
  \fi
\fi
\@qedtrue}

% \def\makeqedrule{\nobreak \ifvmode \relax \else
\def\Qed{\@endproofd}
%       \nobreak \ifdim\lastskip<1.5em \hskip-\lastskip
%       \hskip1.5em plus0em minus0.5em \fi\qedrule\fi}
% \let\qed=\makeqedrule

