latex-setup

My personal LaTeX setup 🦁️⚙️

preamble-common.tex (4897B)

  1 %                                 _     _                                
  2 %  _ __  _ __ ___  __ _ _ __ ___ | |__ | | ___        ___ ___  _ __ ___  
  3 % | '_ \| '__/ _ \/ _` | '_ ` _ \| '_ \| |/ _ \_____ / __/ _ \| '_ ` _ \ 
  4 % | |_) | | |  __/ (_| | | | | | | |_) | |  __/_____| (_| (_) | | | | | |
  5 % | .__/|_|  \___|\__,_|_| |_| |_|_.__/|_|\___|      \___\___/|_| |_| |_|
  6 % |_|                                                                    
  7 %                         _            
  8 %  _ __ ___   ___  _ __  | |_ _____  __
  9 % | '_ ` _ \ / _ \| '_ \ | __/ _ \ \/ /
 10 % | | | | | | (_) | | | || ||  __/>  < 
 11 % |_| |_| |_|\___/|_| |_(_)__\___/_/\_\
 12 %                                      
 13 % Pablo (C) 2022
 14 
 15 \usepackage{amsmath, amssymb, amsthm, stmaryrd, mathrsfs, gensymb, dsfont}
 16 \usepackage{mathtools, adjustbox}
 17 \usepackage[scr=esstix,cal=boondox]{mathalfa}
 18 \usepackage{enumitem, xfrac, xcolor, cancel, multicol, tabularx, relsize}
 19 \usepackage{fancyvrb, hyperref, csquotes}
 20 \usepackage{xalgebra, xtopology, xgeometry, functional, capitalgreekall}
 21 \usepackage{ytableau}
 22 \usepackage[backend=biber]{biblatex}
 23 \usepackage{pgfplots, tikz, tikz-cd}
 24 \usepackage{graphicx, wrapfig}
 25 \usepackage{xparse}
 26 \usepackage[normalem]{ulem}
 27 \usepackage{minted}
 28 
 29 % Set the color scheme used by minted
 30 \usemintedstyle{friendly}
 31 
 32 % Configure graphics
 33 \usetikzlibrary{calc, shadows.blur, shapes.geometric, patterns, arrows}
 34 \pgfplotsset{compat=1.16}
 35 
 36 % Double struck letters
 37 % The following is kept besides \AA being already defined because I don't care
 38 % abaut Å
 39 \renewcommand{\AA}{\mathbb{A}}   % Double struck A
 40 \newcommand{\BB}{\mathbb{B}}     % Double struck B
 41 \newcommand{\CC}{\mathbb{C}}     % Double struck C
 42 \newcommand{\DD}{\mathbb{D}}     % Double struck D
 43 \newcommand{\EE}{\mathbb{E}}     % Double struck E
 44 \newcommand{\FF}{\mathbb{F}}     % Double struck F
 45 \newcommand{\GG}{\mathbb{G}}     % Double struck G
 46 \newcommand{\HH}{\mathbb{H}}     % Double struck H
 47 \newcommand{\II}{\mathbb{I}}     % Double struck I
 48 \newcommand{\JJ}{\mathbb{J}}     % Double struck J
 49 \newcommand{\KK}{\mathbb{K}}     % Double struck K
 50 \newcommand{\LL}{\mathbb{L}}     % Double struck L
 51 \newcommand{\MM}{\mathbb{M}}     % Double struck M
 52 \newcommand{\NN}{\mathbb{N}}     % Double struck N
 53 \newcommand{\OO}{\mathbb{O}}     % Double struck O
 54 \newcommand{\PP}{\mathbb{P}}     % Double struck P
 55 \newcommand{\QQ}{\mathbb{Q}}     % Double struck Q
 56 \newcommand{\RR}{\mathbb{R}}     % Double struck R
 57 % The following is ommited because LaTeX keeps complaining about \SS not being
 58 % allowed in mathmode
 59 % \renewcommand{\SS}{\mathbb{S}} % Double struck S
 60 \newcommand{\TT}{\mathbb{T}}     % Double struck T
 61 \newcommand{\UU}{\mathbb{U}}     % Double struck U
 62 \newcommand{\VV}{\mathbb{V}}     % Double struck V
 63 \newcommand{\WW}{\mathbb{W}}     % Double struck W
 64 \newcommand{\XX}{\mathbb{X}}     % Double struck X
 65 \newcommand{\YY}{\mathbb{Y}}     % Double struck Y
 66 \newcommand{\ZZ}{\mathbb{Z}}     % Double struck Z
 67 \newcommand{\hh}{\mathds{h}}     % Double struck h
 68 \newcommand{\kk}{\mathds{k}}     % Double struck k
 69 
 70 % Use \blacksquare for \qed
 71 \renewcommand{\qedsymbol}{\ensuremath{\blacksquare}}
 72 
 73 % Only use \smallsetminus
 74 \renewcommand{\setminus}{\smallsetminus}
 75 
 76 % Make the \mid symbol taller (this is useful for Group Theory)
 77 \renewcommand{\mid}{\,\mathlarger{\mathlarger{\mathchar"326A}}\,}
 78 \renewcommand{\nmid}{\,\mathlarger{\mathlarger{\mathchar"352D}}\,}
 79 
 80 % Get propper inequality symbols
 81 \renewcommand{\leq}{\leqslant}
 82 \renewcommand{\le}{\leqslant}
 83 \renewcommand{\geq}{\geqslant}
 84 \renewcommand{\ge}{\geqslant}
 85 \renewcommand{\preceq}{\preccurlyeq}
 86 \renewcommand{\succeq}{\succcurlyeq}
 87 
 88 % Add missing arrows
 89 \newcommand{\longhookrightarrow}{\lhook\joinrel\longrightarrow}
 90 \newcommand{\longhookleftarrow}{\longleftarrow\joinrel\rhook}
 91 \DeclareRobustCommand\longtwoheadrightarrow
 92   {\relbar\joinrel\twoheadrightarrow}
 93 
 94 % Fix the subset symbol
 95 \renewcommand{\subset}{\subseteq}
 96 
 97 % Redefine \bar
 98 \renewcommand{\bar}{\overline}
 99 
100 % A semantic alternative to \textbf
101 \newcommand{\strong}[1]{\textbf{#1}}
102 
103 % Set cardinal
104 \newcommand{\card}[1]{\left|\nobreak#1\nobreak\right|}
105 
106 % Minus sign with a dot over it. Usefull for typsetting saturated subtraction
107 \def\dotminus{\mathbin{\ooalign{\hss\raise1ex\hbox{.}\hss\cr
108   \mathsurround=0pt$-$}}}
109 
110 % Empty macro (it's usefull for typesetting Young diagrams)
111 \newcommand{\void}{ }
112 
113 % Display long arrows instead of short ones
114 \renewcommand{\to}{\longrightarrow}
115 \renewcommand{\mapsto}{\longmapsto}
116 \renewcommand{\To}{\Longrightarrow}
117 
118 % Fix the goddamn \chi and \wp macros!
119 % For some reason the default LaTeX fonts place this characters much lower than
120 % where people actually expect them to be. This new definitions place them in
121 % with the appropriate spacing
122 \renewcommand{\chi}{\ensuremath \raisebox{\depth}{$\mathchar"11F$}}
123 \renewcommand{\wp}{\ensuremath \raisebox{\depth}{$\mathchar"17D$}}
124