Normally, this boards sees a lot of traffic about the most efficient and most powerful solvers for huge linear equation systems. But this time, I have the opposite problem:
I need to implement a solver for a linear equation system in a very limited programming system that offers only basic array functionality and no linear algebra whatsoever. Efficiency and scalability is not an issue as the systems have a single-digit number of unknowns. What is way more important is that it's easy to implement and to fully understand with the most basic linear algebra knowledge.
So I'm looking for the simplest algorithm for:
- Direct solution of the system
Ax = b
with a full rank A - Iterative solution of the system
Ax = b
with A not necessarily full rank, but with a good initial guess for x.
Eigen
) do this for small fixed sizes such as 4x4, as it is also the fastest method. $\endgroup$