@ -12,16 +12,9 @@
% \▓▓▓▓▓▓ %
% \▓▓▓▓▓▓ %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Original file:
% https://github.com/vEnhance/dotfiles/blob/main/texmf/tex/latex/evan/evan.sty
% https://github.com/vEnhance/dotfiles/blob/main/texmf/tex/latex/evan/evan.sty
% ░█▄█░▄▀▄░█░░▒█░░░▀█▀░▄▀▄░░░█▒█░▄▀▀▒██▀
% ▒█▒█░▀▄▀░▀▄▀▄▀▒░░▒█▒░▀▄▀▒░░▀▄█▒▄██░█▄▄
%
% If you don't know how to use this file, read:
% +--------------------------------------------+
% | https://web.evanchen.cc/faq-latex.html#L-4 |
% +--------------------------------------------+
%
% TL;DR of the Boost license conditions are as follows:
% TL;DR of the Boost license conditions are as follows:
%
%
% 1. Any SOURCE VERSIONS must cite evan.sty and the Boost license below.
% 1. Any SOURCE VERSIONS must cite evan.sty and the Boost license below.
@ -62,145 +55,88 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ProvidesPackage{evan}
\ProvidesPackage{evan}
%%fakesection Argument processing
% Default Arguments
% We include "Evan" in all of these to make sure
% that they don't collide with anything in external packages
\newif\ifevanfancy\evanfancytrue
\newif\ifevanhdr\evanhdrtrue
\newif\ifevanhref\evanhreftrue
\newif\ifevansetup\evansetuptrue
\newif\ifevanthm\evanthmtrue
\newif\ifevansecthm\evansecthmfalse
\newif\ifevanht\evanhtfalse
\newif\ifevanpkg\evanpkgtrue
\newif\ifevanpdf\evanpdftrue
\newif\ifevanauthor\evanauthortrue
\newif\ifevanchinese\evanchinesefalse
\newif\ifevanmdthm\evanmdthmfalse
\newif\ifevandiagrams\evandiagramsfalse
\newif\ifevanpatchasy\evanpatchasyfalse
\newif\ifevanhints\evanhintsfalse
\newif\ifevanasy\evanasytrue
\newif\ifevancolorsec\evancolorsecfalse
\newif\ifevantitlemark\evantitlemarktrue
\newif\ifevanvonenabled\evanvonenabledfalse
\newif\ifevanbritish\evanbritishtrue
%Receive Arguments
\DeclareOption{chinese}{\evanhreffalse\evanchinesetrue} % Chinese support
% allow href to override this one
\DeclareOption{sexy}{\evansecthmtrue\evanmdthmtrue\evancolorsectrue} % long docs
\DeclareOption{fancy}{\evanfancytrue}
\DeclareOption{nofancy}{\evanfancyfalse}
\DeclareOption{hdr}{\evanhdrtrue}
\DeclareOption{nohdr}{\evanhdrfalse}
\DeclareOption{href}{\evanhreftrue}
\DeclareOption{nohref}{\evanhreffalse}
\DeclareOption{nosetup}{\evansetupfalse}
\DeclareOption{thm}{\evanthmtrue}
\DeclareOption{nothm}{\evanthmfalse}
\DeclareOption{secthm}{\evansecthmtrue}
\DeclareOption{nosecthm}{\evansecthmfalse}
\DeclareOption{ht}{\evanhttrue}
\DeclareOption{nopdf}{\evanpdffalse}
\DeclareOption{nopkg}{\evanpkgfalse}
\DeclareOption{noauthor}{\evanauthorfalse}
\DeclareOption{titlemark}{\evantitlemarktrue} % Sets title in ohead, not \rightmark
\DeclareOption{sectionmark}{\evantitlemarkfalse} % Uses \rightmark not title in ohead
\DeclareOption{mdthm}{\evanmdthmtrue}
\DeclareOption{nomdthm}{\evanmdthmfalse}
\DeclareOption{diagrams}{\evandiagramstrue}
\DeclareOption{nodiagrams}{\evandiagramsfalse}
\DeclareOption{colorsec}{\evancolorsectrue}
\DeclareOption{nocolorsec}{\evancolorsecfalse}
\DeclareOption{patchasy}{\evanpatchasytrue}
\DeclareOption{noasy}{\evanasyfalse}
\DeclareOption{hints}{\evanhintstrue}
\DeclareOption{von}{\evanvonenabledtrue}
\DeclareOption{british}{\evanbritishtrue}
\DeclareOption{american}{\evanbritishfalse}
\ProcessOptions\relax
\ProcessOptions\relax
% if packages not loaded, turn off mdthm and asy
\ifevanpkg\else\evanmdthmfalse\fi
\ifevanpkg\else\evanasyfalse\fi
% If no setup, turn off theorems
\ifevansetup\else\evanthmfalse\fi
%%fakesection Some macros
%Small commands
\usepackage{amsmath,amssymb}
\usepackage{amsmath,amssymb}
\usepackage{iftex}
\usepackage{iftex}
\ifevanpkg
\usepackage[minimal]{yhmath}
\usepackage[minimal]{yhmath}
\fi
\setlength\parindent{0pt}
% Personal commands
\newcommand{\card}[1]{\left|#1\right|}
\newcommand{\nsqrt}[2]{\!\sqrt[#1]{#2}\,}
\newcommand{\zeroset}{\{0\}}
\newcommand{\setminuszero}{\setminus \{0\}}
\newcommand{\corref}[1]{\textit{Corollario \ref{#1}}}
\newcommand{\exref}[1]{\textit{Esercizio \ref{#1}}}
\newcommand{\exmplref}[1]{\textit{Esempio \ref{#1}}}
\newcommand{\propref}[1]{\textit{Proposizione \ref{#1}}}
\newcommand{\lemref}[1]{\textit{Lemma \ref{#1}}}
\newcommand{\thref}[1]{\textit{Teorema \ref{#1}}}
\newcommand{\BB}{\mathcal{B}}
\newcommand{\HH}{\mathbb{H}}
\newcommand{\KK}{\mathbb{K}}
\newcommand{\ZZp}{\mathbb{Z}_p}
\newcommand{\CCx}{\mathbb{C}[x]}
\newcommand{\FFpp}{\mathbb{F}_p}
\newcommand{\FFpd}{\mathbb{F}_{p^d}}
\newcommand{\FFpm}{\mathbb{F}_{p^m}}
\newcommand{\FFpn}{\mathbb{F}_{p^n}}
\newcommand{\FFp}[1]{\mathbb{F}_{p^{#1}}}
\newcommand{\KKx}{\mathbb{K}[x]}
\newcommand{\QQx}{\mathbb{Q}[x]}
\newcommand{\RRx}{\mathbb{R}[x]}
\newcommand{\ZZi}{\mathbb{Z}[i]}
\newcommand{\ZZom}{\mathbb{Z}[\omega]}
\newcommand{\ZZpx}{\mathbb{Z}_p[x]}
\newcommand{\ZZx}{\mathbb{Z}[x]}
\newcommand{\ii}{\mathbf{i}}
\newcommand{\jj}{\mathbf{j}}
\newcommand{\kk}{\mathbf{k}}
\newcommand{\valalpha}{\varphi_\alpha}
\newcommand{\Frob}{\mathcal{F}}
\newcommand{\Frobexp}{\mathcal{F}{\mkern 1.5mu}}
\newcommand{\dual}[1]{#1^{*}}
\newcommand{\LL}[2]{\mathcal{L} \left(#1, \, #2\right)}
\newcommand{\M}[1]{\mathcal{M}_{#1}\left(\KK\right)}
\newcommand{\nsg}{\mathrel{\unlhd}}
\renewcommand{\vec}[1]{\underline{#1}}
\newcommand{\hatpi}{\hat{\pi}}
\newcommand{\hatpip}{\hat{\pi}_p}
% evan.sty original commands
\newcommand{\cbrt}[1]{\sqrt[3]{#1}}
\newcommand{\cbrt}[1]{\sqrt[3]{#1}}
\newcommand{\floor}[1]{\left\lfloor #1 \right\rfloor}
\newcommand{\floor}[1]{\left\lfloor #1 \right\rfloor}
\newcommand{\ceiling}[1]{\left\lceil #1 \right\rceil}
\newcommand{\ceiling}[1]{\left\lceil #1 \right\rceil}
\newcommand{\mailto}[1]{\href{mailto:#1}{\texttt{#1}}}
\newcommand{\mailto}[1]{\href{mailto:#1}{\texttt{#1}}}
\newcommand{\ol}{\overline}
\newcommand{\ul}{\underline}
\newcommand{\wt}{\widetilde}
\newcommand{\wh}{\widehat}
\newcommand{\eps}{\varepsilon}
\newcommand{\eps}{\varepsilon}
%\renewcommand{\iff}{\Leftrightarrow}
%\renewcommand{\implies}{\Rightarrow}
\newcommand{\vocab}[1]{\textbf{\color{blue}\sffamily #1}}
\newcommand{\vocab}[1]{\textbf{\color{blue}\sffamily #1}}
\providecommand{\alert}{\vocab}
\providecommand{\alert}{\vocab}
\providecommand{\half}{\frac{1}{2}}
\newcommand{\catname}{\mathsf}
\newcommand{\catname}{\mathsf}
\newcommand{\hrulebar}{
\par\hspace{\fill}\rule{0.95\linewidth}{.7pt}\hspace{\fill}
\par\nointerlineskip \vspace{\baselineskip}
}
\providecommand{\arc}[1]{\wideparen{#1}}
\providecommand{\arc}[1]{\wideparen{#1}}
%For use in author command
% From H113 "Introduction to Abstract Algebra" at UC Berkeley
\newcommand{\plusemail}[1]{\\ \normalfont \texttt{\mailto{#1}}}
%More commands and math operators
\DeclareMathOperator{\cis}{cis}
\DeclareMathOperator*{\lcm}{lcm}
\DeclareMathOperator*{\argmin}{arg min}
\DeclareMathOperator*{\argmax}{arg max}
%Convenient Environments
\newenvironment{soln}{\begin{proof}[Solution]}{\end{proof}}
\newenvironment{parlist}{\begin{inparaenum}[(i)]}{\end{inparaenum}}
\newenvironment{gobble}{\setbox\z@\vbox\bgroup}{\egroup}
%Inequalities
\newcommand{\cycsum}{\sum_{\mathrm{cyc}}}
\newcommand{\symsum}{\sum_{\mathrm{sym}}}
\newcommand{\cycprod}{\prod_{\mathrm{cyc}}}
\newcommand{\symprod}{\prod_{\mathrm{sym}}}
%From H113 "Introduction to Abstract Algebra" at UC Berkeley
\newcommand{\CC}{\mathbb C}
\newcommand{\CC}{\mathbb C}
\newcommand{\FF}{\mathbb F}
\newcommand{\FF}{\mathbb F}
\newcommand{\NN}{\mathbb N}
\newcommand{\NN}{\mathbb N}
\newcommand{\QQ}{\mathbb Q}
\newcommand{\QQ}{\mathbb Q}
\newcommand{\RR}{\mathbb R}
\newcommand{\RR}{\mathbb R}
\newcommand{\ZZ}{\mathbb Z}
\newcommand{\ZZ}{\mathbb Z}
\newcommand{\charin}{\text{ char }}
\DeclareMathOperator{\sign}{sign}
\DeclareMathOperator{\Aut}{Aut}
\DeclareMathOperator{\Aut}{Aut}
\DeclareMathOperator{\Inn}{Inn}
\DeclareMathOperator{\Inn}{Inn}
\DeclareMathOperator{\Syl}{Syl}
\DeclareMathOperator{\Syl}{Syl}
\DeclareMathOperator{\Gal}{Gal}
\DeclareMathOperator{\Gal}{Gal}
\DeclareMathOperator{\GL}{GL} % General linear group
\DeclareMathOperator{\GL}{GL}
\DeclareMathOperator{\SL}{SL} % Special linear group
\DeclareMathOperator{\SL}{SL}
%From Kiran Kedlaya's "Geometry Unbound"
%From Kiran Kedlaya's "Geometry Unbound"
\newcommand{\abs}[1]{\left\lvert #1 \right\rvert}
\newcommand{\abs}[1]{\left\lvert #1 \right\rvert}
@ -209,188 +145,82 @@
\newcommand{\ray}[1]{\overrightarrow{#1}}
\newcommand{\ray}[1]{\overrightarrow{#1}}
\newcommand{\seg}[1]{\overline{#1}}
\newcommand{\seg}[1]{\overline{#1}}
%From M275 "Topology" at SJSU
% From M275 "Topology" at SJSU
\newcommand{\id}{\mathrm{id}}
\newcommand{\id}{\mathrm{id}}
\newcommand{\taking}[1]{\xrightarrow{#1}}
\newcommand{\taking}[1]{\xrightarrow{#1}}
\newcommand{\inv}{^{-1}}
\newcommand{\inv}{^{-1}}
%From M170 "Introduction to Graph Theory" at SJSU
\DeclareMathOperator{\diam}{diam}
\DeclareMathOperator{\ord}{ord}
\DeclareMathOperator{\ord}{ord}
\newcommand{\defeq}{\overset{\mathrm{def}}{=}}
\newcommand{\defeq}{\overset{\mathrm{def}}{=}}
%From the USAMO .tex files
% From the USAMO .tex files
\newcommand{\ts}{\textsuperscript}
\newcommand{\dg}{^\circ}
\newcommand{\dg}{^\circ}
\newcommand{\ii}{\item}
% From Math 55 and Math 145 at Harvard
\newenvironment{subproof}[1][Proof]{%
\begin{proof}[#1] \renewcommand{\qedsymbol}{$\blacksquare$}}%
{\end{proof}}
\newcommand{\liff}{\leftrightarrow}
\newcommand{\liff}{\leftrightarrow}
\newcommand{\lthen}{\rightarrow}
\newcommand{\lthen}{\rightarrow}
\newcommand{\opname}{\operatorname}
\newcommand{\opname}{\operatorname}
\newcommand{\surjto}{\twoheadrightarrow}
\newcommand{\surjto}{\twoheadrightarrow}
\newcommand{\injto}{\hookrightarrow}
\newcommand{\injto}{\hookrightarrow}
\newcommand{\On}{\mathrm{On}} % ordinals
\DeclareMathOperator{\Char}{char}
\DeclareMathOperator{\img}{im} % Image
\DeclareMathOperator{\Dom}{Dom}
\DeclareMathOperator{\Img}{Im} % Image
\DeclareMathOperator{\Fix}{\textit{Fix}\,}
\DeclareMathOperator{\coker}{coker} % Cokernel
\DeclareMathOperator{\End}{End}
\DeclareMathOperator{\Coker}{Coker} % Cokernel
\DeclareMathOperator{\existsone}{\exists !}
\DeclareMathOperator{\Ker}{Ker} % Kernel
\DeclareMathOperator{\Hom}{Hom}
\DeclareMathOperator{\Imm}{Imm}
\DeclareMathOperator{\Ker}{Ker}
\DeclareMathOperator{\rank}{rank}
\DeclareMathOperator{\rank}{rank}
\DeclareMathOperator{\Spec}{Spec} % spectrum
\DeclareMathOperator{\MCD}{MCD}
\DeclareMathOperator{\Tr}{Tr} % trace
\DeclareMathOperator{\Mor}{Mor}
\DeclareMathOperator{\pr}{pr} % projection
\DeclareMathOperator{\mcm}{mcm}
\DeclareMathOperator{\ext}{ext} % extension
\DeclareMathOperator{\tr}{tr}
\DeclareMathOperator{\pred}{pred} % predecessor
\DeclareMathOperator{\dom}{dom} % domain
\let\oldemptyset\emptyset
\DeclareMathOperator{\ran}{ran} % range
\let\emptyset\varnothing
\DeclareMathOperator{\Hom}{Hom} % homomorphism
\DeclareMathOperator{\Mor}{Mor} % morphisms
\let\oldcirc\circ
\DeclareMathOperator{\End}{End} % endomorphism
\let\circ\undefined
\DeclareMathOperator{\circ}{\oldcirc}
% Things Lie
\newcommand{\kb}{\mathfrak b}
\let\oldexists\exists
\newcommand{\kg}{\mathfrak g}
\let\exists\undefined
\newcommand{\kh}{\mathfrak h}
\DeclareMathOperator{\exists}{\oldexists}
\newcommand{\kn}{\mathfrak n}
\newcommand{\ku}{\mathfrak u}
\let\oldforall\forall
\newcommand{\kz}{\mathfrak z}
\let\forall\undefined
\DeclareMathOperator{\Ext}{Ext} % Ext functor
\DeclareMathOperator{\forall}{\oldforall}
\DeclareMathOperator{\Tor}{Tor} % Tor functor
\newcommand{\gl}{\opname{\mathfrak{gl}}} % frak gl group
\let\oldnexists\nexists
\def\sl{\opname{\mathfrak{sl}}} % frak sl group chktex 6
\let\nexists\undefined
\DeclareMathOperator{\nexists}{\oldnexists}
% More script letters etc.
\newcommand{\SA}{\mathcal A}
\let\oldland\land
\newcommand{\SB}{\mathcal B}
\let\land\undefined
\newcommand{\SC}{\mathcal C}
\DeclareMathOperator{\land}{\oldland}
\newcommand{\SF}{\mathcal F}
\newcommand{\SG}{\mathcal G}
\let\oldlnot\lnot
\newcommand{\SH}{\mathcal H}
\let\lnot\undefined
\newcommand{\OO}{\mathcal O}
\DeclareMathOperator{\lnot}{\oldlnot}
\newcommand{\SCA}{\mathscr A}
\let\oldlor\lor
\newcommand{\SCB}{\mathscr B}
\let\lor\undefined
\newcommand{\SCC}{\mathscr C}
\DeclareMathOperator{\lor}{\oldlor}
\newcommand{\SCD}{\mathscr D}
\newcommand{\SCE}{\mathscr E}
\title{}
\newcommand{\SCF}{\mathscr F}
\author{Gabriel Antonio Videtta}
\newcommand{\SCG}{\mathscr G}
\date{\today}
\newcommand{\SCH}{\mathscr H}
\PassOptionsToPackage{usenames,svgnames,dvipsnames,table}{xcolor}
% Mathfrak primes
\usepackage{xcolor}
\newcommand{\km}{\mathfrak m}
\usepackage[colorlinks=true]{hyperref}
\newcommand{\kp}{\mathfrak p}
\hypersetup{urlcolor=RubineRed,linkcolor=RoyalBlue,citecolor=ForestGreen}
\newcommand{\kq}{\mathfrak q}
\usepackage[nameinlink]{cleveref}
%% Napkin commands
\usepackage{amsthm}
\newcommand{\prototype}[1]{
\usepackage{thmtools}
\emph{{\color{red} Prototypical example for this section:} #1} \par\medskip
\usepackage[framemethod=TikZ]{mdframed}
}
\newenvironment{moral}{%
\mdfdefinestyle{mdbluebox}{%
\begin{mdframed}[linecolor=green!70!black]%
\bfseries\color{green!70!black}}%
{\end{mdframed}}
%%fakesection Asymptote setup
\ifevanasy
\ifevanpatchasy
\usepackage{patchasy}
\else
\usepackage{asymptote}
\fi
\begin{asydef}
defaultpen(fontsize(10pt));
size(8cm); // set a reasonable default
usepackage("amsmath");
usepackage("amssymb");
settings.tex="pdflatex";
settings.outformat="pdf";
// Replacement for olympiad+cse5 which is not standard
import geometry;
// recalibrate fill and filldraw for conics
void filldraw(picture pic = currentpicture, conic g, pen fillpen=defaultpen, pen drawpen=defaultpen)
{ filldraw(pic, (path) g, fillpen, drawpen); }
void fill(picture pic = currentpicture, conic g, pen p=defaultpen)
{ filldraw(pic, (path) g, p); }
// some geometry
pair foot(pair P, pair A, pair B) { return foot(triangle(A,B,P).VC); }
pair orthocenter(pair A, pair B, pair C) { return orthocentercenter(A,B,C); }
pair centroid(pair A, pair B, pair C) { return (A+B+C)/3; }
// cse5 abbreviations
path CP(pair P, pair A) { return circle(P, abs(A-P)); }
path CR(pair P, real r) { return circle(P, r); }
pair IP(path p, path q) { return intersectionpoints(p,q)[0]; }
pair OP(path p, path q) { return intersectionpoints(p,q)[1]; }
path Line(pair A, pair B, real a=0.6, real b=a) { return (a*(A-B)+A)--(b*(B-A)+B); }
// cse5 more useful functions
picture CC() {
picture p=rotate(0)*currentpicture;
currentpicture.erase();
return p;
}
pair MP(Label s, pair A, pair B = plain.S, pen p = defaultpen) {
Label L = s;
L.s = "$"+s.s+"$";
label(L, A, B, p);
return A;
}
pair Drawing(Label s = "", pair A, pair B = plain.S, pen p = defaultpen) {
dot(MP(s, A, B, p), p);
return A;
}
path Drawing(path g, pen p = defaultpen, arrowbar ar = None) {
draw(g, p, ar);
return g;
}
\end{asydef}
\fi
%%fakesection BEGIN MAIN SETUP
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\ifevansetup
%%fakesection Set up author and date
\ifevanauthor
\title{} % empty title to avoid crashes
\ifluatex
\author{Gabriel Antonio Videtta}
\else
\author{Gabriel Antonio Videtta}
\fi
\date{\today}
\fi
%%fakesection Hyperref
\ifevanpkg
\PassOptionsToPackage{usenames,svgnames,dvipsnames,table}{xcolor}
\usepackage{xcolor}
\ifevanhref
\usepackage[colorlinks=true]{hyperref}
\hypersetup{urlcolor=RubineRed,linkcolor=RoyalBlue,citecolor=ForestGreen}
\fi
\usepackage[nameinlink]{cleveref}
\fi
%%fakesection New theorem styles
\ifevanthm
\usepackage{amsthm}
\usepackage{thmtools}
\fi
\ifevanmdthm
\ifevanthm
%% theorem packages loaded already
\else
\usepackage{amsthm}
\usepackage{thmtools}
\fi
\usepackage[framemethod=TikZ]{mdframed}
\mdfdefinestyle{mdbluebox}{%
roundcorner=10pt,
roundcorner=10pt,
linewidth=1pt,
linewidth=1pt,
skipabove=12pt,
skipabove=12pt,
@ -399,15 +229,15 @@
linecolor=blue,
linecolor=blue,
nobreak=true,
nobreak=true,
backgroundcolor=TealBlue!5,
backgroundcolor=TealBlue!5,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\sffamily\bfseries\color{MidnightBlue},
headfont=\sffamily\bfseries\color{MidnightBlue},
mdframed={style=mdbluebox},
mdframed={style=mdbluebox},
headpunct={\\[3pt]},
headpunct={\\[3pt]},
postheadspace={0pt}
postheadspace={0pt}
]{thmbluebox}
]{thmbluebox}
\mdfdefinestyle{mdbluebox2}{%
\mdfdefinestyle{mdbluebox2}{%
roundcorner=10pt,
roundcorner=10pt,
linewidth=1pt,
linewidth=1pt,
skipabove=12pt,
skipabove=12pt,
@ -416,15 +246,15 @@
linecolor=blue,
linecolor=blue,
nobreak=true,
nobreak=true,
backgroundcolor=BlueViolet!9,
backgroundcolor=BlueViolet!9,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\sffamily\bfseries\color{RoyalPurple},
headfont=\sffamily\bfseries\color{RoyalPurple},
mdframed={style=mdbluebox2},
mdframed={style=mdbluebox2},
headpunct={\\[3pt]},
headpunct={\\[3pt]},
postheadspace={0pt}
postheadspace={0pt}
]{thmbluebox2}
]{thmbluebox2}
\mdfdefinestyle{mdredbox}{%
\mdfdefinestyle{mdredbox}{%
linewidth=0.5pt,
linewidth=0.5pt,
skipabove=12pt,
skipabove=12pt,
frametitleaboveskip=5pt,
frametitleaboveskip=5pt,
@ -436,15 +266,15 @@
nobreak=true,
nobreak=true,
backgroundcolor=Salmon!5,
backgroundcolor=Salmon!5,
linecolor=RawSienna,
linecolor=RawSienna,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\bfseries\color{RawSienna},
headfont=\bfseries\color{RawSienna},
mdframed={style=mdredbox},
mdframed={style=mdredbox},
headpunct={\\[3pt]},
headpunct={\\[3pt]},
postheadspace={0pt},
postheadspace={0pt},
]{thmredbox}
]{thmredbox}
\mdfdefinestyle{mdredbox2}{%
\mdfdefinestyle{mdredbox2}{%
roundcorner=10pt,
roundcorner=10pt,
linewidth=1pt,
linewidth=1pt,
skipabove=12pt,
skipabove=12pt,
@ -453,15 +283,15 @@
linecolor=red,
linecolor=red,
nobreak=true,
nobreak=true,
backgroundcolor=WildStrawberry!5,
backgroundcolor=WildStrawberry!5,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\sffamily\bfseries\color{Maroon},
headfont=\sffamily\bfseries\color{Maroon},
mdframed={style=mdredbox2},
mdframed={style=mdredbox2},
headpunct={\\[3pt]},
headpunct={\\[3pt]},
postheadspace={0pt}
postheadspace={0pt}
]{thmredbox2}
]{thmredbox2}
\mdfdefinestyle{mdgreenbox}{%
\mdfdefinestyle{mdgreenbox}{%
skipabove=8pt,
skipabove=8pt,
linewidth=2pt,
linewidth=2pt,
rightline=false,
rightline=false,
@ -470,17 +300,17 @@
bottomline=false,
bottomline=false,
linecolor=ForestGreen,
linecolor=ForestGreen,
backgroundcolor=ForestGreen!5,
backgroundcolor=ForestGreen!5,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\bfseries\sffamily\color{ForestGreen!70!black},
headfont=\bfseries\sffamily\color{ForestGreen!70!black},
bodyfont=\normalfont,
bodyfont=\normalfont,
spaceabove=2pt,
spaceabove=2pt,
spacebelow=1pt,
spacebelow=1pt,
mdframed={style=mdgreenbox},
mdframed={style=mdgreenbox},
headpunct={ --- },
headpunct={ --- },
]{thmgreenbox}
]{thmgreenbox}
\mdfdefinestyle{mdgreenbox2}{%
\mdfdefinestyle{mdgreenbox2}{%
roundcorner=10pt,
roundcorner=10pt,
linewidth=1pt,
linewidth=1pt,
skipabove=12pt,
skipabove=12pt,
@ -489,15 +319,15 @@
linecolor=ForestGreen,
linecolor=ForestGreen,
nobreak=true,
nobreak=true,
backgroundcolor=ForestGreen!5,
backgroundcolor=ForestGreen!5,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\sffamily\bfseries\color{ForestGreen!70!black},
headfont=\sffamily\bfseries\color{ForestGreen!70!black},
mdframed={style=mdgreenbox2},
mdframed={style=mdgreenbox2},
headpunct={\\[3pt]},
headpunct={\\[3pt]},
postheadspace={0pt}
postheadspace={0pt}
]{thmgreenbox2}
]{thmgreenbox2}
\mdfdefinestyle{mdblackbox}{%
\mdfdefinestyle{mdblackbox}{%
skipabove=8pt,
skipabove=8pt,
linewidth=3pt,
linewidth=3pt,
rightline=false,
rightline=false,
@ -506,16 +336,16 @@
bottomline=false,
bottomline=false,
linecolor=black,
linecolor=black,
backgroundcolor=RedViolet!5!gray!10,
backgroundcolor=RedViolet!5!gray!10,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\bfseries,
headfont=\bfseries,
bodyfont=\normalfont\small,
bodyfont=\normalfont\small,
spaceabove=0pt,
spaceabove=0pt,
spacebelow=0pt,
spacebelow=0pt,
mdframed={style=mdblackbox}
mdframed={style=mdblackbox}
]{thmblackbox}
]{thmblackbox}
\mdfdefinestyle{mdblackbox2}{%
\mdfdefinestyle{mdblackbox2}{%
skipabove=8pt,
skipabove=8pt,
linewidth=3pt,
linewidth=3pt,
rightline=false,
rightline=false,
@ -524,137 +354,69 @@
bottomline=false,
bottomline=false,
linecolor=gray,
linecolor=gray,
backgroundcolor=RedViolet!5!gray!10,
backgroundcolor=RedViolet!5!gray!10,
}
}
\declaretheoremstyle[
\declaretheoremstyle[
headfont=\bfseries,
headfont=\bfseries,
bodyfont=\normalfont\small,
bodyfont=\normalfont\small,
spaceabove=0pt,
spaceabove=0pt,
spacebelow=0pt,
spacebelow=0pt,
mdframed={style=mdblackbox2}
mdframed={style=mdblackbox2}
]{thmblackbox2}
]{thmblackbox2}
\newcommand{\listhack}{$\empty$\vspace{-2em}}
\newcommand{\listhack}{$\empty$\vspace{-2em}}
\fi
\declaretheorem[%
%%fakesection Theorem setup
\ifevanthm
\theoremstyle{definition}
%Branching here: the option secthm changes theorems to be labelled by section
\ifevanmdthm
\ifevansecthm
\declaretheorem[%
style=thmbluebox,name=Teorema,numberwithin=section]{theorem}
style=thmbluebox,name=Teorema,numberwithin=section]{theorem}
\else
\declaretheorem[%
\declaretheorem[style=thmgreenbox2,name=Lemma,sibling=theorem]{lemma}
style=thmbluebox,name=Teorema]{theorem}
\declaretheorem[style=thmredbox2,name=Proposizione,sibling=theorem]{proposition}
\fi
\declaretheorem[style=thmbluebox2,name=Corollario,sibling=theorem]{corollary}
\declaretheorem[style=thmgreenbox2,name=Lemma,sibling=theorem]{lemma}
\declaretheorem[style=thmbluebox,name=Teorema,numbered=no]{theorem*}
\declaretheorem[style=thmredbox2,name=Proposizione,sibling=theorem]{proposition}
\declaretheorem[style=thmgreenbox2,name=Lemma,numbered=no]{lemma*}
\declaretheorem[style=thmbluebox2,name=Corollario,sibling=theorem]{corollary}
\declaretheorem[style=thmredbox2,name=Proposizione,numbered=no]{proposition*}
\declaretheorem[style=thmbluebox,name=Teorema,numbered=no]{theorem*}
\declaretheorem[style=thmbluebox2,name=Corollario,numbered=no]{corollary*}
\declaretheorem[style=thmgreenbox2,name=Lemma,numbered=no]{lemma*}
\declaretheorem[style=thmgreenbox,name=Claim,sibling=theorem]{claim}
\declaretheorem[style=thmredbox2,name=Proposizione,numbered=no]{proposition*}
\declaretheorem[style=thmgreenbox,name=Claim,numbered=no]{claim*}
\declaretheorem[style=thmbluebox2,name=Corollario,numbered=no]{corollary*}
\declaretheorem[style=thmredbox,name=Esempio,sibling=theorem]{example}
\else
\declaretheorem[style=thmredbox,name=Esempio,numbered=no]{example*}
\ifevansecthm
\declaretheorem[style=thmblackbox, name=Definizione,sibling=theorem]{definition}
\declaretheorem[name=Teorema,numberwithin=section]{theorem}
\declaretheorem[style=thmblackbox, name=Definizione,numbered=no]{definition*}
\else
\declaretheorem[style=thmblackbox2,name=Osservazione,sibling=theorem]{remark}
\declaretheorem[name=Teorema]{theorem}
\declaretheorem[style=thmblackbox2,name=Osservazione,numbered=no]{remark*}
\fi
\declaretheorem[name=Congettura,sibling=theorem]{conjecture}
\declaretheorem[name=Lemma,sibling=theorem]{lemma}
\declaretheorem[name=Congettura,numbered=no]{conjecture*}
\declaretheorem[name=Proposizione,sibling=theorem]{proposition}
\declaretheorem[name=Esercizio,sibling=theorem]{exercise}
\declaretheorem[name=Corollario,sibling=theorem]{corollary}
\declaretheorem[name=Esercizio,numbered=no]{exercise*}
\declaretheorem[name=Teorema,numbered=no]{theorem*}
\declaretheorem[name=Asserzione,sibling=theorem]{fact}
\declaretheorem[name=Lemma,numbered=no]{lemma*}
\declaretheorem[name=Asserzione,numbered=no]{fact*}
\declaretheorem[name=Proposizione,numbered=no]{proposition*}
\declaretheorem[name=Problema,sibling=theorem]{problem}
\declaretheorem[name=Corollario,numbered=no]{corollary*}
\declaretheorem[name=Problema,numbered=no]{problem*}
\fi
\declaretheorem[name=Domanda,sibling=theorem]{ques}
\declaretheorem[name=Domanda,numbered=no]{ques*}
\ifevanmdthm
\declaretheorem[style=thmgreenbox,name=Claim,sibling=theorem]{claim}
\Crefname{claim}{Claim}{Claim}
\declaretheorem[style=thmgreenbox,name=Claim,numbered=no]{claim*}
\Crefname{conjecture}{Congettura}{Congetture}
\else
\Crefname{exercise}{Esercizio}{Esercizi}
\declaretheorem[name=Claim,sibling=theorem]{claim}
\Crefname{fact}{Asserzione}{Asserzioni}
\declaretheorem[name=Claim,numbered=no]{claim*}
\Crefname{problem}{Problema}{Problemi}
\fi
\Crefname{ques}{Domanda}{Domande}
\ifevanmdthm
\addtokomafont{partprefix}{\rmfamily}
\declaretheorem[style=thmredbox,name=Esempio,sibling=theorem]{example}
\renewcommand*{\partformat}{\color{purple}
\declaretheorem[style=thmredbox,name=Esempio,numbered=no]{example*}
\else
\declaretheorem[name=Esempio,sibling=theorem]{example}
\declaretheorem[name=Esempio,numbered=no]{example*}
\fi
% Remark-style theorems
%\theoremstyle{remark}
\ifevanmdthm
\declaretheorem[style=thmblackbox, name=Definizione,sibling=theorem]{definition}
\declaretheorem[style=thmblackbox, name=Definizione,numbered=no]{definition*}
\declaretheorem[style=thmblackbox2,name=Osservazione,sibling=theorem]{remark}
\declaretheorem[style=thmblackbox2,name=Osservazione,numbered=no]{remark*}
\else
\declaretheorem[name=Definizione,sibling=theorem]{definition}
\declaretheorem[name=Definizione,numbered=no]{definition*}
\declaretheorem[name=Osservazione,sibling=theorem]{remark}
\declaretheorem[name=Osservazione,numbered=no]{remark*}
\fi
\declaretheorem[name=Congettura,sibling=theorem]{conjecture}
\declaretheorem[name=Congettura,numbered=no]{conjecture*}
\declaretheorem[name=Esercizio,sibling=theorem]{exercise}
\declaretheorem[name=Esercizio,numbered=no]{exercise*}
\declaretheorem[name=Asserzione,sibling=theorem]{fact}
\declaretheorem[name=Asserzione,numbered=no]{fact*}
\declaretheorem[name=Problema,sibling=theorem]{problem}
\declaretheorem[name=Problema,numbered=no]{problem*}
\declaretheorem[name=Domanda,sibling=theorem]{ques}
\declaretheorem[name=Domanda,numbered=no]{ques*}
\ifevanpkg
\Crefname{claim}{Claim}{Claim}
\Crefname{conjecture}{Congettura}{Congetture}
\Crefname{exercise}{Esercizio}{Esercizi}
\Crefname{fact}{Asserzione}{Asserzioni}
\Crefname{problem}{Problema}{Problemi}
\Crefname{ques}{Domanda}{Domande}
\fi
\fi
%%fakesection Fancy section and chapter heads
\ifevancolorsec
\@ifundefined{KOMAClassName}{}{
\@ifundefined{chapter}{}{
\addtokomafont{partprefix}{\rmfamily}
\renewcommand*{\partformat}{\color{purple}
\scalebox{2.5}{\thepart}\enlargethispage{2em}}
\scalebox{2.5}{\thepart}\enlargethispage{2em}}
\addtokomafont{chapterprefix}{\raggedleft}
\RedeclareSectionCommand[beforeskip=0.5em]{chapter}
\renewcommand*{\sectionformat}%
\renewcommand*{\chapterformat}{\mbox{%
{\color{purple}\S\thesection\enskip}
\scalebox{1.5}{\chapappifchapterprefix{\nobreakspace}}%
\renewcommand*{\subsectionformat}%
\scalebox{2.718}{\color{purple}\thechapter}\enskip}}
{\color{purple}\S\thesubsection\enskip}
}
\renewcommand*{\subsubsectionformat}%
\renewcommand*{\sectionformat}%
{\color{purple}\S\thesubsubsection\enskip}
{\color{purple}\S\thesection\enskip}
\KOMAoptions{numbers=noenddot}
\renewcommand*{\subsectionformat}%
{\color{purple}\S\thesubsection\enskip}
\usepackage{listings}
\renewcommand*{\subsubsectionformat}%
\usepackage{mathrsfs}
{\color{purple}\S\thesubsubsection\enskip}
\usepackage{textcomp}
\KOMAoptions{numbers=noenddot}
\lstset{basicstyle=\ttfamily\scriptsize,
%\usetocstyle{KOMAlike}
}
\fi
%%fakesection Loads a bunch of useful packages (but allow disabling)
\ifevanpkg
\ifevanvonenabled
\IfFileExists{von.sty}{\usepackage{von}}{}
\fi
\usepackage{listings}
\usepackage{mathrsfs}
\usepackage{textcomp}
\lstset{basicstyle=\ttfamily\scriptsize,
backgroundcolor=\color{green!2!white},
backgroundcolor=\color{green!2!white},
breakatwhitespace=true,
breakatwhitespace=true,
breaklines=true,
breaklines=true,
@ -672,156 +434,39 @@
showstringspaces=false,
showstringspaces=false,
stringstyle=\color{orange},
stringstyle=\color{orange},
tabsize=4,
tabsize=4,
} % chktex 6
}
\lstdefinelanguage{gitcommit}{
alsoletter={:},
\usepackage[shortlabels]{enumitem}
morecomment=[l]{|},
\usepackage[obeyFinal,textsize=scriptsize,shadow]{todonotes}
morekeywords={commit,Author:,Date:,chore,doc,edit,feat,fix,polish,style,tests,},
\usepackage{textcomp}
sensitive=true,
\usepackage{multirow}
}
\usepackage{ellipsis}
\lstdefinelanguage{gitlog}{
\usepackage{mathtools}
morekeywords={chore,doc,edit,feat,fix,polish,style,tests,},
\usepackage{microtype}
morecomment=[s]{[}{]}, % chktex 9
\usepackage{xstring}
sensitive=true,
\usepackage{wrapfig}
}
\addtokomafont{subtitle}{\Large}
\usepackage[shortlabels]{enumitem}
\setkomafont{author}{\Large\scshape}
\usepackage[obeyFinal,textsize=scriptsize,shadow]{todonotes}
\setkomafont{date}{\Large\normalsize}
\usepackage{textcomp}
\usepackage{multirow}
\providecommand{\thetitle}{\@title}
\usepackage{ellipsis} % don't use ugly unicode ellipsis
\providecommand{\theauthor}{\@author}
% Tiny optimizations:
\providecommand{\thedate}{\@date}
\usepackage{mathtools}
\usepackage{microtype}
\usepackage[headsepline]{scrlayer-scrpage}
\usepackage{xstring}
\renewcommand{\headfont}{}
\usepackage{wrapfig}
\addtolength{\textheight}{3.14cm}
\ifevanbritish\usepackage[cleanlook,british]{isodate}\fi % day-first date
\setlength{\footskip}{0.5in}
\setlength{\headsep}{10pt}
% a list I like for walkthrough's --- Drew-style parts
\newlist{walk}{enumerate}{3}
\ihead{\footnotesize\textbf{\rightmark}}
\setlist[walk]{label=\bfseries (\alph*)}
\ohead{\footnotesize\textit{\thetitle}}
% list item for MO style rubrics
\newcommand{\worth}[1]{\def\hfill{\hskip 20pt plus 1fill}\dotfill%
\automark{section}
\IfEq{#1}{0}{\textbf{0~points}}%
\chead{}
{\textbf{\color{blue}#1~point\IfEndWith{#1}{1}{}{s}}}%
\cfoot{\pagemark}
\par}
\newcommand{\subworth}[1]{\def\hfill{\hskip 20pt plus 1fill}\dotfill%
\hfuzz=\maxdimen
\IfEq{#1}{0}{{\footnotesize0~points}}%
\tolerance=10000
{\textbf{\footnotesize#1~point\IfEndWith{#1}{1}{}{s}}}%
\hbadness=10000
\par}
\newlist{rubric}{enumerate}{2}
\setlist[rubric,1]{label=\Roman*.}
\setlist[rubric,2]{label=(\Roman{rubrici}.\alph*)}
\fi
%%fakesection \maketitle configuration
\@ifundefined{KOMAClassName}%
{} % do nothing outside KOMA class
{% If KOMA exists. . .
\addtokomafont{subtitle}{\Large}
\setkomafont{author}{\Large\scshape}
\setkomafont{date}{\Large\normalsize}
}
\providecommand{\thetitle}{\@title}
\providecommand{\theauthor}{\@author}
\providecommand{\thedate}{\@date}
%%fakesection Commutative diagrams support
\ifevandiagrams
\usepackage{tikz-cd}
\usetikzlibrary{decorations.pathmorphing}
\fi
%%fakesection Page setup
\ifevanfancy
\@ifundefined{KOMAClassName}
{
\usepackage{fancyhdr}
\setlength{\headheight}{0.75in}
\setlength{\oddsidemargin}{0in}
\setlength{\evensidemargin}{0in}
\setlength{\voffset}{-1.0in}
\setlength{\headsep}{10pt}
\setlength{\textwidth}{6.5in}
\setlength{\headwidth}{6.5in}
\setlength{\textheight}{8.75in}
\setlength{\parskip}{1ex plus 0.5ex minus 0.2ex}
\setlength{\footskip}{0.3in}
\ifevanhdr
\renewcommand{\headrulewidth}{0.5pt}
\renewcommand{\footrulewidth}{0.0pt}
\pagestyle{fancy}
\lhead{Gabriel Antonio Videtta}
\chead{}
\rhead{\nouppercase{\leftmark}}
\lfoot{}
\cfoot{\thepage}
\rfoot{}
\fi
}
{
\usepackage[headsepline]{scrlayer-scrpage}
\renewcommand{\headfont}{}
\addtolength{\textheight}{3.14cm}
\setlength{\footskip}{0.5in}
\setlength{\headsep}{10pt}
\ihead{\footnotesize\textbf{\theauthor} --- \thedate}
\automark{section}
\chead{}
\ohead{\footnotesize\textbf{\thetitle}}
\cfoot{\pagemark}
}
\fi
%%fakesection Unicode
\ifevanpkg
\ifluatex
\usepackage{fontspec}
% https://tex.stackexchange.com/a/572220/76888
\directlua{luaotfload.add_fallback
("evans_fallbacks",
{
"NotoColorEmoji:mode=harf;",
"Source Han Sans TW:style=Regular;",
"Noto Serif CJK SC:style=Regular;",
}
)}
\setmainfont{lmroman10-regular}[
BoldFont=lmroman10-bold,
ItalicFont=lmroman10-italic,
BoldItalicFont=lmroman10-bolditalic,
SlantedFont=lmromanslant10-regular,
BoldSlantedFont=lmromanslant10-bold,
SmallCapsFont=lmromancaps10-regular,
RawFeature={fallback=evans_fallbacks}
]
\setsansfont{lmsans10-regular}[
BoldFont=lmsans10-bold,
ItalicFont=lmsans10-oblique,
BoldItalicFont=lmsans10-boldoblique,
RawFeature={fallback=evans_fallbacks}
]
\else
\ifevanchinese
\usepackage[italian]{babel}
\usepackage[encapsulated]{CJK}
\usepackage{ucs}
\usepackage[utf8x]{inputenc}
\newenvironment{bsmi}{\begin{CJK}{UTF8}{bsmi}}{\end{CJK}}
\newcommand{\cn}[1]{\begin{bsmi}#1\end{bsmi}}
\AtBeginDocument{\begin{CJK}{UTF8}{bsmi}}
\AtEndDocument{\end{CJK}}
\fi
\fi
\fi
%%fakesection Hints
\ifevanhints
\usepackage{answers}
\Newassociation{hint}{hintitem}{hints}
\renewcommand{\solutionextension}{out}
\Opensolutionfile{hints}
\newcommand{\makehints}{\Closesolutionfile{hints}\input{hints.out}} % chktex 27
\fi
%%fakesection END MAIN SETUP
\fi