04_프로그래밍관련

LaTeX 기본 개념

tothebest 2025. 12. 13. 08:51
728x90

안녕하세요

LaTex 기본 개념에 대해 간단히 정리해 보겠습니다.

 

1. LaTeX 기본 개념

1.1 파일 확장자

확장자용도
.tex 메인 LaTeX 소스
.bib 참고문헌 데이터
.cls 문서 클래스 (IEEEtran 등)
.sty 패키지(스타일)
.pdf 컴파일 결과

논문은 거의 항상 main.tex 하나가 시작점


2. 최소 LaTeX 구조 (필수)

 
\documentclass{article}
\begin{document} Hello LaTeX!
\end{document}

 

IEEE 논문이라면 보통:

 
\documentclass[conference]{IEEEtran}

3. 주석(Comment)

 
%이 줄은 주석입니다

 

 

여러 줄 주석은 보통 이렇게 처리:

 
\iffalse
여러 줄
주석
\fi

4. 패키지 사용 (\usepackage)

 
\usepackage{amsmath} % 수식
\usepackage{graphicx} % 그림
\usepackage{cite} % IEEE 스타일 인용
\usepackage{hyperref} % 링크

5. 섹션 구조

 
\section{Introduction}
\subsection{Background}
\subsubsection{Previous Work}

 

IEEE는 자동 번호 매김
→ 1 Introduction, 1.1 Background


6. 텍스트 스타일

 
\textbf{굵게}
\textit{기울임}
\underline{밑줄}
 
 

줄바꿈:

\\         % 줄바꿈
\newline

 

 

문단 구분:

 
빈 줄 하나

7. 수식 문법 (매우 중요)

7.1 인라인 수식

 
$y = ax + b$

 

7.2 디스플레이 수식

 
\[ y = ax + b \]

또는 번호 포함:

 
\begin{equation}
y = ax + b
\label{eq:linear}
\end{equation}

 

참조:

 
Eq.~(\ref{eq:linear})

7.3 자주 쓰는 수식 기호

표현LaTeX
분수 \frac{a}{b}
\sum_{i=1}^{N}
적분 \int_0^1
벡터 \mathbf{x}
기대값 \mathbb{E}
절댓값 \lvert x \rvert
norm \lVert x \rVert

8. 그림(Figure)

 
\begin{figure}[t]
        \centering
        \includegraphics[width=0.9\linewidth]{fig1.png}
        \caption{Overview of the proposed pipeline.}
        \label{fig:overview}
\end{figure}

 

참조:

 
Fig.~\ref{fig:overview}

 

IEEE 규칙:

  • Fig. 1, Table I
  • 캡션은 문장형, 마침표 없음 or 있음 일관성 유지

9. 표(Table)

 
\begin{table}[t]
\centering
\caption{Quantitative comparison on fixed test set}
\label{tab:results}
\begin{tabular}{lcc}
\hline
Method & PSNR (dB) & SSIM \\
\hline
Baseline & 18.43 & 0.9148 \\
Proposed & 28.22 & 0.9785 \\
Oracle & 36.13 & 0.9922 \\
\hline
\end{tabular}
\end{table}

 

 

참조:

 
Table~\ref{tab:results}

10. 인용(Citation) & 참고문헌

10.1 본문 인용

 
\cite{smith2023rccg}

 

여러 개:

 
\cite{smith2023rccg,lee2024spectral}

10.2 BibTeX (refs.bib)

 
@article{smith2023rccg,
        title={RCCG spectral reconstruction},
        author={Smith, John},
        journal={IEEE Transactions on Image Processing},
        year={2023}
}

10.3 참고문헌 출력

 
\bibliographystyle{IEEEtran}
\bibliography{refs}

11. 자주 쓰는 IEEE 표현

표현예시
그림 참조 Fig.~1
수식 참조 Eq.~(3)
표 참조 Table~I
et al. et al.
i.e. i.e.,
e.g. e.g.,

12. 컴파일 방법

Overleaf

  • 그냥 Recompile 클릭

로컬 (PDF 생성)

 
pdflatex main.tex
bibtex main
pdflatex main.tex
pdflatex main.tex

13. 지금 논문에 바로 쓰는 예문

 
Fig.~\ref{fig:results} xxx xxx xxx, as shown in Table~\ref{tab:results}.

 

 

감사합니다.

728x90