-
Notifications
You must be signed in to change notification settings - Fork 1
/
mystyle.sty
114 lines (91 loc) · 2.47 KB
/
mystyle.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
\usepackage[headheight=14pt]{geometry}
% ---------------------------
% packages
% ---------------------------
% AMS math symbol
\usepackage{amsmath}
\usepackage{amsbsy}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{amscd}
\usepackage{mathrsfs}
%\usepackage{mathptmx} % selects Times Roman as basic font
\usepackage{algorithmic, algorithm}
\usepackage{bm}
% text fonts
\usepackage{txfonts}
%\usepackage{helvet} % selects Helvetica as sans-serif font
%\usepackage{courier} % selects Courier as typewriter font
\usepackage[latin1]{inputenc}
%
% graphcis
\usepackage{graphicx}
\usepackage{subfigure}
\usepackage{tikz}
\usetikzlibrary{shapes,arrows,decorations.pathmorphing,backgrounds,positioning,fit,matrix,calc}
% other tools
\usepackage{hyperref}
\usepackage{type1cm}
%%\usepackage[normalem]{ulem}
\usepackage{soul}
%\usepackage{times}
\usepackage{url}
\usepackage{rotating}
\usepackage{makeidx}
\makeindex
\usepackage{multirow}
\usepackage{multicol}
\usepackage{enumerate}
\usepackage{xspace}
\usepackage{comment}
\usepackage{etoolbox}
%%
% ---------------------------
% Formats
% ---------------------------
% head
\usepackage{titling}
\usepackage{fancyhdr}
\pagestyle{fancy}
\lhead{\leftmark} % Chapter name on the top left.
\rhead{\theauthor} % Author name on the top right.
% page
\pagenumbering{arabic}
% ---------------------------
% Theorems etc.
% ---------------------------
\ifcsmacro{theorem}{}{
\newtheorem{theorem}{Theorem}[section]
}
\ifcsmacro{lemma}{}{
\newtheorem{lemma}[theorem]{Lemma}
}
\ifcsmacro{corollary}{}{
\newtheorem{corollary}[theorem]{Corollary}
}
\ifcsmacro{proposition}{}{
\newtheorem{proposition}[theorem]{Proposition}
}
%\ifcsmacro{assumption}{}{
%\newtheorem{assumption}[theorem]{Assumption}
%}
\newtheorem{assumption}{Assumption}
\renewcommand\theassumption{A\arabic{assumption}}
%\newtheorem{consequence}[equation]{Consequence}
%\newtheorem{conclusion}[equation]{Conclusion}
\newcommand{\Remark}{\noindent{\bf Remark.~}}
%\newtheorem{remark}[theorem]{Remark}
%\newtheorem{definition}[theorem]{Definition}
%\newtheorem{exercise}[theorem]{Exercise}
%\newtheorem{example}[theorem]{Example}
\def\proof{\par{\it Proof}. \ignorespaces}
\def\endproof{{\ \vbox{\hrule\hbox{\vrule
height1.3ex\hskip0.8ex\vrule}\hrule}}\par}
% ---------------------------
% Chapter and sections
% ---------------------------
\let\oldchapter\chapter
\def\chapter{%
\setcounter{exercise}{0}%
\oldchapter
}