Live data from Hacker News

Interactive Linear Algebra (2019)

textbooks.math.gatech.edu

11–20 of 43 posts

Re: Interactive Linear Algebra (2019)

#11
post #9

Earlier quoted context omitted.

I think I prefer physical textbooks for many reasons I wont get in to... but I do really like the interactive and visualization elements computers offer. I feel like teaching kids some amount of coding to be able to play with math could be very helpful.

That's one of the intents behind Logo, see the book Mindstorms by Papert. Programming wasn't an end unto itself, but a means of exploring complex topics. Notebook-style programming is a great modern iteration of this, especially with the ability to produce interesting and complex visualizations of the underlying data and structures.

Yup, notebooks are what I had in mind. I make heavy use of mathematica when I want to explore a new topic.

Re: Interactive Linear Algebra (2019)

#12

I really wish we'd have these kind of tools when I took Linear Algebra (or many other math and engineering courses, for that mater). When I took it, it was purely proofs up and down on the blackboard, zero visualizations.

I think the trouble with LA education is that LA is just so ubiquitous and can look very different dependent on context. No style is going to suit everyones needs.

Re: Interactive Linear Algebra (2019)

#13

I really wish we'd have these kind of tools when I took Linear Algebra (or many other math and engineering courses, for that mater). When I took it, it was purely proofs up and down on the blackboard, zero visualizations.

When you took it isn't really the issue as much as where you took it. Some schools and college majors choose different ways of teaching. I liked my exposure which was over 3 courses: Calc 2 had an embedded LA course; a 2xx level computational-focused LA course (much expanded version of the 2 or 3 week Calc 2 version); a 4xx math major only proof-focused LA course.

Most students just needed the brief intro. A substantial fraction (but not the majority) got the 2xx computational form. A very small number of us took the 4xx version, and since (by then) you understood the applications there was little need to focus on computations since the interesting (to the course) bit was the higher level understanding of LA.

Re: Interactive Linear Algebra (2019)

#14
I wrote an entry on Wikipedia on visualizing the QR algorithm: https://en.wikipedia.org/wiki/QR_algorithm

The visualization helped me spot an unstable fixed point and understand the behaviour of the algorithm near eigenvalue clashes. The behaviour's quite sophisticated.

I think I wrote this there, but here goes again. The idea is that a positive-definite symmetric matrix can be visualized as an ellipse. This follows from the spectral theorem. Each iteration of the QR algorithm causes the ellipse to fall towards the x-axis, as if under the influence of gravity. The unstable fixed point corresponds to when the ellipse is standing up precariously, unable to fall in either direction. If you tilt it by just a bit, it will fall over (so the fixed point is unstable).

The case when the ellipse is nearly circular (corresponding to near eigenvalue clashes) causes the ellipse to fall over slowly. I think this also makes physical sense, if you think of it being under the influence of gravity. If you think of this near-circle as being a matrix, then this matrix is nearly equal to a scalar multiple of the identity matrix, so its eigenvalues are essentially known. The fact that the ellipse falls very slowly implies that the eigenvectors are unstable near eigenvalue clashes, but the eigenvalues are easy to find.

Note: The issues surrounding the unstable fixed point can be fixed using Wilkinson shifts. This makes each iteration into a discontinuous function, allowing all the fixed points to be stable. The issue surrounding instability of the eigenvectors near eigenvalue clashes cannot be fixed, as it's intrinsic to eigendecomposition (even of symmetric matrices). The latter difficulties can be dodged by slightly perturbing the matrix, but the resulting eigenvectors can be very different from the eigenvectors of the unperturbed matrix.

Re: Interactive Linear Algebra (2019)

#15
Being aware of the broad applications for Linear Algebra in engineering, I'm very eager to go through some Linear Algebra course on my own. But my problem is that I can't just learn from a text, even if it's interactive. I need to apply it to something.

What are some fun projects that uses LA for an individual? I'm thinking about things like generative art, if anyone knows of any artists that inspire them.

Re: Interactive Linear Algebra (2019)

#16

