There was one very difficult question, maybe you can help, give recommendations!
Statement of a question:
It is necessary to prepare a course of lectures on "Linear Algebra", there will be many figures and tables, slide format 16:9, output file in .pdf format. However, I choose LaTeX directly as a source. The main problem is this:
For now, the preamble looks like this (compile in overleaf):
\documentclass[aspectratio=169, 10pt]{beamer}
\usepackage[T1,T2A]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usefonttheme{professionalfonts}
\usepackage{concmath}
\usefonttheme{serif}
\usepackage{setspace}
\usepackage{indentfirst}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{amsthm}
\usepackage{ragged2e}
\usepackage{etoolbox}
% 1. Line spacing 1.15
\setstretch{1.0}
% 2. Indent margin 1.25 cm
\setlength{\parindent}{1.15cm}
% 3. Indentation between adjacent paragraphs 12pt (double)
\setlength{\parskip}{4pt}
\setlength{\emergencystretch}{3em}
\expandafter\def\expandafter\normalsize\expandafter{%
\normalsize
\setlength\abovedisplayskip{4pt}
\setlength\belowdisplayskip{4pt}
\setlength\abovedisplayshortskip{4pt}
\setlength\belowdisplayshortskip{4pt}
}
\makeatletter
\newcommand{\repar}{\vspace{-4pt}}
\renewcommand{\indent}{\hspace*{20pt}}
\setbeamertemplate{frametitle}[default][center]
\setbeamersize{text margin left=2em,text margin right=2em}
\setbeamerfont{title}{size=\LARGE}
\setbeamerfont{subtitle}{size=\Large}
\setbeamerfont{frametitle}{size=\Large}
\setbeamerfont{block title}{size=\normalsize}
\setbeamerfont{footline}{size=\normalsize}
\usebeamercolor{structure}
\setbeamercolor{normal text}{fg=black}
\setbeamercolor{structure}{bg=black!20,fg=black}
% \addtobeamertemplate{frametitle}{}{\vspace*{-1ex}\rule{\textwidth}{1pt}}
\setbeamertemplate{navigation symbols}{}
\setbeamertemplate{section in toc}[sections numbered]
\setbeamertemplate{footline}{%
\centering
\begin{minipage}{\dimexpr\paperwidth-\beamer@leftmargin-\beamer@rightmargin\relax}
\vspace{-4ex}
\centering
\rule{\linewidth}{1pt} \vskip 1pt
\usebeamerfont{footline}%
\usebeamercolor{footline}%
% \hfill\insertpagenumber/\inserttotalframenumber
\hfill\insertpagenumber
\hfill%
\llap{\insertframenavigationsymbol\insertbackfindforwardnavigationsymbol}\par
\end{minipage}\vskip1pt
}
\makeatother
\title{\textbf{Linear Algebra}}
\author{Author}
\date{Date}
\apptocmd{\frame}{}{\justifying}{}
\begin{document}
\begin{frame}
\thispagestyle{empty}
\titlepage
\end{frame}
\begin{frame}{Contents}
\tableofcontents[sections=1]
\tableofcontents[sections=2]
\end{frame}
\section{Introduction}
\begin{frame}{Introduction}
\begin{itemize}
\item Your introduction goes here!
\item Use \texttt{itemize} to organize your main points.
\end{itemize}
\vskip 1cm
\end{frame}
\section{Mathematics}
\begin{frame}[allowframebreaks,allowdisplaybreaks]{Readable Mathematics}
\indent Let $X_1, X_2, \ldots, X_n$ be a sequence of independent and identically distributed random variables with $\text{E}[X_i] = \mu$ and $\text{Var}[X_i] = \sigma^2 < \infty$, and let
$$S_n = \frac{X_1 + X_2 + \cdots + X_n}{n}
= \frac{1}{n}\sum_{i}^{n} X_i = \int_{a}^{b} f(x_i) dx$$
\repar denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$.
\indent denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$.
denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean.
Let $X_1, X_2, \ldots, X_n$ be a sequence of independent and identically distributed random variables with $\text{E}[X_i] = \mu$ and $\text{Var}[X_i] = \sigma^2 < \infty$, and let
$$S_n = \frac{X_1 + X_2 + \cdots + X_n}{n}
= \frac{1}{n}\sum_{i}^{n} X_i = \int_{a}^{b} f(x_i) dx$$
\repar denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$.
\indent denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$.
denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$. denote their mean. Then as $n$ approaches infinity, the random variables $\sqrt{n}(S_n - \mu)$ converge \textbf{in distribution} to a normal $\mathcal{N}(0, \sigma^2)$.
\end{frame}
\end{document}
My troubleshooting: the template was chosen other authors, of course, all the text and formulas are just for testing and demonstrating the possibilities, I note that the manual for the beamer class describes very little about the elements of setting and setting the parameters of the template, for example, one of the problems is clearly reflected in the Mathematics block (Readable Mathematics) -- in fact, we can consider that the beginning of each section is the subtitle of each single lecture, and chapter is the lecture itself. For the Readable Mathematics section, the problem is that when you create an additional frame, it automatically creates a numbering and subtitle Readable Mathematics I, Readable Mathematics II - it's enough for me to create Readable Mathematics I alone, and the material on other slides was a continuation and slide was empty, and all its space could be filled with text until I created a new subsection. In documents of classes article or book, such problems are solved, and you can create a structure similar to a book, there is no such thing in beamer (more precisely, I did not find it, probably).
The figure below is an illustration of the situation described above:

How to set such options for beamer template?

I work in Overleaf, sorry for my not clarify question, I will eit this question
– Alex Aug 22 '23 at 11:06I edit my question
– Alex Aug 22 '23 at 11:12$$or\indentin a document and you should change comments if changing code (to avoid confusing yourself later). All your initial comments do not match the lines you comment, eg% 2. Indent margin 1.25 cm \setlength{\parindent}{1.15cm}– David Carlisle Aug 22 '23 at 11:16Thanks for remark!
– Alex Aug 22 '23 at 11:22