-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexample.tex
71 lines (49 loc) · 2.36 KB
/
example.tex
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
\documentclass[a4paper, 12pt]{report}
\newcommand{\ispdfversion}{true}
\input{preamble.tex}
\begin{document}
\chapter{An Example Chapter} % (fold)
\label{cha:an_example_chapter}
In this chapter we demonstrate the features of the preamble.tex file. Section~\ref{sec:example_environment_and_mathematics_layout} covers the use of the example environment and what mathematics looks like, while Section~\ref{sec:algorithm_and_a_quotation} shows the Algorithm environment and a quotation.
\section{Example environment and mathematics layout} % (fold)
\label{sec:example_environment_and_mathematics_layout}
\lipsum[1]
\begin{example}
Let $f=yx-x^2+x$ and $g=2y+x+1 \; \in \Q[x,y]$. We use degree lexicographic order with $y>x$. Dividing $f$ by $g$ gives us:
\[
\setlength{\arraycolsep}{3pt}
\renewcommand{\arraystretch}{1.3}
\begin{array}{r r r r r r r r r r r r}
&&&&& yx &&& - & x^2 & + & x \\
\cline{2-12}
\multicolumn{1}{r|}{2y+x+1}%
& 2y^2x & - & yx^2 & + & 3yx \\
\end{array}
\]
In reduction notation this division looks as follows:
\[
f \myrightarrow{g} -2yx^2+2yx \myrightarrow{g} 2yx+x^3+x^2 \myrightarrow{g} x^3-x.
\]
\end{example}
Math numbers are set $0123456789$, normal numbers are set 0123456789.
% section example_environment_and_mathematics_layout (end)
\section{Algorithm and a quotation} % (fold)
\label{sec:algorithm_and_a_quotation}
\begin{algorithm}[Multivariate Division Algorithm]
\label{alg:multi}
Input: $f,f_1,\ldots,f_t \in \F[x_1,\ldots,x_n]$ with $f_i\neq 0 \; (1\leq i\leq t)$.
Output: $u_1,\ldots,u_t,r \in \F[x_1,\ldots,x_n]$ such that $f = u_1f_1 + \ldots + u_tf_t + r$, $r$ is reduced with respect to $\{f_1,\ldots,f_t\}$ and $\mathrm{lp}(f) = \max(\mathrm{lp}(f_i),\mathrm{lp}(u_i),\mathrm{lp}(r))$.
Initialisation: $u_i:=0$, $r:=0$, $h=f$.
While $h\neq 0$ Do
Loop
\end{algorithm}
\begin{shadequote}
Alice was beginning to get very tired of sitting by her sister on the
bank, and of having nothing to do: once or twice she had peeped into the
book her sister was reading, but it had no pictures or conversations in
it, `and what is the use of a book,' thought Alice `without pictures or
conversation?'
\end{shadequote}
% section algorithm_and_a_quotation (end)
% chapter an_example_chapter (end)
\end{document}