-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlec09.html
469 lines (441 loc) · 20.1 KB
/
lec09.html
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
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"
/>
<title>APMA E2000 - Linearization</title>
<link rel="stylesheet" href="reveal.js/dist/reset.css" />
<link rel="stylesheet" href="reveal.js/dist/reveal.css" />
<link rel="stylesheet" href="reveal.js/dist/theme/dracula.css" />
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.2/css/all.min.css"
/>
<!-- local styles -->
<link rel="stylesheet" href="css/mvc-slides.css" />
<!-- Theme used for syntax highlighted code -->
<link rel="stylesheet" href="reveal.js/plugin/highlight/monokai.css" />
<link
rel="stylesheet"
type="text/css"
href="https://jsxgraph.org/distrib/jsxgraph.css"
/>
<script
type="text/javascript"
src="https://jsxgraph.org/distrib/jsxgraphcore.js"
></script>
</head>
<body>
<div class="reveal">
<div class="slides">
<section>
<section>
<h3 class="framelabel">Lecture 09</h3>
<h1>Linearization</h1>
<h2>APMA E2000</h2>
<div class="r-stretch"></div>
<p style="text-align: right">
Drew Youngren <code>[email protected]</code>
</p>
</section>
<section>
<!-- Set up standard LaTeX macros -->
$\gdef\RR{\mathbb{R}}$ $\gdef\vec{\mathbf}$
$\gdef\bv#1{\begin{bmatrix} #1 \end{bmatrix}}$
$\gdef\proj{\operatorname{proj}}$ $\gdef\comp{\operatorname{comp}}$
<h2>Announcements</h2>
<ul>
<!-- <li class="fragment">
Review session tonight (see Ed Discussions for link)
</li> -->
<li class="fragment">Recitation 5 this week</li>
<li class="fragment">
Quiz 3 this week
<ul>
<li>Scalar fields and partial derivatives</li>
</ul>
</li>
<li class="fragment">HW5 due next Tues</li>
<li class="fragment">Midterm 1 Thursday, 10/10.</li>
</ul>
</section>
</section>
<section>
<section>
<h1>1-minute review</h1>
</section>
<section>
<h6 class="framelabel">Partial $\partial$erivatives</h6>
<p class="r-fit-text">
The <strong>partial derivative</strong> of a function
$f(x_1,\ldots,x_n)$ with respect to $x_i$ is \[\frac{\partial
f}{\partial x_i} = \lim_{h\to 0}
\frac{f(x_1,\ldots,x_i+h,\ldots,x_n) - f(x_1,\ldots,x_n)}{h}.\]
</p>
</section>
</section>
<section>
<section>
<h2>Linear Functions & Differentiability</h2>
</section>
<section>
<p>
A <strong>linear function</strong> on $\RR^n$ has the form
\[L(x_1, \ldots, x_n) = a_0 + \sum_{i=1}^n a_i x_i\] where the
$a_i$'s are constants.
</p>
<div class="r-stretch"></div>
<p class="fragment"><sup>*</sup>really <em>affine</em> linear</p>
</section>
<section>
<h6 class="framelabel">Key Example</h6>
<p>
In one variable, a linear function $L(x)$ is one whose graph is a
<em>line</em>\[y = ax + b.\]
</p>
<p class="fragment">
In two variables, a
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SG93K1RvJm9iajBfa2luZD1ncmFwaCZvYmowX2NvbG9yPSUyMzBkMDg4NyZvYmowX3BhcmFtc19hPS0yJm9iajBfcGFyYW1zX2I9MiZvYmowX3BhcmFtc19jPS0yJm9iajBfcGFyYW1zX2Q9MiZvYmowX3BhcmFtc196PTElMkYyK3grLSszJTJGNCt5KyUyQisxJTJGMyZvYmowX3BhcmFtc190MD0wJm9iajBfcGFyYW1zX3QxPTE="
target="_blank"
rel="noopener noreferrer"
>linear function</a
>
$L(x,y)$ is one whose graph is a <em>plane</em> \[z = ax + by + c.
\]
</p>
</section>
<section>
<h3 class="framelabel">Differentiability</h3>
<div>
<div class="container">
<div class="col">
<p>
In one dimension, a function $f(x)$ is differentiable at $a$
if $f'(a)$ exists.
</p>
<p class="fragment">
Graphically, this means the graph resembles a line at small
scales.
</p>
</div>
<div class="col">
<div
id="box-diffy"
class="jxgbox"
style="width: 500px; height: 500px"
></div>
</div>
</div>
</div>
<script src="js/diffy-curve.js" type="text/javascript"></script>
</section>
<section>
<h3 class="framelabel">Differentiability</h3>
<p>
In 2-D, a function $f(x,y)$ is differentiable at a point if its
graph looks like a plane close-up.
</p>
<h6 class="framelable fragment">
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SW50cm8mb2JqMF9raW5kPWdyYXBoJm9iajBfY29sb3I9JTIzMzIzMmZmJm9iajBfcGFyYW1zX2E9LTImb2JqMF9wYXJhbXNfYj0yJm9iajBfcGFyYW1zX2M9LTImb2JqMF9wYXJhbXNfZD0yJm9iajBfcGFyYW1zX3o9JTI4eCU1RTIrJTJCK3klNUUyJTI5JTJGJTI4MSslMkIreCU1RTIrJTJCK3klNUUyJTI5Jm9iajBfcGFyYW1zX3RhdT0wJm9iajBfcGFyYW1zX3QwPTAmb2JqMF9wYXJhbXNfdDE9Mg=="
target="_blank"
rel="noopener noreferrer"
>Smooth example</a
>
</h6>
<h6 class="framelable fragment">
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SW50cm8mb2JqMF9raW5kPWdyYXBoJm9iajBfY29sb3I9JTIzMzIzMmZmJm9iajBfcGFyYW1zX2E9MCZvYmowX3BhcmFtc19iPTImb2JqMF9wYXJhbXNfYz0wJm9iajBfcGFyYW1zX2Q9MiZvYmowX3BhcmFtc196PSUyOGFicyUyOHglMjkrJTJCK2FicyUyOHklMjklMjklMkYlMjgxKyUyQit4JTVFMislMkIreSU1RTIlMjkmb2JqMF9wYXJhbXNfdGF1PTAmb2JqMF9wYXJhbXNfdDA9MCZvYmowX3BhcmFtc190MT0yJm9iajFfa2luZD1ncmFwaCZvYmoxX2NvbG9yPSUyMzMyMzJmZiZvYmoxX3BhcmFtc19hPS0yJm9iajFfcGFyYW1zX2I9MCZvYmoxX3BhcmFtc19jPTAmb2JqMV9wYXJhbXNfZD0yJm9iajFfcGFyYW1zX3o9JTI4YWJzJTI4eCUyOSslMkIrYWJzJTI4eSUyOSUyOSUyRiUyODErJTJCK3glNUUyKyUyQit5JTVFMiUyOSZvYmoxX3BhcmFtc190YXU9MCZvYmoxX3BhcmFtc190MD0wJm9iajFfcGFyYW1zX3QxPTEmb2JqMl9raW5kPWdyYXBoJm9iajJfY29sb3I9JTIzMzIzMmZmJm9iajJfcGFyYW1zX2E9MCZvYmoyX3BhcmFtc19iPTImb2JqMl9wYXJhbXNfYz0tMiZvYmoyX3BhcmFtc19kPTAmb2JqMl9wYXJhbXNfej0lMjhhYnMlMjh4JTI5KyUyQithYnMlMjh5JTI5JTI5JTJGJTI4MSslMkIreCU1RTIrJTJCK3klNUUyJTI5Jm9iajJfcGFyYW1zX3RhdT0wJm9iajJfcGFyYW1zX3QwPTAmb2JqMl9wYXJhbXNfdDE9MSZvYmozX2tpbmQ9Z3JhcGgmb2JqM19jb2xvcj0lMjMzMjMyZmYmb2JqM19wYXJhbXNfYT0tMiZvYmozX3BhcmFtc19iPTAmb2JqM19wYXJhbXNfYz0tMiZvYmozX3BhcmFtc19kPTAmb2JqM19wYXJhbXNfej0lMjhhYnMlMjh4JTI5KyUyQithYnMlMjh5JTI5JTI5JTJGJTI4MSslMkIreCU1RTIrJTJCK3klNUUyJTI5Jm9iajNfcGFyYW1zX3RhdT0wJm9iajNfcGFyYW1zX3QwPTAmb2JqM19wYXJhbXNfdDE9MQ=="
target="_blank"
rel="noopener noreferrer"
>Nonsmooth example</a
>
</h6>
</section>
<section>
<h6 class="framelabel">Definition</h6>
<p>
A scalar field $f(x_1, \ldots, x_n)$ is
<strong>differentiable</strong> at $(p_1, \ldots, p_n)$ provided
there is a linear function $L(x_1, \ldots, x_n)$ such that
\[f(x_1, \ldots, x_n) - L(x_1, \ldots, x_n) = \sum_{i=1}^n
\epsilon_i (x_i - p_i)\] where each $\epsilon_i \to 0$ as $\vec x
\to \vec p$.
</p>
</section>
<section>
<h6 class="framelabel">Example</h6>
<p>Show $f(x) = x^3$ is differentiable at $x=1$.</p>
<p class="fragment">
<strong>Solution</strong>. Let $L(x) = 3x - 2$.
<span class="fragment">
Then, \[ f(x) - L(x) = x^3 - 3x + 2 \]
</span>
<span class="fragment">\[ = (x^2 + x - 2)(x - 1) \] </span>
</p>
</section>
</section>
<section>
<section>
<h1>Tangent Plane</h1>
</section>
<section>
<h3 class="framelabel">Key example</h3>
<p>
We start with the
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SW50cm8mc2NhbGU9MC4zOCZzaG93UGFuZWw9dHJ1ZSZvYmowX2tpbmQ9Z3JhcGgmb2JqMF9jb2xvcj0lMjNkYzVlNjYmb2JqMF9wYXJhbXNfYT0wJm9iajBfcGFyYW1zX2I9MyZvYmowX3BhcmFtc19jPTAmb2JqMF9wYXJhbXNfZD0zJm9iajBfcGFyYW1zX3o9bG9nJTI4K3grJTJCKzIreSslMkIrMSUyOSZvYmowX3BhcmFtc190MD0wJm9iajBfcGFyYW1zX3QxPTEmb2JqMV9raW5kPXBvaW50Jm9iajFfY29sb3I9JTIzMGQwODg3Jm9iajFfcGFyYW1zX2E9MSZvYmoxX3BhcmFtc19iPTImb2JqMV9wYXJhbXNfYz1sb2clMjg2JTI5Jm9iajFfcGFyYW1zX3QwPTAmb2JqMV9wYXJhbXNfdDE9MQ=="
target="_blank"
rel="noopener noreferrer"
>graph</a
>
of a smooth 2-D function \[ z = f(x,y) = \ln(x + 2y + 1) \] and
calculate the tangent plane at $(1,2, \ln 6)$.
</p>
</section>
<section>
<h6 class="framelabel">Program for Tangent Plane</h6>
<ol>
<li class="fragment">
Construct curve in $x$-direction $\langle t, 2, \ln(t + 5)
\rangle$
</li>
<li class="fragment">
Take derivative at $t=1$, $\langle 1, 0, \frac{1}{6} \rangle$.
</li>
<li class="fragment">
Construct curve in $y$-direction $\langle 1, t, \ln(2 + 2t)
\rangle$
</li>
<li class="fragment">
Take derivative at $t=2$, $\langle 0, 1, \frac{1}{3} \rangle$.
</li>
<li class="fragment">Cross tangent vectors to get normal.</li>
<li class="fragment">
Form
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SW50cm8mb2JqMF9raW5kPWdyYXBoJm9iajBfY29sb3I9JTIzZGM1ZTY2Jm9iajBfcGFyYW1zX2E9MCZvYmowX3BhcmFtc19iPTMmb2JqMF9wYXJhbXNfYz0wJm9iajBfcGFyYW1zX2Q9MyZvYmowX3BhcmFtc196PWxvZyUyOCt4KyUyQisyK3krJTJCKzElMjkmb2JqMF9wYXJhbXNfdDA9MCZvYmowX3BhcmFtc190MT0xJm9iajFfa2luZD1jdXJ2ZSZvYmoxX2NvbG9yPSUyMzBkMDg4NyZvYmoxX3BhcmFtc19hPTAmb2JqMV9wYXJhbXNfYj0zJm9iajFfcGFyYW1zX3g9dCZvYmoxX3BhcmFtc195PTImb2JqMV9wYXJhbXNfej1sb2clMjgrdCsrJTJCKzUlMjkmb2JqMl9raW5kPWN1cnZlJm9iajJfY29sb3I9JTIzZGJkZDY0Jm9iajJfcGFyYW1zX2E9MCZvYmoyX3BhcmFtc19iPTMmb2JqMl9wYXJhbXNfeD0xKyZvYmoyX3BhcmFtc195PXQmb2JqMl9wYXJhbXNfej1sb2clMjgyKyslMkIrMnQlMjkmb2JqM19raW5kPXBvaW50Jm9iajNfY29sb3I9JTIzMDAwMDAwJm9iajNfcGFyYW1zX2E9MSZvYmozX3BhcmFtc19iPTImb2JqM19wYXJhbXNfYz1sb2clMjg2JTI5Jm9iajNfcGFyYW1zX3QwPTAmb2JqM19wYXJhbXNfdDE9MSZvYmo0X2tpbmQ9dmVjdG9yJm9iajRfY29sb3I9JTIzNmU2ZTZlJm9iajRfcGFyYW1zX2E9LTElMkY2Jm9iajRfcGFyYW1zX2I9LTElMkYzJm9iajRfcGFyYW1zX2M9MSZvYmo0X3BhcmFtc194PTEmb2JqNF9wYXJhbXNfeT0yJm9iajRfcGFyYW1zX3o9bG9nJTI4NiUyOSZvYmo0X3BhcmFtc190MD0wJm9iajRfcGFyYW1zX3QxPTEmb2JqNV9raW5kPWxldmVsJm9iajVfY29sb3I9JTIzOTMxMGEyJm9iajVfcGFyYW1zX2c9LSt4KyUyRis2Ky0reSslMkYrMyslMkIreiZvYmo1X3BhcmFtc19rPWxvZyUyODYlMjkrLSs1JTJGNiZvYmo1X3BhcmFtc19hPTAmb2JqNV9wYXJhbXNfYj0zJm9iajVfcGFyYW1zX2M9MCZvYmo1X3BhcmFtc19kPTMmb2JqNV9wYXJhbXNfZT0wJm9iajVfcGFyYW1zX2Y9NQ=="
target="_blank"
rel="noopener noreferrer"
>plane equation</a
>
$-\frac{x}{6} -\frac{y}{3} + z = \ln 6 - \frac56$.
</li>
<li class="fragment">Profit.</li>
</ol>
</section>
<section>
<h6 class="framelabel">Tangent Plane at $(a, b, f(a,b))$.</h6>
<ol>
<li class="fragment">
Construct curve in $x$-direction $\langle t, b, f(t,b) \rangle$
</li>
<li class="fragment">
Take derivative at $t=a$, $\langle 1, 0, f_x(a,b) \rangle$.
</li>
<li class="fragment">
Construct curve in $y$-direction $\langle a, t, f(a,t) \rangle$
</li>
<li class="fragment">
Take derivative at $t=b$, $\langle 0, 1, f_y(a,b) \rangle$.
</li>
<li class="fragment">
Cross tangent vectors to get normal $\vec n = \langle -f_x(a,b),
-f_y(a,b), 1 \rangle$.
</li>
<li class="fragment">Form plane equation.</li>
<li class="fragment">
Profit. \[ z = f(a,b) + f_x(a,b)(x - a) + f_y(a,b)(y - b). \]
</li>
</ol>
</section>
<section>
<div class="r-frame">
<h6 class="framelabel">Normal vector</h6>
\[ \vec n = \left\langle -f_x(a,b), -f_y(a,b), 1 \right\rangle \]
<div class="fragment">
<h6 class="framelabel">Tangent Plane</h6>
\[ z = f(a,b) + f_x(a,b)(x - a) + f_y(a,b)(y - b) \]
<div class="fragment">
\[ = L(x,y) \] This is the <strong>linearization</strong> of
$f$ at the point $(a,b)$.
</div>
</div>
</div>
</section>
</section>
<section>
<section><h1>Linearization</h1></section>
<section>
<div class="r-frame">
<h6 class="framelabel">Definition</h6>
The linearization of a function $f$ at $\vec p = \langle p_1,
\ldots, p_n \rangle$ is a linear function \[L(\vec x) = f(\vec p)
+ \sum_{i=1}^n \frac{\partial f}{\partial x_i}(\vec p)(x_i - p_i)
\]
</div>
</section>
<section>
<p>
Use linearization to estimate values of a function nearby known
points.
</p>
<div class="fragment">
<h6 class="framelabel">Example</h6>
<p>
\[f(x,y,z) = e^{-x^2 + 3y + 3z}\] Estimate $f(3.01, 2.03,
0.99)$.
</p>
<div class="r-stretch">$\ $</div>
</div>
</section>
<section>
<h6 class="framelabel">Example</h6>
<p>Estimate $\sqrt{2/7}$.</p>
<ol>
<li class="fragment">
Use $f(x)= \sqrt{\frac{2}{x}}$ around $x = 8$.
</li>
</ol>
<div class="r-stretch">
<iframe
src="https://drew.youngren.nyc/jupyter-xeus/repl/index.html?kernel=xpython&theme=JupyterLab%20Dark&code=from sympy import *"
frameborder="0"
width="100%"
height="100%"
></iframe>
</div>
</section>
<section>
<h6 class="framelabel">Example</h6>
<p>Estimate $\sqrt{2/7}$.</p>
<ol>
<li class="fragment">
Use $g(x,y) = \sqrt{\frac{x}{y}}$ around $(9, 36)$.
</li>
</ol>
<div class="r-stretch">
<iframe
src="https://drew.youngren.nyc/jupyter-xeus/repl/index.html?kernel=xpython&theme=JupyterLab%20Dark&code=from sympy import *"
frameborder="0"
width="100%"
height="100%"
></iframe>
</div>
</section>
<section>
<h6 class="framelabel">Example</h6>
<p>Estimate $\sqrt{2/7}$.</p>
<div class="r-stretch">
<ol>
<li class="fragment">
Use $f(x)= \sqrt{\frac{2}{x}}$ around $x = 8$.
<span class="fragment"
>\[\sqrt{\frac27} = f(7) \approx f(8) + f'(8)(-1) =
\frac{17}{32}\]
</span>
</li>
<li class="fragment">
Use $g(x,y) = \sqrt{\frac{x}{y}}$ around $(9, 36)$.<span
class="fragment"
>\[\sqrt{\frac{10}{35}} \approx \frac12 + g_x(9,36)(1) +
g_y(9,36)(-1) = \frac{77}{144}\]
</span>
</li>
</ol>
</div>
</section>
<section>
<h3 class="framelabel">Differentials</h3>
<p>
An alternative, compact approach to the same concept is to
estimate changes in functions using
<strong>differentials</strong>.
</p>
<p class="fragment">
We write $\Delta f = f(x,y) - f(a,b) \approx $ \[df = f_x(a,b)dx +
f_y(a,b)dy\]
</p>
</section>
<section>
<h6 class="framelabel">Example</h6>
<p>
A
<a
href="https://3demos.ctl.columbia.edu/?Y3VycmVudENoYXB0ZXI9SG93K1RvJm9iajBfa2luZD1zb2xpZCZvYmowX2NvbG9yPSUyMzBkMDg4NyZvYmowX3BhcmFtc19jb29yZHM9Y3lsJm9iajBfcGFyYW1zX2E9MCZvYmowX3BhcmFtc19iPTMrJTJGKzIrcGkmb2JqMF9wYXJhbXNfYz0wJm9iajBfcGFyYW1zX2Q9My4wMislMkYrNSZvYmowX3BhcmFtc19lPS0yLjUyKyUyRis1Jm9iajBfcGFyYW1zX2Y9Mi41MislMkYrNSZvYmoxX2tpbmQ9c29saWQmb2JqMV9jb2xvcj0lMjNkYzVlNjYmb2JqMV9wYXJhbXNfY29vcmRzPWN5bCZvYmoxX3BhcmFtc19hPS0zKyUyRjQrcGkmb2JqMV9wYXJhbXNfYj1waSslMkYyJm9iajFfcGFyYW1zX2M9MCZvYmoxX3BhcmFtc19kPTIuOTgrJTJGKzUmb2JqMV9wYXJhbXNfZT0tMi40OCslMkYrNSZvYmoxX3BhcmFtc19mPTIuNDgrJTJGKzU="
target="_blank"
rel="noopener noreferrer"
>cylindrical aluminum can</a
>
is is 5cm high with a diameter of 6cm and is 0.4mm thick. Estimate
the volume of the aluminum.
</p>
<p class="fragment">
<strong>Solution</strong>. Let $V = \pi r^2 h$. The volume of the
aluminum is approximately \[ dV = 2\pi r h\, dr + \pi r^2 \,dh =
\pi(30\times0.04 + 9\times 0.08) \]
</p>
</section>
</section>
<section>
<section><h1>Learning Outcomes</h1></section>
<section id="learning-outcomes">
<h6 class="framelabel">You should be able to...</h6>
<ul>
<li>
Determine (quickly) whether a functions of several variables is
linear.
</li>
<li>
Identify the correct linearization formula for a given function
and connect it to tangent lines/planes.
</li>
<li>
Identify an appropriate function and point to use linearization
in estimating various quantities.
</li>
<li>
Use linearization and/or differentials to estimate error (and
relative error.)
</li>
</ul>
</section>
</section>
</div>
</div>
<script src="reveal.js/dist/reveal.js"></script>
<script src="reveal.js/plugin/notes/notes.js"></script>
<script src="reveal.js/plugin/markdown/markdown.js"></script>
<script src="reveal.js/plugin/highlight/highlight.js"></script>
<script src="reveal.js/plugin/math/math.js"></script>
<script>
// More info about initialization & config:
// - https://revealjs.com/initialization/
// - https://revealjs.com/config/
Reveal.initialize({
hash: true,
katex: {
version: "latest",
delimiters: [
{ left: "$", right: "$", display: false },
{ left: "\\(", right: "\\)", display: false },
{ left: "$$", right: "$$", display: true },
{ left: "\\[", right: "\\]", display: true },
],
ignoredTags: ["script", "noscript", "style", "textarea", "pre"],
},
// Learn about plugins: https://revealjs.com/plugins/
plugins: [
RevealMarkdown,
RevealHighlight,
RevealNotes,
RevealMath.KaTeX,
],
});
</script>
</body>
</html>