feat: update math format
define custom theorem + defn environments define cleveref notations
This commit is contained in:
parent
30201682ba
commit
f7a5869f0e
109
format/math.tex
109
format/math.tex
|
@ -1,4 +1,4 @@
|
|||
\input{$LATEX_RESOURCES/format/base.tex}
|
||||
\input{../latex/format/base.tex}
|
||||
|
||||
% ------------------------------------ %
|
||||
|
||||
|
@ -6,80 +6,57 @@
|
|||
\usepackage{amssymb}
|
||||
\usepackage{amsthm}
|
||||
\usepackage{mathrsfs}
|
||||
\usepackage{bbold}
|
||||
\usepackage[framemethod=TikZ]{mdframed}
|
||||
\usepackage{tikz}
|
||||
\usetikzlibrary{automata,arrows}
|
||||
|
||||
% ------------------------------------ %
|
||||
|
||||
\mdfsetup{nobreak=true}
|
||||
\newtheoremstyle{thm}
|
||||
{\topsep}% measure of space to leave above the theorem. E.g.: 3pt
|
||||
{\topsep}% measure of space to leave below the theorem. E.g.: 3pt
|
||||
{\itshape}% name of font to use in the body of the theorem
|
||||
{0pt}% measure of space to indent
|
||||
{\large\bfseries}% name of head font
|
||||
{. \newline}% punctuation between head and body
|
||||
{ }% space after theorem head; " " = normal interword space
|
||||
{\thmname{#1}\thmnumber{ #2}\textnormal{\thmnote{ (#3)}}}
|
||||
|
||||
\newcounter{thm}\setcounter{thm}{0}
|
||||
\renewcommand{\thethm}{\arabic{thm}}
|
||||
\newenvironment{thm}[2][]{
|
||||
\refstepcounter{thm}
|
||||
\ifstrempty{#1}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Theorem~\thethm}}}
|
||||
}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Theorem~\thethm:~#1}}}
|
||||
}
|
||||
\begin{mdframed}[]\relax%
|
||||
\label{#2}}{\end{mdframed}
|
||||
}
|
||||
|
||||
\newcounter{lem}[section]\setcounter{lem}{0}
|
||||
\renewcommand{\thelem}{\arabic{section}.\arabic{lem}}
|
||||
\newenvironment{lem}[2][]{
|
||||
\refstepcounter{lem}
|
||||
\ifstrempty{#1}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Lemma~\thelem}}}
|
||||
}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Lemma~\thelem:~#1}}}
|
||||
}
|
||||
\begin{mdframed}[]\relax%
|
||||
\label{#2}}{\end{mdframed}}
|
||||
|
||||
\newcounter{prop}[subsection]\setcounter{prop}{0}
|
||||
\renewcommand{\theprop}{\arabic{section}.\arabic{prop}}
|
||||
\newenvironment{prop}[2][]{
|
||||
\refstepcounter{prop}
|
||||
\ifstrempty{#1}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Proposition~\theprop}}}
|
||||
}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Proposition~\theprop:~#1}}}
|
||||
}
|
||||
\begin{mdframed}[]\relax%
|
||||
\label{#2}}{\end{mdframed}}
|
||||
|
||||
\newcounter{defn}[section]\setcounter{defn}{0}
|
||||
\renewcommand{\thedefn}{\arabic{defn}}
|
||||
\newenvironment{defn}[2][]{
|
||||
\refstepcounter{defn}
|
||||
\ifstrempty{#1}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Definition~\thedefn}}}
|
||||
}
|
||||
{\mdfsetup{
|
||||
frametitle={%
|
||||
{\strut Definition~\thedefn:~#1}}}
|
||||
}
|
||||
\begin{mdframed}[]\relax%
|
||||
\label{#2}}{\end{mdframed}}
|
||||
\newtheoremstyle{defn}
|
||||
{\topsep}% measure of space to leave above the theorem. E.g.: 3pt
|
||||
{\topsep}% measure of space to leave below the theorem. E.g.: 3pt
|
||||
{\normalfont}% name of font to use in the body of the theorem
|
||||
{0pt}% measure of space to indent
|
||||
{\large\bfseries}% name of head font
|
||||
{. ---}% punctuation between head and body
|
||||
{ }% space after theorem head; " " = normal interword space
|
||||
{\thmname{#1}\thmnumber{ #2}\textnormal{\thmnote{ (#3)}}}
|
||||
|
||||
\theoremstyle{remark}
|
||||
\newtheorem*{rmk}{Remark}
|
||||
\newtheorem*{note}{Note}
|
||||
\theoremstyle{defn}
|
||||
\newtheorem{defn}{Definition}
|
||||
\newtheorem{rmd}{Reminder}
|
||||
\newtheorem{clm}{Claim}
|
||||
\theoremstyle{thm}
|
||||
\newtheorem{thm}{Theorem}
|
||||
\renewcommand{\thethm}{\arabic{thm}}
|
||||
\newtheorem{lem}{Lemma}
|
||||
\renewcommand{\thelem}{\arabic{lem}}
|
||||
\newtheorem{prop}{Proposition}
|
||||
\renewcommand{\theprop}{\arabic{prop}}
|
||||
|
||||
% --------- Cleveref -----------
|
||||
\usepackage{cleveref}
|
||||
\crefname{thm}{Theorem}{Theorems}
|
||||
\Crefname{thm}{Theorem}{Theorems}
|
||||
\crefname{lem}{Lemma}{Lemmas}
|
||||
\Crefname{lem}{Lemma}{Lemmas}
|
||||
\crefname{defn}{definition}{definitions}
|
||||
\Crefname{defn}{Definition}{Definitions}
|
||||
\crefname{rmd}{reminder}{reminders}
|
||||
\Crefname{rmd}{Reminder}{Reminders}
|
||||
\crefname{clm}{claim}{claims}
|
||||
\Crefname{clm}{Claim}{Claims}
|
||||
|
|
Loading…
Reference in New Issue