-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathspikey.sty
109 lines (94 loc) · 3.55 KB
/
spikey.sty
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
\ProvidesPackage{spikey}
% Macro package by Tianyu Du.
\RequirePackage[utf8]{inputenc}
\RequirePackage[english]{babel}
\RequirePackage{amsthm}
\RequirePackage{amsmath}
\RequirePackage{amssymb}
\RequirePackage{dsfont}
\RequirePackage{pifont} % http://ctan.org/pkg/pifont
% Change QED symbol to blacksquare
\renewcommand\qedsymbol{$\blacksquare$}
% ================ General Shortcuts ================
\newcommand{\tx}[1]{\text{{#1}}}
\newcommand{\mc}[1]{\mathcal{{#1}}}
\newcommand{\tbf}[1]{\textbf{#1}}
% ================ Mathematics: General ================
% Absolute Value
\newcommand{\abs}[1]{\big \vert {#1} \big \vert}
\DeclareMathOperator*{\argmax}{argmax}
\DeclareMathOperator*{\argmin}{argmin}
\newcommand{\cmark}[0]{\ding{51}}
\newcommand{\xmark}[0]{\ding{55}}
% Bold symbols for vector.
\newcommand{\vex}[0]{\textbf{x}}
\newcommand{\bfX}[0]{\textbf{X}}
\newcommand{\vey}[0]{\textbf{y}}
\newcommand{\vez}[0]{\textbf{z}}
\newcommand{\vea}[0]{\textbf{a}}
\newcommand{\veb}[0]{\textbf{b}}
\newcommand{\vep}[0]{\textbf{p}}
% ================ Mathematics: Linear Algebra ================
% TRANSformation
\newcommand{\trans}[3]{{#1}: {#2} \to {#3}}
% COORdinate.
\newcommand{\coor}[2]{[\vec{{#1}}]_{{#2}}}
% Transformation's MATrix representation
\newcommand{\tmat}[3]{[{#1}]_{{#2}}^{{#3}}}
% Vector SET, with index.
\newcommand{\vset}[3]{\{\vec{{#1}_{#2}}, \dots, \vec{{#1}_{#3}}\}}
% Scalar SET, with index.
\newcommand{\sset}[3]{\{{{#1}_{#2}}, \dots, {{#1}_{#3}}\}}
% Scalar TUPLE.
\newcommand{\stuple}[3]{({{#1}_{#2}}, \dots, {{#1}_{#3}})}
% INNER product.
\newcommand{\inner}[2]{\langle {#1}, {#2} \rangle}
% NORM.
\newcommand{\norm}[1]{\vert \vert {#1} \vert \vert}
\newcommand{\ve}[1]{\textbf{#1}}
\newcommand{\bs}[1]{\boldsymbol{#1}}
\newcommand{\red}[1]{\textcolor{red}{#1}}
\newcommand{\green}[1]{\textcolor{green}{#1}}
\newcommand{\blue}[1]{\textcolor{blue}{#1}}
\newcommand{\orange}[1]{\textcolor{orange}{#1}}
% ================ Mathematics: Spaces ================
\newcommand{\R}[0]{\mathbb{R}} % Real number field.
\newcommand{\C}[0]{\mathbb{C}} % Complex number field.
\newcommand{\Q}[0]{\mathbb{Q}} % Rational field.
\newcommand{\N}[0]{\mathbb{N}}
\newcommand{\Z}[0]{\mathbb{Z}}
\newcommand{\nnr}[0]{\mathbb{R}_{\geq0}}
\newcommand{\RM}[2]{M_{{#1} \times {#2}}(\mathbb{R})} % Real matrix space.
\newcommand{\M}[3]{M_{{#1} \times {#2}}({#3})} % Arbitary matrix space.
% ================ Mathematics: Calculus ================
% Partial Derivative
\newcommand{\pd}[2]{\frac{\partial{#1}}{\partial{#2}}}
\newcommand{\curl}[0]{\text{curl}}
\newcommand{\grad}[0]{\text{grad}}
\newcommand{\dive}[0]{\text{div}}
% ================ Statistics ================
% Indicator Function
\newcommand{\id}[1]{\mathds{1}\{{#1}\}}
% Expectation
\newcommand{\expect}[1]{\mathbb{E}[{#1}]}
\newcommand{\var}[1]{\mathbb{V}[{#1}]}
\newcommand{\prob}[1]{\mathbb{P}[{#1}]}
% ================ Economics ================
\newcommand{\pref}[0]{\succsim}
% ================ Theorems ================
\theoremstyle{definition}
\newtheorem{definition}{Definition}[section]
\newtheorem{theorem}{Theorem}[section]
\newtheorem{notation}{Notation}[section]
\newtheorem{corollary}{Corollary}[section]
\newtheorem{lemma}{Lemma}[section]
\newtheorem{proposition}{Proposition}[section]
\newtheorem{remark}{Remark}[section]
\newtheorem{assumption}{Assumption}[section]
\newtheorem{example}{Example}[section]
\newtheorem{property}{Property}[section]
\newtheorem{axiom}{Axiom}[section]
\newtheorem{rules}{Rule}[section]
% Experimental
\newcommand{\seq}[2]{({#1}_{#2})_{{#2}=1}^\infty}
\newcommand{\ser}[2]{\sum_{{#2}=1}^\infty {#1}_{#2}}