Notes

My template for LaTex notes

Category

Other

License

Free to use (MIT)

File

main.tex

main.texRead-only preview
\documentclass[hidelinks,11pt,letterpaper]{article}

\usepackage[margin=1in]{geometry}
\setlength{\headheight}{16pt}  
\usepackage{amsmath,amsthm,amssymb}
\usepackage{graphicx}
\usepackage{booktabs}
\usepackage{xcolor}
\usepackage{tcolorbox}
\usepackage{fancyhdr}
\usepackage{titlesec}
\usepackage{hyperref}
\usepackage{enumitem}
\usepackage{tikz}

\definecolor{headingcolor}{HTML}{0F4F46}
\definecolor{examplecolor}{HTML}{2EB49B} 
\definecolor{onexample}{HTML}{071815}
\definecolor{ideacolor}{HTML}{F9DD02} 
\definecolor{onidea}{HTML}{4B4202}
\definecolor{remarkcolor}{HTML}{E57571} 
\definecolor{onremark}{HTML}{050101}

\titleformat{\section}
{\normalfont\LARGE\bfseries\color{headingcolor}}
{\thesection}{1em}{}[\titlerule]

\newcounter{example}[section]
\newenvironment{example}
{\refstepcounter{example}\par\medskip
   \begin{tcolorbox}[colback=white,
                     colframe=examplecolor,
                     arc=0.5mm,
                     title=Example~\thesection.\arabic{example},
                     fonttitle=\bfseries,
                     toptitle=4pt,
                     bottomtitle=4pt,
                     colbacktitle=examplecolor,
                     coltitle=onexample]
}
{\end{tcolorbox}\par\medskip}

\newcounter{keyidea}[section]
\newenvironment{keyidea}
{\refstepcounter{keyidea}\par\medskip
   \begin{tcolorbox}[colback=white,
                     colframe=ideacolor,
                     arc=0.5mm,
                     title=Key Idea~\thesection.\arabic{keyidea},
                     fonttitle=\bfseries,
                     toptitle=4pt,
                     bottomtitle=4pt,
                     colbacktitle=ideacolor,
                     coltitle=onidea]
}
{\end{tcolorbox}\par\medskip}

\newcounter{remark}[section]
\newenvironment{remark}
{\refstepcounter{remark}\par\medskip
   \begin{tcolorbox}[colback=white,
                     colframe=remarkcolor,
                     arc=0.5mm,
                     title=Remark~\thesection.\arabic{remark},
                     fonttitle=\bfseries,
                     toptitle=4pt,
                     bottomtitle=4pt,
                     colbacktitle=remarkcolor,
                     coltitle=onremark]
}
{\end{tcolorbox}\par\medskip}

\pagestyle{fancy}
\fancyhf{}
\fancyhead[L]{\textit{\bookname}}
\fancyhead[R]{\textit{Chapter \thesection}}
\fancyfoot[C]{\thepage}
\renewcommand{\headrulewidth}{0.4pt}

\newcommand{\bookname}{}
\newcommand{\booknotes}[3]{
    \renewcommand{\bookname}{#1}
    \title{\textbf{\Huge{Notes on:}\\\Huge{\textcolor{headingcolor}{#1}}}}
    \author{#2}
    \date{#3}
}

\begin{document}

\booknotes{Sample Document}{Joshua Motoaki Lau}{Summer 2025}
\maketitle
\tableofcontents
\newpage

\section{Introduction to Real Analysis}

This chapter covers the foundations of real analysis, beginning with properties of the real number system.

\begin{keyidea}
    The completeness property of real numbers states that every non-empty set of real numbers that is bounded above has a least upper bound.
\end{keyidea}

\begin{example}
    Consider the set $S = \{x \in \mathbb{R} : x^2 < 2\}$. 
    This set is bounded above, and its least upper bound is $\sqrt{2}$.
    
    We can verify this by noting that:
    \begin{itemize}
        \item If $x^2 < 2$, then $x < \sqrt{2}$, so $\sqrt{2}$ is an upper bound.
        \item For any $\varepsilon > 0$, $(\sqrt{2} - \varepsilon)^2 < 2$, so $\sqrt{2} - \varepsilon \in S$.
    \end{itemize}
    
    Therefore, $\sqrt{2}$ is the least upper bound of $S$.
\end{example}

\begin{remark}
    The completeness property distinguishes the real numbers from the rational numbers. For instance, the set $\{x \in \mathbb{Q} : x^2 < 2\}$ has no least upper bound in $\mathbb{Q}$.
\end{remark}

A proper understanding of completeness\footnote{This concept was first rigorously formulated by Dedekind in the 19th century.} is essential for developing the theory of limits and continuity.

\newpage
\section{Sequences and Series}

In this chapter, we explore infinite sequences and series, their convergence properties, and tests for convergence.

\begin{keyidea}
    A sequence $\{a_n\}$ converges to a limit $L$ if for every $\varepsilon > 0$, there exists $N \in \mathbb{N}$ such that $|a_n - L| < \varepsilon$ for all $n \geq N$.
\end{keyidea}

\begin{example}
    Let's prove that the sequence $a_n = \frac{1}{n}$ converges to 0.
    
    Given $\varepsilon > 0$, we need to find $N$ such that $|\frac{1}{n} - 0| < \varepsilon$ for all $n \geq N$.
    
    Since $|\frac{1}{n} - 0| = \frac{1}{n}$, we need $\frac{1}{n} < \varepsilon$, which is equivalent to $n > \frac{1}{\varepsilon}$.
    
    Therefore, we can choose $N = \lceil\frac{1}{\varepsilon}\rceil$, and for all $n \geq N$, we have $|a_n - 0| < \varepsilon$.
\end{example}

\begin{remark}
    While many sequences converge, there are important examples of divergent sequences like $a_n = (-1)^n$ and $a_n = n$.
\end{remark}


\end{document}
Preview
Notes preview
Notes LaTeX Template | Bibby | Bibby AI