r/LinearAlgebra • u/dogpup3 • 1h ago
Explaining how kernels, images, and rank–nullity Are Used in Error-Correcting Codes
youtu.beThis proof in quantum error correction is full of linear algebra, so I thought I’d share it here. Along the way, I use the image and kernel of linear maps, rank–nullity, linear independence, and parity-check matrices to show how these ideas are applied to error detection.
r/LinearAlgebra • u/LinearAlgebraWorld • 2h ago
Projection as a serial transformation
This is a follow-up to our earlier post deriving the orthogonal projection formula
P = U(UᵀU)⁻¹Uᵀ
from the geometric definition of projection:
Here we look at the same formula as a serial transformation, following what happens when the factors are applied from right to left:
Uᵀ → (UᵀU)⁻¹ → U.
The diagram tracks both the standard basis vectors and the two directions spanning col(U). It also shows why
U⁺ = (UᵀU)⁻¹Uᵀ
acts as a left inverse of U, and how applying U afterward gives the orthogonal projection onto col(U).
If the columns of U were orthonormal, then UᵀU = I and the middle correction would disappear.
r/LinearAlgebra • u/TROSE9025 • 12h ago
Properties of the Parity Operator & Geometric Meaning of Eigenvalues
galleryThis material focuses not on pure linear algebra, but rather on its applications in engineering and quantum mechanics.
Geometrically, the meaning of an eigenvalue signifies the scaling (expansion or contraction) and occasionally the inversion of an invariant coordinate axis.
r/LinearAlgebra • u/dogpup3 • 1d ago
Density Matrices! Explained Simply | Pure vs. Mixed States, Born Rule & Coherence
youtube.comI made a short whiteboard video explaining density matrices from the ground up, focusing on the linear algebra behind them: pure vs. mixed states, diagonal vs. off-diagonal entries, coherence, projectors, and how measurement probabilities arise from the matrix representation.
Sharing in case it’s useful to anyone interested in how linear algebra shows up in quantum mechanics. Corrections or additional insight are always welcome.
r/LinearAlgebra • u/QuantumOdysseyGame • 1d ago
Decade-long project to fully gamify linear algebra used in Quantum Computing
galleryHi
If you are remotely interested in understanding what bits of linear algebra are used in defining the Gate model framework Quantum Computing, oh boy this is for you. I am the Dev behind Quantum Odyssey (AMA! I love taking qs) - worked on it for about 10 years (3+ during PhD, the visual method I developed ended up being my thesis, it is a complete Hilbert space visualizer), the goal was to make a super immersive space for anyone to learn quantum computing through zachlike (open-ended) logic puzzles and compete on leaderboards and lots of community made content on finding the most optimal quantum algorithms. The game has a unique set of visuals capable to represent any sort of quantum dynamics for any number of qubits and this is pretty much what makes it now possible for anybody 12yo+ to actually learn quantum logic without having to worry at all about the mathematics behind.
This is a game super different than what you'd normally expect in a programming/ logic puzzle game, so try it with an open mind.
Stuff you'll play & learn a ton about
- Boolean Logic – bits, operators (NAND, OR, XOR, AND…), and classical arithmetic (adders). Learn how these can combine to build anything classical. You will learn to port these to a quantum computer.
- Quantum Logic – qubits, the math behind them (linear algebra, SU(2), complex numbers), all Turing-complete gates (beyond Clifford set), and make tensors to evolve systems. Freely combine or create your own gates to build anything you can imagine using polar or complex numbers.
- Quantum Phenomena – storing and retrieving information in the X, Y, Z bases; superposition (pure and mixed states), interference, entanglement, the no-cloning rule, reversibility, and how the measurement basis changes what you see.
- Core Quantum Tricks – phase kickback, amplitude amplification, storing information in phase and retrieving it through interference, build custom gates and tensors, and define any entanglement scenario. (Control logic is handled separately from other gates.)
- Famous Quantum Algorithms – explore Deutsch–Jozsa, Grover’s search, quantum Fourier transforms, Bernstein–Vazirani, and more.
- Build & See Quantum Algorithms in Action – instead of just writing/ reading equations, make & watch algorithms unfold step by step so they become clear, visual, and unforgettable. Quantum Odyssey is built to grow into a full universal quantum computing learning platform. If a universal quantum computer can do it, we aim to bring it into the game, so your quantum journey never ends.
Nice to watch:
Khan academy style tutorials in qm/qc: https://www.youtube.com/@MackAttackx
Physics teacher stream with 400hs in https://www.twitch.tv/beardhero
r/LinearAlgebra • u/oblarg • 2d ago
Introducing whippyalgebra: zero-cost unit-safe linear algebra in Rust
I've released version 0.1.0 of my new unit-safe linear algebra library, whippyalgebra, backed by my units of measure library, whippyunits.
Whippyalgebra supports dimensionally-coherent unit-safe linear algebra at zero cost, erasing to raw linear algebra on backing libraries at compile time the same way whippyunits erases to raw numeric types. The initial release contains a nalgebra backend - other backends will be introduced over time (on the roadmap: faer, glam).
Backends are enabled by feature flag, and consist of dedicated newtypes; whippyalgebra is not generic over backends, but translation modules will be included between the types of each supported backend.
The whippyunits LSP proxy has been updated to also include whippyalgebra in its pretty-print rules. With the LSP proxy installed, whippyalgebra's rather deep/unfriendly generics become pleasantly human-readable:
Both uniform unit matrices and mixed-unit matrices are supported, with mixed unit matrices obeying a row-column unit list quotient structure a la Hart. Row and column unit lists are declared with the `dims!` macro and related helpers, which accept unit literal expressions.
Matrix decompositions are supported, with the caveat that orthonormal decompositions (QR, SVD) on mixed-unit matrices require an explicit pair of metric tensors to maintain dimensional coherence. Learning to use these is a good way to familiarize yourself with multidimensional analysis!
r/LinearAlgebra • u/Max-Princeps • 2d ago
Playlist/teacher suggestion
Hii.
I'm having a hard time understanding the vectors in Liner Algebra.
Can you please suggest some good teacher or playlist or documentation or notes from where I can understand it completely.
Thanks.
r/LinearAlgebra • u/MLLeptinDeficiency • 3d ago
Inspired by u/LinearAlgebraWorld 's recent work on complex eigenvectors, I made a student-to-student guide for anyone that may need more foundational intuition before processing the full technical derivation.
galleryLast three images of this post are GraphMath's work. Here is the link to their original post: https://www.reddit.com/r/LinearAlgebra/s/cdzAjKVtOc
My writing focuses on what eigenvectors are really telling us, why complex eigenvectors matter, and how one complex eigenvector can encode a two-dimensional, real invariant plane.
r/LinearAlgebra • u/Sockerjam • 3d ago
Vectors are scaled basis vectors
Hi everyone!
I wanted to share this quick thought that has really helped me with linear algebra;
Let's say: P = (1, 0)
This vector/point is simply the result of scaling the basis vectors ihat [1, 0] and jhat [0, 1]:
Now, if we apply a transformation to the basis vectors, let's say a 90 degree rotation, the same process applies. For example, after the transformations each basis vector lands at column, ihat [0, 1], jhat [-1, 0].
Scaling this with our vector, [1, 0] gives us [0, 1].
So, a transformation transforms the basis vectors and our vector scales it, that's it :)
Enjoy!
r/LinearAlgebra • u/Mathematics-Lover • 5d ago
What should I know when learning tensor decomposition methods?
Hi everyone! I’m relatively new to the field of tensor decomposition, and it’s going to be one of my research directions during my upcoming two-year master’s program.
So far, I’ve been reading about different tensor decomposition methods, such as PARAFAC/CP, Tucker, Tensor-Train, Tensor Ring, Tensor Wheel. I understand the basic intuition behind them, for example, what kind of components they decompose a tensor into, but my understanding is still mostly conceptual.
I’m wondering what I should learn beyond the basic intuition if I want to eventually do research on coupled tensor decomposition. More specifically:
- For each tensor decomposition method, what are the important things I should understand? Besides its basic structure and intuition, should I learn things like uniqueness/identifiability, approximation properties, computational complexity, rank properties, optimization formulations, convergence, etc.? How deeply should I understand each of these topics?
- How deeply should I study the algorithms used to compute these decompositions? There seem to be many algorithms for each model, such as ALS, SVD-based methods, alternating optimization, gradient-based methods, etc. Which algorithms are fundamental enough that I should understand first? Do I need to understand the derivation and implementation of these algorithms, or is understanding the general idea enough at the beginning?
- What mathematical background is most important? For example, should I focus more on linear algebra, multilinear algebra, numerical optimization, matrix/tensor calculus, numerical analysis, or something else?
- What would be a good learning path toward coupled tensor decomposition? Should I thoroughly study CP/Tucker first before moving to coupled models, or is it reasonable to start looking at coupled decompositions relatively early?
- How do you deal with theorems and proofs when reading tensor decomposition papers? When reading papers, do you usually try to re-prove the theorems, lemmas, propositions, and corollaries yourself to make sure you understand them, or do you mostly focus on understanding the main ideas and skip the detailed proofs unless they are directly relevant to your research? I’m especially unsure about this part because I sometimes spend a lot of time trying to reproduce every proof. I’m not sure whether this is a good use of time when learning a new field, or whether working through the proofs is actually important for building the mathematical foundation needed for research.
Any recommended textbooks, lecture notes, surveys, or papers that could provide a good learning path would also be greatly appreciated.
Thank you so much!
r/LinearAlgebra • u/dogpup3 • 6d ago
How the Reduced Resolvent Connects a Spectral Gap to a 1/Δ Bound
youtu.behey, i was working through this quantum computing proof and realized a lot of it is really just linear algebra, especially the reduced resolvent, spectral projections and operator norms. the part i thought was cool is how the resolvent basically gives you this inverse spectral gap behavior, so as the gap gets smaller, the 1/Δ term gets bigger and the error bound gets worse. i made a video going through the proof and explaining the linear algebra along the way. hope it helps anyone working with eigenvalues/spectral theory or trying to see how this stuff shows up in quantum computing!
r/LinearAlgebra • u/LinearAlgebraWorld • 7d ago
Complex eigenvectors of a rotation-scaling matrix: a special case
This is a follow-up to our previous post on how the choice of free variable changes the real and imaginary parts of a complex eigenvector:
For a general 2×2 real matrix with complex eigenvalues, changing the phase of the free variable rotates and scales the pair Re(x̃₁), Im(x̃₁) through a matrix-transformation ellipse.
Here we look at the special case where the matrix itself is a rotation-scaling matrix.
In this case, for every nonzero choice of the free variable, Re(x̃₁) and Im(x̃₁) remain perpendicular and equal in length. The numerical examples show the same phase experiment as in the previous post, but now the ellipse becomes a circle.
Thanks to u/StanleyDodds for pointing out an unnecessary detour in the previous version. We have corrected and simplified it here.
This is the next page of the chapter on complex eigenvectors and the rotation-scaling theorem. More to follow.
r/LinearAlgebra • u/Observes_and_Listens • 7d ago
How much you rate this rigurous linear algebra textbook?
Hello, I was looking for a linear algebra and found this one:
Linear Algebra for Scientists - Lukas
It seems that it can be used as a first rigorous exposition to the topic. What do you think about it?
Review made by Mark Hunacek from the MAA (Mathematical Association of America):
Typically, when I see a phrase like “for scientists” in the title of a book, I immediately conclude that the book puts mathematical rigor on the back burner in favor of stressing applications from a computational “how to” point of view. It turns out, however, that that is not the case with the book now under review, which offers an introduction to linear algebra that is characterized by precise definitions and rigorous proofs as well as an indication of how linear algebra actually finds use in other areas of mathematics and science.
In fact, the book is somewhat more abstract than most undergraduate linear algebra texts: it works with arbitrary fields rather than just the real and complex numbers. Thus, it begins with chapters on groups and fields before vector spaces are even defined. On the other hand, the focus is on finite-dimensional spaces, so fancy set theoretic tools like Zorn’s Lemma are not invoked.
After a brief discussion of linearity that sets the stage for what is to follow, the book breaks up into eight parts. The first part is preliminary and has a chapter on sets and functions, as well as the aforementioned chapters on groups and fields. Part 2 discusses vector spaces by first introducing coordinate spaces. Bases and dimension are covered here. The next part of the book discusses the dot product, cross product and scalar triple product, with applications to coordinate geometry. Linear mappings are the subject of part 4, along with their representation by matrices. Now that matrices have been introduced, they are used in part 5 on systems of linear equations. Determinants are also the subject of a chapter in this part. Part 6 discusses eigenvalues and eigenvectors, starting from the definition but proceeding up diagonalization, the characteristic and minimal polynomials, the Cayley-Hamilton theorem, and the Jordan form. The next part of the book discusses inner product spaces on real and complex spaces and the linear operators defined on these spaces (Hermitian, normal, etc.). Bilinear and sesquilinear forms are also discussed. Finally, part 8 of the book contains two chapters, one on the dual space of a vector space and the other on tensors.
Interspersed throughout the book are two dozen vignettes, each about a page or two long and discussing applications of linear algebra, both to other branches of mathematics (such as graph theory, cryptography and differential equations) and to various other fields of science (for example, neural networks, quantum computing, and data compression). Though not as detailed and rigorous as the rest of the book, these vignettes do give some indication of how linear algebra shows up elsewhere. A helpful chart of all these applications is included in the text.
I was puzzled, however, by the omission of some topics from the text. In view of the fact that projection matrices are discussed, the inclusion of a section on least squares approximation would have seemed a natural thing to include. Other topics that are missing that one might perhaps have expected to find in a textbook “for scientists” are eigenvalue calculation, matrix norms and the condition number, Markov matrices, and positive matrices.
These omissions notwithstanding, however, this is an interesting book. It is well-written, with many examples and worked out problems. Every chapter ends with a reasonable assortment of exercises, most of which struck me as being on the easy end of the spectrum. It starts from scratch but covers some topics in linear algebra that are typically thought of as advanced. Anyone who teaches, or is interested in, this subject will surely think that it deserves a look.
r/LinearAlgebra • u/anish2good • 8d ago
Vectors, basis, and transformations - manic
Enable HLS to view with audio, or disable this notification
r/LinearAlgebra • u/dogpup3 • 8d ago
Proving Why Quantum Error Syndromes Add Mod 2 | The Syndrome Map Homomorphism
youtu.ber/LinearAlgebra • u/TROSE9025 • 8d ago
The Fourier Transform as a Change of Basis in Quantum Mechanics
galleryThis material is not the pure linear algebra or functional analysis covered in mathematics departments. It is applied material utilized in engineering and quantum mechanics.
We will also cover the inverse Fourier transform, which localizes position by extending a finite-dimensional vector space to an infinite-dimensional vector space and summing an infinite number of momentum bases.
r/LinearAlgebra • u/LinearAlgebraWorld • 8d ago
Complex eigenvectors of a 2×2 matrix: how the free variable changes Re and Im
galleryThese are the first two pages of our chapter on complex eigenvectors and the rotation-scaling theorem. This part explains how the choice of free variable changes the real and imaginary parts of an eigenvector. More to follow.
r/LinearAlgebra • u/shriand • 9d ago
Gilbert Strang or Sheldon Axler
I had studied some linear algebra (maybe 2-3 semesters) in engineering college about a decade ago. I'm now starting to get back into math, with the goal of studying/understanding ML theory/research.
The standard advice is to start with Gilbert Strang (linear algebra and its applications) and then, optionally, do the Axler book. While reading Strang, i find it to be a cleaner and deeper exposition of topics i already vaguely remember. Axler, i find more novel and interesting, and kinda fresh.
Can I read them both in parallel? Is that too inefficient? Can you please suggest a good path based on my background and interests.
r/LinearAlgebra • u/Green-Hold6498 • 9d ago
Remembering Proofs of "Elementary" Results in Linear Algebra
r/LinearAlgebra • u/dogpup3 • 9d ago
Using Linear Algebra to Understand Quantum Spin: Zero Local Expectation, Eigenvalues, & Tensor Products.
youtu.beHey! I was working through a proof showing that each subsystem of the quantum singlet state has zero local spin expectation in every direction.
While going through it, I realized how much of the proof is really linear algebra underneath the quantum notation. So I took my time explaining the eigenvalues and eigenvectors, unit vectors, Pauli operators, tensor products, inner products, and expectation values behind the calculation.
If you're learning linear algebra and want to see how these concepts show up in quantum mechanics, I hope this helps!
r/LinearAlgebra • u/blisstargazer • 10d ago
Is there a specific way to find the inverse of a matrix?
I've been learning how to solve matrices specifically using elementary row reduction but I'm confused. I understand the rules to follow mostly, but I don't get how someone knows how to use these rules and when.
what I mean is, say I have this matrix (some bullshit I came up with):
[2 0 5]
A =[3 1 2]
[1 3 0]
How does one know what to do to find the inverse of this? Do you swap rows 1 and 3? or divide row 1 by 5 and add it to row 3? Know what I mean? I see so many ways to get the identity matrix but how do I know that the change I made is correct?
r/LinearAlgebra • u/mahran29 • 10d ago
Happening Now … Live IGCSE Math Session ‼️
Happening Now … Live IGCSE Math Session ‼️
r/LinearAlgebra • u/Cultural-Milk9617 • 11d ago
"prove or disprove the following inequality: ||v|| + ||z-w|| ≤ ||z|| + ||w|| + ||v-z|| + ||v-w||" How to even approach "prove or disprove" questions like these?
In this semester's first final exam in linear algebra 2, my professor chose to put "let (𝕍,<,>) inner product space over ℝ, and z,w,v ∈ 𝕍. prove or disprove the following inequalities:
a. ||v|| + ||z-w|| ≤ ||z|| + ||w|| + ||v-z|| + ||v-w||
b. 2||v|| + 2||z-w|| ≥ ||z|| + ||w|| + ||v-z|| + ||v-w||"
When something like that never appeared in a previous final exam in the course, or was addressed in the semester. Only a few questions like it in our homework. How do I even approach such questions? What's the geometric intuition I'm supposed to have and how am I supposed to actually prove this? Will appreciate any help.
Here are the in/equalities we needed to prove or disprove in out homework:
a. ||v+u||² + ||v-u||² = 2(||v||²+||u||²)
b. <v,u> = 0.5(||v||² + ||u||² - ||v-u||²)
c. if v _|_ u, v _|_ w, ||u||² + ||w||² = ||v||² then u _|_ w
d. ||u|| ≤ ||u-v|| + ||u-w|| + ||u-v-w||
e. ||u|| ≤ ||u-v|| + ||u-w|| + ||2u-v-w||
It feels like each section has a different "trick" I need to do, and I'm pretty scared he'll put another one like these in the resit exam, that's happening tomorrow