I've only just skimmed through this. And it's a subject I already know so I can't tell if it's actually a good resource. However, my initial impression is that I love it. I think that textbooks, math textbooks in particular, are an example where print publishing does a disservice. (I'm counting PDFs here too.) By having to lay everything out in print form, you have to clutter up your explanations with examples and fo…

> an example where print publishing does a disservice

What would be an example (in the area of learning) where it does not? In the age of pervasive computing printed text is just that - a printout. A screenshot, if you will. Not extremely useful. Even a basic 3D model of something (like a car engine) that you could simply rotate and zoom is immensely more informative than a static picture of the same object.

Text, such as a mathematical proof, too, could be made dynamic for the benefit of the student: you could hide or show references, insert notes, etc.

Static/printed content is merely an artifact of the past technology we continue clinging to for no good reason.

To say nothing about the environmental impact.

Re: Interactive Linear Algebra (2019)

#17
post #14

I wrote an entry on Wikipedia on visualizing the QR algorithm: https://en.wikipedia.org/wiki/QR_algorithm The visualization helped me spot an unstable fixed point and understand the behaviour of the algorithm near eigenvalue clashes. The behaviour's quite sophisticated. I think I wrote this there, but here goes again. The idea is that a positive-definite symmetric matrix can be visualized as an ellipse. This follows…

> a positive-definite symmetric matrix can be visualized as an ellipse.

It is clear that you mean the ellipsoid as a set of points {x | x^T * A * x = 1} (or some other constant). There is another way in which all square matrices define an ellipsoid based on how the matrix transforms a unit sphere: {A*x | x^T * x = 1} (different matrices can map to the same ellipse here, however).

I always like to clarify which one.

(I unfortunately do not have intuition for the QR algorithm, but I am distracted by the description of an ellipse falling, as if it's rolling against the x-axis)

Re: Interactive Linear Algebra (2019)

#18
post #14

I wrote an entry on Wikipedia on visualizing the QR algorithm: https://en.wikipedia.org/wiki/QR_algorithm The visualization helped me spot an unstable fixed point and understand the behaviour of the algorithm near eigenvalue clashes. The behaviour's quite sophisticated. I think I wrote this there, but here goes again. The idea is that a positive-definite symmetric matrix can be visualized as an ellipse. This follows…

Since you mentioned QR, I want to link [1] to one of my favorite articles, which explains how to use the QR decomposition to sample a random orthogonal matrix uniformly at random. The basic idea, of course, is that if A is a random matrix, and we compute A = QR, then Q is a random orthogonal matrix. But with what distribution? Well, it turns out to be almost uniform (according to Haar measure), but there are some density issues. A simple scaling of QR decomposition resolves the issue.

When I was a TA I loved giving this as an example to students. It's a great teaser for the rabbit hole that is random matrix theory.

[1] Mezzadri 2002, "How to Generate Random Matrices from the Classical Compact Groups" (http://www.ams.org/notices/200705/fea-mezzadri-web.pdf)

Re: Interactive Linear Algebra (2019)

#19
post #15

Being aware of the broad applications for Linear Algebra in engineering, I'm very eager to go through some Linear Algebra course on my own. But my problem is that I can't just learn from a text, even if it's interactive. I need to apply it to something. What are some fun projects that uses LA for an individual? I'm thinking about things like generative art, if anyone knows of any artists that inspire them.

One possible perspective: thinking of images as a vector space, and thinking of image operations like blurring, sharpening, and even any spatial transformation as linear operators (representable as matrices).

This perspective is most straightforward with a 1-dimensional domain, like an audio signal, or the temperature along a thin rod, because there's a clear way to organize all the values in a vector, e.g. all the audio samples are just in sequence. So if that's appealing to you at all, I would recommend that first. You can do filtering (like with an "equalizer") and add effects like echo/reverb as linear operations.

I think that it is particularly fun to think of some ground-truth signal that is corrupted by an echo in a room and a microphone that attenuates some frequencies, and trying to undo that corruption.

Re: Interactive Linear Algebra (2019)

#20

I've only just skimmed through this. And it's a subject I already know so I can't tell if it's actually a good resource. However, my initial impression is that I love it. I think that textbooks, math textbooks in particular, are an example where print publishing does a disservice. (I'm counting PDFs here too.) By having to lay everything out in print form, you have to clutter up your explanations with examples and fo…

> I think that textbooks, math textbooks in particular, are an example where print publishing does a disservice. (I'm counting PDFs here too.) By having to lay everything out in print form, you have to clutter up your explanations with examples and footnotes that take up physical room. .

I agree with your sentiment. Although, I believe there is bit of problem of generalizing it to a wider field. Surely, you can make explorables with Linear Algebra, Trigonometry, Geometry, Number Theory etc, but there still exists a lot of mathematical fields, where such explanation using visualization is pretty difficult. It takes a lot of time to come up good explanations, while even longer for interactive explorables.

> All in all, I'd love to see more interactive textbooks. We've got this really expressive kind of document via the web. I think we should be taking advantage of it more.

This is something I have spent the last 4 years of my life building. I designed an alternative way of writing interactive books that takes a different approach than using just explorables. It's a conversational way of learning subjects designed for auto-didacts.

You interact (converse?) with the book and learn gradually. You can of course embed explorables into it (which I am planning to for upcoming linear algebra / discrete mathematics course), but the general process can still be generalized to any field. And if you are a LaTeX fan, you are in luck as all your notes are compiled as a Tufte-Latex Notebook. The medium is called Primer, homage to the diamond age.

You can checkout Primer here https://primerlabs.io.

A comic-based guide to understand how Primer helps you learn effectively: https://primerlabs.io/comics/introducing-primer-comics/

Post reply on HN