Sarmate.net Sarmate.net
Home Features Pricing Documentation Contact
Log in Sign up
Back to gallery
LaTeX EN

Arithmetic course (high school) — divisors, parity, prime numbers

Sarmate sarmate_examples 2026-05-03 0 16

Complete high-school arithmetic course covering: divisors and multiples (with proof of the sum-of-multiples property), even and odd numbers (with proof of square-of-odd via contrapositive), prime numbers, and the Sieve of Eratosthenes in Python. Numbered coloured theorem boxes (Definition, Property, Example, Remark) via tcolorbox. Translated from a French course used in 2nde (grade 10).

Open in demo Sign in to like
\documentclass[11pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}
\usepackage[margin=2cm]{geometry}
\usepackage{amsmath, amssymb, amsthm}
\usepackage[most]{tcolorbox}
\usepackage{enumitem}
\usepackage[hidelinks]{hyperref}
\usepackage{listings}
\usepackage{xcolor}

\newtcbtheorem[number within=section]{definition}{Definition}{
  enhanced, breakable, colback=blue!5, colframe=blue!60!black,
  fonttitle=\bfseries, coltitle=white,
  attach boxed title to top left={xshift=8pt, yshift=-8pt},
  boxed title style={colback=blue!60!black, sharp corners, rounded corners=northwest}
}{def}

\newtcbtheorem[use counter from=definition]{property}{Property}{
  enhanced, breakable, colback=green!5, colframe=green!50!black,
  fonttitle=\bfseries, coltitle=white,
  attach boxed title to top left={xshift=8pt, yshift=-8pt},
  boxed title style={colback=green!50!black, sharp corners, rounded corners=northwest}
}{prop}

\newtcolorbox{example}{
  enhanced, breakable, colback=orange!5, colframe=orange!70!black,
  title=Example, fonttitle=\bfseries, coltitle=white,
  attach boxed title to top left={xshift=8pt, yshift=-8pt},
  boxed title style={colback=orange!70!black, sharp corners, rounded corners=northwest}
}

\newenvironment{remark}{%
  \par\smallskip\noindent\textcolor{gray!50!black}{\rule{3pt}{1.4em}}\hspace{0.5em}%
  \textbf{Remark.}\itshape\space%
}{\par\smallskip}

\newtheorem*{proof*}{Proof}

\lstset{
  basicstyle=\ttfamily\footnotesize, language=Python,
  frame=single, framerule=0.4pt, backgroundcolor=\color{gray!5},
  rulecolor=\color{gray!40}, showstringspaces=false, breaklines=true,
}

\title{Arithmetic --- High School Course}
\author{}
\date{}

\begin{document}
\maketitle

\section{Divisor and multiple}

\begin{definition}{Divisor, multiple}{div-mult}
Let $a$ and $b$ be two integers. We say that $a$ is a \textbf{divisor} of $b$ if there exists $k \in \mathbb{Z}$ such that $b = k \times a$.
\medskip

If $a$ is a divisor of $b$, we may equivalently say:
\begin{itemize}[nosep]
  \item $a$ \emph{divides} $b$,
  \item $b$ is a \emph{multiple} of $a$,
  \item $b$ is \emph{divisible by} $a$.
\end{itemize}
\end{definition}

\begin{example}
The number $3$ is a divisor of $153$ since $153 = 3 \times 51$.
\medskip

\textbf{Divisors of $132$:} we observe that $132 = 2 \times 2 \times 3 \times 11$. Taking all combinations, the list of divisors of $132$ is:
\\[3pt]
\centerline{$1$,~$2$,~$3$,~$4$,~$6$,~$11$,~$12$,~$22$,~$33$,~$44$,~$66$,~$132$.}
\medskip

\textbf{Divisors of $109$:} the number $109$ has exactly two divisors, $1$ and $109$.
\end{example}

\begin{property}{Sum of two multiples}{sum-multiples}
Let $a \in \mathbb{Z}$. If $b$ and $b'$ are both multiples of $a$, then $b + b'$ is also a multiple of $a$.
\end{property}

\begin{proof*}
Let $a \in \mathbb{Z}$ and let $b, b'$ be multiples of $a$. There exist $k, k' \in \mathbb{Z}$ such that $b = ak$ and $b' = ak'$. Then:
\[ b + b' = ak + ak' = a(k + k'), \]
so $b + b'$ is a multiple of $a$. \qedhere
\end{proof*}

\section{Even and odd numbers}

\begin{definition}{Even, odd}{even-odd}
Let $a \in \mathbb{Z}$.
\begin{itemize}[nosep]
  \item $a$ is \textbf{even} if it is divisible by $2$, i.e.\ if there exists $k \in \mathbb{Z}$ such that $a = 2k$.
  \item $a$ is \textbf{odd} if it is not divisible by $2$, i.e.\ if there exists $k \in \mathbb{Z}$ such that $a = 2k + 1$.
\end{itemize}
\end{definition}

\begin{example}
$17 = 2 \times 8 + 1$ is odd. \\
$158 = 2 \times 79$ is even.
\end{example}

\begin{property}{Square of an odd number}{square-odd}
Let $a \in \mathbb{Z}$. If $a$ is odd, then $a^2$ is odd.
\end{property}

\begin{proof*}
Let $a$ be odd. There exists $k \in \mathbb{Z}$ such that $a = 2k + 1$. Then:
\begin{align*}
a^2 &= (2k + 1)^2 = 4k^2 + 4k + 1 = 2(2k^2 + 2k) + 1 = 2N + 1,
\end{align*}
with $N = 2k^2 + 2k \in \mathbb{Z}$. Hence $a^2$ is odd. \qedhere
\end{proof*}

\begin{property}{Converse}{converse}
Let $a \in \mathbb{Z}$. If $a^2$ is odd, then $a$ is odd.
\end{property}

\begin{proof*}[Proof by contrapositive]
We show that ``if $a$ is even, then $a^2$ is even''. If $a$ is even, there exists $k \in \mathbb{Z}$ with $a = 2k$. Then $a^2 = (2k)^2 = 4k^2 = 2 \times (2k^2)$, so $a^2$ is even. \qedhere
\end{proof*}

\begin{remark}
The two properties above are conveniently combined into the equivalence:
\\
\centerline{$a^2$ is odd \quad $\Longleftrightarrow$ \quad $a$ is odd.}
\end{remark}

\section{Prime numbers}

\begin{definition}{Prime number}{prime}
A positive integer is called \textbf{prime} if it has exactly two distinct divisors: $1$ and itself.
\end{definition}

\begin{example}
The numbers $2, 3, 5, 7, 11, 13$ are prime. \\
The number $60$ is not prime: its divisors are $1, 2, 3, 4, 5, 6, 10, 12, 15, 20, 30, 60$.
\end{example}

\subsection*{Sieve of Eratosthenes (Python)}

The following algorithm, inspired by the sieve of Eratosthenes, prints the prime numbers below $100$:

\begin{lstlisting}
for i in range(2, 101):
    is_prime = True
    for j in range(2, i):
        if i % j == 0:
            is_prime = False
    if is_prime:
        print(i)
\end{lstlisting}

\end{document}
This example is licensed under CC‑BY‑4.0. You may copy, modify, and redistribute it as long as you credit the author (Sarmate sarmate_examples).