Why renumbering works for LduMatrix?

 Register Blogs Members List Search Today's Posts Mark Forums Read

 July 30, 2017, 11:16 Why renumbering works for LduMatrix? #1 Member   Di Cheng Join Date: May 2010 Location: Beijing, China Posts: 47 Rep Power: 15 AFAIK, renumbering works for sparse matrix to reduce its band width if it is stored as array of diagonals data structure. However, for lduMatrix format used by OpenFOAM, it seems meanlingless to use renumbering because it does not reduce the operations (at least for matrix-vector product) performed by the solvers. From the point of view of linear algebra, reordering does not change the eigen value of matrix hence its condition number. So I am confused that why renumbering works for LduMatrix? We know that each algorithm is also working with data structure. For lduMatrix data structure, how can we find the optimality of its algorithm?

 July 31, 2017, 02:55 #2 Senior Member   Hrvoje Jasak Join Date: Mar 2009 Location: London, England Posts: 1,899 Rep Power: 32 Hi, You need to read up on iterative solvers. For direct solvers, ordering formally makes no difference, although what Gauss elimination does includes pivoting - which is the same as renumbering. You get 2 benefits from renumbering: fixed point iterations work better because the updated neighborhood is richer; also, computers run faster because you increased the cache hit rate. However in FVM, unlike FEM, the benefit isn't huge. Hrv __________________ Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk

 July 31, 2017, 04:22 #3 Member   Di Cheng Join Date: May 2010 Location: Beijing, China Posts: 47 Rep Power: 15 Thanks for your explanation, I did not count the cache hit rate. Considering cache hit rate, the same amount of operations can be completed faster. I am still little confused by the fixed point iterations. Think about a Gauss-Seidel iteration. x_new=inv(L+D)*U*x_old. You said "working better because the updated neighborhood is richer". Does it mean making eigen values of (inv(L+D)*U) smaller, though the eigen value set of (L+D+U) does not change during renumbering?

 July 31, 2017, 10:28 #4 Senior Member   Hrvoje Jasak Join Date: Mar 2009 Location: London, England Posts: 1,899 Rep Power: 32 Please consult a book: cell renumbering and order of equations influences the performance of Guass-Seidel sweeps. Consider for example red-black renumbering, which reduces Gauss Seidel to (almost) point Jacobi sweep. Reduced matrix band increases the number of equation neighbours that have already been visited, and thus influences the efficiency of the algorithm. May I recommend the numerical linear algebra course I hold at Uni Zagreb. Hrv __________________ Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk

 July 31, 2017, 18:54 #5 Member   Di Cheng Join Date: May 2010 Location: Beijing, China Posts: 47 Rep Power: 15 Thanks for your reply. But I cannot find the book, could you give me the ISBN or DOI? Or the webpage relating to your numerical linear algebra course. I am currently looking for algorithms which is extremely scalable and matrix free. I can see the benefits of more updated neighbours. Just like the GS iteration is almost two times faster than Jacobi iteration because the spectrum of iterative matrix of GS iteration is half of Jacobi iteration and hence the residual decreases faster. From viewpoint of information theory, more updated neighbour means faster horizontal broadcast of information. Higher cache hit rates also means higher vectical information transimission speed. I am just curious about if there is some proof or experiment data about the acceleration factor of renumbering on both effects. For unpreconditioned Krylov-type solver which only uses matrix-vector product, the renumbering should only benefits from increased cache hit rates. I will try to do some test on it.

 Tags openfoam, renumbering