-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdefault.tex
More file actions
108 lines (86 loc) · 4.49 KB
/
default.tex
File metadata and controls
108 lines (86 loc) · 4.49 KB
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
\documentclass[leqno]{article}
\usepackage{fancyhdr, framed, listings, graphicx, amsmath, ulem, caption, amsthm, tabu, tikz, enumitem, lipsum, listings, hyperref, lastpage, tabularx, fontenc, centernot, mathtools, pgfgantt, multirow, cancel, parskip}
\DeclarePairedDelimiter{\ceil}{\lceil}{\rceil}
\usepackage[T1]{fontenc}
\usepackage[bitstream-charter]{mathdesign}
\usepackage[margin=1in]{geometry}
\def\ojoin{\setbox0=\hbox{$\bowtie$}%
\rule[-.02ex]{.25em}{.4pt}\llap{\rule[\ht0]{.25em}{.4pt}}}
\def\leftouterjoin{\mathbin{\ojoin\mkern-5.8mu\bowtie}}
\def\rightouterjoin{\mathbin{\bowtie\mkern-5.8mu\ojoin}}
\def\fullouterjoin{\mathbin{\ojoin\mkern-5.8mu\bowtie\mkern-5.8mu\ojoin}}
\newcommand{\semijoin}{\ltimes}
\newcommand{\rightsemijoin}{\rtimes}
\newcommand{\antisemijoin}{\overline{\ltimes}}
\pagestyle{fancy}
\newcommand{\lastpage}{\pageref{LastPage}}
\def\ojoin{\setbox0=\hbox{$\bowtie$}%
\rule[-.02ex]{.25em}{.4pt}\llap{\rule[\ht0]{.25em}{.4pt}}}
\def\leftouterjoin{\mathbin{\ojoin\mkern-5.8mu\bowtie}}
\def\rightouterjoin{\mathbin{\bowtie\mkern-5.8mu\ojoin}}
\def\fullouterjoin{\mathbin{\ojoin\mkern-5.8mu\bowtie\mkern-5.8mu\ojoin}}
\newcommand{\studentName}{Kahlil Oppenheimer}
\newcommand{\courseNumber}{COSI 30A}
\newcommand{\courseTitle}{Theory of Computation}
\newcommand{\assignmentType}{Problem Set}
\newcommand{\assignmentNum}{1}
\newcommand{\assignmentTitle}{\assignmentType \ \assignmentNum}
\newcommand{\assignmentDueDate}{9/15/14}
\renewcommand{\and}{\wedge}
\newcommand{\nott}{\neg}
\newcommand{\imply}{\rightarrow}
\newcommand{\orr}{\vee}
\newenvironment{blockquote}{%
\par%
\medskip
\leftskip=4em\rightskip=2em%
\noindent\ignorespaces}{%
\par\medskip}
\newcommand{\njoin}{\bowtie}
\lhead{\studentName}
\chead{\courseNumber\ - \courseTitle}
\rhead{\today}
\lfoot{\assignmentTitle}
\cfoot{Page \thepage/\lastpage}
\rfoot{Due \assignmentDueDate}
\newtheorem{theorem}{Theorem}
\newtheorem{definition}{Definition}
\usetikzlibrary{shadows,calc}
% code adapted from http://tex.stackexchange.com/a/11483/3954
% some parameters for customization
\def\shadowshift{3pt,-3pt}
\def\shadowradius{6pt}
\colorlet{innercolor}{black!60}
\colorlet{outercolor}{gray!05}
% this draws a shadow under a rectangle node
\newcommand\drawshadow[1]{
\begin{pgfonlayer}{shadow}
\shade[outercolor,inner color=innercolor,outer color=outercolor] ($(#1.south west)+(\shadowshift)+(\shadowradius/2,\shadowradius/2)$) circle (\shadowradius);
\shade[outercolor,inner color=innercolor,outer color=outercolor] ($(#1.north west)+(\shadowshift)+(\shadowradius/2,-\shadowradius/2)$) circle (\shadowradius);
\shade[outercolor,inner color=innercolor,outer color=outercolor] ($(#1.south east)+(\shadowshift)+(-\shadowradius/2,\shadowradius/2)$) circle (\shadowradius);
\shade[outercolor,inner color=innercolor,outer color=outercolor] ($(#1.north east)+(\shadowshift)+(-\shadowradius/2,-\shadowradius/2)$) circle (\shadowradius);
\shade[top color=innercolor,bottom color=outercolor] ($(#1.south west)+(\shadowshift)+(\shadowradius/2,-\shadowradius/2)$) rectangle ($(#1.south east)+(\shadowshift)+(-\shadowradius/2,\shadowradius/2)$);
\shade[left color=innercolor,right color=outercolor] ($(#1.south east)+(\shadowshift)+(-\shadowradius/2,\shadowradius/2)$) rectangle ($(#1.north east)+(\shadowshift)+(\shadowradius/2,-\shadowradius/2)$);
\shade[bottom color=innercolor,top color=outercolor] ($(#1.north west)+(\shadowshift)+(\shadowradius/2,-\shadowradius/2)$) rectangle ($(#1.north east)+(\shadowshift)+(-\shadowradius/2,\shadowradius/2)$);
\shade[outercolor,right color=innercolor,left color=outercolor] ($(#1.south west)+(\shadowshift)+(-\shadowradius/2,\shadowradius/2)$) rectangle ($(#1.north west)+(\shadowshift)+(\shadowradius/2,-\shadowradius/2)$);
\filldraw ($(#1.south west)+(\shadowshift)+(\shadowradius/2,\shadowradius/2)$) rectangle ($(#1.north east)+(\shadowshift)-(\shadowradius/2,\shadowradius/2)$);
\end{pgfonlayer}
}
% create a shadow layer, so that we don't need to worry about overdrawing other things
\pgfdeclarelayer{shadow}
\pgfsetlayers{shadow,main}
\newsavebox\mybox
\newlength\mylen
\newcommand\shadowimage[2][]{%
\setbox0=\hbox{\includegraphics[#1]{#2}}
\setlength\mylen{\wd0}
\ifnum\mylen<\ht0
\setlength\mylen{\ht0}
\fi
\divide \mylen by 120
\def\shadowshift{\mylen,-\mylen}
\def\shadowradius{\the\dimexpr\mylen+\mylen+\mylen\relax}
\begin{tikzpicture}
\node[anchor=south west,inner sep=0] (image) at (0,0) {\includegraphics[#1]{#2}};
\drawshadow{image}
\end{tikzpicture}}