Contact
CoCalc Logo Icon
StoreFeaturesDocsShareSupport News AboutSign UpSign In
| Download
Views: 16658
1
\documentclass{beamer}
2
\usepackage{graphicx}
3
\usepackage{sagetex}
4
\usepackage{url}
5
6
\mode<presentation> {
7
\usetheme{Madrid}
8
}
9
10
\title[LaTeX, part 1]{Using \LaTeX{} in SageMathCloud (part 1)}
11
\author[Kiran Kedlaya (lecturer: Alina)]{Kiran Kedlaya (guest lecturer: Alina Bucur)}
12
\institute[UCSD]{University of California, San Diego}
13
\date{January 23, 2017}
14
15
\begin{document}
16
17
\begin{frame}
18
\titlepage
19
20
Lecture 6 from Math 152: Intro to Mathematical Software (University of California, San Diego \\
21
22
based on lectures by William Stein, University of Washington
23
24
\end{frame}
25
26
27
28
\begin{frame}
29
\frametitle{Announcements}
30
\begin{block}{Announcements}
31
\begin{enumerate}
32
\item Discussion sections meet as usual this week. Please attend your assigned section.
33
\item No instructor office hours this Tuesday. TA office hours meet as usual.
34
\item HW 2 due Tuesday, January 24 at 8pm. Correction: problem 3c should read ``The set of positive integers $n<1000$ such that $n^3 \equiv 1 \pmod{3}$.''
35
\item HW 2 peer evaluations due Thursday, January 26 at 8pm.
36
\item We are still monitoring the waitlist. We will email you if space becomes available.
37
\end{enumerate}
38
\end{block}
39
\end{frame}
40
41
42
\begin{frame}
43
\frametitle{General Remarks about \LaTeX{}}
44
\begin{block}{\LaTeX{}...}
45
\begin{enumerate}
46
\item Create professional quality documents involving mathematics. Most research mathematicians (and many scholars in nearby disciplines) use \LaTeX for writing their papers.
47
\item Completely open source and free. You can install it anywhere.
48
\item There are many ways to use \LaTeX, but SageMathCloud is one of the easiest for beginners.
49
\end{enumerate}
50
\end{block}
51
\end{frame}
52
53
\begin{frame}
54
\frametitle{\LaTeX{} Tutorial: first steps}
55
\begin{block}{Do the following}
56
\begin{enumerate}
57
\item Create a new blank latex document.
58
\item Edit it, changing the title and your name, and seeing the result to the right.
59
\item Find a random math-related wikipedia article, and copy/paste a paragraph of text into your document (this shouldn't work too well, but gives you some math to play with).
60
\item Try out forward and inverse search.
61
\item Make errors and see them listed under issues.
62
\item Download the PDF.
63
\item Click build, then latex to see the output.
64
\item Change preview zoom and resolution.
65
\end{enumerate}
66
\end{block}
67
68
\end{frame}
69
70
\begin{frame}[fragile]
71
\frametitle{\LaTeX{} Tutorial: next steps}
72
\begin{block}{Do the following}
73
\begin{enumerate}
74
\item In your document, type some formulas surrounded by dollar signs. Try each of the following and some variations on them:
75
\item \verb|$x^3$|
76
\item \verb|$\sin(x^\pi)$|
77
\item \verb|$e^{2\pi i}$|
78
\item \verb|$\frac{2}{3 + x}$|
79
\item \verb|$1 + 2 + \cdots + n$|
80
\item \verb|$\sum_{i=1}^{n} i$|
81
\item \verb|$\int_{0}^{\pi} \sin(x)$|
82
\item \verb|$\sqrt{x^3 + 2}$|
83
\end{enumerate}
84
\end{block}
85
\end{frame}
86
87
88
\begin{frame}[fragile]
89
\frametitle{\LaTeX{} Tutorial: sagetex}
90
\begin{block}{Do the following}
91
\begin{enumerate}
92
\item Put \verb|\usepackage{sagetex}| in the {\bf preamble} of your
93
latex document. This means put it after \verb|\documentclass...| and before \verb|\begin{document}|.
94
95
\item Try typing this formula in: \verb|$2018 = \sage{factor(2018)}$|.
96
97
\item Once that works, try
98
some things from \url{http://mirrors.ibiblio.org/CTAN/macros/latex/contrib/sagetex/sagetexpackage.pdf}
99
100
\item \verb|\sageplot[width=.7\textwidth]{plot(sin,0,1)}|
101
102
\end{enumerate}
103
\end{block}
104
\end{frame}
105
106
\begin{frame}
107
\frametitle{Plot}
108
\sageplot[width=.7\textwidth]{plot(sin,0,2*pi)}
109
\end{frame}
110
111
\end{document}
112
113
114