%% hangul.sty  04-Feb-1994 by koaunghi.un@zdv.uni-tuebingen.de
%%
%% ���۱��� GNU General Public License�� ���մϴ�.
%%
%% ������
%% ------
%% 1. \cite������ ����ó���� 100% �Ϻ����� �ʽ��ϴ�.
%%     ��:
%%       \cite{bib:label}�� ���ÿ� --> [skating]�� ���ÿ�.
%%     bibliography�ۼ��� �̷� ���� ����� ���ϵ��� �Ͻʽÿ�.
%%
%% 2. ����ó���� �Ϻ����� �����ϴ�.
%%   1. hlatex��ũ��Ʈ�� ���� ���� ���:
%%      1) �츮���� /�� 0���̿� �ɴϴ�.
%%      2) �츮���� �ڼҿ� ���� �׷��� ������ �����ϴ�.
%%   2. hlatex��ũ��Ʈ�� �Ἥ �۾��� ���:
%%      1) �츮���� ���� ASCII�ڵ忡 ����, ���������� �ɹ�, �ѱ�, ������
%%         ������ ��Ÿ���ϴ�.
%%      2) hangul.ist�� ������� ������ �츮���� `�����ٶ�...'�����
%%         ������ ���� ���� ASCII�ڵ忡 ���� \indexspace�� �����ϴ�.
%%      3) hangul.ist�� ����ϸ� �츮���� `�����ٶ�...'����� ������
%%         �Ǹ�, �ɹ��� ���ڴ� ���� �ϳ��� �׷����� ó���˴ϴ�.
%%   3. �ڵ�����ó����ɿ� ����, makeidx.sty�� ���� ���ǵǴ� \see��
%%      ������ \space�� �����ϰ� ������ ������ �߻��մϴ�. \space��ſ�
%%      ~�� ���� ����� �۵��մϴ�. ��:
%%      \index{����ó���� ������|see{�ڵ� ���� ó�� ���}}
%%        �� \index{����ó���� ������|see{�ڵ�~����~ó��~���}}
%%

\NeedsTeXFormat{LaTeX2e}
\def\filedate{1997/05/26}
\def\fileversion{0.97}
\def\filename{hangul.sty}

