author | Christian Urban <christian.urban@kcl.ac.uk> |
Sun, 29 Sep 2024 18:46:02 +0100 | |
changeset 965 | 94f5cce73a4f |
parent 922 | e86ea06e3b25 |
child 968 | d8d8911a3d6f |
permissions | -rw-r--r-- |
236
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
1 |
\usepackage{xcolor} |
399
5c1fbb39c93e
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
398
diff
changeset
|
2 |
%%\usepackage{fontspec} |
236
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
3 |
\usepackage[sc]{mathpazo} |
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
4 |
\usepackage{fontspec} |
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
5 |
\setmainfont[Ligatures=TeX]{Palatino Linotype} |
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
6 |
\usepackage{amssymb} |
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
7 |
\usepackage{amsmath} |
798 | 8 |
%\usepackage{menukeys} |
236
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
9 |
\definecolor{darkblue}{rgb}{0,0,0.6} |
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
10 |
\usepackage[colorlinks=true,urlcolor=darkblue,linkcolor=darkblue]{hyperref} |
618 | 11 |
\usepackage{soul} |
743 | 12 |
\usepackage{marginnote} |
13 |
\usepackage{fontawesome5} |
|
236
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
14 |
|
400
e4afe3f46c29
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
399
diff
changeset
|
15 |
%%% for regular expressions and values |
398
c8ce95067c1a
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
395
diff
changeset
|
16 |
\newcommand{\ZERO}{\mbox{\bf 0}} |
c8ce95067c1a
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
395
diff
changeset
|
17 |
\newcommand{\ONE}{\mbox{\bf 1}} |
400
e4afe3f46c29
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
399
diff
changeset
|
18 |
\newcommand{\Left}{\textit{Left}} |
669 | 19 |
\newcommand{\Right}{\textit{Right}} |
433
c08290ee4f1f
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
416
diff
changeset
|
20 |
\newcommand{\Der}{\textit{Der}} |
c08290ee4f1f
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
416
diff
changeset
|
21 |
\newcommand{\der}{\textit{der}} |
c08290ee4f1f
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
416
diff
changeset
|
22 |
\newcommand{\Ders}{\textit{Ders}} |
c08290ee4f1f
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
416
diff
changeset
|
23 |
\newcommand{\ders}{\textit{ders}} |
669 | 24 |
\newcommand{\inj}{\textit{inj}} |
25 |
\newcommand{\nullable}{\textit{nullable}} |
|
398
c8ce95067c1a
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
395
diff
changeset
|
26 |
|
295
19f23c4c2167
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
239
diff
changeset
|
27 |
|
239
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
28 |
|
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
29 |
|
743 | 30 |
%%% url pointers |
756 | 31 |
\newcommand{\hv}[1]{\href{#1}{\faFilm}} |
754 | 32 |
\newcommand{\hr}[1]{\href{#1}{\faHandPointRight[regular]}} |
743 | 33 |
\newcommand{\here}[1]{\marginnote{\href{#1}{\faHandPointRight[regular]}}} |
34 |
\newcommand{\video}[1]{\marginnote{\href{#1}{\faFilm}}} |
|
35 |
\newcommand{\alert}{\reversemarginpar\marginpar{\mbox{}\hfill\textcolor{red}{\faExclamationTriangle}}} |
|
36 |
||
37 |
||
239
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
38 |
\newcommand{\dn}{\stackrel{\mbox{\scriptsize def}}{=}} |
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
39 |
\newcommand{\defn}[1]{\textit{\textbf{#1}}} |
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
40 |
\newcommand{\dq}[1]{\mbox{\tt{"}}#1\mbox{\tt{"}}} |
68d98140b90b
added notation handout
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
236
diff
changeset
|
41 |
|
236
34e901c529ce
farmed out style files
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
diff
changeset
|
42 |
\definecolor{codegray}{gray}{0.9} |
331
a2c18456c6b7
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
327
diff
changeset
|
43 |
|
395
e57d3d92b856
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
394
diff
changeset
|
44 |
\makeatletter |
e57d3d92b856
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
394
diff
changeset
|
45 |
\def\fnote{\gdef\@thefnmark{}\@footnotetext} |
e57d3d92b856
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
394
diff
changeset
|
46 |
\makeatother |
e57d3d92b856
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
394
diff
changeset
|
47 |
|
908 | 48 |
%% a line after figures |
49 |
\usepackage{caption} |
|
50 |
\DeclareCaptionFormat{custom} |
|
51 |
{% |
|
52 |
\textbf{#1#2}#3 |
|
53 |
\raisebox{0.5em}{\rule{\textwidth}{0.1mm}} |
|
54 |
} |
|
55 |
\captionsetup{format=custom} |
|
56 |
||
57 |
%\usepackage{float} |
|
58 |
%\newcommand{\topfigrule}{\vspace*{1pt}\noindent\rule{\columnwidth}{0.4pt}\vspace{2.6pt}} |
|
59 |
%\newcommand{\dblfigrule}{\vspace*{1pt}\noindent\rule{\columnwidth}{0.4pt}\vspace{2.6pt}} |
|
60 |
%\newcommand{\botfigrule}{\vspace*{1pt}\noindent\rule{\columnwidth}{0.4pt}\vspace{2.6pt}} |
|
61 |
||
62 |
||
63 |
||
331
a2c18456c6b7
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
327
diff
changeset
|
64 |
\newcommand{\HEADER}{{\bf Please submit your solutions via email. Please submit |
743 | 65 |
only PDFs! Every solution should be preceeded by the corresponding |
461 | 66 |
question text, like: |
347
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
67 |
|
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
68 |
\begin{center} |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
69 |
\begin{tabular}{ll} |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
70 |
Q$n$: & \ldots a difficult question from me\ldots\\ |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
71 |
A: & \ldots an answer from you \ldots\\ |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
72 |
Q$n+1$ & \ldots another difficult question\ldots\\ |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
73 |
A: & \ldots another brilliant answer from you\ldots |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
74 |
\end{tabular} |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
75 |
\end{center} |
22b5294daa2a
updated hws
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
331
diff
changeset
|
76 |
|
438
84608b4b3578
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
433
diff
changeset
|
77 |
\noindent Solutions will only be accepted until 20th December! Please send only |
394
2f9fe225ecc8
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
347
diff
changeset
|
78 |
one homework per email.}\bigskip} |
403
564f7584eff1
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
400
diff
changeset
|
79 |
|
564f7584eff1
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
400
diff
changeset
|
80 |
\newcommand{\POSTSCRIPT}{ |
564f7584eff1
updated
Christian Urban <christian dot urban at kcl dot ac dot uk>
parents:
400
diff
changeset
|
81 |
{\bf (Optional)} This question is for you to provide |
416 | 82 |
regular feedback to me: for example |
83 |
what were the most interesting, least interesting, or confusing |
|
84 |
parts in this lecture? Any problems with my Scala code? Please |
|
618 | 85 |
feel free to share any other questions or concerns. Also, all my |
86 |
material is \st{crap} imperfect. If you have any suggestions for |
|
743 | 87 |
improvement, I am very grateful to hear.\medskip |
88 |
||
89 |
If *you* want to share anything (code, videos, links), you are |
|
922 | 90 |
encouraged to do so. Just drop me an email or send a message to the Forum.} |
719 | 91 |
|
92 |
||
93 |
% CW deadlines |
|
915 | 94 |
\def\cwONE{16 October} |
95 |
\def\cwTWO{10 November} |
|
96 |
\def\cwTHREE{27 November} |
|
97 |
\def\cwFOUR{14 December} |
|
98 |
\def\cwFIVE{12 January} |
|
719 | 99 |
|
876 | 100 |
%%\def\cwISABELLE{11 December} |
917 | 101 |
|
102 |
||
103 |
%%%%%%%%%%%%%% |
|
104 |
%% lualatex testing commandline arguments |
|
105 |
\newcommand{\luaif}[1]{\ifnum1=\directlua{if #1 then tex.sprint(1) else tex.sprint(0) end} } |
|
106 |
||
107 |
\luaif{arg[2] == "sol"} |
|
108 |
\newcommand{\solution}[1]{% |
|
109 |
\begin{quote}\sf% |
|
110 |
#1% |
|
111 |
\end{quote}} \else |
|
112 |
\newcommand{\solution}[1]{} |
|
113 |
\fi |