An AI skill that turns books into animated, narrated, interactive web experiences
JavaScript ai-agentsai-educationanimationclaudeclaude-codeclaude-skillsedtecheducationinteractive-textbookscormtext-to-video
feat(linear-algebra): chapters 16-19 reviewed; Unit 2 on the contents
yzre0840035baef
diff --git a/site/linear-algebra/ch15/index.html b/site/linear-algebra/ch15/index.htmlindex a1b64cc..36f430a 100644--- a/site/linear-algebra/ch15/index.html+++ b/site/linear-algebra/ch15/index.html@@ -17,7 +17,7 @@<script src="audio/en/timings.js"></script><script>'use strict';-const CHAPTER = { number: 15, title: 'More Numbers Than Axes', minutes: 9, language: 'en' };+const CHAPTER = { number: 15, title: 'More Numbers Than Axes', minutes: 9, language: 'en' , next: '../ch16/' };/* ---------- the systems of this chapter ---------- */const LA = [[2, -1], [-1, 2]]; // the lecture's 2 × 2 (the unit close)@@ -191,7 +191,7 @@ const BEATS = [barsFlash(bs, [key], m(k));barsFlash(bs, cells, m(kb));});- const glow = (rows, t, color = COL.task, dur = 1.6) => rows.forEach(i => {+ const glow = (rows, t, color = COL.chalk, dur = 1.6) => rows.forEach(i => {const r = mk('rect', { x: 96, y: bs.zeroY(i) - 35, width: 1430, height: 70, rx: 10, fill: color, 'fill-opacity': .1, stroke: color, 'stroke-opacity': .5, 'stroke-width': 2 }, p);put(r, { o: 0 }); show(r, t, .3); hide(r, t + dur, .4);});@@ -246,7 +246,7 @@ const BEATS = [show(bs.ax.g, m('same'), .5); bs.eqs.forEach(e => show(e, m('same') + .3, .3));const span = m('match') - m('move') + 1.2;x9.forEach((x, j) => bs.to({ [`x${j}`]: x }, m('move') + j * span / 9, .55));- const cant = text(p, 'nine axes: we can’t draw them. nine numbers: we can compute, and watch them move.', 800, 855, m('cant'), { size: 28, fill: COL.task, anchor: 'middle', weight: 600 });+ const cant = text(p, 'nine axes: we can’t draw them. nine numbers: we can compute, and watch them move.', 800, 855, m('cant'), { size: 28, fill: COL.chalk, anchor: 'middle', weight: 600 });hide(cant, m('q') - .3, .3);text(p, 'every b? yes, when each column brings a new direction', 800, 855, m('yes'), { size: 28, fill: COL.good, anchor: 'middle', weight: 600 });// keep the bars alive while the voice talks: the amounts step back and land again@@ -283,11 +283,11 @@ const BEATS = [all3({ b0: -4, b1: 2 }, m('no') + 5.6, 1.2); // a b on their line: endlessly many mixes (rows: one line)all3({ a01: -1, a11: 2, b0: 0, b1: 3 }, m('next'), 1.2);const big = G(p, { o: 0 });- T(big, 'every b?', { x: 90, y: 830, size: 30, fill: COL.task, weight: 600 });+ T(big, 'every b?', { x: 90, y: 830, size: 30, fill: COL.chalk, weight: 600 });show(big, m('big'), .4);text(p, 'yes: the columns fill the space', 270, 830, m('yes'), { size: 30, fill: COL.good, weight: 600 });text(p, 'no: they lie flat (a line, a plane)', 810, 830, m('no'), { size: 30, fill: COL.bad, weight: 600 });- text(p, 'next: Unit 2, elimination', 1520, 110, m('next'), { size: 30, fill: COL.task, anchor: 'end', weight: 600 });+ text(p, 'next: Unit 2, elimination', 1520, 110, m('next'), { size: 30, fill: COL.dim, anchor: 'end', weight: 600 });}],['wrap', 'Summary', (m) => {@@ -297,7 +297,7 @@ const BEATS = [['4 or 9 numbers: no axes to draw, the same rules, the same question.', 'w3'],['Unit 1: row picture, column picture, and A x = b.', 'w4']].forEach(([str, mark], i) => {const g = G(p, { x: -16, y: 230 + i * 130, o: 0 });- mk('circle', { cx: 150, cy: -12, r: 26, fill: COL.task }, g);+ mk('circle', { cx: 150, cy: -12, r: 26, fill: COL.chalk }, g);T(g, String(i + 1), { x: 150, y: -1, size: 30, fill: COL.board, weight: 700, anchor: 'middle' });T(g, str, { x: 210, size: 34, weight: 600 });tw(g, { o: 1, x: 0 }, m(mark), .6);diff --git a/site/linear-algebra/ch16/audio/en/easy.mp3 b/site/linear-algebra/ch16/audio/en/easy.mp3index 9900d11..02c4838 100644Binary files a/site/linear-algebra/ch16/audio/en/easy.mp3 and b/site/linear-algebra/ch16/audio/en/easy.mp3 differdiff --git a/site/linear-algebra/ch16/audio/en/timings.js b/site/linear-algebra/ch16/audio/en/timings.jsindex 058e7b9..188d87f 100644--- a/site/linear-algebra/ch16/audio/en/timings.js+++ b/site/linear-algebra/ch16/audio/en/timings.js@@ -25,15 +25,16 @@ window.TIMINGS = {]},"easy": {- "dur": 44.136,+ "dur": 46.32,"marks": {- "eq": 3.073,- "flat": 7.109,- "y": 14.349,- "put": 19.648,- "x": 25.768,- "meet": 29.531,- "lesson": 34.401+ "eq": 3.229,+ "rows": 7.279,+ "flat": 9.883,+ "y": 17.005,+ "put": 22.318,+ "x": 28.385,+ "meet": 32.044,+ "lesson": 36.888},"cues": [[@@ -41,47 +42,51 @@ window.TIMINGS = {"Let's start with a system that is easy to solve."],[- 3.073,+ 3.229,"x plus two y equals five, and two y equals four."],[- 7.109,+ 7.279,+ "We'll call them row one and row two."+ ],+ [+ 9.883,"The second equation has no x."],[- 9.648,+ 12.266,"In chapter one we saw what that means: x is free, so its line is flat."],[- 14.349,+ 17.005,"And it tells us y straight away."],[- 16.393,+ 19.115,"Two y equals four, so y equals two."],[- 19.648,+ 22.318,"Now put two in place of y in the first equation."],[- 22.891,+ 25.247,"x plus two times two equals five."],[- 25.768,+ 28.385,"x plus four equals five, so x equals one."],[- 29.531,+ 32.044,"The answer is one, two, and there it is, where the two lines meet."],[- 34.401,+ 36.888,"So a system is easy when one equation has lost its x."],[- 38.464,+ 40.859,"That's our plan for every system: make the second equation lose its x."]]diff --git a/site/linear-algebra/ch16/index.html b/site/linear-algebra/ch16/index.htmlindex f8cea2e..b24f785 100644--- a/site/linear-algebra/ch16/index.html+++ b/site/linear-algebra/ch16/index.html@@ -128,10 +128,12 @@ const BEATS = [text(p, 'An easy system', 60, 110, .2, { size: 40, weight: 600 });const sys = twoLines(p, [[1, 2], [0, 2]], [5, 4], { t0: m('eq') - .3, lines: false, meet: false });show(sys.lines[0].l, m('eq') + 1, .8);+ text(p, 'row 1', 560, 194, m('rows'), { size: 26, fill: BLUE, weight: 600 });+ text(p, 'row 2', 560, 286, m('rows') + .6, { size: 26, fill: CORAL, weight: 600 });show(sys.lines[1].l, m('flat') + 2.4, .8);flash(sys, 'a10', m('flat'));hl(p, 128, 252, 110, 58, m('flat'), m('y') - .3);- text(p, 'no x: a flat line', 520, 300, m('flat') + 2.4, { size: 28, fill: CORAL, weight: 600 });+ text(p, 'no x: a flat line', 90, 352, m('flat') + 2.4, { size: 28, fill: CORAL, weight: 600 });wl(p, '2y', '4', 420, m('y') + 1);wl(p, 'y', '2', 420, m('y') + 3, { xEq: 610, fill: COL.task });say(p, ['→'], 500, 420, m('y') + 3, { size: 40, fill: COL.dim });@@ -280,7 +282,7 @@ const BEATS = [['swing', 'A little at a time', (m) => {const p = panel(0);- text(p, 'Row 2 − ℓ × row 1, a little at a time', 60, 110, .2, { size: 40, weight: 600 });+ text(p, 'Take row 1 away a little at a time', 60, 110, .2, { size: 40, weight: 600 });const A = [[1, 2], [3, 4]], b = [5, 11];const sys = twoLines(p, A, b, { t0: .2 });const el = elim(p, sys, { at: MAT, t0: .2 });@@ -321,8 +323,9 @@ const BEATS = [wl(p, 'y', '−1', 600, m('y') + 2.4, { xEq: 420, size: 38, fill: COL.task });wl(p, '2x − 1', '3', 670, m('x'), { xEq: 200, size: 38 });say(p, ['→'], 320, 670, m('x') + 2.2, { size: 38, fill: COL.dim });- wl(p, '2x', '4', 670, m('x') + 2.2, { xEq: 420, size: 38 });- wl(p, 'x', '2', 740, m('x2'), { xEq: 420, size: 38, fill: COL.task });+ wl(p, '2x', '4', 670, m('x') + 2.2, { xEq: 440, size: 38 });+ say(p, ['→'], 540, 670, m('x2'), { size: 38, fill: COL.dim });+ wl(p, 'x', '2', 670, m('x2'), { xEq: 640, size: 38, fill: COL.task });show(sys.meetBox, m('pt'), .5); pulse(sys.meet, m('pt') + .3);}],@@ -349,7 +352,7 @@ const BEATS = [ghost(sys, 6, -1, 2, 1, m('go'));el.mult(2, m('go') + .2, 2, { count: false });lightCells(el, [m('e1'), m('e2'), m('e3')]);- const sgn = say(p, ['−1 − 2 = −3'], 470, 680, m('e2') + 1, { size: 34, fill: COL.task });+ const sgn = say(p, ['y: −1 − 2 = −3'], 90, 680, m('e2') + 1, { size: 34, fill: COL.task });hide(sgn, m('y') - .3, .3);hide(w, m('y') - .3, .3);const wg = G(p, {});@@ -358,9 +361,9 @@ const BEATS = [wl(wg, 'y', '1', 600, m('y') + 2.4, { xEq: 420, size: 38, fill: COL.task });wl(wg, '3x + 1', '7', 660, m('x'), { xEq: 200, size: 38 });say(wg, ['→'], 320, 660, m('x') + 2.4, { size: 38, fill: COL.dim });- wl(wg, '3x', '6', 660, m('x') + 2.4, { xEq: 420, size: 38 });- say(wg, ['→'], 500, 660, m('x2'), { size: 38, fill: COL.dim });- wl(wg, 'x', '2', 660, m('x2'), { xEq: 610, size: 38, fill: COL.task });+ wl(wg, '3x', '6', 660, m('x') + 2.4, { xEq: 440, size: 38 });+ say(wg, ['→'], 540, 660, m('x2'), { size: 38, fill: COL.dim });+ wl(wg, 'x', '2', 660, m('x2'), { xEq: 640, size: 38, fill: COL.task });tw(wg, { o: 0 }, m('chk') - .4, .4);text(p, 'check (2, 1) in the original equations:', 90, 600, m('chk'), { size: 28, fill: COL.dim, weight: 600 });say(p, ['3x + y = 7: 3·2 + 1 = 7'], 90, 665, m('c1'), { size: 36, fill: BLUE });@@ -373,13 +376,13 @@ const BEATS = [['q3', 'Quick check', () => {const p = panel(0);text(p, 'Quick check', 60, 110, .2, { size: 40, weight: 600 });- S.sys = twoLines(p, [[1, 1], [2, 3]], [4, 11]);+ S.sys = twoLines(p, [[1, 1], [2, 3]], [4, 11], { meet: false });}, { ask: done => quiz(CARD, [{id: 'c-which', prompt: ['Row 2 − 2 × row 1 gives which new row 2?'],build: choice([[$m('y = 3')], [$m('y = 7')], [$m('2y = 3')], [$m('4x + 5y = 19')]], 0,'2 × row 1 is 2x + 2y = 8. Take it away: 3y − 2y = y and 11 − 8 = 3.',[null, 'The right side was not multiplied: take away 2 × 4 = 8, not 4.', 'Only the x number was doubled: 2 × row 1 is 2x + 2y, so 3y − 2y = y.', 'That adds 2 × row 1. Subtract it, so the x numbers cancel.'],- () => { const s = S.sys; fxp(q => s.set({ a10: 2 - 2 * q, a11: 3 - 2 * q, b1: 11 - 8 * q }), 0, 1.6); }),+ () => { const s = S.sys; fxp(q => s.set({ a10: 2 - 2 * q, a11: 3 - 2 * q, b1: 11 - 8 * q }), 0, 1.6); fx(s.meetBox, { o: 1 }, 1.6, .5); }),}], done) }],['wrap', 'Summary', (m) => {diff --git a/site/linear-algebra/ch17/audio/en/both.mp3 b/site/linear-algebra/ch17/audio/en/both.mp3new file mode 100644index 0000000..fe8a3b9Binary files /dev/null and b/site/linear-algebra/ch17/audio/en/both.mp3 differdiff --git a/site/linear-algebra/ch17/audio/en/timings.js b/site/linear-algebra/ch17/audio/en/timings.jsindex 56a2cc1..15e5a32 100644--- a/site/linear-algebra/ch17/audio/en/timings.js+++ b/site/linear-algebra/ch17/audio/en/timings.js@@ -353,6 +353,84 @@ window.TIMINGS = {]]},+ "both": {+ "dur": 51.024,+ "marks": {+ "sys": 5.013,+ "div": 10.286,+ "op": 18.021,+ "half": 26.966,+ "go": 29.818,+ "e1": 31.107,+ "e2": 34.01,+ "e3": 36.992,+ "turn": 39.141,+ "y": 42.773,+ "x": 46.615+ },+ "cues": [+ [+ 0.104,+ "Now both at once: a multiplier that is negative and a fraction."+ ],+ [+ 5.013,+ "Two x plus y equals four, and minus x plus three y equals five."+ ],+ [+ 10.286,+ "The number to remove is minus one."+ ],+ [+ 12.943,+ "The pivot is two."+ ],+ [+ 14.544,+ "Minus one divided by two is minus one half."+ ],+ [+ 18.021,+ "So the step is row two minus, minus one half, times row one."+ ],+ [+ 22.734,+ "Taking away minus a half is the same as adding a half."+ ],+ [+ 26.966,+ "Half of row one is one, one half, two."+ ],+ [+ 29.818,+ "Add it to row two."+ ],+ [+ 31.107,+ "Minus one plus one is zero."+ ],+ [+ 34.01,+ "Three plus one half is seven halves."+ ],+ [+ 36.992,+ "Five plus two is seven."+ ],+ [+ 39.141,+ "The line swings round the meeting point and lies flat."+ ],+ [+ 42.773,+ "Seven halves y equals seven, so y equals two."+ ],+ [+ 46.615,+ "Then two x plus two equals four, so x equals one."+ ]+ ]+ },"drill": {"dur": 29.304,"marks": {diff --git a/site/linear-algebra/ch17/index.html b/site/linear-algebra/ch17/index.htmlindex e493f27..7f887d7 100644--- a/site/linear-algebra/ch17/index.html+++ b/site/linear-algebra/ch17/index.html@@ -33,7 +33,7 @@ const table = (p, A, b, caption, { t0 = .1, meet = true, dens = [1, 2], step = 1sys.E.style.display = 'none';if (!meet) put(sys.meetBox, { o: 0 });const cap = say(p, [caption], 90, 182, t0 + .1, { size: 32, fill: COL.dim });- const el = elim(p, sys, { at: TOP, size: 50, cw: 92, rh: 78, t0, dens, step, labelX: 494 });+ const el = elim(p, sys, { at: TOP, size: 50, cw: 92, rh: 78, t0, dens, step, labelX: 466 });return { sys, el, cap };};// The old line of row 2, dashed, through the meeting point (sx, sy).@@ -127,7 +127,7 @@ const BEATS = [const { sys, el } = table(p, A, b, 'x + 2y = 5, 3x + 4y = 11', { t0: m('sys') - .3 });el.op(1, 0, 3, m('step'));el.ring(0, 0, m('piv'));- text(p, 'pivot row', 494, 268, m('piv') + 2.5, { size: 28, fill: BLUE, weight: 600 });+ text(p, 'pivot row', 466, 268, m('piv') + 2.5, { size: 28, fill: BLUE, weight: 600 });legend(p, false, ['pivot: 1'], 500, m('piv'));el.ring(1, 0, m('rem'), { dash: true });legend(p, true, ['to remove: 3'], 560, m('rem'));@@ -163,8 +163,8 @@ const BEATS = [say(p, ['8 − ℓ·4 = 0'], 90, 630, m('ask'), { size: 34, fill: COL.task });say(p, ['ℓ = 8 ÷ 4 = 2'], 340, 630, m('div') + 1.4, { size: 34, fill: COL.task });const box = G(p, { o: 0 });- mk('rect', { x: 76, y: 664, width: 520, height: 76, rx: 14, fill: 'none', stroke: COL.task, 'stroke-width': 3 }, box);- M(box, ['multiplier ℓ = ', F('number to remove', 'pivot')], { x: 96, y: 712, size: 32, fill: COL.task, anchor: 'start' });+ mk('rect', { x: 76, y: 660, width: 600, height: 92, rx: 14, fill: 'none', stroke: COL.task, 'stroke-width': 3 }, box);+ M(box, ['multiplier ℓ = ', F('number to remove', 'pivot')], { x: 96, y: 716, size: 40, fill: COL.task, anchor: 'start' });show(box, m('rule'));el.op(1, 0, 2, m('go'));el.mult(2, m('go') + .6, 1.8, { count: false });@@ -230,6 +230,25 @@ const BEATS = [show(sys.meetBox, m('x') + 3, .5);}],+ ['both', 'Negative and a fraction', (m) => {+ const p = panel(0);+ text(p, 'Negative and a fraction', 60, 110, .2, { size: 40, weight: 600 });+ const A = [[2, 1], [-1, 3]], b = [4, 5];+ const { sys, el } = table(p, A, b, '2x + y = 4, −x + 3y = 5', { t0: m('sys') - .3, meet: false });+ el.ring(1, 0, m('div'), { dash: true }); el.ring(0, 0, m('div') + 2.2);+ say(p, ['ℓ = −1 ÷ 2 = −', F(1, 2)], 90, 520, m('div') + 4, { size: 36, fill: COL.task });+ el.op(1, 0, -.5, m('op'));+ say(p, ['row 2 − (−', F(1, 2), ') × row 1 = row 2 + ', F(1, 2), ' × row 1'], 90, 590, m('op') + 3.4, { size: 30, fill: COL.task });+ el.line([1, .5, 2], 2, m('half'), { label: [F(1, 2), ' × row 1'], color: BLUE, sign: '+' });+ ghost(sys, -1, 3, 1, 2, m('go'));+ el.mult(-.5, m('go') + .2, 2, { count: false });+ lightCells(el, [m('e1'), m('e2'), m('e3')]);+ pin(sys, 1, 2, m('turn'));+ say(p, [F(7, 2), 'y = 7, y = 2'], 90, 680, m('y'), { size: 36, fill: COL.task });+ say(p, ['2x + 2 = 4, x = 1'], 90, 760, m('x'), { size: 36, fill: COL.task });+ show(sys.meetBox, m('x') + 2, .5);+ }],+['drill', 'Three quick ones', (m) => {const p = panel(0);text(p, 'Three quick ones', 60, 110, .2, { size: 40, weight: 600 });@@ -267,13 +286,11 @@ const BEATS = [const s = bare([[1, 2], [0, -2]], [5, -4]);const el = elim(p, s, { at: TOP, size: 50, cw: 92, rh: 78, t0: .2 });say(p, ['x + 2y = 5, −2y = −4'], 90, 182, .3, { size: 32, fill: COL.dim });- // the diagonal through the pivots, the zero under it, the triangle above it- const d = path(p, `M${el.cx(0) - 40} ${el.ry(0) - 60}L${el.cx(1) + 40} ${el.ry(1) + 20}`, { stroke: COL.task, 'stroke-width': 4, 'stroke-dasharray': '10 8', fill: 'none' }, { o: 0 });- show(d, m('diag'), .5);+ // the diagonal through the pivots, the zero under it, the triangle on and above it (all behind the numbers)+ el.diag(m('diag'));el.ring(0, 0, m('diag') + .4); el.ring(1, 1, m('diag') + 1);el.flash(1, m('below'), 0); el.flash(1, m('below') + 1.4, 0);- const tri = path(p, `M${el.cx(0) - 44} ${el.ry(0) - 56}L${el.cx(1) + 46} ${el.ry(0) - 56}L${el.cx(1) + 46} ${el.ry(1) + 26}Z`, { fill: COL.task, stroke: COL.task, 'stroke-width': 2, 'fill-opacity': .14 }, { o: 0 });- show(tri, m('tri'), .6);+ el.upper(m('tri'));say(p, ['U'], el.cx(0) + 46, el.ry(1) + 120, m('tri') + 3, { size: 54, fill: COL.task, anchor: 'middle' });text(p, 'upper triangular', el.cx(0) + 90, el.ry(1) + 112, m('tri') + 3, { size: 30, fill: COL.task, weight: 600 });el.focus(1, m('why')); el.focus(null, m('why') + 4);@@ -284,8 +301,7 @@ const BEATS = [// three equations make a bigger triangle (chapter 18)const s3 = bare([[1, 2, 1], [0, 2, -2], [0, 0, 5]], [2, 6, -10]);const e3 = elim(p, s3, { at: [980, 330], size: 44, cw: 80, rh: 70, t0: m('tri') + 4.5 });- const tri3 = path(p, `M${e3.cx(0) - 38} ${e3.ry(0) - 50}L${e3.cx(2) + 40} ${e3.ry(0) - 50}L${e3.cx(2) + 40} ${e3.ry(2) + 22}Z`, { fill: COL.task, stroke: COL.task, 'stroke-width': 2, 'fill-opacity': .12 }, { o: 0 });- show(tri3, m('tri') + 5, .6);+ e3.upper(m('tri') + 5);text(p, 'three equations: a bigger triangle (chapter 18)', 1120, 630, m('tri') + 5, { size: 26, fill: COL.dim, weight: 600, anchor: 'middle' });}],diff --git a/site/linear-algebra/ch18/audio/en/ex3.mp3 b/site/linear-algebra/ch18/audio/en/ex3.mp3new file mode 100644index 0000000..4da311eBinary files /dev/null and b/site/linear-algebra/ch18/audio/en/ex3.mp3 differdiff --git a/site/linear-algebra/ch18/audio/en/timings.js b/site/linear-algebra/ch18/audio/en/timings.jsindex f0ede47..6d724b0 100644--- a/site/linear-algebra/ch18/audio/en/timings.js+++ b/site/linear-algebra/ch18/audio/en/timings.js@@ -440,6 +440,115 @@ window.TIMINGS = {]]},+ "ex3": {+ "dur": 84.288,+ "marks": {+ "eq": 3.841,+ "c1": 13.698,+ "l21": 16.758,+ "w21": 22.487,+ "s21": 25.521,+ "l31": 32.461,+ "w31": 36.315,+ "s31": 39.987,+ "c2": 45.69,+ "l32": 49.349,+ "w32": 54.062,+ "s32": 63.828,+ "u": 71.185,+ "z": 80.26+ },+ "cues": [+ [+ 0.104,+ "One more, slowly, with every line of working."+ ],+ [+ 3.841,+ "x plus y plus z equals two."+ ],+ [+ 6.432,+ "Two x plus three y plus z equals one."+ ],+ [+ 10.247,+ "And three x plus y plus four z equals ten."+ ],+ [+ 13.698,+ "Column one."+ ],+ [+ 14.714,+ "The pivot is the one at the top."+ ],+ [+ 16.758,+ "Row two starts with two, so the multiplier is two divided by one: two."+ ],+ [+ 22.487,+ "Two times row one is two, two, two, four."+ ],+ [+ 25.521,+ "Take it away, and watch the coral plane turn: zero, one, minus one, minus three."+ ],+ [+ 32.461,+ "Row three starts with three, so the multiplier is three."+ ],+ [+ 36.315,+ "Three times row one is three, three, three, six."+ ],+ [+ 39.987,+ "Take it away, and the yellow plane turns: zero, minus two, one, four."+ ],+ [+ 45.69,+ "Column two."+ ],+ [+ 46.81,+ "The new pivot is the one in row two."+ ],+ [+ 49.349,+ "Under it sits minus two."+ ],+ [+ 51.016,+ "Minus two divided by one is minus two."+ ],+ [+ 54.062,+ "Taking away minus two rows means adding two rows: two times row two is zero, two, minus two, minus six."+ ],+ [+ 63.828,+ "Add it, and row three becomes zero, zero, minus one, minus two."+ ],+ [+ 69.167,+ "The yellow plane lies flat."+ ],+ [+ 71.185,+ "The triangle again, with pivots one, one, and minus one."+ ],+ [+ 75.638,+ "And through all three steps, the meeting point stayed where it was."+ ],+ [+ 80.26,+ "Minus z equals minus two, so z equals two."+ ]+ ]+ },"q3": {"dur": 4.728,"marks": {},diff --git a/site/linear-algebra/ch18/index.html b/site/linear-algebra/ch18/index.htmlindex 7e38cb8..1401cf6 100644--- a/site/linear-algebra/ch18/index.html+++ b/site/linear-algebra/ch18/index.html@@ -23,6 +23,7 @@ const CHAPTER = { number: 18, title: 'Elimination: Three Equations', minutes: 11const LEC = { A: [[1, 2, 1], [3, 8, 1], [0, 4, 1]], b: [2, 12, 2] }; // the lecture's system (OCW 18.06, lecture 2)const AFTER1 = { A: [[1, 2, 1], [0, 2, -2], [0, 4, 1]], b: [2, 6, 2] }; // after column 1const U_ = { A: [[1, 2, 1], [0, 2, -2], [0, 0, 5]], b: [2, 6, -10] }; // the triangle U and c+const EX3 = { A: [[1, 1, 1], [2, 3, 1], [3, 1, 4]], b: [2, 1, 10] }; // ℓ = 2, 3, −2; U rows (0, 1, −1 | −3), (0, 0, −1 | −2); (1, −1, 2)const VIEW = { yaw: -40, pitch: 20 };const TBL = [120, 240]; // [A | b]: rows at 240, 306, 372const CARD = { x: 40, y: 420, w: 720, cls: 'side' }; // under the table, beside the space@@ -42,12 +43,8 @@ const CAP_LEC = 'x + 2y + z = 2, 3x + 8y + z = 12, 4y + z = 2';// The hinge: a meeting line of two planes (0: planes 1 and 2, 1: planes 1 and 3, 2: planes 2 and 3), thickened.const hinge = (sys, n, t0, dur = 1.6) => prog(q => sys.lines[n].e.setAttribute('stroke-width', 2.5 + 5 * Math.sin(Math.PI * q)), t0, dur, lin);const lightRow = (el, i, ts) => ts.forEach((t, j) => el.flash(i, t, j));-// A light triangle over the entries on and above the diagonal of a 3 × 3 table.-const triangle = (p, el, t0) => {- const e = path(p, `M${el.cx(0) - 40} ${el.ry(0) - 48}L${el.cx(2) + 42} ${el.ry(0) - 48}L${el.cx(2) + 42} ${el.ry(2) + 20}Z`, { fill: COL.task, stroke: COL.task, 'stroke-width': 2, 'fill-opacity': .13 }, { o: 0 });- show(e, t0, .6);- return e;-};+// The triangle U: a staircase round the entries on and above the diagonal, behind the numbers.+const triangle = (p, el, t0) => el.upper(t0);// A small 3 × 3 system with no picture, for the title card: the same .v, .to, .set, .onChange elim uses.const bare = (A, b) => {const v = {}, fs = [];@@ -119,8 +116,7 @@ const BEATS = [tw(sys.E, { o: 0 }, m('table') - .2, .4);say(p, [CAP_LEC], 90, 160, m('table'), { size: 28, fill: COL.dim });const el = elim(p, sys, { at: TBL, size: 44, cw: 84, rh: 66, t0: m('table'), labelX: 530 });- const d = path(p, `M${el.cx(0) - 40} ${el.ry(0) - 50}L${el.cx(2) + 40} ${el.ry(2) + 20}`, { stroke: COL.task, 'stroke-width': 3, 'stroke-dasharray': '10 8', fill: 'none' }, { o: 0 });- show(d, m('goal'), .5);+ el.diag(m('goal'));text(p, 'goal: zeros below the pivots', 90, 470, m('goal') + .5, { size: 30, fill: COL.task, weight: 600 });el.ring(1, 0, m('z1'), { dash: true, color: COL.task }); el.ring(2, 0, m('z1') + .5, { dash: true, color: COL.task });el.ring(2, 1, m('z2'), { dash: true, color: COL.task });@@ -140,12 +136,12 @@ const BEATS = [el.line([3, 6, 3, 6], 3, m('three'), { label: '3 × row 1', color: BLUE });sys.focus(1, m('go'));el.mult(3, m('go') + .6, 4, { count: false });- V.turn({ yaw: VIEW.yaw + 30 }, m('go'), 11);+ V.turn({ yaw: VIEW.yaw - 22 }, m('go'), 11);hinge(sys, 0, m('hinge'), 2); hinge(sys, 0, m('hinge') + 2.4, 2);sys.focus(null, m('nums'));lightRow(el, 1, [m('e1'), m('e2'), m('e3'), m('e4')]);text(p, 'row 2 has no x: its plane runs along x', 90, 570, m('nox'), { size: 30, fill: CORAL, weight: 600 });- V.turn({ yaw: VIEW.yaw + 75, pitch: 14 }, m('nox') + .3, 3); // look along x: the coral plane stands edge-on+ V.turn({ yaw: -90, pitch: 0 }, m('nox') + .3, 3); // look along x (x points at the viewer): the coral plane stands edge-on}],['step1b', 'Column one: row 3', (m) => {@@ -218,14 +214,14 @@ const BEATS = [text(p, 'A system of our own', 60, 110, .2, { size: 40, weight: 600 });const { sys, el, V } = three(p, { A: [[2, 1, 1], [4, 1, 3], [-2, 2, 1]], b: [3, 3, 1] }, '2x + y + z = 3, 4x + y + 3z = 3, −2x + 2y + z = 1', { t0: m('eq') - .3, view: { yaw: -20, pitch: 22 } });el.ring(0, 0, m('c1'));- say(p, ['row 2: ℓ = 4 ÷ 2 = 2'], 90, 470, m('l21'), { size: 32, fill: COL.task });+ say(p, ['column 1, row 2: ℓ = 4 ÷ 2 = 2'], 90, 470, m('l21'), { size: 32, fill: COL.task });el.op(1, 0, 2, m('l21') + 1.5);el.mult(2, m('s21'), 1.8, { count: false });- say(p, ['row 3: ℓ = −2 ÷ 2 = −1'], 90, 525, m('l31'), { size: 32, fill: COL.task });+ say(p, ['column 1, row 3: ℓ = −2 ÷ 2 = −1'], 90, 525, m('l31'), { size: 32, fill: COL.task });el.op(2, 0, -1, m('l31') + 1.5);el.mult(-1, m('s31') + 1.2, 1.8, { count: false });el.ring(1, 1, m('c2'));- say(p, ['row 3: ℓ = 3 ÷ (−1) = −3'], 90, 580, m('l32'), { size: 32, fill: COL.task });+ say(p, ['column 2, row 3: ℓ = 3 ÷ (−1) = −3'], 90, 580, m('l32'), { size: 32, fill: COL.task });el.op(2, 1, -3, m('l32') + 1.5);el.mult(-3, m('s32') + .8, 1.8, { count: false });V.turn({ yaw: -45, pitch: 24 }, m('eq'), 9);@@ -247,6 +243,41 @@ const BEATS = [(v, l) => `Row 3 still has ${num(v.a21)}y. The pivot of row 2 is 1; the number to remove is 3.`, () => S.el.set({ l: 3 })),}], done) }],+ ['ex3', 'One more, step by step', (m) => {+ const p = panel(0);+ text(p, 'One more, step by step', 60, 110, .2, { size: 40, weight: 600 });+ const { sys, el, V } = three(p, EX3, 'x + y + z = 2, 2x + 3y + z = 1, 3x + y + 4z = 10', { t0: m('eq') - .3, view: { yaw: -35, pitch: 22 } });+ V.sway(5, 13);+ const L = (parts, y, t) => say(p, parts, 90, y, t, { size: 30, fill: COL.task });+ el.ring(0, 0, m('c1'));+ L(['column 1, row 2: ℓ = 2 ÷ 1 = 2'], 520, m('l21'));+ el.op(1, 0, 2, m('l21') + 1.2);+ const w1 = el.line([2, 2, 2, 4], 3, m('w21'), { label: '2 × row 1', color: BLUE });+ sys.focus(1, m('s21'));+ el.mult(2, m('s21') + .3, 2.6, { count: false });+ hide(w1, m('l31') - .3, .3);+ L(['column 1, row 3: ℓ = 3 ÷ 1 = 3'], 570, m('l31'));+ el.op(2, 0, 3, m('l31') + 1.2);+ const w2 = el.line([3, 3, 3, 6], 3, m('w31'), { label: '3 × row 1', color: BLUE });+ sys.focus(2, m('s31'));+ el.mult(3, m('s31') + .3, 2.6, { count: false });+ V.turn({ yaw: -10, pitch: 26 }, m('s21'), 12);+ hide(w2, m('c2') - .3, .3);+ sys.focus(null, m('c2'));+ el.ring(1, 1, m('c2') + .4);+ L(['column 2, row 3: ℓ = −2 ÷ 1 = −2'], 620, m('l32'));+ el.op(2, 1, -2, m('l32') + 1.6);+ el.line([0, 2, -2, -6], 3, m('w32'), { label: '2 × row 2', color: CORAL, sign: '+' });+ sys.focus(2, m('s32'));+ el.mult(-2, m('s32') + .3, 2.6, { count: false });+ V.turn({ yaw: -25, pitch: 34 }, m('s32') + 1, 4);+ sys.focus(null, m('u'));+ triangle(p, el, m('u'));+ el.ring(2, 2, m('u') + 1.2);+ pulse(sys.meet.e, m('u') + 4); pulse(sys.meet.e, m('u') + 5.2);+ say(p, ['−z = −2, z = 2'], 90, 690, m('z'), { size: 34, fill: COL.task });+ }],+['q3', 'Quick check', () => {const p = panel(0);text(p, 'Quick check', 60, 110, .2, { size: 40, weight: 600 });diff --git a/site/linear-algebra/ch19/audio/en/slip.mp3 b/site/linear-algebra/ch19/audio/en/slip.mp3new file mode 100644index 0000000..7833851Binary files /dev/null and b/site/linear-algebra/ch19/audio/en/slip.mp3 differdiff --git a/site/linear-algebra/ch19/audio/en/timings.js b/site/linear-algebra/ch19/audio/en/timings.jsindex 84f4dc6..6baf7c9 100644--- a/site/linear-algebra/ch19/audio/en/timings.js+++ b/site/linear-algebra/ch19/audio/en/timings.js@@ -473,6 +473,82 @@ window.TIMINGS = {]]},+ "slip": {+ "dur": 51.552,+ "marks": {+ "eq": 2.513,+ "z": 9.961,+ "y": 15.052,+ "x": 18.607,+ "orig": 23.906,+ "c1": 29.141,+ "c2": 34.115,+ "c3": 40.039,+ "bad": 44.023+ },+ "cues": [+ [+ 0.104,+ "Why bother checking?"+ ],+ [+ 1.419,+ "Watch a slip."+ ],+ [+ 2.513,+ "Say that in the last step of elimination we worked out two minus twelve as minus five, instead of minus ten."+ ],+ [+ 9.961,+ "Then five z equals minus five, and z is minus one."+ ],+ [+ 15.052,+ "Two y plus two equals six, so y is two."+ ],+ [+ 18.607,+ "And x plus four minus one equals two, so x is minus one."+ ],+ [+ 23.906,+ "Now check minus one, two, minus one in the original equations."+ ],+ [+ 29.141,+ "Row one: minus one plus four minus one is two."+ ],+ [+ 33.346,+ "True."+ ],+ [+ 34.115,+ "Row two: minus three plus sixteen minus one is twelve."+ ],+ [+ 39.036,+ "True again."+ ],+ [+ 40.039,+ "Row three: eight minus one is seven, not two."+ ],+ [+ 44.023,+ "One false row is enough."+ ],+ [+ 45.99,+ "The real planes don't meet at the ring, so the answer is wrong."+ ],+ [+ 49.87,+ "Go back and find the slip."+ ]+ ]+ },"q3": {"dur": 2.832,"marks": {},diff --git a/site/linear-algebra/ch19/index.html b/site/linear-algebra/ch19/index.htmlindex 0edbd79..74751a5 100644--- a/site/linear-algebra/ch19/index.html+++ b/site/linear-algebra/ch19/index.html@@ -37,7 +37,7 @@ const three = (p, { A, b }, { t0 = .1, view = VIEW, meet = false } = {}) => {const lineOf23 = (sys, t0, dur = 1.6) => prog(q => sys.lines[2].e.setAttribute('stroke-width', 2.5 + 6 * Math.sin(Math.PI * q)), t0, dur, lin);// A box round a term of lin3's equations: row i (0–2), term j (0: x, 1: y, 2: z).const termBox = (p, i, j, t0, t1, color = COL.task) => {- const r = mk('rect', { x: 128 + 135 * j, y: 190 + 70 * i - 42, width: 92, height: 56, rx: 10, fill: 'none', stroke: color, 'stroke-width': 3 }, p);+ const r = mk('rect', { x: 136 + 135 * j, y: 190 + 70 * i - 42, width: 80, height: 56, rx: 10, fill: 'none', stroke: color, 'stroke-width': 3 }, p);put(r, { o: 0 }); show(r, t0, .3); if (t1) hide(r, t1, .3);return r;};@@ -133,10 +133,10 @@ const BEATS = [V.sway(5, 13);sys.focus(2, m('row'));termBox(p, 2, 2, m('row') + .8, m('div') + 3);- say(p, ['5z = −10'], 90, 450, m('div'), { size: 40, fill: YELLOW });- say(p, ['z = −10 ÷ 5 = −2'], 330, 450, m('div') + 2.6, { size: 40, fill: COL.task });+ say(p, ['5z = −10'], 90, 440, m('div'), { size: 40, fill: YELLOW });+ say(p, ['z = −10 ÷ 5 = −2'], 330, 440, m('div') + 2.6, { size: 40, fill: COL.task });V.turn({ yaw: VIEW.yaw + 15, pitch: 34 }, m('floor'), 2.5);- text(p, 'every point on the yellow plane has z = −2', 90, 790, m('floor') + 1, { size: 26, fill: YELLOW, weight: 600 });+ text(p, 'every point on the yellow plane has z = −2', 90, 490, m('floor') + 1, { size: 26, fill: YELLOW, weight: 600 });}],['middle', 'The middle row', (m) => {@@ -145,10 +145,10 @@ const BEATS = [const w = G(p, {});sys.focus([1, 2], m('eq'));termBox(p, 1, 1, m('eq') + .5, m('div') + 3);- say(w, ['2y − 2·(−2) = 6'], 90, 520, m('put') + 1.4, { size: 38 });- say(w, ['2y + 4 = 6'], 90, 580, m('sign') + 2.4, { size: 38 });- say(w, ['2y = 2'], 90, 640, m('sub4'), { size: 38 });- say(w, ['y = 1'], 330, 640, m('div') + 1.4, { size: 38, fill: COL.task });+ say(w, ['2y − 2·(−2) = 6'], 90, 560, m('put') + 1.4, { size: 38 });+ say(w, ['2y + 4 = 6'], 90, 615, m('sign') + 2.4, { size: 38 });+ say(w, ['2y = 2'], 90, 670, m('sub4'), { size: 38 });+ say(w, ['y = 1'], 330, 670, m('div') + 1.4, { size: 38, fill: COL.task });lineOf23(sys, m('line') + .4, 2); lineOf23(sys, m('line') + 3, 2);V.turn({ yaw: VIEW.yaw - 10, pitch: 28 }, m('line'), 3);S.w = w;@@ -159,11 +159,11 @@ const BEATS = [V.sway(5, 13);sys.focus(null, m('eq'));termBox(p, 0, 0, m('eq') + .5, m('pt'));- say(p, ['x + 2·1 + (−2) = 2'], 90, 720, m('put') + 1.6, { size: 38 });- say(p, ['x = 2'], 470, 720, m('x'), { size: 38, fill: COL.task });+ say(p, ['x + 2·1 + (−2) = 2'], 90, 750, m('put') + 1.6, { size: 38 });+ say(p, ['x = 2'], 470, 750, m('x'), { size: 38, fill: COL.task });show(sys.meet.e, m('pt'), .4); pulse(sys.meet.e, m('pt') + .4); pulse(sys.meet.e, m('pt') + 1.6);V.turn({ yaw: VIEW.yaw + 20 }, m('pt'), 4);- const a = chip(p, ['(2, 1, −2)'], COL.task, { x: 640, y: 628, size: 34 });+ const a = chip(p, ['(2, 1, −2)'], COL.task, { x: 690, y: 738, size: 34 });put(a, { o: 0, s: .6 }); tw(a, { o: 1, s: 1 }, m('ans'), .5, back);}],@@ -172,7 +172,7 @@ const BEATS = [text(p, 'One new unknown in each row', 60, 110, .2, { size: 40, weight: 600 });const sys = three(p, U_, { meet: true });sys.space.sway(5, 13);- const sh = path(p, 'M120 140L640 140L640 345Z', { fill: COL.task, 'fill-opacity': .1, stroke: COL.task, 'stroke-width': 2 }, { o: 0 });+ const sh = path(p, 'M106 140H500V354H374V284H239V214H106Z', { fill: COL.task, 'fill-opacity': .1, stroke: COL.task, 'stroke-width': 2, 'stroke-linejoin': 'round' }, { o: 0 });show(sh, m('look'), .5); hide(sh, m('r3') + .5, .4);termBox(p, 2, 2, m('r3'));termBox(p, 1, 1, m('r2')); termBox(p, 1, 2, m('r2') + 1.2, null, COL.dim);@@ -182,7 +182,7 @@ const BEATS = [say(p, ['pivot 0: ÷ 0 ✗'], 90, 560, m('zero'), { size: 34, fill: COL.bad });say(p, ['3x + 8y + z = 12'], 90, 660, m('orig'), { size: 40, fill: CORAL });text(p, 'three unknowns at once, none known', 90, 720, m('orig') + 2.5, { size: 28, fill: COL.dim, weight: 600 });- const ob = mk('rect', { x: 80, y: 618, width: mathW(['3x + 8y + z'], 40) + 20, height: 58, rx: 10, fill: 'none', stroke: COL.bad, 'stroke-width': 3 }, p);+ const ob = mk('rect', { x: 80, y: 618, width: mathW(['3x + 8y + z'], 40) + 6, height: 58, rx: 10, fill: 'none', stroke: COL.bad, 'stroke-width': 3 }, p);put(ob, { o: 0 }); show(ob, m('orig') + 4, .3); pulse(ob, m('orig') + 5, 1.08);}],@@ -241,7 +241,7 @@ const BEATS = [['frac', 'A fraction', (m) => {const p = panel(0);text(p, 'Fractions change nothing', 60, 110, .2, { size: 40, weight: 600 });- const sys = three(p, { A: [[1, 1, 2], [0, 2, 4], [0, 0, 4]], b: [4, 4, 2] }, { t0: m('eq') - .3 });+ const sys = three(p, { A: [[1, 1, 2], [0, 2, 4], [0, 0, 4]], b: [4, 4, 2] }, { t0: m('eq') - .3, view: { yaw: -40, pitch: 46 } });sys.meet.label('(2, 1, ½)');sys.space.sway(5, 13);sys.focus(0, m('eq') + .8); sys.focus(1, m('eq') + 3); sys.focus(2, m('eq') + 5.4);@@ -254,7 +254,7 @@ const BEATS = [say(p, ['x + 1 + 2·', F(1, 2), ' = 4, x + 2 = 4'], 90, 680, m('x') + .6, { size: 38 });say(p, ['x = 2'], 90, 760, m('x2'), { size: 38, fill: COL.task });show(sys.meet.e, m('pt'), .4); pulse(sys.meet.e, m('pt') + .4);- sys.space.turn({ yaw: VIEW.yaw + 30 }, m('z'), 14);+ sys.space.turn({ yaw: -10, pitch: 40 }, m('z'), 14);}],['q2', 'Your turn', () => {@@ -269,6 +269,34 @@ const BEATS = [() => S.sys.set({ b0: 5, b1: 2, b2: 5 }), ['b0', 'b1', 'b2']),}], done) }],+ ['slip', 'A slip, caught', (m) => {+ const p = panel(0);+ text(p, 'A slip, caught by the check', 60, 110, .2, { size: 40, weight: 600 });+ const sys = three(p, { A: U_.A, b: [2, 6, -5] }, { t0: .2, view: { yaw: -35, pitch: 26 } });+ sys.space.sway(5, 13);+ termBox(p, 2, 3, m('eq') + .3, m('z') - .2, COL.bad).setAttribute('x', 562); // the right side of row 3+ say(p, ['2 − 12 = −5 ✗ (it is −10)'], 90, 430, m('eq') + 1.2, { size: 32, fill: COL.bad });+ sys.focus(2, m('z'));+ say(p, ['5z = −5, z = −1'], 90, 490, m('z') + .4, { size: 34 });+ sys.focus([1, 2], m('y'));+ say(p, ['2y + 2 = 6, y = 2'], 90, 545, m('y') + .4, { size: 34 });+ sys.focus(null, m('x'));+ say(p, ['x + 4 − 1 = 2, x = −1'], 90, 600, m('x') + .4, { size: 34 });+ // the slipped answer, ringed; then the original system: its planes meet somewhere else+ const r = ring3(sys.space, [-1, 2, -1], '(−1, 2, −1)?');+ put(r.e, { o: 0 }); show(r.e, m('x') + 2, .4);+ sys.to(keys3(LEC), m('orig') + .4, 1.2);+ show(sys.meet.e, m('orig') + 1.6, .4);+ [['row 1: −1 + 4 − 1 = 2', 'c1', true], ['row 2: −3 + 16 − 1 = 12', 'c2', true], ['row 3: 8 − 1 = 7, not 2', 'c3', false]].forEach(([str, k, ok], i) => {+ sys.focus(i, m(k));+ say(p, [str], 90, 670 + 50 * i, m(k) + .3, { size: 30, fill: S3_ROW[i] });+ text(p, ok ? '✓' : '✗', 470, 670 + 50 * i, m(k) + 2, { size: 30, fill: ok ? COL.good : COL.bad, weight: 700 });+ });+ sys.focus(null, m('bad'));+ pulse(r.e, m('bad') + .5, 1.5); pulse(sys.meet.e, m('bad') + 2, 1.4);+ sys.space.turn({ yaw: -5, pitch: 26 }, m('orig'), 12);+ }],+['q3', 'Quick check', () => {const p = panel(0);text(p, 'Quick check', 60, 110, .2, { size: 40, weight: 600 });diff --git a/site/linear-algebra/index.html b/site/linear-algebra/index.htmlindex 9cd266b..3ae8feb 100644--- a/site/linear-algebra/index.html+++ b/site/linear-algebra/index.html@@ -73,6 +73,7 @@ Contents.book({start: { unit: 1, chapter: 1 },units: [ // [unit title, [[chapter title, minutes], ...]]['The Geometry of Linear Equations', [['One Equation, One Line', 10], ['Two Equations, One Point', 11], ['Crossing, Parallel or the Same Line', 10], ['Vectors: Arrows and Columns of Numbers', 9], ['Adding and Stretching Vectors', 10], ['Linear Combinations', 10], ['The Column Picture', 10], ['Matrices and Ax = b', 10], ['Matrix Times Vector, Two Ways', 10], ['A Matrix Moves the Whole Plane', 10], ['Three Unknowns: A Plane in Space', 12], ['Three Planes, One Point', 14], ['Three Columns in Space', 13], ['Can We Solve for Every b?', 10], ['More Numbers Than Axes', 9]]],+ ['Elimination with Matrices', [['Elimination: Two Equations', 12], ['Pivots and Multipliers', 10], ['Elimination: Three Equations', 11], ['Back Substitution', 11]]],],hues: ['#f4a48c', '#86c9e8', '#f3c95c', '#e8a0c8', '#8fd6b0', '#bba8ee', '#f0b45a'], // one colour per unit, cycling});diff --git a/site/linear-algebra/lib/elim.js b/site/linear-algebra/lib/elim.jsindex 23f836d..0c4dd23 100644--- a/site/linear-algebra/lib/elim.js+++ b/site/linear-algebra/lib/elim.js@@ -9,6 +9,7 @@// el.step(1, 0, 3, at, dur) // the label and the step: row 2 − 3 × row 1, on the beat clock// el.mult(2, at, dur) // the open operation with another multiplier (its label counts)// el.ring(0, 0, at) // a circle round an entry: the pivot+// el.diag(at); el.upper(at) // behind the numbers: the diagonal band, the upper triangle (U)// el.opNow(2, 1) // inside a question: open "row 3 − ℓ × row 2" at once//// While elim is attached, move the system through el.to(next, at, dur) (or el.step, el.mult): elim keeps the plan@@ -99,7 +100,7 @@ function elim(p, sys, { at: [x0, y0] = [130, 450], size = 46, cw = 96, rh = 70,const m = M(mh, ps, { size: fs + 2, fill: COL.chalk, anchor: 'start' });const w1 = t1.getComputedTextLength() || 80, w2 = t2.getComputedTextLength() || 14, mw = m._w || 20, frac = ps.some(q => q.f);put(t2, { x: w1 + 14 });- const mx = w1 + 14 + w2 + 16;+ const mx = w1 + 14 + w2 + 22;put(mg, { x: mx });const hgt = frac ? fs * 1.75 : fs * 1.3, ytop = frac ? -fs * 1.12 : -fs * .98;for (const [a, b] of Object.entries({ x: -9, y: ytop, width: mw + 18, height: hgt })) mbox.setAttribute(a, b);@@ -176,6 +177,24 @@ function elim(p, sys, { at: [x0, y0] = [130, 450], size = 46, cw = 96, rh = 70,return e;}const draw_ = (e, at, dur) => tw(e, { d: 1 }, at, dur);+ // Behind the numbers (so nothing is struck through): the diagonal as a soft band through the pivot places, and the+ // upper triangle as a staircase round the entries on and above it (A only, not b).+ const behind = e => { g.insertBefore(e, rowG[0]); return e; };+ const mid = i => ry(i) - size * .32;+ function diag(at, { color = COL.task, dur = .5 } = {}) {+ const e = behind(path(g, `M${cx(0)} ${mid(0)}L${cx(n - 1)} ${mid(n - 1)}`, { stroke: color, 'stroke-width': size * 1.3, 'stroke-linecap': 'round', 'stroke-opacity': .2, fill: 'none' }, { o: 0 }));+ show(e, at, dur);+ return e;+ }+ function upper(at, { color = COL.task, dur = .6 } = {}) {+ const L = j => cx(j) - cw / 2 + 2, R = cx(n - 1) + cw / 2 - 2, B = i => mid(i) + rh / 2 - 3;+ let d = `M${L(0)} ${mid(0) - rh / 2 + 3}H${R}V${B(n - 1)}`;+ for (let i = n - 1; i > 0; i--) d += `H${L(i)}V${B(i - 1)}`;+ d += `H${L(0)}Z`;+ const e = behind(path(g, d, { fill: color, 'fill-opacity': .12, stroke: color, 'stroke-opacity': .75, 'stroke-width': 2.5, 'stroke-linejoin': 'round' }, { o: 0 }));+ show(e, at, dur);+ return e;+ }// Light the entries of row i (one entry with j) for a moment.function flash(i, at, j = null) {cells[i].forEach((cl, c) => { if (j === null || j === c) { tw(cl.glow, { o: .32 }, at, .25); tw(cl.glow, { o: 0 }, at + 1.1, .6); } });@@ -299,7 +318,7 @@ function elim(p, sys, { at: [x0, y0] = [130, 450], size = 46, cw = 96, rh = 70,get plan() { return plan; },get l() { return lNow; },get op_() { return cur; },- op, opNow, mult, step, ring, line, rule, flash, focus, to, load,+ op, opNow, mult, step, ring, line, rule, flash, focus, to, load, diag, upper,scrub,// playAsk and elTask: the system's numbers plus the multiplier lget v() { return { ...sys.v, l: lNow }; },