\ProvidesPackage{hangul}[\filedate\space Document Package for HLaTeX]
\typeout{Hangul Document Package `\filename' <\filedate>.}

%%
%% option "hanja"�� �ܿ��� �̸����� ���ڷ� ǥ���մϴ�.
%% option "pshan"�� PostScript �ѱ� ������ ����ϵ��� �մϴ�.
%% option "hardbold"�� �̹� ������� bfseries �ѱ� ������ ����ϰ�,
%% option "softbold"�� bfseries�۲��� ��ġ���� ���� ���¿��� mdseries
%% �ѱ� ������ ����Ͽ� ��ũ�θ� ���� bfseries�� ����������� �մϴ�.
%% �� ���� �ƹ� �͵� �������� ������ "softbold"�� �˴ϴ�.
%% option "oldhan"�� �ѱ�LaTeX-0.92e���� ���Ǵ� �ѱ� �۲÷� ������
%% �ۼ��� �� �ʿ��� ���������Դϴ�.
%%
%% �� option�� ������ ������ ���� �մϴ�.
%%       \documentclass[hanja,...]{...}
%%       \usepackage{hangul,...}
%% Ȥ�� \documentclass�� ������
%%       \usepackage[hanja]{hangul}
%%

\newif\if@hanja
\newif\if@makebold
\newif\if@oldhan
\@hanjafalse \@makeboldtrue \@oldhanfalse
\edef\@pshan{}

\DeclareOption{hanja}{\@hanjatrue}
\DeclareOption{pshan}{\edef\@pshan{p}}
\DeclareOption{hardbold}{\@makeboldfalse}
\DeclareOption{softbold}{\@makeboldtrue}
\DeclareOption{oldhan}{\@oldhantrue}

\if@compatibility
\InputIfFileExists{hltx209.cfg}{}{}
\else
\ProcessOptions
\fi

\if p\@pshan\ExecuteOptions{softbold}\fi

%% ������ �ѱ�LaTeX ���̵忡 ����ϱ� ����.
\let\HLaTeXversion\fileversion
\let\HLaTeXdate\filedate

%%
%% �ѱ� ������ ����
%%

\if@oldhan
  \input hfontold.tex
\else
  \input hfont.tex
\fi

%%% From File: lterror.dtx
\def\@latex@warning@no@line#1{\let\protect\relax%
   \@latex@warning{#1\@gobble}}

%%% From File: ltfsstrc.dtx
\def\@font@warning#1{\let\protect\relax%
         \GenericWarning{(Font)\@spaces\@spaces\@spaces\space\space}%
                        {LaTeX Font Warning: #1}}%

%%% From File: ltmiscen.dtx
\expandafter\def\expandafter\centering\expandafter{\centering\ks@break}
\expandafter\def\expandafter\raggedright\expandafter{\raggedright\ks@break}
\expandafter\def\expandafter\raggedleft\expandafter{\raggedleft\ks@break}

%%% From File: ltsect.dtx
\def\thanks#1{\footnotemark\let\KSC@\noexpand
    \protected@xdef\@thanks{\@thanks
        \protect\footnotetext[\the\c@footnote]{#1}}%
}

%%% From File: ltpage.dtx
\def\markboth#1#2{\gdef\@themark{{#1}{#2}}{%
     \let\protect\@unexpandable@protect \let\KSC@\noexpand
     \let\label\relax \let\index\relax \let\glossary\relax
     \mark{\@themark}}\if@nobreak\ifvmode\nobreak\fi\fi}
\def\@markright#1#2#3{\let\KSC@\noexpand \gdef\@themark{{#1}{#3}}}

\@nameuse{hfont.sty}
%%
%% hfont.sty�� ���⼭ �����ϴ�.
%%

\begingroup
\let\KSC@\noexpand
\def\d@t@#1/#2/#3\relax{\if@hanja#1Ҵ #2�� #3��\else#1�� #2�� #3��\fi}
\protected@xdef\HLaTeXdate{\expandafter\d@t@\HLaTeXdate\relax}
\endgroup

%%
%% standard class�� ���� �κ��� article�� book/report�� ���������� �޸�
%% �մϴ�. ������ counter�� �� ���� ������ �� �ֵ��� �մϴ�.
%%

\newcounter{ks@ctr}
\@ifclassloaded{article}{\setcounter{ks@ctr}{\z@}}{\setcounter{ks@ctr}{\@ne}}
\@ifclassloaded{letter}{\setcounter{ks@ctr}{\thr@@}}{}
\@ifclassloaded{slides}{\setcounter{ks@ctr}{4}}{}

%%
%% �Ʒ��� �̸����� �츮�� ������ �������� ���� �̸����Դϴ�.
%%
%% ������ ���ǵ� �츮�� �̸����� \LaTeX�� ����� �� �ְ� �մϴ�.
%% ���� �ٸ� package�� �� �̸����� �ٽ� ���ϰ� �� ��쿡�� ����
%% �������� ���ǵ� �̸��� ȿ���� ���� �˴ϴ�. �׷��� �츮��
%% hangul.sty�� ����ϰ� �� ���� �ѱ۹��������� �����ϰ� �Ʒ���
%% ���ǰ� ��� package�� �� ó���ϰ� �� ���� �������� ����ǵ���
%% �մϴ�. ���� ���� �̸��� �������Ϸ��� \begin{document}�տ���
%% \renewcommand�� ���� ������ �� �����ϴ�.
%%

\if@hanja
  \def\kstoday{\number\year Ҵ~\number\month ��~\number\day ��}
  \def\ksenclname{��ݾڪ}% Ȥ�� ����ڪ
  \def\ksccname{����}
  \def\ksheadtoname{������}
  \def\ksseename{����}
  \def\kscontentsname{��~�}
  \def\kslistfigurename{�׸�~���}
  \def\kslisttablename{��~���}
  \def\ksrefname{����~����}
  \def\ksindexname{��~��}
  \def\kstablename{��}
  \def\ksabstractname{�~�}
  \def\ksbibname{����~����}
  \def\ksappendixname{ݾ��}
  \def\ksTHE{�}
  \def\kspartname{��}
  \def\kschaptername{��}
  \def\kssectionname{�}
  \def\kscolorlayer{�����̵� ����}
  \def\ksglossaryname{��~��}
\else
  \def\kstoday{\number\year ��~\number\month ��~\number\day ��}
  \def\ksenclname{÷�ι�}% Ȥ�� ������
  \def\ksccname{�纻}
  \def\ksheadtoname{�޴���}
  \def\ksseename{����}
  \def\kscontentsname{��~��}
  \def\kslistfigurename{�׸�~����}
  \def\kslisttablename{ǥ~����}
  \def\ksrefname{����~����}
  \def\ksindexname{��~��}
  \def\kstablename{ǥ}
  \def\ksabstractname{��~��}
  \def\ksbibname{����~����}
  \def\ksappendixname{�η�}
  \def\ksTHE{��}
  \def\kspartname{��}
  \def\kschaptername{��}
  \def\kssectionname{��}
  \def\kscolorlayer{�����̵� ����}
  \def\ksglossaryname{��~��}
\fi
\def\kspagename{������}
\def\ksfigurename{�׸�}

\def\ks@noexpand{\ifx\protect\@typeset@protect\relax\else
  \expandafter\noexpand\fi}
\AtBeginDocument{%
  \def\today{\ks@noexpand\kstoday}
  \def\enclname{\ks@noexpand\ksenclname}
  \def\ccname{\ks@noexpand\ksccname}
  \def\headtoname{\ks@noexpand\ksheadtoname}
  \def\seename{\ks@noexpand\ksseename}
  \def\contentsname{\ks@noexpand\kscontentsname}
  \def\listfigurename{\ks@noexpand\kslistfigurename}
  \def\listtablename{\ks@noexpand\kslisttablename}
  \def\refname{\ks@noexpand\ksrefname}
  \def\indexname{\ks@noexpand\ksindexname}
  \def\tablename{\ks@noexpand\kstablename}
  \def\abstractname{\ks@noexpand\ksabstractname}
  \def\bibname{\ks@noexpand\ksbibname}
  \def\appendixname{\ks@noexpand\ksappendixname}
  \def\ks@the{\ks@noexpand\ksTHE}
  \def\partname{\ks@noexpand\kspartname}
  \def\chaptername{\ks@noexpand\kschaptername}
  \def\sectionname{\ks@noexpand\kssectionname}
  \def\pagename{\ks@noexpand\kspagename}
  \def\figurename{\ks@noexpand\ksfigurename}
  \def\glossaryname{\ks@noexpand\ksglossaryname}}

%%
%% �ܿ��� �ѱ�ȭ
%% =============
%%
%% Part I       --> �� I ��, � I ��
%% Chapter 1    --> �� 1 ��, � 1 ��   <book,report>
%% Section 1    --> �� 1 ��, � 1 �
%% Appendix A   --> �η�  A, ݾ��  A
%%
%% ���� ���� �ܿ��� �ѱ�ȭ�� ��(�)���� ������ ��Ĩ�ϴ�. �׷��Ƿ� �츮��
%% ������ \subsubsection���� �ܿ��� ��ȣ�� �Բ� �������� �մϴ�.
%% article������ �̹� 3���� �����Ǿ�����, �׿ܿ����� 2�� �����Ǿ�
%% \subsection������ ��ȣ�� ������ �������� �Ǿ� �����ϴ�.
%%

\setcounter{secnumdepth}{\thr@@}

\ifcase\theks@ctr% <article>
  \renewcommand{\appendix}{\par
    \setcounter{section}{0}%
    \setcounter{subsection}{0}%
    \gdef\ks@chapapp{\ksappendixname}% �͹̳ο�
    \def\@chapapp{\appendixname}%
    \def\thesection{\@Alph\c@section}}%
\or% <report|book>
  \renewcommand{\thesection}{\@arabic\c@section}
  \renewcommand{\@chapapp}{\chaptername}%
  \renewcommand{\appendix}{\par
    \setcounter{chapter}{0}%
    \setcounter{section}{0}%
    \gdef\ks@chapapp{\ksappendixname}% �͹̳ο�
    \def\@chapapp{\appendixname}%
    \renewcommand{\thechapter}{\Alph{chapter}}}%
\fi

%%
%% ���Ͱ��� �����Ƿ� ������ ������ �߻��մϴ�.
%% 1. \part�� \partname~\thepart�� ������ �˴ϴ�. ��~I
%% 2. \chapter�� \@chapapp{} \thechapter��. ��~1
%% 3. \section�� \sectionname~\thesection����. ��~1
%% 4. �����ۼ��� indentation�� �츮�� ȯ�濡 �������� �ʽ��ϴ�.
%% 5. heading�� �۲��� slshape���� �ٲ����μ� �츮���� �Ҿ��������ϴ�.
%%
%% ������ �̷� ������ �����ϱ� ����, ��ũ���� �������Դϴ�.
%%

\ifcase\theks@ctr% <article>
  \def\@part[#1]#2{%
    \ifnum \c@secnumdepth >\m@ne
      \refstepcounter{part}%
      \addcontentsline{toc}{part}{\ks@the\ \thepart\ \partname\hspace{1em}#1}%
    \else
      \addcontentsline{toc}{part}{#1}%
    \fi
    {\parindent \z@ \raggedright
     \interlinepenalty \@M
     \normalfont
     \ifnum \c@secnumdepth >\m@ne
       \Large\bfseries \ks@the\ \thepart\ \partname
       \par\nobreak
     \fi
     \huge \bfseries #2%
     \markboth{}{}\par}%
   \nobreak
   \vskip 3ex
   \@afterheading}
\or% <report|book>
  \def\@part[#1]#2{%
    \ifnum \c@secnumdepth >-2\relax
      \refstepcounter{part}%
      \addcontentsline{toc}{part}{\ks@the\ \thepart\ \partname\hspace{1em}#1}%
    \else
      \addcontentsline{toc}{part}{#1}%
    \fi
    \markboth{}{}%
    {\centering
     \interlinepenalty \@M
     \normalfont
     \ifnum \c@secnumdepth >-2\relax
       \huge\bfseries \ks@the\ \thepart\ \partname
       \par
       \vskip 20\p@
     \fi
     \Huge \bfseries #2\par}%
   \@endpart}
\fi

\@ifclassloaded{book}{%
  \def\@chapter[#1]#2{%
    \ifnum \c@secnumdepth >\m@ne
      \if@mainmatter
        \refstepcounter{chapter}%
        \ifx\ks@chapapp\@undefined
          \typeout{\ksTHE\space\thechapter\space\kschaptername.}%
        \else\typeout{\ks@chapapp\space\thechapter.}\fi
        \addcontentsline{toc}{chapter}{%
          \ifx\ks@chapapp\@undefined
            \protect\numberline{\ks@the\ \thechapter\ \@chapapp}
          \else\protect\numberline{\@chapapp\ \thechapter}\fi
          #1}%
      \else
        \addcontentsline{toc}{chapter}{#1}%
      \fi
    \else
      \addcontentsline{toc}{chapter}{#1}%
    \fi
    \chaptermark{#1}%
    \addtocontents{lof}{\protect\addvspace{10\p@}}%
    \addtocontents{lot}{\protect\addvspace{10\p@}}%
    \if@twocolumn
      \@topnewpage[\@makechapterhead{#2}]%
    \else
      \@makechapterhead{#2}%
      \@afterheading
    \fi}
  \def\@makechapterhead#1{%
    \vspace*{50\p@}%
    {\parindent \z@ \raggedright \normalfont
     \ifnum \c@secnumdepth >\m@ne
       \if@mainmatter
         \huge\bfseries
         \ifx\ks@chapapp\@undefined%
           \ks@the\ \thechapter\ \@chapapp
         \else\@chapapp\ \thechapter\fi
         \par\nobreak
         \vskip 20\p@
       \fi
     \fi
     \interlinepenalty\@M
     \Huge \bfseries #1\par\nobreak
     \vskip 40\p@
     }}}%
{\ifcase\theks@ctr\relax\or% <report>
  \def\@chapter[#1]#2{%
    \ifnum \c@secnumdepth >\m@ne
      \refstepcounter{chapter}%
      \ifx\ks@chapapp\@undefined
        \typeout{\ksTHE\space\thechapter\space\kschaptername.}%
      \else\typeout{\ks@chapapp\space\thechapter.}\fi
      \addcontentsline{toc}{chapter}{%
        \ifx\ks@chapapp\@undefined%
          \protect\numberline{\ks@the\ \thechapter\ \@chapapp}
        \else\protect\numberline{\@chapapp\ \thechapter}\fi%
        #1}%
    \else
      \addcontentsline{toc}{chapter}{#1}%
    \fi
    \chaptermark{#1}%
    \addtocontents{lof}{\protect\addvspace{10\p@}}%
    \addtocontents{lot}{\protect\addvspace{10\p@}}%
    \if@twocolumn
      \@topnewpage[\@makechapterhead{#2}]%
    \else
      \@makechapterhead{#2}%
      \@afterheading
    \fi}
  \def\@makechapterhead#1{%
    \vspace*{50\p@}%
    {\parindent \z@ \raggedright \normalfont
      \ifnum \c@secnumdepth >\m@ne
        \huge\bfseries
        \ifx\ks@chapapp\@undefined%
          \ks@the\ \thechapter\ \@chapapp
        \else\@chapapp\ \thechapter\fi
        \par\nobreak
        \vskip 20\p@
      \fi
      \interlinepenalty\@M
      \Huge \bfseries #1\par\nobreak
      \vskip 40\p@
    }}
 \fi}

\@ifundefined{chapter}{}{%
  \renewcommand\l@chapter[2]{%
    \ifnum \c@tocdepth >\m@ne
      \addpenalty{-\@highpenalty}%
      \vskip 1.0em \@plus\p@
      \setbox\z@=\hbox{\bfseries\ksTHE~\chaptername}
      \setlength\@tempdima{1.5em}
      \advance\@tempdima\wd\z@
      \begingroup
        \parindent \z@ \rightskip \@pnumwidth
        \parfillskip -\@pnumwidth
        \leavevmode \bfseries
        \advance\leftskip \@tempdima
        \hskip -\leftskip
        #1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
        \penalty\@highpenalty
      \endgroup
    \fi}}

\def\section{%
  \if@noskipsec \leavevmode \fi
  \par
  \@afterindentfalse
  \if@nobreak
    \everypar{}%
  \else
    \addpenalty\@secpenalty\addvspace{3.5ex \@plus 1ex \@minus .2ex\relax}
  \fi
  \secdef\ks@sect\ks@ssect}
\def\ks@sect[#1]#2{%
  \ifnum \c@secnumdepth<1
    \let\@svsec\@empty
  \else
    \refstepcounter{section}%
    \ifx\ks@chapapp\@undefined%
      \protected@edef\@svsec{\ks@the\ \thesection\ \sectionname\quad\relax}%
    \else\protected@edef\@svsec{\@chapapp\ \thesection\quad\relax}\fi
  \fi
  \begingroup
    \normalfont\Large\bfseries{%
      \@hangfrom{\hskip \z@\relax\@svsec}%
      \interlinepenalty \@M #2\@@par}%
  \endgroup
  \sectionmark{#1}%
  \addcontentsline{toc}{section}{%
    \ifnum \c@secnumdepth<1 \else
      \ifx\ks@chapapp\@undefined%
        \protect\numberline{\ks@the\ \thesection\ \sectionname}
      \else\protect\numberline{\@chapapp\ \thesection}\fi%
    \fi
    #1}%
  \@xsect{2.3ex \@plus.2ex}}
\def\ks@ssect#1{%
  \begingroup
    \normalfont\Large\bfseries{%
      \@hangfrom{\hskip \z@}%
      \interlinepenalty \@M #1\@@par}%
  \endgroup
  \@xsect{2.3ex \@plus.2ex}}

\ifcase\theks@ctr
  \renewcommand*\l@section[2]{%
    \ifnum \c@tocdepth >\z@
      \addpenalty{\@secpenalty}%
      \addvspace{1.0em \@plus\p@}%
      \setbox\z@=\hbox{\bfseries\ksTHE~\sectionname}
      \setlength\@tempdima{1.5em}
      \advance\@tempdima\wd\z@
      \begingroup
        \parindent \z@ \rightskip \@pnumwidth
        \parfillskip -\@pnumwidth
        \leavevmode \bfseries
        \advance\leftskip\@tempdima
        \hskip -\leftskip
        #1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par
      \endgroup
    \fi}
\or
  \renewcommand*\l@section{\@dottedtocline{1}{1em}{4em}}%1.5em 2.3em
\fi

%%
%% ������ \ps@headings�� \ps@myheadings�� �ѱۿ� �°� ������ ���Դϴ�.
%% ������ class���� ���� �ٸ� ������� ������ �Ӹ��� ¥�Ƿ� �츮��
%% ���⼭ ������ ���ε��� ������ �־�� �մϴ�. \ps@myheadings�� ����
%% ���� �����Ƿ� ���� ������ �ѱ�ȭ�� �� �����ϴ�.
%% \LaTeXe�� ������ ���Ե� \MakeUpperCase�� 8bit ���ڸ� ����
%% isolatin�� ���� �ٸ� package�� ����� �� �����մϴ�. -- ����
%% ��-�����̹Ƿ� �ܼ��� \uppercase�� ��ġ�մϴ�.
%%

\DeclareRobustCommand{\MakeUppercase}[1]{\uppercase{#1}}
\DeclareRobustCommand{\MakeLowercase}[1]{\lowercase{#1}}

\@ifclassloaded{article}{%
  \if@twoside
    \renewcommand\ps@headings{%
      \let\@oddfoot\@empty\let\@evenfoot\@empty
      \def\@evenhead{\thepage\hfil\slshape\leftmark}%
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\sectionmark##1{%
        \markboth {\MakeUppercase{%
          \ifnum \c@secnumdepth >\z@
            \ifx\ks@chapapp\@undefined
              \ks@the~\thesection~\sectionname
            \else\@chapapp~\thesection\fi
            \quad\fi
          ##1}}{}}%
      \def\subsectionmark##1{%
        \markright {%
          \ifnum \c@secnumdepth >\@ne
            \thesubsection\quad
          \fi
          ##1}}}
  \else
    \def\ps@headings{%
      \let\@oddfoot\@empty
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\sectionmark##1{%
        \markright {\MakeUppercase{%
          \ifnum \c@secnumdepth >\m@ne
            \ifx\ks@chapapp\@undefined
              \ks@the~\thesection~\sectionname
            \else\@chapapp~\thesection\fi\quad
          \fi
          ##1}}}}
  \fi
  }{}

\@ifclassloaded{book}{%
  \if@twoside
    \def\ps@headings{%
      \let\@oddfoot\@empty\let\@evenfoot\@empty
      \def\@evenhead{\thepage\hfil\slshape\leftmark}%
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\chaptermark##1{%
        \markboth {\MakeUppercase{%
            \ifnum \c@secnumdepth >\m@ne
              \if@mainmatter
                \ifx\ks@chapapp\@undefined
                  \ks@the\ \thechapter\ \@chapapp
                \else\@chapapp\ \thechapter\fi\ \ \fi
            \fi
            ##1}}{}}%
      \def\sectionmark##1{%
        \markright {\MakeUppercase{%
            \ifnum \c@secnumdepth >\z@
              \ks@the\ \thesection\ \sectionname\ \ \fi
            ##1}}}}
  \else
    \def\ps@headings{%
      \let\@oddfoot\@empty
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\chaptermark##1{%
        \markright {\MakeUppercase{%
          \ifnum \c@secnumdepth >\m@ne
            \if@mainmatter
              \ifx\ks@chapapp\@undefined
                \ks@the\ \thechapter\ \@chapapp
              \else\@chapapp\ \thechapter\fi\ \ %
            \fi
          \fi
          ##1}}}}
  \fi
  \pagestyle{headings}
  }{}

\@ifclassloaded{report}{%
  \if@twoside
    \def\ps@headings{%
      \let\@oddfoot\@empty\let\@evenfoot\@empty
      \def\@evenhead{\thepage\hfil\slshape\leftmark}%
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\chaptermark##1{%
        \markboth {\MakeUppercase{%
          \ifnum \c@secnumdepth >\m@ne
            \ifx\ks@chapapp\@undefined
              \ks@the\ \thechapter\ \@chapapp
            \else\@chapapp\ \thechapter\fi\ \ \fi
            ##1}}{}}%
      \def\sectionmark##1{%
        \markright {\MakeUppercase{\ifnum \c@secnumdepth >\z@
            \ks@the\ \thesection\ \sectionname\ \ \fi
            ##1}}}}
  \else
    \def\ps@headings{%
      \let\@oddfoot\@empty
      \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
      \let\@mkboth\markboth
      \def\chaptermark##1{%
        \markright {\MakeUppercase{%
          \ifnum \c@secnumdepth >\m@ne
            \ifx\ks@chapapp\@undefined
              \ks@the\ \thechapter\ \@chapapp
            \else\@chapapp\ \thechapter\fi\ \ \fi
            ##1}}}}
  \fi
  }{}
\def\ps@myheadings{%
  \let\@oddfoot\@empty\let\@evenfoot\@empty
  \def\@evenhead{\thepage\hfil\slshape\leftmark}%
  \def\@oddhead{{\slshape\rightmark}\hfil\thepage}%
  \let\@mkboth\@gobbletwo
  \ifcase\theks@ctr\relax
    \let\subsectionmark\@gobble
  \else\let\chaptermark\@gobble
  \fi
  \let\sectionmark\@gobble
}

%%
%% \LaTeX�� �ѱ�ȭ:
%% ----------------
%%% From File: ltbibl.dtx
\def\@lbibitem[#1]#2{\item[\@biblabel{#1}\hfill]\if@filesw
      {\let\protect\noexpand
       \immediate
       \write\@auxout{\string\bibcite{#2}%
        {#1\string\make@josa{#1}}}}\fi\ignorespaces}
\def\@bibitem#1{\item\if@filesw
       {\let\load@ksc\@gobbletwo\let\bold@ksc\@gobble%
        \immediate\write\@auxout
        {\string\bibcite{#1}{\the\value{\@listctr}%
         \string\ks@num{\the\value{\@listctr}}}}}\fi\ignorespaces}
\def\bibcite{\let\protect\string\@newl@bel b}
\def\@citex[#1]#2{\let\protect\string%
  \let\@citea\@empty
  \@cite{\@for\@citeb:=#2\do
    {\@citea\def\@citea{,\penalty\@m\ }%
     \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
     \if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
     \let\protect\@typeset@protect
     \@ifundefined{b@\@citeb}{\mbox{\reset@font\bfseries ?}%
       \G@refundefinedtrue
       \@latex@warning
         {Citation `\@citeb' on page \thepage \space undefined}}%
       {\hbox{\csname b@\@citeb\endcsname}}}}{#1}%
       \let\protect\@typeset@protect}
