|
[Sponsors] |
February 18, 2021, 13:01 |
How to verify AMG code?
|
#1 |
New Member
ibopaul
Join Date: Nov 2020
Posts: 12
Rep Power: 6 |
Hi, recently i made my CFD code which uses algebraic multigrid method to solve compressible Euler equation (cell-centered FVM).
I wanted to know this code works properly, by comparing with similar reference papers. However, i couldn't find appropriate reference paper which shows AMG performance(how much does calculation accelerated) while solving compressible Euler equation. Is there any way to verify AMG code? Thank you. |
|
February 18, 2021, 16:56 |
|
#2 |
Senior Member
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,286
Rep Power: 34 |
Take uniform mesh and observe the convergence. At each cycle you should be able to achieve text book efficiency. That is error should drop almost 10 times with each cycle.
This shall happen with all the cases you try with uniform and good meshes. If it does not happen then there is something wrong. I was reading a book and the author mentioned that people often get happen with say 5 to 7 times drop per cycle and think that everything is good. He says that if for simple problem it does not drop by at least a factor of 10 then you should carefully check everything and doubt what you have. |
|
February 18, 2021, 21:38 |
Thank you for reply
|
#3 |
New Member
ibopaul
Join Date: Nov 2020
Posts: 12
Rep Power: 6 |
Thank you for reply.
Can you tell me about document you've read? I think i need to study more about AMG. Thank you. |
|
February 18, 2021, 23:04 |
|
#4 | |
Senior Member
Kira
Join Date: Nov 2020
Location: Canada
Posts: 435
Rep Power: 9 |
Quote:
|
||
February 18, 2021, 23:53 |
|
#5 |
Senior Member
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,286
Rep Power: 34 |
I have been reading lots of papers and books over last 20 years so it is hard to pin point where i read that. (it goes back at least 8 years when i read it).
So I point out two most useful documents that i ever read on amg: https://www.researchgate.net/publica...al_2nd_Edition https://www.ljll.math.upmc.fr/~frey/...0multigrid.pdf Read both of them, they were very useful to me in learning it. |
|
February 19, 2021, 00:50 |
|
#6 | |
Senior Member
Kira
Join Date: Nov 2020
Location: Canada
Posts: 435
Rep Power: 9 |
Quote:
I also just found this: https://computing.llnl.gov/sites/def...05_revised.pdf where a quote from the book is "Here, solving a problem is defined as reducing the residual by 10 orders of magnitude..." |
||
February 19, 2021, 01:12 |
|
#7 |
New Member
ibopaul
Join Date: Nov 2020
Posts: 12
Rep Power: 6 |
Thank you for recommendations!
|
|
February 19, 2021, 03:44 |
|
#8 |
Senior Member
Arjun
Join Date: Mar 2009
Location: Nurenberg, Germany
Posts: 1,286
Rep Power: 34 |
Here is quote from page 56 of first document
"Diagnostic Tools As with any numerical code, debugging can be the most difficult part of creating a successful program. For multigrid, this situation is exacerbated in two ways. First, the interactions between the various multigrid components are very subtle, and it can be difficult to determine which part of a code is defective. Even more insidious is the fact that an incorrectly implemented multigrid code can perform quite well—sometimes better than other solution methods! It is not uncommon for the beginning multigrid user to write a code that exhibits convergence factors in the 0.2–0.3 range for model problems, while proper tuning would improve the factors to something more like 0.05. The difficulty is convincing the user that 0.2–0.3 is not good enough. After all, this kind of performance solves the problem in very few cycles. But the danger is that performance that is below par for model problems might really expose itself as more complexities are introduced. Diagnostic tools can be used to detect defects in a multigrid code—or increase confidence in the observed results. |
|
February 19, 2021, 05:46 |
|
#9 |
New Member
ibopaul
Join Date: Nov 2020
Posts: 12
Rep Power: 6 |
Thank you very much for detailed explanation!
I will study by reading the recommended document. Thanks again. |
|
Tags |
algebraic multigrid, verification |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Fortran->Assembly : How to remove redundant non-vectorized code? | aerosayan | Main CFD Forum | 6 | November 20, 2020 06:37 |
The FOAM Documentation Project - SHUT-DOWN | holger_marschall | OpenFOAM | 242 | March 7, 2013 13:30 |
Small 3-D code | Zdravko Stojanovic | Main CFD Forum | 2 | July 19, 2010 11:11 |
AMG versus ICCG | msrinath80 | OpenFOAM Running, Solving & CFD | 2 | November 7, 2006 16:15 |
Design Integration with CFD? | John C. Chien | Main CFD Forum | 19 | May 17, 2001 16:56 |