\def\nocite#1{\@bsphack\let\protect\string%
  \@for\@citeb:=#1\do{%
    \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
    \if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
    \let\protect\relax
    \@ifundefined{b@\@citeb}{\G@refundefinedtrue
        \@latex@warning{Citation `\@citeb' undefined}}{}}%
  \@esphack}
%%
\def\make@josa#1{\decide@josa#1\relax}
\def\decide@josa{\afterassignment\analyse@ksc\let\next= }
\def\analyse@ksc{%
  \ifx\next\relax
    \if m\expandafter\@car\meaning\@second\relax\@nil
      \set@display@protect
      \edef\reserved@a{\@first~}%
      \@tempcnta\expandafter\expandafter\expandafter
        `\expandafter\@firstoftwo\reserved@a
      \edef\reserved@a{\@second~}%
      \@tempcntb\expandafter\expandafter\expandafter
        `\expandafter\@firstoftwo\reserved@a
      \count\z@\@tempcnta \divide\@tempcnta\sixt@@n
      \count@\@tempcnta \multiply\count@\sixt@@n
      \advance\count\z@-\count@
      \count\tw@\@tempcntb \divide\@tempcntb\sixt@@n
      \count@\@tempcntb \multiply\count@\sixt@@n
      \advance\count\tw@-\count@
      \set@typeset@protect
      \expandafter\ifx\csname\hexnumber@{\@tempcnta}%
        \hexnumber@{\count\z@}|\hexnumber@{\@tempcntb}%
        \hexnumber@{\count\tw@}\endcsname\relax\@jong\else%
       \expandafter\csname\hexnumber@{\@tempcnta}%
        \hexnumber@{\count\z@}|\hexnumber@{\@tempcntb}%
        \hexnumber@{\count\tw@}\endcsname\fi\else
    \ifx 0\@second\@jong\else
    \ifx 1\@second\ri@ul\else
    \ifx 2\@second\@jung\else
    \ifx 3\@second\@jong\else
    \ifx 4\@second\@jung\else
    \ifx 5\@second\@jung\else
    \ifx 6\@second\@jong\else
    \ifx 7\@second\ri@ul\else
    \ifx 8\@second\ri@ul\else
    \ifx 9\@second\@jong\else
    \ifx l\@second\ri@ul\else
    \ifx m\@second\@jong\else
    \ifx n\@second\@jong\else
    \ifx r\@second\ri@ul\else
    \ifx L\@second\ri@ul\else
    \ifx M\@second\@jong\else
    \ifx N\@second\@jong\else
    \ifx R\@second\ri@ul\else\@jung
    \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi\else
  \let\@first\@second\let\@second\next\let\next\decide@josa\fi\next}

%%%% From File: ltxref.dtx
\def\@setref#1#2#3{%
  \let\protect\relax
  \ifx#1\relax
   \protect\G@refundefinedtrue
   \nfss@text{\reset@font\bfseries ??}%
   \@latex@warning{Reference `#3' on page \thepage \space
             undefined}%
  \else
   \expandafter#2#1
  \fi}
\def\label#1{\@bsphack
  \protected@write\@auxout{\@ksromantrue}%
         {\string\newlabel{#1}{{\@currentlabel}{\thepage}}}%
  \@esphack}
\def\ref#1{\let\protect\string
        \expandafter\@setref\csname r@#1\endcsname\@firstoftwo{#1}}
\def\pageref#1{\let\protect\string
          \expandafter\@setref\csname r@#1\endcsname\@secondoftwo{#1}}
\def\newlabel{\let\protect\string\@newl@bel r}%

%%% From File: ltfiles.dtx
\newif\if@ksroman\@ksromanfalse
\long\def \protected@write#1#2#3{%
      \begingroup
       #2%
       \if@ksroman\let\thepage\relax\else
       \let\ks@num\@gobble\def\@jung{}\def\@jong{}\def\ri@ul{}\fi
       \let\protect\@unexpandable@protect
       \edef\reserved@a{\write#1{#3}}%
       \reserved@a
      \endgroup
      \if@nobreak\ifvmode\nobreak\fi\fi
}

%%% From File: ltcounts.dtx
%% �������ڿ��� �츮�� ����ó��
\def\@arabic#1{\number #1\ifx\protect\string\else
  \expandafter\ks@num\expandafter{\number #1}\fi}
\def\@roman#1{\romannumeral #1\ifx\protect\string\else
  \expandafter\ks@num\expandafter{\number #1}\fi}
\def\@Roman#1{\expandafter\uppercase\expandafter{\romannumeral #1}%
  \ifx\protect\string\else\expandafter\ks@num\expandafter{\number #1}\fi}
\def\@alph#1{%
  \ifcase#1\or a\or b\or c\or d\or e\or f\or g\or h\or i\or j\or
   k\or l\or m\or n\or o\or p\or q\or r\or s\or t\or u\or v\or w\or x\or
    y\or z\else\@ctrerr\fi\alph@josa{#1}}
\def\@Alph#1{%
  \ifcase#1\or A\or B\or C\or D\or E\or F\or G\or H\or I\or J\or
   K\or L\or M\or N\or O\or P\or Q\or R\or S\or T\or U\or V\or W\or X\or
    Y\or Z\else\@ctrerr\fi\alph@josa{#1}}
\def\@fnsymbol#1{\ensuremath{\ifcase#1\or *\or \dagger\or \ddagger\or
   \mathchar "278\or \mathchar "27B\or \|\or **\or \dagger\dagger
   \or \ddagger\ddagger \else\@ctrerr\fi}\@jung}
\def\alph@josa#1{%
  \ifnum#1=12 \ri@ul\else
  \ifnum#1=13 \@jong\else
  \ifnum#1=14 \@jong\else
  \ifnum#1=18 \ri@ul\else\@jung
  \fi\fi\fi\fi}

%%%
%%% �����ڵ�ó����� �� �츮�� �۲ùٲ޸���:
%%%   \��/\�� \��/\�� \��/\�� \��/\�� \����/\�� (\���μ�/\�μ� \���ν�/\�ν�)
%%%   \����\�ܰ�\����\��\����\�׷���\�ü�\������\�ʱ�\��۾�\���긲\���۾�
%%%
%% �츮�� ����
\def\^^c0#1{%
  \ifx#1^^cc\@josa{��}{��}\else% \��(yi)
  \ifx#1^^ba\@josa{��}{��}\else% \��(eun)
  \ifx#1^^bb\@josa{��}{��}\else% \��(eul)
  \ifx#1^^b8% \��(��)(eu)
    \if y\is@rieul\else\@josa{}{��}\fi
  \fi\fi\fi\fi}
\def\��{\��}% \��(neun)
\def\��{\if y\is@rieul\else\@josa{}{��}\fi��}% \��(ro)
% \����(yt)\�ܰ�(ol), \��(wa)
\def\^^bf{\@ifnextchar^^cd{\@josa{��}{��}\@gobble}\yt@or@ol}
\def\yt@or@ol#1#2#3{\ifx#1^^be\ytfamily\else
        \ifx#1^^dc\olfamily\fi\fi\ignorespaces}
% \����(mj)\��(mg), \��(reul)
\def\^^b8{\@ifnextchar^^a6{\��\@gobble}\mj@or@mg}
\def\mj@or@mg#1#2#3{\ifx#1^^ed\mjfamily\else
        \ifx#1^^f1\mgfamily\fi\fi\ignorespaces}
% \����(gt), \��(ga)\��(gwa)
\def\^^b0{\@ifnextchar^^ed\only@gt\ga@or@gwa}
\def\only@gt#1#2#3{\ifx#1^^ed\gtfamily\fi\ignorespaces}
\def\ga@or@gwa#1{\ifx#1^^a1\��\else\ifx#1^^fa\@josa{��}{��}\fi\fi}
\def\^^b1{\@ifnextchar^^c3\only@gs\only@gr}                 % \�׷���, \�ü�
\def\only@gs#1#2#3{\ifx#1^^c3\gsfamily\fi\ignorespaces}
\def\only@gr#1#2#3#4#5{\ifx#1^^d7\grfamily\fi\ignorespaces}
\def\������{\smfamily\ignorespaces}                         % \������
\def\�ʱ�{\pgfamily\ignorespaces}                           % \�ʱ�
\def\��#1#2#3#4{\pnfamily\ifx#1^^c8\itshape\fi\ignorespaces}% \��۾�,\���긲
\def\���۾�{\bmfamily\ignorespaces}                         % \���۾�
\def\Ÿ��{\tzfamily\ignorespaces}                           % \Ÿ��

\DeclareRobustCommand*{\@jung}{\gdef\is@rieul{n}%
  \global\let\@josa\@firstoftwo\ignorespaces}
\DeclareRobustCommand*{\@jong}{\gdef\is@rieul{n}%
  \global\let\@josa\@secondoftwo\ignorespaces}
\DeclareRobustCommand*{\ri@ul}{\gdef\is@rieul{y}%
  \global\let\@josa\@secondoftwo\ignorespaces}
\DeclareRobustCommand*{\ks@num}[1]{{\count@#1%
  \ifnum\count@<\z@ \count@-\count@ \fi\count2\count@
  \divide\count2 10 \multiply\count2 10 \advance\count@-\count2
  \ifcase\count@\@jong\or\ri@ul\or\@jung\or\@jong\or\@jung\or
  \@jung\or\@jong\or\ri@ul\or\ri@ul\or\@jung\fi}\ignorespaces}

\begingroup
\IfFileExists{josa.tab}{\if@oldhan\else%
  \newread\JS@tab
  \endlinechar\m@ne
  \def\JS@{\read\JS@tab to\@t \expandafter\split@t\@t\relax
    \ifnum\count@=2 \let\next\relax \else
      \ifcase\count@\let\next\@jung\or\let\next\ri@ul\fi
      \global\expandafter\let\csname\reserved@a\endcsname\next
      \let\next\JS@ \fi\next}
  \def\split@t##1,##2,##3\relax{\count@##1\def\reserved@a{##2|##3}}%
  \openin\JS@tab=josa.tab \JS@ \closein\JS@tab\fi}%
{\PackageWarningNoLine{\string\HLaTeX}{Missing ``josa.tab'' !!!^^J
  \@spaces\@spaces\@spaces\@spaces\@spaces\@spaces
  Automatic Josa's for citation will be incorrect}}
\endgroup

%% �츮������
\def\jaso#1{\@jaso{\@nameuse{c@#1}}}
\def\@jaso#1{\ifcase#1\or��\or��\or��\or��\ri@ul\else\@ijaso{#1}\fi\@jong}
\def\@ijaso#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\gana#1{\@gana{\@nameuse{c@#1}}}
\def\@gana#1{\ifcase#1\or��\or��\or��\or��\else\@igana{#1}\fi\@jung}
\def\@igana#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\orī\orŸ\or��\or��\else\@ctrerr\fi}
\def\ojaso#1{\@ojaso{\@nameuse{c@#1}}}
\def\@ojaso#1{\ifcase#1\or��\or��\or��\or��\ri@ul\else\@iojaso{#1}\fi\@jong}
\def\@iojaso#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\ogana#1{\@ogana{\@nameuse{c@#1}}}
\def\@ogana#1{\ifcase#1\or��\or��\or��\or��\else\@iogana{#1}\fi\@jung}
\def\@iogana#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\pjaso#1{\@pjaso{\@nameuse{c@#1}}}
\def\@pjaso#1{\ifcase#1\or��\or��\or��\or��\ri@ul\else\@ipjaso{#1}\fi\@jong}
\def\@ipjaso#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\pgana#1{\@pgana{\@nameuse{c@#1}}}
\def\@pgana#1{\ifcase#1\or��\or��\or��\or��\else\@ipgana{#1}\fi\@jung}
\def\@ipgana#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\onum#1{\@onum{\@nameuse{c@#1}}}
\def\@onum#1{\ifcase#1\or��\or��\or��\or��\else\@ionum{#1}\fi
  \ifnum#1<\sixt@@n\ifx\protect\string\else
  \expandafter\ks@num\expandafter{\number #1}\fi\fi}
\def\@ionum#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��
  \or��\or��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\pnum#1{\@pnum{\@nameuse{c@#1}}}
\def\@pnum#1{\ifcase#1\or��\or��\or��\or��\else\@ipnum{#1}\fi
  \ifnum#1<\sixt@@n\ifx\protect\string\else
  \expandafter\ks@num\expandafter{\number #1}\fi\fi}
\def\@ipnum#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��
  \or��\or��\or��\or��\or��\or��\or��\else\@ctrerr\fi}
\def\oeng#1{\@oeng{\@nameuse{c@#1}}}
\def\@oeng#1{\ifcase#1\or��\or��\or��\or��\else\@ioeng{#1}\fi\alph@josa{#1}}
\def\@ioeng#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or
  ��\or��\or��\else\@ctrerr\fi}
\def\peng#1{\@peng{\@nameuse{c@#1}}}
\def\@peng#1{\ifcase#1\or��\or��\or��\or��\else\@ipeng{#1}\fi\alph@josa{#1}}
\def\@ipeng#1{\ifcase#1\or\or\or\or\or��\or��\or��\or��\or��\or��\or
  ��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or��\or
  ��\or��\or��\else\@ctrerr\fi}

%%
%% �����ۼ��� makeidx.sty�� ���� \see�� ���ǵ˴ϴ�.
%%
\AtBeginDocument{%
  \@ifundefined{see}{}{%
    \renewcommand*\see[2]{#1\make@josa{#1}\emph{\��\ \seename}}}
}

%% hangul.ist�� ����Ͽ� ������ �ۼ��� ��, ������ ��ũ�δ� �츮����
%% �ڼұ׷��� �˸°� �и��մϴ�.
\begingroup
\if@hanja\gdef\hj@head{����}\else\gdef\hj@head{����}\fi
\gdef\KSitem #1\endKS{\@tempcnta\expandafter`\@car#1\@nil\relax
  \ifnum\@tempcnta>"0A0
    \ifnum\@tempcnta<"0B0\let\hitem\item
      \expandafter\ifx\csname I|4\endcsname\relax
        \indexspace��{\bfseries�ɹ�}��\hfil\nopagebreak
        \global\expandafter\let\csname I|4\endcsname\@empty\fi
    \else\ifnum\@tempcnta<"0CA\advance\@tempcnta-"0B0
      \gdef\hitem{\@ifnextchar#1{\@nameuse{I-\number\@tempcnta}}%
        {\def\reserved@f{#1}\expandafter\KS@item}}
    \else\let\hitem\item
      \expandafter\ifx\csname I|5\endcsname\relax
        \indexspace��{\bfseries\hj@head}��\hfil\nopagebreak
        \global\expandafter\let\csname I|5\endcsname\@empty\fi\fi\fi
  \else\indexspace��{\bfseries#1}��\hfil\nopagebreak\fi}
\gdef\KS@item#1#2{%
  \expandafter\ifx\reserved@f#1%
    \@tempcnta`#1\advance\@tempcnta-"0B0
    \@nameuse{I-\number\@tempcnta} #1#2%
  \else\ifx\protect#1\expandafter\KS@item#2
  \else\item #1#2\fi\fi}
\gdef\hindexhead#1{��{\bfseries#1}��\hfil}
\def^^a0#1#2{\count@`#1\advance\count@-"0B0
  \@tempcnta`#2\advance\@tempcnta-"0A1
  \expandafter\xdef\csname I-\number\count@\endcsname ##1##2{%
    \noexpand\expandafter\noexpand\ifx\noexpand\csname
    I|\number\@tempcnta\noexpand\endcsname\relax
      \noexpand\indexspace\noexpand\hindexhead{\noexpand^^a4\noexpand#2}
      \noexpand\nopagebreak 
      \noexpand\global\noexpand\expandafter\let\noexpand\csname
      I|\number\@tempcnta\noexpand\endcsname\noexpand\@empty
    \noexpand\fi
    \noexpand\item ##1##2}}
\def^^ff#1#2#3#4{\count@`#1\advance\count@-"0B0
  \@tempcnta`#3\advance\@tempcnta-"0A1\@tempcntb\@tempcnta
  \ifnum\@tempcnta=1\advance\@tempcntb2\else
  \ifnum\@tempcnta=3\advance\@tempcntb3\else
  \ifnum\@tempcnta=8\advance\@tempcntb8\else
  \ifnum\@tempcnta=18\advance\@tempcntb2
  \else\advance\@tempcntb1\fi\fi\fi\fi
  \expandafter\xdef\csname I-\number\count@\endcsname ##1##2{%
    \noexpand\ifnum`##2<#2
      \noexpand\expandafter\noexpand\ifx\noexpand\csname
      I|\number\@tempcnta\noexpand\endcsname\relax
        \noexpand\indexspace\noexpand\hindexhead{\noexpand^^a4\noexpand#3}
        \noexpand\nopagebreak
        \noexpand\global\noexpand\expandafter\let\noexpand\csname
        I|\number\@tempcnta\noexpand\endcsname\noexpand\@empty
      \noexpand\fi
    \noexpand\else
      \noexpand\expandafter\noexpand\ifx\noexpand\csname
      I|\number\@tempcntb\noexpand\endcsname\relax
        \noexpand\indexspace\noexpand\hindexhead{\noexpand^^a4\noexpand#4}
        \noexpand\nopagebreak
        \noexpand\global\noexpand\expandafter\let\noexpand\csname
        I|\number\@tempcntb\noexpand\endcsname\noexpand\@empty
      \noexpand\fi
    \noexpand\fi
    \noexpand\item ##1##2}}
^^a0^^b0^^a1^^ff^^b1{"0EE}^^a1^^a2^^a0^^b2^^a2^^ff^^b3{"0AA}^^a2^^a4
^^ff^^b4{"0D9}^^a4^^a7^^ff^^b5{"0FB}^^a7^^a8^^ff^^b6{"0F3}^^a8^^a9
^^a0^^b7^^a9^^ff^^b8{"0B6}^^a9^^b1^^ff^^b9{"0D9}^^b1^^b2
^^ff^^ba{"0FC}^^b2^^b3^^ff^^bb{"0E7}^^b3^^b5^^a0^^bc^^b5
^^ff^^bd{"0CE}^^b5^^b6^^ff^^be{"0C6}^^b6^^b7^^a0^^bf^^b7
^^ff^^c0{"0DA}^^b7^^b8^^a0^^c1^^b8
\expandafter\gdef\csname I-18\endcsname #1#2{%
  \ifnum`#2<"0A5
    \expandafter\ifx\csname I|23\endcsname\relax
      \indexspace\hindexhead{��}\nopagebreak
      \global\expandafter\let\csname I|23\endcsname\@empty
    \fi
  \else\ifnum`#2<"0F7
    \expandafter\ifx\csname I|24\endcsname\relax
      \indexspace\hindexhead{��}\nopagebreak
      \global\expandafter\let\csname I|24\endcsname\@empty
    \fi
  \else
    \expandafter\ifx\csname I|25\endcsname\relax
      \indexspace\hindexhead{��}\nopagebreak
      \global\expandafter\let\csname I|25\endcsname\@empty
    \fi
  \fi\fi
  \item #1#2}
^^a0^^c3^^ba^^ff^^c4{"0AB}^^ba^^bb^^ff^^c5{"0B8}^^bb^^bc
^^ff^^c6{"0C4}^^bc^^bd^^ff^^c7{"0CF}^^bd^^be^^a0^^c8^^be
\endgroup
%% �������� ���� �� ������ ���� ȯ���� ���ǰ� �ʿ��մϴ�.
\let\gloitem\@idxitem
\def\glopage{\hfill}
\newenvironment{theglossary}
               {\if@twocolumn
                  \@restonecolfalse
                \else
                  \@restonecoltrue
                \fi
                \columnseprule \z@
                \columnsep 35\p@
                \twocolumn[\section*{\glossaryname}]%
                \@mkboth{\MakeUppercase{\glossaryname}}%
                        {\MakeUppercase{\glossaryname}}%
                \thispagestyle{plain}\parindent\z@
                \parskip\z@ \@plus .3\p@\relax
                \let\item\gloitem}
               {\if@restonecol\onecolumn\else\clearpage\fi}
\newcommand\printglossary{\@input@{\jobname.gls}}

%% �ѱ�LaTeX�� logo�� �̷� ������ �� �������ϴ�.
\DeclareRobustCommand{\HLaTeX}{��\kern-.4ex\lower.3ex\hbox{��}\kern-.4ex\LaTeX}

%%% Local Variables:
%%% mode: plain-tex
%%% End:
